25 for (
i = 0;
i <= nspigot;
i++) {
44 for (
int i = 0;
i < 3;
i++)
57 unsigned char LRB_error_word) {
64 spigotInfo[spigot_id] |= (LRB_error_word << 16) | ((
data.getErrorsWord() & 0xFF) << 24);
67 ctdch0 |= (1 << (spigot_id + 14));
69 unsigned int lenSoFar = 0;
70 for (
unsigned int i = 0;
i < spigot_id;
i++)
72 unsigned short* startingPoint =
73 ((
unsigned short*)
this) +
sizeof(
CastorCTDCHeader) /
sizeof(
unsigned short) + lenSoFar * 2;
74 memcpy(startingPoint,
data.getRawData(),
sizeof(
unsigned short) *
data.getRawLength());
76 lenSoFar +=
data.getRawLength() / 2;
77 uint32_t* trailer = ((uint32_t*)
this) +
sizeof(
CastorCTDCHeader) /
sizeof(uint32_t) + lenSoFar;
80 trailer[0] = 0xA0000000u | len64;
84 unsigned int spigot_id = 2;
92 ctdch0 |= (1 << (spigot_id + 14));
94 unsigned int lenSoFar = 0;
95 for (
unsigned int i = 0;
i < spigot_id;
i++)
97 unsigned short* startingPoint =
98 ((
unsigned short*)
this) +
sizeof(
CastorCTDCHeader) /
sizeof(
unsigned short) + lenSoFar * 2;
99 memcpy(startingPoint,
data.getRawData(),
sizeof(
unsigned short) *
data.getRawLength());
101 lenSoFar +=
data.getRawLength() / 2;
102 uint32_t* trailer = ((uint32_t*)
this) +
sizeof(
CastorCTDCHeader) /
sizeof(uint32_t) + lenSoFar;
105 trailer[0] = 0xA0000000u | len64;
void adoptData(const unsigned short *data, int length)
char data[epos_bytes_allocation]