This repository contains a Python script that demonstrates remote control and data acquisition from networked laboratory instruments using the VXI-11 protocol.
It enables communication with a signal generator and an oscilloscope over Ethernet, automated waveform retrieval, and graphical analysis.
The project illustrates a laboratory automation workflow where instruments are accessed and controlled remotely via TCP/IP.
The script provides the following functionality:
- Establishes communication with VXI-11–compatible instruments.
- Reads configuration parameters from a signal generator.
- Acquires waveform data from an oscilloscope.
- Automatically plots and saves the captured waveforms in PDF format.
- Allows remote configuration of generator parameters.
This setup can be adapted for laboratory experiments, automated testing, or research data collection.
networked-instruments-and-python/
## 2. Repository Structure
---
networked-instruments-and-python/
├── automated-electronics-characterization/
│ ├── media/ # Images, plots, or related files
│ ├── output/ # Measurement results or processed data
│ └── code.py # Script for automated electronics characterization
│
├── instrument-control-and-acquisition/
│ ├── media/ # Supporting media (images or figures)
│ ├── output/ # Generated waveform or log data
│ └── code.py # Python script for instrument control and data acquisition
│
├── video-demonstrations-in-laboratory/
│ ├── instrument_control_demo.mp4 # Demonstration of instrument control process
│ ├── info.txt # Supplementary information about demonstrations
│ └── README.md # Documentation for video demonstrations
│
└── README.md # Main project documentation
The code is compatible with Python 3.x and requires the following packages:
python-vxi11
numpy
matplotlib
si-prefix
To install all dependencies:
pip install -r requirements.txtIf a requirements.txt file is not yet present, the packages above can be installed individually.
Update the IP addresses of your instruments in the script before execution:
g = vxi11.Instrument('172.17.51.102') # Signal generator
o = vxi11.Instrument('172.17.51.103') # OscilloscopeEnsure both devices are reachable from the host computer and support the VXI-11 protocol.
It is recommended to verify communication using the *IDN? SCPI command prior to running automated measurements.
- Clone this repository:
git clone https://github.com/YOUR_USERNAME/networked-instruments-python-labs.git
cd networked-instruments-python-labs- (Optional) Create and activate a virtual environment:
python -m venv venv
source venv/bin/activate # macOS/Linux
venv\Scripts\activate # Windows- Install required packages:
pip install -r requirements.txt- Run the main script:
python src/instruments.pyThe script will connect to the instruments, acquire waveform data, and save the generated plot in PDF format.
A short demonstration of the measurement and plotting process is available in the repository:
instrument_control_demo-360p.mp4
Each measurement produces a waveform plot saved as a timestamped PDF file, for example:
waveform-oscilloscope-20251020-153245.pdf
The plot includes both oscilloscope channels with voltage and time scaling extracted directly from instrument parameters.
This project was developed for Electronics education and remote instrument control and automated data acquisition using Python.
This project uses a dual-license model:
- Source code is licensed under the MIT License.
- Documentation, images, and other non-code content are licensed under the Creative Commons Attribution 4.0 International License (CC BY 4.0).