GxSmuSourceGetMode

Applies To

GX3104, GX3116e

Purpose

Returns the specified channel’s operation mode, constant Voltage or Constant Current.

Syntax

GxSmuSourceGetMode (nHandle, nChannel, pnMode, pnStatus)

Parameters

Name
Type
Description
nHandle
SHORT
Handle to a GX3104 or GX3116e board.
nChannel
SHORT
GX3104: Specifies the channel number (0-3): GX3104_CHANNEL_1 to GX3104_CHANNEL_4
GX3116e: Specifies channel number (0-15) is GX3116_CHANNEL_1 to GX3116_CHANNEL_16.
pnMode
PSHORT
Specified channel’s operation mode, constant Voltage or Constant Current
0.      GXSMU_SOURCE_MODE_CONSTANT_VOLTAGE: Source Voltage is constant while the current may change as a function of the load. In this mode the output behaves as a voltage source.
1.    GXSMU_SOURCE_MODE_CONSTANT_CURRENT: Source current is constant while the output voltage changes as a function of the load. In this mode the output behaves as a current source.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

In constant voltage, the Source Voltage is constant while the current may change as a function of the load. In this mode the output behaves as a voltage source, and the output is limited by the current limit value, i.e. the load can draw current up to the current limit value. Applicable APIs are:

In constant current, the Source current is constant while the output voltage changes as a function of the load. In this mode the output behaves as a current source, and the output is limited by the voltage limit value, i.e. the load can draw voltage up to the voltage limit value. Applicable APIs are:

Example

The following example sets channel 1 to constant voltage mode:

 

SHORT nMode, nStatus;

 

GxSmuSourceSetMode (nHandle, GX3104_CHANNEL_1, GXSMU_SOURCE_MODE_CONSTANT_VOLTAGE, &nStatus);

GxSmuSourceGetMode (nHandle, GX3104_CHANNEL_1, &nMode, &nStatus);

 

See Also

GxSmuSourceSetCurrent, GxSmuSourceSetCurrentLimit, GxSmuSourceSetCurrentClamps, GxSmuSourceSetCurrentRange, GxSmuSourceSetMode, GxSmuSourceSetOutputState, GxSmuSourceSetRangeMode, GxSmuSourceSetVoltage, GxSmuSourceSetVoltageLimit, GxSmuGetErrorString