|
QLIB-function: QAPIExtReadAD
With the function QAPIExtReadAD it is possible to read a digital value from an input channel of an A/D card.
ULONG QAPIExtReadAD(
ULONG cardhandle
ULONG channel
ULONG mode
);
Parameter 1
| cardhandle |
Defines the handle from the opened card |
Parameter 2:
| channel |
Defines the channel, from which the digital value should be read |
Parameter 3:
| mode |
Defines a card dependent parameter (look also card specific parameter) |
Return value
If the function was terminated successful, then is the return value the same as the calculated digital value. The value range is dependent of the resulution of the A/D changer.
If the function is not successful, so is the return value always 0L.
Commands
The function can also have an error, when the card has no A/D part. In this case the function always shows the return value 0. The maximum Return value is dependent of the resulution from the A/D card contained A/D changer. By a 12-Bit changer the greatest back delivered value is value 212 - 1 = 4095. General for the maximum digital value:
dwmax = 2resulution_of_the_AD_changer - 1
Back to the QLIB overview
|