Operator`s manual

Table Of Contents
131 Signametrics
DMMSetDCVSource
SMU2060 SMU2064
Description Set the DCV source output level.
#include "SMU2060.h"
#include "USBDMMUser.h"
int DMMSetDCVSource(int nDmm, double ldVolts)
Remarks This function sets the DC voltage source output to ldVolts. The DMM must be in
VDC_SRC. Reading the DMM (DMMRead or DMMReadStr) will return the
measurement of the output voltage at the DMM terminals. This function acts on the main
12 bit source DAC. If better accuracy is needed it can be accomplished by selecting the
ClosedLoop mode (DMMSetSourceMode). This mode engages the Trim DAC, which
augments the 12 bit DAC to produce 18 effective bits. In ClosedLoop mode, the source
level is adjusted every time the DMM is read, making small corrections until the reading
is equal to ldVolts. However, for the ClosedLoop mode to update the source level, it is
necessary to read the DMM multiple times. Aperture should be set to 160ms or higher,
with Read Interval set to 0 when using the Closed Loop mode. The DMM reads voltages
using the 24 V range.
Parameter
Type/Description
nDmm
int Identifies the DMM. DMMs are numbered starting with zero.
ldVolts
double DC voltage to be set. Can be –10.5 to 10.5 V
Return Value Integer error code.
Value
Meaning
DMM_OKAY
Operation successfully completed.
Negative Value
Error code
Example
double reading; int I;
DMMSetDCVSource(0, 1.25); // Set source to 1.25V
DMMSetSourceMode(0, CLOSED_LOOP); // Closed loop mode
for(I=0;I<100;I++) DMMRead(0,&reading); // update 100 times