#include <user/Input.h>
Definition at line 26 of file Input.h.
◆ Input()
◆ ~Input()
◆ Read_Init()
Initialize data input, using port and command.
This is generic virtual method to initialize input, using configurations from Port and (or) from the Command
- Parameters
-
[in] | wrk | reference on input port |
[in] | cmd | reference on command object |
- Returns
- false when method fails
Reimplemented from dabc::DataInput.
Definition at line 52 of file Input.cxx.
◆ Read_Size()
unsigned user::Input::Read_Size |
( |
| ) |
|
|
protectedvirtual |
Defines required buffer size for next operation.
- Returns
- 0..di_ValidSize - size of buffer for next read operation (di_ValidSize = 0xFFFFFFF0)
- di_EndOfStream - this is end of stream, normal close of the input
- di_DfltBufSize - any non-zero buffer can be provided
- di_Repeat - nothing to read now, try again as soon as possible
- di_RepeatTimeOut - nothing to read now, try again after timeout
- di_CallBack - input will activate transport via callback
- di_Error - error, close input
Reimplemented from dabc::DataInput.
Definition at line 67 of file Input.cxx.
◆ Read_Start()
Prepare buffer for reading (if required)
- Returns
- di_Ok - buffer must be filled in Read_Complete call
- di_CallBack - input will do readout and activate transport via callback
- di_Error (or other) - error, skip buffer
Reimplemented from dabc::DataInput.
Definition at line 72 of file Input.cxx.
◆ Read_Complete()
Complete reading of the buffer from source,.
- Returns
- di_Ok - buffer filled and ready
- di_EndOfStream - this is end of stream, normal close of the input
- di_SkipBuffer - skip buffer
- di_Error - error, skip buffer and close input
- di_Repeat - not ready, call again as soon as possible
- di_RepeatTimeOut - not ready, call again after timeout
Reimplemented from dabc::DataInput.
Definition at line 78 of file Input.cxx.
◆ Read_Timeout()
double user::Input::Read_Timeout |
( |
| ) |
|
|
protectedvirtual |
Provide timeout value.
- Returns
- timeout in seconds
When Read_Size or Read_Complete operations returns di_RepeatTimeout argument, specified timeout will be used before next operation will be done
Reimplemented from dabc::DataInput.
Definition at line 61 of file Input.cxx.
◆ GetReadLength()
unsigned int user::Input::GetReadLength |
( |
| ) |
|
|
inlineprotected |
◆ User_Init()
int user::Input::User_Init |
( |
| ) |
|
|
protectedvirtual |
Initialize the readout hardware on startup.
Definition at line 147 of file Input.cxx.
◆ User_Readout()
int user::Input::User_Readout |
( |
uint32_t * |
pdat, |
|
|
unsigned long & |
size |
|
) |
| |
|
protectedvirtual |
Fill the data at the buffer pointer.
size returns filled size in bytes
Definition at line 177 of file Input.cxx.
◆ User_WaitForTrigger()
int user::Input::User_WaitForTrigger |
( |
| ) |
|
|
protectedvirtual |
Here any kind of external trigger can be waited for.
Definition at line 162 of file Input.cxx.
◆ User_ResetTrigger()
int user::Input::User_ResetTrigger |
( |
| ) |
|
|
protectedvirtual |
Used to clear any kind of external trigger information.
Definition at line 171 of file Input.cxx.
◆ User_Cleanup()
int user::Input::User_Cleanup |
( |
| ) |
|
|
protectedvirtual |
shut down the readout hardware properly at the end
Definition at line 156 of file Input.cxx.
◆ Gauss_Rnd()
double user::Input::Gauss_Rnd |
( |
double |
mean, |
|
|
double |
sigma |
|
) |
| |
|
protected |
produce random spectra for the go4 example
Definition at line 195 of file Input.cxx.
◆ fURL
remember specifications of this input from port config
Definition at line 74 of file Input.h.
◆ fErrorRate
◆ fReadLength
unsigned int user::Input::fReadLength |
|
protected |
actual payload length of read buffer
Definition at line 79 of file Input.h.
◆ fNumEvents
unsigned int user::Input::fNumEvents |
|
protected |
Event number since device init.
Definition at line 83 of file Input.h.
◆ fSubeventSize
unsigned int user::Input::fSubeventSize |
|
protected |
subevent size for this example
Definition at line 86 of file Input.h.
◆ fSubeventSubcrate
unsigned int user::Input::fSubeventSubcrate |
|
protected |
For mbsformat: defines subevent subcrate id for case fSingleSubevent=true.
Definition at line 89 of file Input.h.
◆ fSubeventProcid
unsigned int user::Input::fSubeventProcid |
|
protected |
For mbsformat: defines subevent procid.
Definition at line 92 of file Input.h.
◆ fSubeventControl
unsigned int user::Input::fSubeventControl |
|
protected |
For mbsformat: defines subevent control.
Definition at line 95 of file Input.h.
◆ fEarlyTriggerClear
bool user::Input::fEarlyTriggerClear |
|
protected |
rest the trigger before device buffer has been read out.
This can speed up things if DAQ is provided with double buffering or external data queues.
Definition at line 99 of file Input.h.
◆ fDebug
flag for optional debug output
Definition at line 102 of file Input.h.
The documentation for this class was generated from the following files: