Creates device file, then the device can
be used.
To access a device, you need to perform this function in advance.
This function supports multi-process.
Ret = AioInit ( DeviceName , Id )
DeviceName
[ VB.NET : String ] [ C, C++ : char * ] [ C# : string ] [ Python : ctypes.c_char_p
]
Specifies the device name set by device manager property page or setting
tool.
Id
[ VB.NET : Short ] [ C, C++ : short * ] [ C# : out short ] [ Python :
ctypes.POINTER(ctypes.c_short) ]
Specifies address of the variable that receives the ID.
The sequent functions can use the value stored in this variable to access
the device.
Ret [ VB.NET : Integer ] [ C, C++ : long ] [ C# : int ] [ Python : ctypes.c_long ]
Return values |
Content |
0 |
Normality completion |
2 |
Failed
in the registration of the interruption routine |
3 |
Failed
in the allocation of the memory |
8 |
Initialization failed because caio.sys is not found |
9 |
Initialization failed because the file version of caio.dll cannot be acquired |
10 |
Initialization failed because the file version of caio.sys cannot be acquired |
11 |
Initialization failed because the file version of caio.dll is not same as caio.sys |
10000 |
The
device name which wasn't registered by a device manager was specified |
10003 |
Failed
in the creation of the file |
10100 |
A
device name isn't stored in DeviceName |
10101 |
Pointer
to Id is NULL |
20000 |
It
failed in memory allocation for the object preparation |
20035 |
It's need to upgrade the firmware |
20036 |
It's need to upgrade the host driver |
20100 |
The number of
processes met an upper limit |
When the function is first performed in process,
all internal parameters are set to default values.
If the device is configured with registers, the registers are set to default
values.
If the function AioExit isn't performed, even if AioInit is performed,
the internal parameters don't return to the default values.
To return the internal parameters to their default values, please use AioResetDevice.
This function can be performed even if the device is in operation, but the operation of device doesn't stop.
When USB modules are used, the version of analog input and output driver must match the version of firmware inside USB modules. If a invalid combination is detected, the error is returned by the version check. For valid combinations, please refer to each Readme of analog input and output driver and firmware on the CD attached to the USB modules.
Performs initialization by device name "AIO000".
VB.NET |
Dim
Ret As Integer |
C, C++ |
long
Ret; |
C# |
int
Ret; |
Python |
Ret
= ctypes.c_long() |
Multi-process Device Device Manager Property Page Device Name ID Resource