Sets the function mode to Auto Ratio.
GxCntSetFunctionAutoRatio (nHandle, nMode, pnStatus)
Name |
Type |
Description |
nHandle |
SHORT |
Handle to a counter board. |
nMode |
SHORT |
Measurement Mode:
|
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
This mode determines the ratio between the signal frequency on one input channel and the signal frequency on the second input channel. The measurement is performed during a user definable interval or gate time: (long gate time produce higher resolution results).
The counter tests the input signals and automatically selects the internal connections that maximize resolution. The measurement results are automatically converted to the specified mode (e.g. A/B or B/A).
Note: Only one of the input signals may exceed 25MHz and should not be used when signal frequencies drop below 400 Hz. If arming slope is specified the counter reverts to GxCntSetFunctionRatio.
The following example sets the function to Auto Ratio and measuring channel A divided by channel B:
SHORT nHandle, nStatus;
GxCntSetFunctionAutoRatio (nHandle, GXCNT_MEASURE_A_DIVIDED_BY_B, &nStatus);
GxCntSetFunctionRatio, GxCntSetGateTime, GxCntSetAcquisitionTimeInterval, GxCntGetErrorString