Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

keyoscacquire is a Python package for acquiring traces from Keysight oscilloscopes through a VISA interface.

Project description

keyoscacquire is a Python package for acquiring traces from Keysight InfiniiVision oscilloscopes through a VISA interface.

Based on PyVISA, keyoscacquire provides programmes for acquiring and exporting traces to your choice of ASCII format files (default csv) or numpy npy, and a png of the trace plot. The package provides a class Oscilloscope and data processing functions that can be used in other scripts. For example, to capture the active channels on an oscilloscope connected with VISA address USB0::1234::1234::MY1234567::INSTR from command prompt:

get_single_trace -v USB0::1234::1234::MY1234567::INSTR

or in the python console:

>>> import keyoscacquire.oscacq as koa
>>> osc = koa.Oscilloscope(address='USB0::1234::1234::MY1234567::INSTR')
>>> time, y, channel_numbers = osc.set_options_get_trace()

where time is a vertical numpy vector of time values and y is a numpy array which columns contain the data from the active channels listed in channel_numbers.

If you need to find the VISA address of your oscilloscope, use the command line programme list_visa_devices provided by this package.

The code has been tested on Windows 7 and 10 with a Keysight DSO2024A model using a USB connection.


In order to connect to a VISA instrument, NI MAX or similar might need to be running on the computer. Installation of Keysight Connection Expert might also be necessary.


Available here.


Contributions are welcome, find the project on github. The package is written and maintained by Andreas Svela.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for keyoscacquire, version 3.0.1
Filename, size File type Python version Upload date Hashes
Filename, size keyoscacquire-3.0.1-py3-none-any.whl (20.3 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size keyoscacquire-3.0.1.tar.gz (18.5 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page