

#idString RIGOL TECHNOLOGIES,DP832A,
#name Rigol DP832A
#handle DP832A
#port 5555


; A list of possible column name with unit and formatter (SI, Time, Int, D0..D6)
#value Voltage_CH1 V D3 
#value Current_CH1 A D3 
#value Power_CH1 W D3
#value VoltageSet_CH1 V D3 
#value CurrentSet_CH1 A D3 
#value Voltage_CH2 V D3 
#value Current_CH2 A D3 
#value Power_CH2 W D3
#value VoltageSet_CH2 V D3 
#value CurrentSet_CH2 A D3 
#value Voltage_CH3 V D3 
#value Current_CH3 A D3 
#value Power_CH3 W D3
#value VoltageSet_CH3 V D3 
#value CurrentSet_CH3 A D3 

; How to poll for data, this is used for table and #values?
; a #askMode, #cmdMode and #prepareSample is used before this is string is used.
; This is a single line command
#askValues :MEASURE:VOLTAGE? CH1;:MEASURE:CURRENT? CH1;:MEASURE:POWER? CH1;:SOUR1:VOLT?;:SOUR1:CURRENT?;:MEASURE:VOLTAGE? CH2;:MEASURE:CURRENT? CH2;:MEASURE:POWER? CH2;:SOUR2:VOLT?;:SOUR2:CURRENT?;:MEASURE:VOLTAGE? CH3;:MEASURE:CURRENT? CH3;:MEASURE:POWER? CH3;:SOUR3:VOLT?;:SOUR3:CURRENT?


; Format of answer: f=float, u=remove trailing letters, x=skip
#askValuesReadFormat 

; Accept this delay when reading values (seconds)
;#readingDelay 2

; Mode change have a longer delay on reading values (seconds)
;#modeChangeDelay 10

; Switch meter to this mode during start, leave empty to avoid any switching
#initialMode 

; String to ask about actual meter mode, 
; This is a single line command
#askMode 

; When one of these commands are used through the command interface a new configuration will be done before using #askMode
; Only one word for each #mayModifyMode
; Specify command without initial colon and in the shortest possible form
;#mayModifyMode 



; Prepare the meter to response to #askValues
#prepareSample


; Initial commands to meter when establishing connection
#initCmd  


; Final command to meter before breaking connection
#finalCmd :SYSTEM:LOCAL
; :OUTP OFF;:VOLT 1;:CURRENT 0;

#outputOff :OUTP OFF


#interfaceType PS
#interface setVoltage :VOLT (value)
#interface setCurrent :CURRENT (value)
#interface setOn :OUTPUT (value)
#interface getVoltage :VOLT?
:readFormat: f
#interface getCurrent :CURRENT?
:readFormat: f
#interface getOn :OUTPUT:STAT?
#interface readVoltage 0
#interface readCurrent 1



; Strings to configure device in different modes
; First parameter must match a #value (4 parameter) and second parameter must match what #askMode returns
; First parameter is also used in shortcut menu
;#cmdMode 

; Setup menu functions
; The parameters on the first line is: type name page 
; Settings on the following lines are:
; read: SCPI to read value from device, is used to synchronize when opening setup page or setting equal named fields. Not always used
; readformat: Parse read value.
; write: Send the value to device, this field is used in combination with data fields in the details to send updates to device.
; tip: Add this tip to all components for this input field.


#cmdSetup buttonsOn CH1_Output Main 
:read: :OUTPUT? CH1
:write: :OUTPUT CH1,
:readmath: getElement("OFF ON",listIndex(value,"OFF ON"," ")," ")
:string:
:tip: Turn output on or off
:updatealloff:
:update: Output
:updatedelayed: 0.3 
Off OFF
On ON


#cmdSetup radio CH1_Voltage Main 
:read: :SOURCE1:VOLT?;
:readFormat: 
:write: :SOURCE1:VOLT #
:tip: Setup this voltage
3V 3
5V 5.0
12V 12.0
24V 24.0

#cmdSetup radio CH1_Current Main 
:read: :SOURCE1:CURRENT?
:readFormat: 
:write: :SOURCE1:CURRENT
:tip: Output will current limit at this current
100mA 0.1
300mA 0.3
1A 1.0
3A 3.0

#cmdSetup number CH1_Voltage Main 
:read: :SOURCE1:VOLT?
:readformat: f
:write: :SOURCE1:VOLT 
:tip: Setup this voltage, do not turn output on/off
Volt 0 32


#cmdSetup number CH1_Current Main 
:read: :SOURCE1:CURRENT?
:readformat: f
:write: :SOURCE1:CURRENT 
:tip: Setup this current, do not turn output on/off
Amps 0.0001 3.2


#cmdSetup buttonsOn CH2_Output Main 
:read: :OUTPUT? CH2
:write: :OUTPUT CH2,
:readmath: getElement("OFF ON",listIndex(value,"OFF ON"," ")," ")
:string:
:tip: Turn output on or off
:updatealloff:
:update: Output
:updatedelayed: 0.3 
Off OFF
On ON


#cmdSetup radio CH2_Voltage Main 
:read: :SOURCE2:VOLT?;
:readFormat: 
:write: :SOURCE2:VOLT #
:tip: Setup this voltage
3V 3
5V 5.0
12V 12.0
24V 24.0

#cmdSetup radio CH2_Current Main 
:read: :SOURCE2:CURRENT?
:readFormat: 
:write: :SOURCE2:CURRENT
:tip: Output will current limit at this current
100mA 0.1
300mA 0.3
1A 1.0
3A 3.0

#cmdSetup number CH2_Voltage Main 
:read: :SOURCE2:VOLT?
:readformat: f
:write: :SOURCE2:VOLT 
:tip: Setup this voltage, do not turn output on/off
Volt 0 32

#cmdSetup number CH2_Current Main 
:read: :SOURCE2:CURRENT?
:readformat: f
:write: :SOURCE2:CURRENT 
:tip: Setup this current, do not turn output on/off
Amps 0.0001 3.2


;Chanel 3


#cmdSetup buttonsOn CH3_Output Main 
:read: :OUTPUT? CH3
:write: :OUTPUT CH3,
:readmath: getElement("OFF ON",listIndex(value,"OFF ON"," ")," ")
:string:
:tip: Turn output on or off
:updatealloff:
:update: Output
:updatedelayed: 0.3 
Off OFF
On ON


#cmdSetup radio CH3_Voltage Main 
:read: :SOURCE3:VOLT?;
:readFormat: 
:write: :SOURCE3:VOLT #
:tip: Setup this voltage
1V 1.0
2V 2.0
3V 3.0
5V 5.0

#cmdSetup radio CH3_Current Main 
:read: :SOURCE3:CURRENT?
:readFormat: 
:write: :SOURCE3:CURRENT
:tip: Output will current limit at this current
100mA 0.1
300mA 0.3
1A 1.0
3A 3.0

#cmdSetup number CH3_Voltage Main 
:read: :SOURCE3:VOLT?
:readformat: f
:write: :SOURCE3:VOLT 
:tip: Setup this voltage, do not turn output on/off
Volt 0 5

#cmdSetup number CH3_Current Main 
:read: :SOURCE3:CURRENT?
:readformat: f
:write: :SOURCE3:CURRENT 
:tip: Setup this current, do not turn output on/off
Amps 0.0001 3.2

;Limits----------------


#cmdSetup number CH1_OVP Limits 
:read: :SOURCE1:VOLT:PROT?
:readformat: f
:write: :SOURCE1:VOLT:PROT #;:SOURCE(1):VOLT:PROT:STAT ON
:tip: Output will turn off if it is above this voltage
Volt 0.001 33

#cmdSetup radio CH1_OVP Limits 
:read: :SOURCE1:VOLT:PROT:STAT?
:string: 
:write: :SOURCE1:VOLT:PROT:STAT  
:tip: Turn over voltage protection (OVP) on or off
Off OFF
On ON

#cmdSetup number CH1_OCP Limits 
:read: :SOURCE1:CURRENT:PROT?
:readformat: f
:write: :SOURCE1:CURRENT:PROT #;:SOURCE(1):CURRENT:PROT:STAT ON
:tip: Output will turn off if it is above this current
Amps 0.001 3.3

#cmdSetup radio CH1_OCP Limits 
:read: :SOURCE1:CURRENT:PROT:STAT?
:string: 
:write: :SOURCE1:CURRENT:PROT:STAT  
:tip: Turn over current protection (OCP) on or off
Off OFF
On ON


#cmdSetup number CH2_OVP Limits 
:read: :SOURCE2:VOLT:PROT?
:readformat: f
:write: :SOURCE2:VOLT:PROT #;:SOURCE2:VOLT:PROT:STAT ON
:tip: Output will turn off if it is above this voltage
Volt 0.001 33

#cmdSetup radio CH2_OVP Limits 
:read: :SOURCE2:VOLT:PROT:STAT?
:string: 
:write: :SOURCE2:VOLT:PROT:STAT  
:tip: Turn over voltage protection (OVP) on or off
Off OFF
On ON

#cmdSetup number CH2_OCP Limits 
:read: :SOURCE2:CURRENT:PROT?
:readformat: f
:write: :SOURCE2:CURRENT:PROT #;:SOURCE2:CURRENT:PROT:STAT ON
:tip: Output will turn off if it is above this current
Amps 0.001 3.3

#cmdSetup radio CH2_OCP Limits 
:read: :SOURCE2:CURRENT:PROT:STAT?
:string: 
:write: :SOURCE2:CURRENT:PROT:STAT  
:tip: Turn over current protection (OCP) on or off
Off OFF
On ON

;CH 3 limits


#cmdSetup number CH3_OVP Limits 
:read: :SOURCE3:VOLT:PROT?
:readformat: f
:write: :SOURCE3:VOLT:PROT #;:SOURCE3:VOLT:PROT:STAT ON
:tip: Output will turn off if it is above this voltage
Volt 0.001 5

#cmdSetup radio CH3_OVP Limits 
:read: :SOURCE3:VOLT:PROT:STAT?
:string: 
:write: :SOURCE3:VOLT:PROT:STAT  
:tip: Turn over voltage protection (OVP) on or off
Off OFF
On ON

#cmdSetup number CH3_OCP Limits 
:read: :SOURCE3:CURRENT:PROT?
:readformat: f
:write: :SOURCE3:CURRENT:PROT #;:CURRENT:PROT:STAT ON
:tip: Output will turn off if it is above this current
Amps 0.001 3.3

#cmdSetup radio CH3_OCP Limits 
:read: :SOURCE3:CURRENT:PROT:STAT?
:string: 
:write: :SOURCE3:CURRENT:PROT:STAT  
:tip: Turn over current protection (OCP) on or off
Off OFF
On ON

#cmdSetup radio Display Display
:read: :DISPLAY?
:string:
:write: :DISPLAY 
:tip: Turn the front panel off and on
Off OFF
On ON


#cmdSetup radio Display_brightness Display
:read: :SYSTEM:BRIGHTNESS?
:write: :SYSTEM:BRIGHTNESS 
:tip: Adjust the front panel brightness
Min 1
25% 25
50% 50
Max 100


#cmdSetup radio Display_mode Display
:read: :DISPLAY:MODE?
:string:
:write: :DISPLAY:MODE 
:tip: Set the front panel display mode
Normal NORMAL
Waveform WAVE
Dials DIAL



