Sets the specified channel input slope.
CalCounterSetSlope (hHandle, nChannel, lSlope, plStatus)
Name |
Type |
Comments |
hHandle |
LONG |
Handle for a Counter. |
nChannel |
SHORT |
Select channel (0-based). |
lSlope |
SHORT |
Channel’s slope:0. aCounterPositiveSlope: Rising (Positive) edge.1. aCounterNegativeSlope: Falling (Negative) edge. |
plStatus |
PLONG |
Returned status: 0 on success, negative number on failure. |
Channel slope sets the input signal edge that utilized for the measurement. The slope can specify either rising (Positive) edge or falling (Negative) edge.
The following example sets channel 0’s input slope to rising edge:
LONG lHandle, lStatus;
CalCounterSetSlope (lHandle, 0, aCounterPositiveSlope, &lStatus);
CalCounterMeasure, CalCounterSetFunctionPulseWidth, CalCounterSetGateTime, CalCounterSetTriggerLevel, CalCounterGetError