GxAoLoadChannelVoltage

Purpose

Load the specified groups’ channel with new voltage value.

Syntax

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

Parameters

Name
Type
Description
nHandle
SHORT
Handle to an initialized 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 new voltage value.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

Loading a channel with a new value does not affect the channels output. The channel’s DAC will be programmed with the new value only after calling GxAoUpdateGroupVoltage. Calling GxAoSetChannelVoltage will only update all the channels in the specified group with their current loaded values. This function allows the user to load different values to different channels/groups and update all the channels at once.

Calling this function will set GxAoGetGroupUpdateState to high (i.e. new value is waiting for the group to be updated).

If the new voltage is out of range the function will return an error.

Example

The following example load channel five group B with 5.8 volts:

 

SHORT nStatus, nDirection;

GxAoLoadChannelVoltage (nHandle, GXAO_GROUPB, 5, 5.8, &nStatus);

 

See Also

GxAoSetChannelVoltage, GxAoGetChannelVoltage, GxAoGetGroupUpdateState, GxAoUpdateGroupVoltage, GxAoGetErrorString