AiInputMultiChannel  [Binary value]


Function

 

Converts the more than one channel one time, the conversion data are returned in binary value.

 

Format

 

ret = dncDaq01.AiInputMultiChannel(DeviceNo, ChannelNum, AiData)

 

Parameters

 

DeviceNo [ C#: short ] [ VB.NET: Short ]

Specifies the device No. managed by DncDaq.

 

ChannelNum [ C#: short ] [ VB.NET: Short ]

Specifies the number of channels to be converted.

 

AiData [ C#: int[] ] [ VB.NET: Integer() ]

Specifies the address of the array that stores the converted data. The converted data are stored in binary value.

Resolution of device is 10 bit

0 to 1023

Resolution of device is 12 bit

0 to 4095

Resolution of device is 16 bit

0 to 65535

 

Return value

 

Ret [ C#: int ] [ VB.NET: Integer ]

 

■Common

Value

Description

0

Normality completion

500001

The method on an unconfigured device has been called. Check the device settings.

500002

The method was called that the device does not support.

510001

The input parameter is invalid. Check the parameter contents.

 

■AIO Devices

Value

Description

11440

The value of ChannelNum is outside the designated range of the method
Please specify the number of channels setting in range: 1 <= ChannelNum <= Max number of channels.

11441

Pointer to AiData is NULL
Please specify the address of variable to parameter.

20002

Cannot run because the device is running
To use this method, analog input operation must be stopped.

21441

The number of conversion channels was exceeded. It is converted on the maximum channel

Other errors (see: Error code details)

 

Remarks

 

This method cannot be used on devices without the analog input function.
This method cannot be executed if the device is operating in continuous mode.

 

Example

 

Converts from channel 0 to channel 7 one time.

C#

int    Ret
int[]  AiData = new int[8];

Ret = dncDaq01.AiInputMultiChannel(DeviceNo, 8, AiData);

 

VB.NET

Dim Ret As Integer
Dim AiData(7) As Integer

Ret = dncDaq01.AiInputMultiChannel(DeviceNo, 8, AiData)