Reply To: SA44B python API

Forums SA Series Discussions SA44B python API Reply To: SA44B python API

#247043
RogerRoger
Moderator

Hi Gal,

There are potentially two ways to accomplish this in Python: using Spike’s SCPI interface or with the device API. The SDK contains the needed resources for both, and can be downloaded here.

1. SCPI

Spike can be programmatically controlled with SCPI commands. Presets can be loaded using the following commands, for named and quick presets respectively:

:SYSTem:PRESet[:USER]:LOAD
*RCL

Then, an acquisition command such as :TRACe[:DATA]? would be used to get the sweep data, which Python could then output to CSV.

An example to get you started is in the SDK at scpi/Spike/examples/python/scpi_simple_sweep.py. The Spike SCPI Programming Manual is also there as a command reference.

2. API

This is a direct connection to the device that is an alternative to Spike.

The configuration functions would be used to replicate the Spike preset, followed by an acquisition function to get the data, and then output CSV from Python.

An example to get you started is in the SDK at device_apis/sa_series/examples/python/sweep_plot.py. The API documentation is available there and online here.

Let me know if you have further questions.

Roger