Sets the next comparison count value loaded after comparison count match.
Ret = AioSetCntComparisonReg ( Id , CntChannel , ComparisonNumber, ComparisonData, Flag )
Id
[ VB.NET : Short ] [ C, C++ : short ] [ C# : short ] [ Python : ctypes.c_short
]
Specifies the device ID retrieved from AioInit.
CntChannel
[ VB.NET : Short ] [ C, C++ : short ] [ C# : short ] [ Python : ctypes.c_short
]
Sets the channel of counter.
ComparisonNumber
[ VB.NET : Integer ] [ C, C++ : long ] [ C# : int ] [ Python : ctypes.c_long
]
Specifies the total number of comparison count data to be set.
ComparisonData
[ VB.NET : Integer() ] [ C, C++ : long * ] [ C# : int[] ] [ Python : ctypes.POINTER(ctypes.c_long)
]
Specifies the pointer to the array that stores the comparison count.
The range that can be set is different according to devices.
Flag
[ VB.NET : Short ] [ C, C++ : short ] [ C# : short ] [ Python : ctypes.c_short
]
Specifies whether to repeatedly set the data array of comparison count
value.
0 |
Not repeat |
1 |
Repeat |
If Repeat is set, the first
comparison count value data of the array is set again when the last comparison
count value of the array matches the next comparison count set.
If Not repeat is set, data isn't preset when the last comparison count
value of the array matches the followed comparison count set.
Ret [ VB.NET : Integer ] [ C, C++ : long ] [ C# : int ] [ Python : ctypes.c_long ]
Return values |
Content |
0 |
Normality completion |
7 |
Execute AioResetDevice function because the device has recovered from standby mode |
10001 |
Invalid
Id was specified |
10002 |
AIO
driver can't be called |
15040 |
The value of CntChannel is outside the designated range of the function |
15041 |
The value of ComparisonNumber is outside the designated range of the function |
15042 |
The value of Flag is outside the designated range of the function |
15043 |
Pointer
to ComparisonData is NULL |
20001 |
This function can't be used by this device |
20002 |
Can
not use while by another device works |
20003 |
Can
not use because another process is using the device |
25040 |
The value of CntChannel is outside the designated range of the device being used |
25041 |
The value of ComparisonNumber is outside the designated range of the device being used |
None
The value set by using this function is loaded
as the next comparison count value after comparison count match.
The values set in the array are set in turn when comparison count match
occurs every time.
If the comparison count value is fixed, please set ComparisonNumber = 1 and Flag = 1.
In order to use this functionality, you should
set comparison count value load as the operation mode by using the function
AioSetCntComparisonMode.
This function cannot be used on devices without counter functionality.
If the device is in operation, the function cannot be performed.
AI-1664UG-PE AIO-163202G-PE |
ComparisonNumber
can be set in 1 to 255(FFH). |
AIO-160802L-LPE |
ComparisonNumber
can be set in 1 to 255(FFH). |
AI-1616L-LPE |
ComparisonNumber
can be set in 1 to 255(FFH). |
AO-1604L-LPE |
ComparisonNumber
can be set in 1 to 255(FFH). |
AIO-163202FX-USB |
ComparisonNumber
can be set in 1 to 255(FFH). |
AIO-121602LN-USB |
ComparisonNumber
can be set in 1 to 255(FFH). |
AI-1664LAX-USB |
ComparisonNumber
can be set in 1 to 255(FFH). |
AO-1604LX-USB |
ComparisonNumber
can be set in 1 to 255(FFH). |
Set the first comparison count value 10000 to channel 0 repeatedly.
VB.NET |
Dim
Ret As Integer |
C, C++ |
long
Ret; |
C# |
int
Ret; |
Python |
Ret
= ctypes.c_long() |