INT32S DRV_QCounterRead ( PTR_T DeviceHandle, PT_QCounterRead *lpQCounterRead );
On the device indicated by the DeviceHandle, it retrieves the current count value and overflow flag from the device without disturbing the counting process.
Some parameters, such as target counter channel (counter), overflow status (overflow), low count buffer (LoCount) and high count buffer (HiCount), are stored in the PT_QCounterRead structure pointed by the lpQCounterRead.
| Name | Direction | Range | Description |
| DeviceHandle | input | default | The pointer retrieved from DRV_DeviceOpen which specifies the target device. |
| lpQCounterRead | input / output | default | The pointer to indicate the user-prepared structure PT_QCounterRead that stores target counter channel (INT16U counter), overflow status (INT16U * overflow), low count buffer (INT32U* LoCount) and high count buffer (INT32U * HiCount)。 |
| 1. 0 | Successful. |
| 2. InvalidDriverHandle | The Driverhandle is NULL. |
| 3. InvalidChannel | The target channel is out of range. |
| 4. Other value | Please reference ErrorCodes |