User Tools

Site Tools


slice:dhv:api

This is an old revision of the document!


Table of Contents

SLICE-DHV Serial API

Implementation Instructions

Listed below is the command set for the Application Programming Interface (API) for the SLICE-DHV. All operations that can be performed via the touchscreencan be also be performed via the API.

Computer communication to the SLICE instrument occurs by first establishing a Serial COM port via the USB 2.0 physical interface. Computer communication should be platform independent, though appropriate USB drivers may have to be installed. The following table shows the serial port settings:

Baud Rate 9600
Data Bits 8
Parity None
Stop Bits 1
Flow Control None

To perform an operation, an ASCII-based text message is first constructed from a command and its arguments, and then the message is transmitted to the SLICE instrument through the COM port. The following rules apply:

  1. Syntax is insensitive to case.
  2. A message is an ASCII string composed of a command followed by zero or more arguments.
  3. A command and its arguments are delimited by spaces.
  4. Messages are terminated by a carriage return (“\r”).
  5. All valid messages return an ASCII string value.
  6. [Int] refers to an integer argument that has no decimal point.
  7. [Float] refers to a floating point argument that has a decimal point in its value.

Changes effected by issuing a serial command from this API are not permanently stored in non-volatile memory until you issue a SAVE command. Configuration changes without the SAVE command will be lost with power cycling. The Save command stores the entire configuration and so several configuration changes can be implemented and then a single SAVE command could be issued.

SLICE-DHV Specific Notes

  1. Valid values for the CHANNEL argument are {1, 2}.
  2. All enable commands use an integer argument to convey the state: 0 = Off, 1 = On.
  3. All voltages are set and returned in Volts [V].

Global SLICE Commands

The following commands are operational on all SLICE products.


Obtain System Controller firmware version: #VERSION

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns firmware version of System Controller.


Reset System to Factory default: _FACTORY

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Restores “Personality Board” to factory default settings. No return value.

Power cycle the SLICE unit to complete factory reset.

Save current configuration in non-volatile memory: SAVE

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Saves “Personality Board” settings into EEPROM. Unsaved changes will be lost if board is powered off without issuing a SAVE command. The SAVE command saves the entire configuration into non-volatile memory. A single SAVE command can be issued after any number of configuration changes. When changes are made to the SLICE configuration through the touch screen, the new values are automatically saved and it is not necessary to issue a SAVE command.

Slot Number

  • 1 = first slot
  • 2 = second slot

Possible Responses

  • SUCCESS
  • FAIL

SCPI device information: *IDN?

Replace [asterix] with a *

Arguments: None

Example:

   
Vescent Photonics, [serial#], S-V1.74, DHV-V1.18

I2C Command Number:


Description

Returns SCPI device information. Running System Controller firmware version 1.74 and DHV firmware version 1.18.


SLICE-DHV-specific Commands

The following commands are specific to the SLICE-DHV high-voltage amplifier.

Changes to operation parameters executed by these commands are stored only in RAM. If you wish to permanently save new parameter values, you must execute a SAVE command after parameter changes.

Query Output Voltage Maximum: VLIM?

Arguments:

[Int] CHANNEL

Example:

 2 
123.45

I2C Command Number:


Description

Returns maximum output in Volts for CHANNEL.

  • In the example, CH 2 is seen to have a maximum of 123.45 V.
  • Set Vout maximum with the VLIM command.

Set Output Voltage Maximum: VLIM

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Sets the maximum output in Volts for CHANNEL.

  • In the example, the maximum output of CH 2 is set to 123.45 V.
  • Returns VLIM?
  • Query Vout maximum with the VLIM? command.

Query Operation Mode: CONTROL?

Arguments:

[Int] CHANNEL

Example:

 1  
0

I2C Command Number:


Description

Returns the enumerated modulation mode and status for CHANNEL. Where:

Response Gain Range Operation Status
0 1 V/V ±10 V OFF
1 20 V/V 0-200 V OFF
2 1 V/V ±10 V ON
3 20 V/V 0-200 V ON
Tab. 1: Possible return values & meaning for CHANNEL? command
  • In the example, CH 1 is found to have Gain = 1 V/V, allowing control over the range of Vout = Vbias ± 10 V, with the voltage output turned off.
  • Set these parameters with the CONTROL command.

—-

Set Operation Mode: CONTROL

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Sets the enumerated modulation mode and status for CHANNEL. Where:

MODE Input Gain Range Operation Status
0 1 V/V ±10 V OFF
1 20 V/V 0-200 V OFF
2 1 V/V ±10 V ON
3 20 V/V 0-200 V ON
Tab. 1: Possible return values & meaning for CHANNEL? command
  • In the example, CH 2 is set to Mode 2 (Gain = 1 V/V, with control over the range Vout = Vbias ± 10 V). The output of CH 2 is turned ON.
  • Returns value of CONTROL?

Query DC Bias: DCBIASV?

Arguments:

[Int] CHANNEL

Example:

 2 
123.456

I2C Command Number:


Description

Returns Vbias in Volts for CHANNEL.

  • In the example, CH 2 has Vbias = 123.456 V.
  • If the CHANNEL is turned OFF, the returned value will be Vbias, but Vout will remain at 0 V.
  • Set Vbias with the DCBIASV command.

Set DC Bias: DCBIASV

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns DCBIASV?

  • In the example, CH 2 Vbias is set to 123.45 V.
  • If the CHANNEL is turned OFF, Vbias will be set to the input value, but Vout will remain at 0 V until the CHANNEL is turned ON.
  • If a value that is negative or above the Voltage Limit (see below) is attempted, the value will be set to the exceeded boundary.
  • Query Vbias with the DCBIASV? command.
  • Query Vout with the OUTVOLT? command.

Query Output Voltage: OUTVOLT?

Arguments:

[Int] CHANNEL

Example:

 2 
123.45689

I2C Command Number:


Description

Returns Vout for CHANNEL.

  • In the example, CH 2 reports Vout = 123.456789 V.
  • The user can only directly set Vbias, not Vout.

Query Range of Voltage Sweep: RANGEV?

Arguments:

[Int] CHANNEL

Example:

 2 
12.34

I2C Command Number:


Description

Returns Range of the Sweep in Volts for CHANNEL.

  • In the example, CH 2 is seen to have a Sweep Range of 12.34 V.
  • Vout sweeps from (Vbias - Range/2) to (Vbias + Range/2) in a sawtooth waveform.
  • If the CHANNEL is turned OFF, the returned value will be the Range over which Vout will sweep when the CHANNEL is turned ON, but Vout will remain at 0 V.
  • Set Range with the RANGEV command.

Set Range of Voltage Sweep: RANGEV

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Sets Range of the Sweep in Volts for CHANNEL.

  • Returns RANGEV?
  • In the example, the Range of the Sweep for CH 1 is set to 12.34 V.
  • Vout sweeps from (Vbias - Range/2) to (Vbias + Range/2) in a sawtooth waveform.
  • If the CHANNEL is turned OFF, the value will be the Range over which Vout will sweep when the CHANNEL is turned ON, but Vout will remain at 0 V.
  • Query Range with the RANGEV? command.

Query Repetition Rate of Voltage Sweep: SWEEPRT?

Arguments:

[Int] CHANNEL

Example:

 2 
12.34

I2C Command Number:


Description

Returns Repetition Rate of the Sweep in Hertz for CHANNEL.

  • In the example, CH 2 is seen to have a Sweep Repetition Rate of 12.34 Hz.
  • Set Sweep repetition rate with the SWEEPRT command.

Set Repetition Rate of Voltage Sweep: SWEEPRT

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Sets CHANNEL Sweep Repetition Rate to Rep_Rate (in Hertz).

  • Returns SWEEPRT?
  • In the example, the Repetition Rate of the Sweep for CH 1 is set to 12.34 Hz
  • Valid Repetition Rate Range: 0-30 Hz
  • Query Sweep repetition rate with the SWEEPRT? command

Query Sweep Mode: SWEEPMD?

Arguments:

[Int] CHANNEL

Example:

 1 
2

I2C Command Number:


Description

Returns the enumerated Current Sweep Mode for CHANNEL.

Response Sweep Mode Status
0 OFF
1 ON
2 Sweep Tune
Tab. 3: Possible return values & meaning for SWEEPMD? command
  • In the example, CH 1 is seen to be in TUNE Mode.
  • To set Sweep Mode use SWEEPMD command.

—-

Set Sweep Mode: SWEEPMD

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns SWEEPMD? for CHANNEL.

Response Sweep Status
0 OFF
1 ON
2 Sweep Tune
Tab. 4: Possible input values & meaning for SWEEPMD command
  • In the example, CH 1 Sweep Mode is set to OFF.
  • To query Sweep Mode use SWEEPMD? command.

Query Repetition Rate of Voltage Sweep: SWEEPRT?

Arguments:

[Int] CHANNEL

Example:

 2 
12.34

I2C Command Number:


Description

Returns Repetition Rate of the Sweep in Hertz for CHANNEL.

  • In the example, CH 2 is seen to have a Sweep Repetition Rate of 12.34 Hz.
  • Set Sweep repetition rate with the SWEEPRT command.

Set Repetition Rate of Voltage Sweep: SWEEPRT

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Sets CHANNEL Sweep Repetition Rate to Rep_Rate (in Hertz).

  • Returns SWEEPRT?
  • In the example, the Repetition Rate of the Sweep for CH 1 is set to 12.34 Hz
  • Valid Repetition Rate Range: 0-30 Hz
  • Query Sweep repetition rate with the SWEEPRT? command

Query Sweep Mode: SWEEPMD?

Arguments:

[Int] CHANNEL

Example:

 1 
2

I2C Command Number:


Description

Returns the enumerated Current Sweep Mode for CHANNEL.

Response Sweep Mode Status
0 OFF
1 ON
2 Sweep Tune
Tab. 3: Possible return values & meaning for SWEEPMD? command
  • In the example, CH 1 is seen to be in TUNE Mode.
  • To set Sweep Mode use SWEEPMD command.

—-

Set Sweep Mode: SWEEPMD

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns SWEEPMD? for CHANNEL.

Response Sweep Status
0 OFF
1 ON
2 Sweep Tune
Tab. 4: Possible input values & meaning for SWEEPMD command
  • In the example, CH 1 Sweep Mode is set to OFF.
  • To query Sweep Mode use SWEEPMD? command.

Query Error Code: ERROR?

Arguments:

[Int] CHANNEL

Example:

 1 
49152

I2C Command Number:


Description

Returns the Error Code for CHANNEL.

Response Meaning
49152 No Error
Other Error Codes TBD
Tab. 7: Possible return values & meaning for ERROR? command
  • In the example, CH 1 did not detect an Error.
  • To clear an Error Code, use ERROR command.

Clear Error Code: Error

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns ERROR? for CHANNEL.

Input Error Cleared
49152 No error detected
TBD Other errors
Tab. 8
  • In the example, the “no error detected” code is cleared for CH 1.
  • To query Error Code, use ERROR? command.

Query Response to Trigger In: TRIGIN?

Arguments:

[Int] CHANNEL

Example:

 1 
1

I2C Command Number:


Description

Returns the effect of Trigger In signal on CHANNEL as seen in table 9.

Response Meaning
0 Trigger In status has no effect on CHANNEL
1 High signal on Trigger In enables CHANNEL. Low signal on Trigger In disables CHANNEL
Tab. 9: Possible return values & meaning for TRIGIN? command
  • In the example, CH 1 will respond to a Trigger In signal.
  • To set the response to a Trigger In signal, use TRIGIN

Set Response to Trigger In: TRIGIN

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns TRIGIN? for CHANNEL.

Selection Programmed Response to Trigger In
0 CHANNEL will not respond to Trigger In
1 High signal on Trigger In enables CHANNEL. Low signal on Trigger In disables CHANNEL
Tab. 10
  • In the example, CHANNEL 1 will henceforth respond to Trigger In.
  • To query response to trigger input, use TRIGIN? command.

Query Trigger Out Meaning: TRIGOUT?

Arguments:

[Int] CHANNEL

Example:

 1 
1

I2C Command Number:


Description

Returns the meaning of the Trigger Out signal with respect to CHANNEL as seen in table 11.

Response Meaning
0 No change in state of the Trigger Out based state of CHANNEL
1 The signal at Trigger Out will go high in sync with the ramp on CHANNEL
Tab. 11: Possible return values & meaning for TTL high at the Trigger Out
  • In the example, the signal at Trigger Out will go high in sync with the ramp on CH 1.
  • To set the meaning of the Trigger Out signal, use TRIGOUT

Set Trigger Out: TRIGOUT

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns TRIGOUT? for CHANNEL.

Selection Meaning of Trigger Out with respect to CHANNEL
0 Trigger out is unresponsive to state of CHANNEL
1 A TTL high signal at Trigger Out will be in sync with ramp of CHANNEL
Tab. 12
  • In the example, Trigger Out will go high in sync with ramp on CH 1
  • To query Trigger Out meaning, use TRIGOUT? command
  • Setting the Trigger Out to be in sync with CH 1 removes Trigger Out's synchronicity with CH 2 & vice versa

Query Source of Modulation Signal for CH 1: MODEA?

Arguments:

No Arguments Taken

Example:

  
257

I2C Command Number:


Description

Returns from where CH 1 receives modulation control as seen in table 13.

Response Meaning
0 CH 1 accepts its modulation signal from rear-panel SMA connector
257 CH 1 accepts its modulation signal from front-panel Input A BNC connector
Tab. 13: Possible return values & meaning MODEA? command
  • In the example, CH 1 accepts its modulation signal from the front-panel Input A.
  • To set from where CH 1 accepts a modulation signal, use MODEA
  • Only one modulation source may be active at a time

Set Source of Modulation Signal for CH 1: MODEA

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns MODEA?

Mode Location of modulation input for CH 1
0 CH 1 accepts modulation signal from rear-panel SMA connector
1 CH 1 accepts modulation signal from front-panel Input A BNC connector
Tab. 14
  • In the example, CH 1 will accept a modulation signal from the front-panel Input A BNC
  • To query the modulation source for CH 1, use MODEA? command

Query Source of Modulation Signal for CH 2: MODEB?

Arguments:

No Arguments Taken

Example:

  
513

I2C Command Number:


Description

Returns from where CH 2 receives modulation control as seen in table 15.

Response Meaning
0 CH 2 accepts its modulation signal from rear-panel SMA connector
513 CH 2 accepts its modulation signal from front-panel Input B BNC connector
Tab. 15: Possible return values & meaning MODEB? command
  • In the example, CH 2 accepts its modulation signal from the front-panel Input B.
  • To set from where CH B accepts a modulation signal, use MODEB
  • Only one modulation source may be active at a time

Set Source of Modulation Signal for CH 2: MODEB

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns MODEB?

Mode Location of modulation input for CH 2
0 CH 2 accepts modulation signal from rear-panel SMA connector
1 CH 2 accepts modulation signal from front-panel Input B BNC connector
Tab. 16
  • In the example, CH 2 will henceforth accept a modulation signal from the front-panel Input B BNC
  • To query the modulation source for CH 2, use MODEB? command

Query Signal Delivered to Front-Panel Output 1: MODE1?

Arguments:

No Arguments Taken

Example:

  
257

I2C Command Number:


Description

Returns identity of signal delivered to front-panel Output 1 according to table 17.

Response Meaning
0 Front-panel Output 1 has no signal
257 Front-panel Output 1 monitors CH 1 HV output
Tab. 17: Possible return values & meaning MODE1? command
  • In the example, front-panel output 1 is monitoring CH 1 output
  • V1 = VCH 1 ÷ 20
  • To set what signal is delivered to front-panel Output 1, use MODE1

Set Signal Delivered to Front-Panel Output 1: MODE1

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns MODE1?

Mode Result
0 Sets signal at front-panel Output 1 to no signal
1 Sets signal at front-panel Output 1 to monitor CH 1 Output
Tab. 18
  • In the example, front-panel Output 1 will henceforth monitor the CH 1 output
  • Vout = VCH 1 ÷ 20
  • To query the signal delivered to the front-panel Output 1, use MODE1? command

Query Signal Delivered to Front-Panel Output 2: MODE2?

Arguments:

No Arguments Taken

Example:

  
513

I2C Command Number:


Description

Returns identity of signal delivered to front-panel Output 2 according to table 19.

Response Meaning
0 Front-panel Output 2 has no signal
513 Front-panel Output 2 monitors CH 2 HV output
Tab. 19: Possible return values & meaning MODE2? command
  • In the example, front-panel Output 2 is monitoring CH 2 output
  • V2 = VCH 2 ÷ 20
  • To set what signal is delivered to front-panel Output 2, use MODE2

Set Signal Delivered to Front-Panel Output 2: MODE2

Arguments:

No Arguments Taken

Example:

I2C Command Number:


Description

Returns MODE2?

Mode Result
0 Sets signal at front-panel Output 2 to no signal
1 Sets signal at front-panel Output 2 to monitor CH 2 Output
Tab. 20
  • In the example, front-panel Output 2 will henceforth monitor the CH 2 output
  • Vout = VCH 2 ÷ 20
  • To query the signal delivered to the front-panel Output 2, use MODE2? command

slice/dhv/api.1590799042.txt.gz · Last modified: 2021/08/26 14:26 (external edit)