AioGetDeviceType


Function

Find out the type of a device. This function supports multi-process.

Format

Ret = AioGetDeviceType ( Device , DeviceType )

Parameters

Device [ VB.NET : String ] [ C, C++ : char * ] [ C# : string ] [ Python : ctypes.c_char_p ]
Specifies the device name.(For example: "AD12-16U(PCI)EV")

DeviceType [ VB.NET : Short ] [ C, C++ : short * ] [ C# : out short ] [ Python : ctypes.POINTER(ctypes.c_short) ]
Specifies the address of a variable that receives the type of device.

0

Reserved

1

PCI

2

PC Card

3

USB

4

Reserved

5

Demo Device

6

Card Bus

20

NET

Return value

Ret [ VB.NET : Integer ] [ C, C++ : long ] [ C# : int ] [ Python : ctypes.c_long ]

Return values

Content

0

Normality completion

10013

Could not get device type

10014

Pointer to Device is NULL
Specify the address of variable to parameter.

10015

Pointer to DeviceType is NULL
Specify the address of variable to parameter.

Example

Retrieves the type of device "AD12-16(PCI)EV".

VB.NET

Dim Ret As Integer
Dim DeviceType As Short
Ret = AioGetDeviceType ( "AD12-16(PCI)EV" , DeviceType )
 

C, C++

long Ret;
short DeviceType;
Ret = AioGetDeviceType ( "AD12-16(PCI)EV" , &DeviceType );
 

C#

int Ret;
short DeviceType;
Ret = aio.GetDeviceType ( "AD12-16(PCI)EV" , out DeviceType );
 

Python

Ret = ctypes.c_long()
DeviceType = ctypes.c_short()
Ret.value = caio.AioGetDeviceType ( "AD12-16(PCI)EV" , ctypes.byref(DeviceType) )