Sets the pulse measurement parameters for the specified channel.
Ret = DioSetPulseMeasurementSetting ( Id , ChNo , ChNum , MeasurementTarget, PulsePeriod )
Id [ C, C++: short ] [ Python: ctypes.c_short ]
Specify the device ID retrieved from DioInit.
ChNo [ C, C++: short * ] [ Python: ctypes.POINTER(ctypes.c_short) ]
Specify the start address of the array that stores the channel numbers to set.
ChNum [ C, C++: short ] [ Python: ctypes.c_short ]
Specify the number of channels specified in ChNo.
MeasurementTarget [ C, C++: unsigned short * ] [ Python: ctypes.POINTER(ctypes.c_ushort) ]
Specify the start address of the array that stores the pulse measurement time settings.
|
Definition |
Value [Dec] |
Description |
|
DIO_PULSE_MEASUREMENT_TARGET_OFF_TIME |
0 |
Measure the OFF time |
|
DIO_PULSE_MEASUREMENT_TARGET_ON_TIME |
1 |
Measure the ON time |
PulsePeriod [ C, C++: unsigned short * ] [ Python: ctypes.POINTER(ctypes.c_ushort) ]
Specify the start address of the array that stores the pulse measurement period settings.
|
Definition [Dec] |
Description |
|
0 |
25nsec |
|
1 |
50nsec |
|
2 |
100nsec |
|
3 |
200nsec |
|
4 |
400nsec |
|
5 |
800nsec |
|
6 |
1.6usec |
|
7 |
3.2usec |
|
8 |
6.4usec |
|
9 |
12.8usec |
|
10 |
25.6usec |
|
11 |
51.2usec |
|
12 |
102.4usec |
|
13 |
204.8usec |
|
14 |
409.6usec |
|
15 |
819.2usec |
|
16 |
1.6384msec |
|
17 |
3.268msec |
|
18 |
6.5536msec |
|
19 |
13.1072msec |
|
20 |
26.2144msec |
Ret [ C, C++: long ] [ Python: ctypes.c_long ]
|
Definition |
Value [Dec] |
Description |
|
DIO_ERR_SUCCESS |
0 |
Normal completed. |
|
DIO_ERR_DLL_INVALID_ID |
10001 |
Invalid ID specified. |
|
DIO_ERR_DLL_CALL_DRIVER |
10002 |
Driver cannot be called (failed in ioctl). |
|
DIO_ERR_DLL_BUFF_ADDRESS |
10100 |
Invalid data buffer address. |
|
DIO_ERR_SYS_NOT_SUPPORTED |
20001 |
This board couldn't use this function. |
|
DIO_ERR_SYS_CH_NO |
20105 |
Specify the start address of the array that stores the channel numbers to set. |
|
DIO_ERR_SYS_CH_NUM |
20106 |
Specify the number of channels specified in ChNo. |
|
DIO_ERR_SYS_PULSE_MEASUREMENT_TARGET |
20950 |
The pulse measurement time is out of range. |
|
DIO_ERR_SYS_PULSE_MEASUREMENT_PERIOD |
20951 |
The pulse measurement period is out of range. |
|
DIO_ERR_SYS_PULSE_MEASUREMENT_RUNNING |
20952 |
Function is not allowed to be called during the pulse measurement operation. |
The others (See also: Details of Error Code)
MeasurementTarget = DIO_PULSE_MEASUREMENT_TARGET_OFF_TIME(0)
PulsePeriod = 25nsec (0)
Sets the pulse measurement parameters for the specified channel.
This function cannot be executed during pulse measurement operation.
Sets the pulse measurement time of channel 0 to “measure ON time” and the pulse measurement period to 100 nsec.
|
C, C++ |
long Ret; |
|
Python |
Ret = ctypes.c_long() |