GxAoSetChannelVoltage

Purpose

Sets the specified channel’s group voltage.

Syntax

GxAoSetChannelVoltage (nHandle, nGroup, nChannel, dVoltage, pnStatus)

Parameters

Name
Type
Description
nHandle
SHORT
Handle to a GX16xx board.
nGroup
SHORT
Group number:
0.   GXAO_GROUPA
1.   GXAO_GROUPB
2.   GXAO_GROUPC
3.   GXAO_GROUPD
nChannel
SHORT
Channel number 0-15.
dVoltage
DOUBLE
Channel's voltage.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

The voltage must be in the group’s voltage range otherwise the function returns an error.

Calling this function will set GxAoGetGroupUpdateState to low (i.e. the group was updated).

Example

The following example sets the voltage for group A channel 4 to 2.34V:

 

SHORT nStatus;

 

GxAoGetChannelVoltage (nHandle, GXAO_GROUPA, 4, 2.34, &nStatus);

 

See Also

GxAoGetChannelVoltage, GxAoSetGroupVoltageRange, GxAoGetGroupVoltageRange, GxAoGetErrorString