XDM 2041 Digital Multimeter
Programming Manual
www.owon.com.cn
Content
Table of Contents
Introduction to the SCPI Language ......................................................................................... 1
Syntax Rules........................................................................................................................... 1
Rule to format mnemonics ........................................................................................ 1
Usage of symbols ......................................................................................................... 1
Parameter Type ............................................................................................................. 2
Command Abbreviation ..................................................................................................... 3
Contact Us .............................................................................................................................. 4
Third-party API ..................................................................................................................... 4
IEEE488.2 Common Commands ............................................................................................... 5
*IDN ......................................................................................................................................... 5
*RST ......................................................................................................................................... 5
SCPI Command List ..................................................................................................................... 1
SENSe command subsystem..................................................................................... 1
[SENSe:]FUNCtion[1|2] ................................................................................................ 1
[SENSe:]TEMPerature:RTD:TYPe ............................................................................... 3
[SENSe:]TEMPerature:RTD:UNIT ............................................................................... 3
[SENSe:]TEMPerature:RTD:SHOW ............................................................................ 4
[SENSe:]CONT:THREshold.................................................................................................. 4
CONFigure command sub system ............................................................................................. 4
CONFigure[:SCALar][:VOLTage]:{AC|DC}................................................................. 4
CONFigure[:SCALar]:CURRent:{AC|DC} ................................................................... 5
CONFigure[:SCALar]:{RESistance|FRESistance} ..................................................... 5
i
Content
CONFigure[:SCALar]:{FREQuency|PERiod} ............................................................. 6
CONFigure[:SCALar]:CAPacitance ............................................................................ 6
CONFigure[:SCALar]:TEMPerature:RTD .................................................................. 7
CONFigure[:SCALar]:DIODe ....................................................................................... 7
CONFigure[:SCALar]:CONTinuity.............................................................................. 8
CALCulate command Subsystem ............................................................................................... 8
CALCulate:AVERage:ALL?............................................................................................ 8
CALCulate:AVERage:AVERage? ................................................................................. 9
CALCulate:AVERage:MAXimum? .............................................................................. 9
CALCulate:AVERage:MINimum? ............................................................................. 10
CALCulate:DB:REFerence .......................................................................................... 10
CALCulate:DBM:REFerence ...................................................................................... 11
CALCulate:FUNCtion.................................................................................................. 11
CALCulate:NULL:OFFSet ........................................................................................... 12
CALCulate:STATe ......................................................................................................... 12
SYSTem command Subsystem ................................................................................................. 13
SYSTem:BEEPer:STATe ................................................................................................ 13
SYSTem:DATE? ............................................................................................................. 13
SYSTem:TIME? ............................................................................................................. 14
SYSTem:LOCal .............................................................................................................. 14
SYSTem:REMote .......................................................................................................... 15
Other commands .................................................................................................................... 15
AUTO ............................................................................................................................. 15
RANGE ........................................................................................................................... 16
ii
Content
RATE ............................................................................................................................... 16
MEAS? ........................................................................................................................... 17
MEAS1? ......................................................................................................................... 17
MEAS2? ......................................................................................................................... 18
iii
Introduction to the SCPI Language
Introduction to the SCPI Language
Syntax Rules
SCPI language itself defines a group of sub-system keywords, and at the same time allows users
to add or reduce keywords. Those keywords can be some meaningful English words and are easy
to remember, which are called mnemonics. Mnemonic has long and short types. The short are
the abbreviation of the long. Use specific character to separate keywords, data and sentences.
Rule to format mnemonics
1) If the letter number of an English word is less than or equal to 4, then the word itself can be
the mnemonic.(such as “Free” can be “FREE”);
2) If the letter number of an English word exceeds 4, then the first four letters will be the
mnemonic.(such as “Frequency” can be “FREQ”);
3) If the forth letter is vowel, then mnemonic uses the former three letters. Vowels consists of a,
e, i, o, and u.(such as “Power” can be “POW”);
4) If it is not a word but a sentence, then use the first letters of the former words and the whole
of the last word. (such as “Input Voltage “ can be “IVOLtage”)
Usage of symbols
1) Space
1
Introduction to the SCPI Language
The space is used to separate command and parameter.
2) Colon:
If the colon is in front of the first character, it means the following is Root Command. When the
colon is set between two keywords, then it means moving from the current level to the next level.
3) *asterisk
The commands start with asterisk are named Common Command, which is used to execute
IEEE488.2 common commands.
4) Braces{}
The parameters enclosed in the braces are optional and are usually separated by the vertical bar
"|". When using this command, one of the parameters must be selected.
5) Vertical Bar |
The vertical bar is used to separate multiple parameters and one of the parameters must be
selected when using the command.
6) Triangle Brackets < >
The parameter enclosed in the triangle brackets must be replaced by an effective value.
Parameter Type
1) Value
The command required to use value type parameter. It’s compatible with all the common
decimal display terms including optional symbol, decimal point, scientific notation and etc.
Specific value such as MIN, MAX and DEF are available.
VOLTage:{AC|DC}:RANGe {<range>|MINimum|MAXimum}
2
Introduction to the SCPI Language
2) Discrete
The parameter should be one of the values listed. For example,
TEMPerature:RTD:UNIT {C|F|K}
3) Integer
Unless otherwise noted, the parameter can be any integer (NR1 format) within the effective value
range. Note that, do not set the parameter to a decimal, otherwise errors will occur.
4) Bool
The parameter could be "OFF", "ON", for example,
TEMPerature:RTD:NULL {OFF|ON}
Command Abbreviation
Each SCPI command can be written mixed with uppercase and lowercase according to the syntax
rules, and the capital letter part is just the abbreviation of the command. If abbreviation is used,
all the capital letters in the command must be written completely. For parameters with units,
please refer to the detail parameter specifications in the sub-system.
VOLTage:DC:RANGe
Abbreviation Below:
VOLT:DC:RANG
3
Introduction to the SCPI Language
Contact Us
If you have any problem or requirement when using our products, please contact OWON.
Service & Support Hotline:4006 909 365
E-mail: info@owon.com.cn
Website:www.owon.com.cn
Third-party API
The SCPI protocol of this product adopts USB port or LAN port to communication.
If you want to use the software of our company, after you open the software, click to enter
remote control, then click the SCPI command on the remoter control interface to enable SCPI
protocol and communicate through SCPI protocol.
4
IEEE488.2 Common Commands
IEEE488.2 Common Commands
*IDN
Return the ID character string of the instrument
Description
The query returns the ID character string of the instrument.
Return Format
OWON,<model>,<serial number>,X.XX.XX,{3}
<model>:the model number of the instrument
<serial number>:the serial number of the instrument
X.XX.XX:the software version of the instrument.
Example
OWON,XDM2041,1546011,V1.0.0,3
*RST
Restore the instrument to its default value.
5
SCPI Command List
SCPI Command List
SENSe command subsystem
SenSe subsystem configuration. The basic SenSe command is [SENSe:]FUNCtion[1|2], which can
choose main display and sub display measurement function. FUNCtion[1|2] to switch mode.
Other SenSe command only change specific mode parameter, don’t change mode, for example:
VOLT:AC:RANGE:AUTO ON command will start AC voltage mode and auto-measure, but don’t
switch to AC voltage mode.
[SENSe:]FUNCtion[1|2]
Command format
[SENSe:]FUNCtion[2] "<function>"
[SENSe:]FUNCtion[1|2]?
Function description
Select measure function, some functions can only be selected as main display.
Parameter
[1|2]
1 for main display, 2 for sub display. If leave out this parameter, display defaults at 1 (main display).
The parameter for [SENSe:]FUNCtion[2] "<function>", that is, can only been used as sub
display:
1
SCPI Command List
Name Type Parameter Measure Function
Secondary display opening
FREQuency
<function> discrete frequency measurement
NONe close sub display
Return format
Use quotation to keep abbreviated selected return function, no available keyword.
Return value Measure function
VOLT AC AC voltage measure
VOLT DC voltage measure
CURR AC AC current measure
CURR DC current measure
FREQ Frequency measure
PER Period measure
CAP Capacitance measure
CONT Continuity test
DIOD Diode test
Four-wire Resistance
FRES
measure
RES Resistance measure
TEMP Temperature measure
For FUNCtion2? command, if not start dual display, then return NONe.
2
SCPI Command List
[SENSe:]TEMPerature:RTD:TYPe
Syntax
[SENSe:]TEMPerature:RTD:TYPe {<RTD Type>}
[SENSe:]TEMPerature:RTD:TYPe?
Description
Select RTD type for temperature measurement.
Parameter
Name Type Range
<RTD Type > Discrete KITS90, PT100
Return format
Return the query result by character.
[SENSe:]TEMPerature:RTD:UNIT
Syntax
[SENSe:]TEMPerature:RTD:UNIT {C|F|K}
Description
Select temperature unit for temperature measurement, optional for C (Celsius), F(Fahrenheit),
K(Kelvin).
Return format
Return the query result by character
3
SCPI Command List
[SENSe:]TEMPerature:RTD:SHOW
Syntax
[SENSe:]TEMPerature:RTD:SHOW {TEMP|MEAS|ALL}
Description
Select temperature measurement display mode, optional for TEMP (only display temperature),
MEAS (only display measured value), ALL (display both temperature and measured value)
Return format
Return the query result by character
[SENSe:]CONT:THREshold
Syntax
[SENSe:]CONT:THREshold <values>
Description
Sets the continuity threshold
CONFigure command sub system
CONFigure sub system is used to switch measure mode
CONFigure[:SCALar][:VOLTage]:{AC|DC}
Syntax
CONFigure[:SCALar][:VOLTage]:{AC|DC} [<range>]
4
SCPI Command List
Description
Restore all the measurement and trigger parameters to default, process AC/DC voltage
measurement. Then set the measuring range.
Parameter
Name Type Range
<range> Discrete AC: 500E-3(500mV), 5(5V), 50(50V), 500(500V), 750(750V)
DC: 500E-3(500mV), 5(5V), 50(50V), 500(500V), 1000(1000V)
CONFigure[:SCALar]:CURRent:{AC|DC}
Syntax
CONFigure[:SCALar]:CURRent:{AC|DC} [<range>]
Description
Restore all the measurement and trigger parameters to default, process AC/DC current
measurement. Then set the measuring range.
Parameter
Name Type Range
<range> Discrete AC: 500E-3(500mV), 5(5V), 50(50V), 500(500V), 750(750V)
DC: 50E-3(50mV), 500E-3(500mV), 5(5V), 50(50V), 500(500V), 1000(1000V)
CONFigure[:SCALar]:{RESistance|FRESistance}
Syntax
CONFigure[:SCALar]:{RESistance|FRESistance} [<range>]
5
SCPI Command List
Description
Restore all the measurement and trigger parameters to default, process RESistance and
FRESistance measurement. Then set the measuring range.
Parameter
Name Type Range
<range> Discrete 500(500Ω), 5E3(5KΩ), 50E3(50KΩ), 500E3(500KΩ), 5E6(5MΩ), 50E6(50MΩ),
500E6(500MΩ)
Note: the maximum range of four-wire resistance is 50KΩ.
CONFigure[:SCALar]:{FREQuency|PERiod}
Syntax
CONFigure[:SCALar]:{FREQuency|PERiod}
Description
Restore all the measurement and trigger parameters to default, process FREQuency/PERiod
measurement.
CONFigure[:SCALar]:CAPacitance
Syntax
CONFigure[:SCALar]:CAPacitance [<range>]
Description
Restore all the measurement and trigger parameters to default, process capacitance
measurement. Then set the scale.
6
SCPI Command List
Parameter
Name Type Range
<range> Discrete 50E-9(50nF),500E-9(500nF),5E-6(5uF),50E-6(50uF),500E-6(500uF),5E-3(5mF),
50E-3(50mF)
CONFigure[:SCALar]:TEMPerature:RTD
Syntax
CONFigure[:SCALar]:TEMPerature:RTD [{<RTD Type>}]
Description
Restore all the measurement and trigger parameters to default, process temperature
measurement. Then set the PT type.
Parameter
Name Type Range
<RTD Type > Discrete KITS90, PT100
CONFigure[:SCALar]:DIODe
Syntax
CONFigure[:SCALar]:DIODe
Description
Restore all the measurement and trigger parameters to default, process diode measurement.
7
SCPI Command List
Parameter
CONFigure[:SCALar]:CONTinuity
Syntax
CONFigure[:SCALar]:CONTinuity
Description
Restore all the measurement and trigger parameters to default, process continuity test.
Parameter
CALCulate command Subsystem
CALCulate command is used to manage math function (Sum up, db/dbm, relative value),
Function command is used to switch math mode (from three modes). AVERage, DB,DBM, NULL
command is used to set corresponding function parameter, won’t change the current math
function.
CALCulate:AVERage:ALL?
Syntax
CALCulate:AVERage:ALL?
Description
8
SCPI Command List
Query returns the minimum value, maximum value , average value and count of all
measurements taken since the statistics were last cleared.
Parameter
(none)
CALCulate:AVERage:AVERage?
Syntax
CALCulate:AVERage:AVERage?
Description
Query returns the average value of all measurements taken since the statistics were last cleared.
Parameter
(none)
CALCulate:AVERage:MAXimum?
Syntax
CALCulate:AVERage:MAXimum?
Description
9
SCPI Command List
Query returns the maximum value of all measurements taken since the statistics were last
cleared.
Parameter
(none)
CALCulate:AVERage:MINimum?
Syntax
CALCulate:AVERage:MINimum?
Description
Query returns the minimum value of all measurements taken since the statistics were last
cleared.
Parameter
(none)
CALCulate:DB:REFerence
Syntax
CALCulate:DB:REFerence <Ref R>
CALCulate:DB:REFerence?
Description
10
SCPI Command List
Set DB relative resistance.
Parameter
Name Type Range
<Ref R> Discrete 50, 75, 93, 110, 124, 125, 135, 150, 250, 300, 500, 600, 800, 900, 1000, 1200, 8000
CALCulate:DBM:REFerence
Syntax
CALCulate:DBM:REFerence <Ref R>
CALCulate:DBM:REFerence?
Description
Set DBM relative resistance.
Parameter
Name Type Range
<Ref R> Discret 50, 75, 93, 110, 124, 125, 135, 150, 250, 300, 500, 600, 800, 900, 1000, 1200, 8000
e
CALCulate:FUNCtion
Syntax
CALCulate:FUNCtion {NULL|DB|DBM|AVERage}
CALCulate:FUNCtion?
Description
Set mathematic calculation as NULL, DB, DBM, AVERage.
11
SCPI Command List
CALCulate:NULL:OFFSet
Syntax
CALCulate:NULL:OFFSet {<value>|MINimum|MAXimum}
CALCulate:NULL:OFFSet? [MINimum|MAXimum]
Description
Set relative value.
Parameter
Name Type Range
<value>
CALCulate:STATe
Syntax
CALCulate:STATe {OFF}
Description
Close MATH function
Parameter
Name Type Range
<bool> Bool {OFF}
12
SCPI Command List
SYSTem command Subsystem
SYSTem:BEEPer:STATe
Syntax
SYSTem:BEEPer:STATe {ON|OFF}
SYSTem:BEEPer:STATe?
Description
Start or close the buzzer
Parameter
Name Type Range 默认值
<bool> Bool {ON|OFF} ON
Return format
Return 0 (OFF) or 1 (ON) after query。
SYSTem:DATE?
Syntax
SYSTem:DATE?
Description
Query date (includes year, month and day) inside device real-time clock
Parameter
13
SCPI Command List
Return format
Return query result
SYSTem:TIME?
Syntax
SYSTem:TIME?
Description
Query time (includes hour, minute and second) inside device real-time clock
Parameter
Return format
Return query result
SYSTem:LOCal
Syntax
SYSTem:LOCal
Description
Exit SCPI mode
Parameter
14
SCPI Command List
SYSTem:REMote
Syntax
SYSTem:REMote
Description
Enter SCPI mode
Parameter
Other commands
AUTO
Syntax
AUTO
AUTO?
Description
Enable autoscale
Parameter
Return format
15
SCPI Command List
Return autoscale setting, 1 for auto, 0 for manual
RANGE
Syntax
RANGE {<range1>|DEF}
Description
Set measuring range
Parameter
Name Type Range
DCV 1(50mV), 2(500mV), 3(5V), 4(50V), 5(500V), 6(1000V)
ACV 1(500mV), 2(5V), 3(50V), 4(500V), 5(750V)
DCI 1(500uA), 2(5mA), 3(50mA), 4(500mA), 5(5A), 6(10A)
<range1> Discrete ACI 1(500uA), 2(5mA), 3(50mA), 4(500mA), 5(5A), 6(10A)
RES 1(500Ω), 2(5KΩ), 3(50KΩ), 4(500KΩ), 5(5MΩ), 6(50MΩ)
CAP 1(50nF), 2(500nF), 3(5uF), 4(50uF), 5(500uF), 6(5mF) ,7(50mF)
TEMP 1(KITS90),2(PT100)
RATE
Syntax
RATE <speed>
RATE?
Description
Set speed.
Parameter
16
SCPI Command List
Name Type Range
<speed> Discret F:high speed; M:middle speed; L:low speed
e
Return format
Return current speed, F for high speed, M for middle speed, L for low speed.
MEAS?
Syntax
MEAS?
Description
If start dual display, return main and sub display measured value; or return main display measure
value.
Parameter
Return format
Return measured result by scientific notation. If start dual display, the return format is: main
display measured value, sub display measured value.
MEAS1?
Syntax
MEAS1?
Description
17
SCPI Command List
Return main display measured value
Parameter
Return format
Return measured result by scientific notation.
MEAS2?
Syntax
MEAS2?
Description
Return sub display measured value
Parameter
Return format
Return measured result by scientific notation.
18