DoOutputBit


Function

 

Performs the specified 1-bit digital output.

 

Format

 

ret = dncDaq01.DoOutputBit(DeviceNo, DoBit, DoData)

 

Parameters

 

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

Specifies the device No. managed by DncDaq.

 

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

Specifies the logical output bit number.
Specifies the logic output bit number. The logical output bit number is a number, which is assigned consecutively from the first output bit of a device as 0 to the last one.

 

DoData [ C#: out byte ] [ VB.NET: Byte ]  

Specifies the output data to either 0 or 1.

 

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

14020

The value of DoBit is outside the designated range of the function
Specifies the digital output bit in range: 0 <= DoBit <= Max bit.

14021

The value of DoData is outside the designated range of the function

24020

The value of DoBit is outside the designated range of the device being used

 

■DIO Devices

Value

Description

20102

The bit number exceeds the specifiable range.

20104

Bit data beyond the limit of 0 to 1.

Other errors (see: Error code details)

 

Remarks

 

Outputs 1 bit to an output bit. Specifies 0 or 1 for the output data.

 

Example

 

Outputs 1 to bit 0.

C#

int Ret;

Ret = dncDaq01.DoOutputBit(DeviceNo, 0, 1);

 

VB.NET

Dim Ret As Integer

Ret = dncDaq01.DoOutputBit(DeviceNo, 0, 1)