SECTION 4 - PROGRAMMING GUIDE
Page 4.3
pickering
ISOLATED MILLIVOLT THERMOCOUPLE SIMULATOR 41-761
Setting Thermocouple Range
The Thermocouple Simulator has three ranges; low, medium and high.
● LOW Range (-20 and +20 mV)
● MED Range (-50 and +50mV)
● HIGH Range (-100mV and +100mV)
By default AUTO Range is selected which switches between the three ranges based on what voltage is set on the
card.
Enum dened in the header le are:
enum
{
TS_AUTO_RANGE = 0,
TS_LOW_RANGE = 1,
TS_MED_RANGE = 2,
TS_HIGH_RANGE = 3
};
C code example using the Direct I/O Driver. By default AUTO RANGE is set, to set LOW (or any other range),
please use the SetAttribute function as dened in the following example:
DWORD l_CardNum;
DWORD attr = TS_LOW_RANGE;
void *v;
v = &attr;
err = PIL_SetAttribute(card, 1, 1, ATTR_TS_SET_RANGE, v);
Setting Isolation Switches
The isolation switches for Vo and Vcold are dened after the voltage source channels (Sub-unit 33 in a 32-channel
card). To set these switches, the Opbit command is used. C code example using the Direct I/O Driver:
IsoSub = 33
err = PIL_OpBit(card, IsoSub , 1, 1); //Turn Vo1 on
err = PIL_OpBit(card, IsoSub , 2, 1); //Turn Vcold1 on
err = PIL_OpBit(card, IsoSub , 3, 1); //Turn Vo2 on
err = PIL_OpBit(card, IsoSub , 1, 0); //Turn Vo1 o