bit field for missing packets, added commands r_padding and r_discardpolicy, hdf5 bitfield metadata left to do

This commit is contained in:
2018-07-05 13:47:20 +02:00
parent ca8cb33569
commit c366e94a96
28 changed files with 796 additions and 451 deletions

View File

@ -103,6 +103,18 @@ class UDPBaseImplementation : protected virtual slsReceiverDefs, public UDPInter
*/
uint32_t getFramesPerFile() const;
/**
* Get Frame Discard Policy
* @return Frame Discard Policy
*/
frameDiscardPolicy getFrameDiscardPolicy() const;
/**
* Get Partial Frame Padding Enable
* @return Partial Frame Padding Enable
*/
bool getFramePaddingEnable() const;
/**
* Get Scan Tag
* @return scan tag //FIXME: needed? (unsigned integer?)
@ -368,6 +380,18 @@ class UDPBaseImplementation : protected virtual slsReceiverDefs, public UDPInter
*/
void setFramesPerFile(const uint32_t i);
/**
* Set Frame Discard Policy
* @param i Frame Discard Policy
*/
void setFrameDiscardPolicy(const frameDiscardPolicy i);
/**
* Set Partial Frame Padding Enable
* @param i Partial Frame Padding Enable
*/
void setFramePaddingEnable(const bool i);
/**
* Set Scan Tag
* @param i scan tag //FIXME: needed? (unsigned integer?)
@ -638,52 +662,25 @@ class UDPBaseImplementation : protected virtual slsReceiverDefs, public UDPInter
*/
void registerCallBackAcquisitionFinished(void (*func)(uint64_t, void*),void *arg);
/**
* Call back for raw data
* args to raw data ready callback are
* frameNumber is the frame number
* expLength is the subframe number (32 bit eiger) or real time exposure time in 100ns (others)
* packetNumber is the packet number
* bunchId is the bunch id from beamline
* timestamp is the time stamp with 10 MHz clock
* modId is the unique module id (unique even for left, right, top, bottom)
* xCoord is the x coordinate in the complete detector system
* yCoord is the y coordinate in the complete detector system
* zCoord is the z coordinate in the complete detector system
* debug is for debugging purposes
* roundRNumber is the round robin set number
* detType is the detector type see :: detectorType
* version is the version number of this structure format
* dataPointer is the pointer to the data
* dataSize in bytes is the size of the data in bytes.
*/
void registerCallBackRawDataReady(void (*func)(uint64_t, uint32_t,
uint32_t, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t,
uint16_t, uint32_t, uint16_t, uint8_t, uint8_t,
char*, uint32_t, void*),void *arg);
/**
* Call back for raw data
* args to raw data ready callback are
* sls_receiver_header frame metadata
* dataPointer is the pointer to the data
* dataSize in bytes is the size of the data in bytes.
*/
void registerCallBackRawDataReady(void (*func)(char* ,
char*, uint32_t, void*),void *arg);
/**
* Call back for raw data (modified)
* args to raw data ready callback are
* frameNumber is the frame number
* expLength is the subframe number (32 bit eiger) or real time exposure time in 100ns (others)
* packetNumber is the packet number
* bunchId is the bunch id from beamline
* timestamp is the time stamp with 10 MHz clock
* modId is the unique module id (unique even for left, right, top, bottom)
* xCoord is the x coordinate in the complete detector system
* yCoord is the y coordinate in the complete detector system
* zCoord is the z coordinate in the complete detector system
* debug is for debugging purposes
* roundRNumber is the round robin set number
* detType is the detector type see :: detectorType
* version is the version number of this structure format
* sls_receiver_header frame metadata
* dataPointer is the pointer to the data
* revDatasize is the reference of data size in bytes. Can be modified to the new size to be written/streamed. (only smaller value).
* revDatasize is the reference of data size in bytes.
* Can be modified to the new size to be written/streamed. (only smaller value).
*/
void registerCallBackRawDataModifyReady(void (*func)(uint64_t, uint32_t,
uint32_t, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t,
uint16_t, uint32_t, uint16_t, uint8_t, uint8_t,
void registerCallBackRawDataModifyReady(void (*func)(char* ,
char*, uint32_t &,void*),void *arg);
@ -731,6 +728,10 @@ class UDPBaseImplementation : protected virtual slsReceiverDefs, public UDPInter
runStatus status;
/** Activated/Deactivated */
int activated;
/** frame discard policy */
frameDiscardPolicy frameDiscardMode;
/** frame padding */
bool framePadding;
//***connection parameters***
/** Ethernet Interface */
@ -808,53 +809,24 @@ class UDPBaseImplementation : protected virtual slsReceiverDefs, public UDPInter
void *pAcquisitionFinished;
/**
* Call back for raw data
* args to raw data ready callback are
* frameNumber is the frame number
* expLength is the subframe number (32 bit eiger) or real time exposure time in 100ns (others)
* packetNumber is the packet number
* bunchId is the bunch id from beamline
* timestamp is the time stamp with 10 MHz clock
* modId is the unique module id (unique even for left, right, top, bottom)
* xCoord is the x coordinate in the complete detector system
* yCoord is the y coordinate in the complete detector system
* zCoord is the z coordinate in the complete detector system
* debug is for debugging purposes
* roundRNumber is the round robin set number
* detType is the detector type see :: detectorType
* version is the version number of this structure format
* dataPointer is the pointer to the data
* dataSize in bytes is the size of the data in bytes.
*/
void (*rawDataReadyCallBack)(uint64_t, uint32_t,
uint32_t, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t,
uint16_t, uint32_t, uint16_t, uint8_t, uint8_t,
char*, uint32_t, void*);
/**
* Call back for raw data
* args to raw data ready callback are
* sls_receiver_header frame metadata
* dataPointer is the pointer to the data
* dataSize in bytes is the size of the data in bytes.
*/
void (*rawDataReadyCallBack)(char* ,
char*, uint32_t, void*);
/**
* Call back for raw data (modified)
* args to raw data ready callback are
* frameNumber is the frame number
* expLength is the subframe number (32 bit eiger) or real time exposure time in 100ns (others)
* packetNumber is the packet number
* bunchId is the bunch id from beamline
* timestamp is the time stamp with 10 MHz clock
* modId is the unique module id (unique even for left, right, top, bottom)
* xCoord is the x coordinate in the complete detector system
* yCoord is the y coordinate in the complete detector system
* zCoord is the z coordinate in the complete detector system
* debug is for debugging purposes
* roundRNumber is the round robin set number
* detType is the detector type see :: detectorType
* version is the version number of this structure format
* sls_receiver_header frame metadata
* dataPointer is the pointer to the data
* revDatasize is the reference of data size in bytes. Can be modified to the new size to be written/streamed. (only smaller value).
*/
void (*rawDataModifyReadyCallBack)(uint64_t, uint32_t,
uint32_t, uint64_t, uint64_t, uint16_t, uint16_t, uint16_t,
uint16_t, uint32_t, uint16_t, uint8_t, uint8_t,
void (*rawDataModifyReadyCallBack)(char* ,
char*, uint32_t &, void*);
void *pRawDataReady;