File/string/stream data input/output methods to be implemented by plugins.
More...
#include <signal_io.h>
|
long int | InitDevice (const char *deviceConfig) |
| Creates plugin specific signal input/output device data structure. More...
|
|
void | EndDevice (long int deviceID) |
| Discards given signal input/output device data structure
More...
|
|
bool | HasError (long int deviceID) |
| Verifies occurence of errors on given device. More...
|
|
void | Reset (long int deviceID) |
| Resets data and errors for given device. More...
|
|
size_t | GetMaxInputSamplesNumber (long int deviceID) |
| Gets number of samples aquired for every given device input channel on each Read() call. More...
|
|
bool | CheckInputChannel (long int deviceID, unsigned int channel) |
| Check reading availability for specified input channel of given device. More...
|
|
size_t | Read (long int deviceID, unsigned int channel, double *ref_value) |
| Reads samples list from specified channel of given device. More...
|
|
bool | AcquireOutputChannel (long int deviceID, unsigned int channel) |
| Check availability and get exclusive access for specified output channel of given device. More...
|
|
void | ReleaseOutputChannel (long int deviceID, unsigned int channel) |
| Give up exclusive access for specified output channel of given device. More...
|
|
bool | Write (long int deviceID, unsigned int channel, double value) |
| Writes value to specified channel of given device. More...
|
|
File/string/stream data input/output methods to be implemented by plugins.
◆ AcquireOutputChannel()
bool AcquireOutputChannel |
( |
long int |
deviceID, |
|
|
unsigned int |
channel |
|
) |
| |
Check availability and get exclusive access for specified output channel of given device.
- Parameters
-
[in] | deviceID | output device identifier |
[in] | channel | output device channel index |
- Returns
- true on successful channel acquisition (availability for writing), false otherwise
◆ CheckInputChannel()
bool CheckInputChannel |
( |
long int |
deviceID, |
|
|
unsigned int |
channel |
|
) |
| |
Check reading availability for specified input channel of given device.
- Parameters
-
[in] | deviceID | input device identifier |
[in] | channel | input device channel index |
- Returns
- true on channel availability for reading, false otherwise
◆ EndDevice()
void EndDevice |
( |
long int |
deviceID | ) |
|
Discards given signal input/output device data structure
- Parameters
-
[in] | deviceID | input/output device identifier |
◆ GetMaxInputSamplesNumber()
size_t GetMaxInputSamplesNumber |
( |
long int |
deviceID | ) |
|
Gets number of samples aquired for every given device input channel on each Read() call.
- Parameters
-
[in] | deviceID | input device identifier |
- Returns
- max read samples number (0 on errors)
◆ HasError()
bool HasError |
( |
long int |
deviceID | ) |
|
Verifies occurence of errors on given device.
- Parameters
-
[in] | deviceID | input/output device identifier |
- Returns
- true on detected error, false otherwise
◆ InitDevice()
long int InitDevice |
( |
const char * |
deviceConfig | ) |
|
Creates plugin specific signal input/output device data structure.
- Parameters
-
[in] | deviceConfig | implementation specific device configuration string |
- Returns
- generic identifier to newly created device (SIGNAL_IO_TASK_INVALID_ID on errors)
◆ Read()
size_t Read |
( |
long int |
deviceID, |
|
|
unsigned int |
channel, |
|
|
double * |
ref_value |
|
) |
| |
Reads samples list from specified channel of given device.
- Parameters
-
[in] | deviceID | input device identifier |
[in] | channel | input device channel index |
[out] | ref_value | allocated buffer long enough to hold the samples number returned by GetMaxInputSamplesNumber() |
- Returns
- number of samples read (0 on errors)
◆ ReleaseOutputChannel()
void ReleaseOutputChannel |
( |
long int |
deviceID, |
|
|
unsigned int |
channel |
|
) |
| |
Give up exclusive access for specified output channel of given device.
- Parameters
-
[in] | deviceID | output device identifier |
[in] | channel | output device channel index |
◆ Reset()
void Reset |
( |
long int |
deviceID | ) |
|
Resets data and errors for given device.
- Parameters
-
[in] | deviceID | input/output device identifier |
◆ Write()
bool Write |
( |
long int |
deviceID, |
|
|
unsigned int |
channel, |
|
|
double |
value |
|
) |
| |
Writes value to specified channel of given device.
- Parameters
-
[in] | deviceID | output device identifier |
[in] | channel | output device channel index |
[in] | value | value to be written |
- Returns
- true on successful writing, false otherwise
The documentation for this class was generated from the following file: