INT32S DRV_CounterEventRead ( PTR_T DeviceHandle, PT_CounterEventRead *lpCounterEventRead );
On the device indicated by the DeviceHandle, it retrieves the current counting value and the overflow flag from the specified counter without disturbing the counting process.
Some parameters, such as target counter channel (counter), overflow status (overflow) and current count (count), are stored in the PT_CounterEventRead structure pointed by the lpCounterEventRead.
|
Name |
Direction |
Range |
Description |
|
DeviceHandle |
input |
default |
Retrieved from DRV_DeviceOpen which specifies the target device. |
|
lpCounterEventRead |
input / output |
default |
The pointer to indicate the user-prepared structure PT_CounterEventRead that stores target counter channel (INT16U counter), overflow status (INT16U * overflow) and read back current count (INT32U * count). |
|
1. 0 |
Successful. |
|
2. InvalidDeviceHandle |
The Devicehandle is NULL. |
|
3. InvalidChannel |
The target channel is out of range. |
|
4. Other value |
Please reference ErrorCodes |