mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-19 16:27:13 +02:00
quad implemented
This commit is contained in:
@ -238,19 +238,42 @@ public:
|
||||
|
||||
/**
|
||||
* Send Message Header
|
||||
* @param buf message
|
||||
* @param length length of message
|
||||
* @param dummy true if end of acquistion else false
|
||||
* @param index self index for debugging
|
||||
* @param dummy true if a dummy message for end of acquisition
|
||||
* @param jsonversion json version
|
||||
* @param dynamicrange dynamic range
|
||||
* @param fileIndex file or acquisition index
|
||||
* @param ndetx number of detectors in x axis
|
||||
* @param ndety number of detectors in y axis
|
||||
* @param npixelsx number of pixels/channels in x axis for this zmq socket
|
||||
* @param npixelsy number of pixels/channels in y axis for this zmq socket
|
||||
* @param imageSize number of bytes for an image in this socket
|
||||
* @param frameNumber current frame number
|
||||
* @param expLength exposure length or subframe index if eiger
|
||||
* @param packetNumber number of packets caught for this frame
|
||||
* @param bunchId bunch id
|
||||
* @param timestamp time stamp
|
||||
* @param modId module Id
|
||||
* @param row row index in complete detector
|
||||
* @param column column index in complete detector
|
||||
* @param reserved reserved
|
||||
* @param debug debug
|
||||
* @param roundRNumber not used yet
|
||||
* @param detType detector enum
|
||||
* @param version detector header version
|
||||
* @param gapPixelsEnable gap pixels enable (exception: if gap pixels enable for 4 bit mode, data is not yet gap pixel enabled in receiver)
|
||||
* @param flippedData int array of 2 elements for x and y, if it is flipped across x or y axis
|
||||
* @param additionalJsonHeader additional json header
|
||||
* @returns 0 if error, else 1
|
||||
*/
|
||||
int SendHeaderData ( int index, bool dummy, uint32_t jsonversion, uint32_t dynamicrange = 0, uint64_t fileIndex = 0,
|
||||
uint32_t npixelsx = 0, uint32_t npixelsy = 0, uint32_t imageSize = 0,
|
||||
uint32_t ndetx = 0, uint32_t ndety = 0, uint32_t npixelsx = 0, uint32_t npixelsy = 0, uint32_t imageSize = 0,
|
||||
uint64_t acqIndex = 0, uint64_t fIndex = 0, char* fname = NULL,
|
||||
uint64_t frameNumber = 0, uint32_t expLength = 0, uint32_t packetNumber = 0,
|
||||
uint64_t bunchId = 0, uint64_t timestamp = 0,
|
||||
uint16_t modId = 0, uint16_t row = 0, uint16_t column = 0, uint16_t reserved = 0,
|
||||
uint32_t debug = 0, uint16_t roundRNumber = 0,
|
||||
uint8_t detType = 0, uint8_t version = 0, int* flippedData = 0,
|
||||
uint8_t detType = 0, uint8_t version = 0, int gapPixelsEnable = 0, int* flippedData = 0,
|
||||
char* additionalJsonHeader = 0) {
|
||||
|
||||
|
||||
@ -261,6 +284,7 @@ public:
|
||||
"\"jsonversion\":%u, "
|
||||
"\"bitmode\":%u, "
|
||||
"\"fileIndex\":%llu, "
|
||||
"\"detshape\":[%u, %u], "
|
||||
"\"shape\":[%u, %u], "
|
||||
"\"size\":%u, "
|
||||
"\"acqIndex\":%llu, "
|
||||
@ -283,11 +307,12 @@ public:
|
||||
"\"version\":%u, "
|
||||
|
||||
//additional stuff
|
||||
"\"gappixels\":%u, "
|
||||
"\"flippedDataX\":%u"
|
||||
|
||||
;//"}\n";
|
||||
int length = sprintf(buf, jsonHeaderFormat,
|
||||
jsonversion, dynamicrange, fileIndex, npixelsx, npixelsy, imageSize,
|
||||
jsonversion, dynamicrange, fileIndex, ndetx, ndety, npixelsx, npixelsy, imageSize,
|
||||
acqIndex, fIndex, (fname == NULL)? "":fname, dummy?0:1,
|
||||
|
||||
frameNumber, expLength, packetNumber, bunchId, timestamp,
|
||||
@ -295,6 +320,7 @@ public:
|
||||
detType, version,
|
||||
|
||||
//additional stuff
|
||||
gapPixelsEnable,
|
||||
((flippedData == 0 ) ? 0 :flippedData[0])
|
||||
);
|
||||
if (additionalJsonHeader && strlen(additionalJsonHeader)) {
|
||||
|
Reference in New Issue
Block a user