Class for implementing the SLS data receiver in the users application. Callbacks can be defined for processing and/or saving data.
More...
#include <slsReceiverUsers.h>
|
| slsReceiverUsers (int argc, char *argv[], int &success) |
|
| ~slsReceiverUsers () |
|
int | start () |
|
void | stop () |
|
int64_t | getReceiverVersion () |
|
void | registerCallBackStartAcquisition (int(*func)(char *filepath, char *filename, uint64_t fileindex, uint32_t datasize, void *), void *arg) |
| register calbback for starting the acquisition More...
|
|
void | registerCallBackAcquisitionFinished (void(*func)(uint64_t nf, void *), void *arg) |
| register callback for end of acquisition More...
|
|
void | registerCallBackRawDataReady (void(*func)(char *header, char *datapointer, uint32_t datasize, void *), void *arg) |
| register callback to be called when data are available (to process and/or save the data). More...
|
|
void | registerCallBackRawDataModifyReady (void(*func)(char *header, char *datapointer, uint32_t &revDatasize, void *), void *arg) |
| register callback to be called when data are available (to process and/or save the data). More...
|
|
Class for implementing the SLS data receiver in the users application. Callbacks can be defined for processing and/or saving data.
slsReceiverUsers is a class that can be instantiated in the users software to receive the data from the detectors. Callbacks can be defined for processing and/or saving data
Definition at line 15 of file slsReceiverUsers.h.
slsReceiverUsers::slsReceiverUsers |
( |
int |
argc, |
|
|
char * |
argv[], |
|
|
int & |
success |
|
) |
| |
Constructor reads config file, creates socket, assigns function table
- Parameters
-
argc | from command line |
argv | from command line |
success | socket creation was successfull |
slsReceiverUsers::~slsReceiverUsers |
( |
| ) |
|
int64_t slsReceiverUsers::getReceiverVersion |
( |
| ) |
|
get get Receiver Version
- Returns
- id
void slsReceiverUsers::registerCallBackAcquisitionFinished |
( |
void(*)(uint64_t nf, void *) |
func, |
|
|
void * |
arg |
|
) |
| |
register callback for end of acquisition
- Parameters
-
func | end of acquisition callback. Argument nf is total frames caught |
arg | argument |
- Returns
- nothing
void slsReceiverUsers::registerCallBackRawDataModifyReady |
( |
void(*)(char *header, char *datapointer, uint32_t &revDatasize, void *) |
func, |
|
|
void * |
arg |
|
) |
| |
register callback to be called when data are available (to process and/or save the data).
- Parameters
-
func | raw data ready callback. arguments are sls_receiver_header, dataPointer, revDatasize is the reference of data size in bytes. Can be modified to the new size to be written/streamed. (only smaller value). |
arg | argument |
- Returns
- nothing
void slsReceiverUsers::registerCallBackRawDataReady |
( |
void(*)(char *header, char *datapointer, uint32_t datasize, void *) |
func, |
|
|
void * |
arg |
|
) |
| |
register callback to be called when data are available (to process and/or save the data).
- Parameters
-
func | raw data ready callback. arguments are sls_receiver_header, dataPointer, dataSize |
arg | argument |
- Returns
- nothing
void slsReceiverUsers::registerCallBackStartAcquisition |
( |
int(*)(char *filepath, char *filename, uint64_t fileindex, uint32_t datasize, void *) |
func, |
|
|
void * |
arg |
|
) |
| |
register calbback for starting the acquisition
- Parameters
-
func | callback to be called when starting the acquisition. Its arguments are filepath, filename, fileindex, datasize |
arg | argument |
- Returns
- value is insignificant at the moment, we write depending on file write enable, users get data to write depending on call backs registered
int slsReceiverUsers::start |
( |
| ) |
|
starts listening on the TCP port for client comminication
- Returns
- 0 for success or 1 for FAIL in creating TCP server
void slsReceiverUsers::stop |
( |
| ) |
|
stops listening to the TCP & UDP port and exit receiver program
slsReceiver* slsReceiverUsers::receiver |
The documentation for this class was generated from the following file:
- /afs/psi.ch/project/sls_det_software/dhanya_softwareDevelopment/mySoft/test/slsDetectorPackage/slsReceiverSoftware/include/slsReceiverUsers.h