7-6 Relative, mX+b and Percent (%)
SCPI programming — mX+b and percent
A) :DATA? and :DATA:LATest?
The INITiate command must be sent to trigger the measurements and calculations. The
number of calculations depend on how many measurements the instrument is programmed to
perform.
If the instrument is programmed to perform a finite number of measurements, the :DATA?
command will return all the CALC1 readings after the last reading is taken. The :DATA:LATest?
command will only return the last (latest) CALC1 reading.
If the instrument is programmed to perform an infinite number of measurements (arm count
or trigger count set to infinite), you cannot use the :DATA? command to return CALC1 readings.
However, you can use the :DATA:LATest? command to return the last CALC1 reading after
aborting the measurement process. After sending the INITiate command to start the measure-
ment process, use the ABORt command to abort the measurement process, then use
:DATA:LATest? to return the last CALC1 reading.
Programming example — mX+b
This command sequence performs a single mX+b calculation and displays the result on the
computer CRT:
*RST ‘ Restores RST defaults.
CALC:FORM MXB ‘ Selects mX+b calculation.
CALC:KMAT:MMF 2 ‘ Sets scale factor (M) to 2.
CALC:KMAT:MBF 0.5 ‘ Sets offset (B) to 0.5.
CALC:STAT ON ‘ Enables calculation.
INIT ‘ Perform one measurement and
calculate mX+b.
CALC:DATA? ‘ Request mX+b result.
Table 7-3
SCPI commands — mX+b and percent
Commands Description Default Ref
CALCulate[1] CALCulate1 Subsystem:
:FORMat <name> Select calculation; MXB or PERCent. MXB
:KMATh Path to configure mX+b and percent:
:MMFactor <n> Specify scale factor (M) for mX+b; -9.99999e20 to
9.99999e20.
1.0
:MBFactor <n> Specify offset (B) for mX+b; -9.99999e20 to 9.99999e20. 0.0
:MUNits <name> Specify units for mX+b; 3 characters “A” through “Z”. MXB
:PERCent Percent: 1.0
:REFerence <n> Specify reference value; -9.99999e20 to 9.99999e20.
:ACQuire Use input signal as reference value.
:STATe <b> Enable or disable the selected calculation. OFF
:DATA? Returns all CALC1 results triggered by the INITiate. A
:DATA:LATest? Returns only the latest CALC1 reading. A