Skip to main content

Python VISA bindings for GPIB, RS232, TCPIP and USB instruments

Project description

Continuous integration Documentation building Keysight assisted testing Code Coverage Documentation Status PyPI - License PyPI https://joss.theoj.org/papers/10.21105/joss.05304/status.svg

A Python package for support of the “Virtual Instrument Software Architecture” (VISA), in order to control measurement devices and test equipment via GPIB, RS232, Ethernet or USB.

Description

The programming of measurement instruments can be real pain. There are many different protocols, sent over many different interfaces and bus systems (GPIB, RS232, USB). For every programming language you want to use, you have to find libraries that support both your device and its bus system.

In order to ease this unfortunate situation, the Virtual Instrument Software Architecture (VISA) specification was defined in the middle of the 90’s. Today VISA is implemented on all significant operating systems. A couple of vendors offer VISA libraries, partly with free download. These libraries work together with arbitrary peripheral devices, although they may be limited to certain interface devices, such as the vendor’s GPIB card.

The VISA specification has explicit bindings to Visual Basic, C, and G (LabVIEW’s graphical language). Python can be used to call functions from a VISA shared library (.dll, .so, .dylib) allowing to directly leverage the standard implementations. In addition, Python can be used to directly access most bus systems used by instruments which is why one can envision to implement the VISA standard directly in Python (see the PyVISA-Py project for more details). PyVISA is both a Python wrapper for VISA shared libraries but can also serve as a front-end for other VISA implementation such as PyVISA-Py.

VISA and Python

Python has a couple of features that make it very interesting for controlling instruments:

  • Python is an easy-to-learn scripting language with short development cycles.

  • It represents a high abstraction level [2], which perfectly blends with the abstraction level of measurement programs.

  • It has a rich set of native libraries, including numerical and plotting modules for data analysis and visualisation.

  • A large set of books (in many languages) and on-line publications is available.

Requirements

  • Python (tested with 3.10+)

  • VISA (tested with NI-VISA 17.5, Win7, from www.ni.com/visa and Keysight-VISA )

Installation

Using pip:

$ pip install pyvisa

or easy_install:

$ easy_install pyvisa

or download and unzip the source distribution file and:

$ python setup.py install

Documentation

The documentation can be read online at https://pyvisa.readthedocs.org

Citing

If you are using this package, you can cite the PyVISA publication

Grecco et al., (2023). PyVISA: the Python instrumentation package. Journal of Open Source Software, 8(84), 5304, https://doi.org/10.21105/joss.05304

Project details


Download files

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

Source Distribution

pyvisa-1.16.1.tar.gz (238.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyvisa-1.16.1-py3-none-any.whl (181.3 kB view details)

Uploaded Python 3

File details

Details for the file pyvisa-1.16.1.tar.gz.

File metadata

  • Download URL: pyvisa-1.16.1.tar.gz
  • Upload date:
  • Size: 238.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyvisa-1.16.1.tar.gz
Algorithm Hash digest
SHA256 44d637ef977097cae6247ce621514739e7a68b0e1d683d4e4b191b67f5b4d7b3
MD5 75d9edfaebf5e798ef7dbc4f639f3f3b
BLAKE2b-256 5f45b2cf76f58097040827fc6c61af4cb3ae473ef2fa47bc4f3e582e95fab3a0

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyvisa-1.16.1.tar.gz:

Publisher: release.yml on pyvisa/pyvisa

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyvisa-1.16.1-py3-none-any.whl.

File metadata

  • Download URL: pyvisa-1.16.1-py3-none-any.whl
  • Upload date:
  • Size: 181.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyvisa-1.16.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b0109a146f1d1a5d66d988fd5ea2a2abafb526f276d7cd60bfdba784513de3a7
MD5 d62abb1e722c680946ae4c73f1b07a31
BLAKE2b-256 911e701cde98f835aaf84cd17851103715615a5ccb2f3d2ce3e215df8b5a4550

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyvisa-1.16.1-py3-none-any.whl:

Publisher: release.yml on pyvisa/pyvisa

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page