Installation¶
This page describes how to install the Siglent Oscilloscope Control library.
Requirements¶
- Python: 3.8 or higher
- Operating System: Windows, macOS, or Linux
- Network: Ethernet connection to oscilloscope
- Oscilloscope: Siglent SDS series with SCPI support
Basic Installation¶
Install the base package using pip:
This provides the core functionality for programmatic control.
Optional Features¶
The library provides several optional feature sets that can be installed as needed:
GUI Application¶
For the PyQt6-based graphical interface:
Includes:
- PyQt6 >= 6.6.0
- PyQt6-WebEngine >= 6.6.0
- pyqtgraph >= 0.13.0 (high-performance plotting)
Data Export¶
For advanced data export formats:
Includes:
- h5py >= 3.8.0 (HDF5 file format support)
Vector Graphics¶
For XY mode vector graphics and shapes:
Includes:
- shapely >= 2.0.0 (geometric operations)
- Pillow >= 10.0.0 (text rendering)
- svgpathtools >= 1.6.0 (SVG support)
All Features¶
Install everything:
Development Installation¶
For contributing to the project:
# Clone the repository
git clone https://github.com/little-did-I-know/SCPI-Instrument-Control.git
cd SCPI-Instrument-Control
# Install in editable mode with development dependencies
pip install -e ".[dev]"
# Set up pre-commit hooks
make dev-setup
Development extras include:
- pytest and pytest-cov (testing)
- black (code formatting)
- flake8 (linting)
- isort (import sorting)
- bandit (security checks)
- build and twine (packaging)
Documentation¶
To build the documentation locally:
# Install documentation dependencies
pip install "SCPI-Instrument-Control[docs]"
# Serve documentation locally
mkdocs serve
Then open http://127.0.0.1:8000 in your browser.
Verification¶
Verify your installation:
import scpi_control
print(scpi_control.__version__)
# Test connection (replace with your oscilloscope IP)
from scpi_control import Oscilloscope
scope = Oscilloscope('192.168.1.100')
scope.connect()
print(scope.identify())
scope.disconnect()
Expected output:
Network Configuration¶
Finding Your Oscilloscope IP¶
- On the oscilloscope, press Utility → System → LAN Setup
- Note the IP address shown (e.g., 192.168.1.100)
- Ensure the oscilloscope and your computer are on the same network
Testing Connection¶
Ping the oscilloscope to verify network connectivity:
Test SCPI connection using netcat (Linux/macOS):
Or using PowerShell (Windows):
$client = New-Object System.Net.Sockets.TcpClient("192.168.1.100", 5024)
$stream = $client.GetStream()
$writer = New-Object System.IO.StreamWriter($stream)
$reader = New-Object System.IO.StreamReader($stream)
$writer.WriteLine("*IDN?")
$writer.Flush()
$reader.ReadLine()
$client.Close()
Troubleshooting¶
Import Errors¶
Problem: ModuleNotFoundError: No module named 'siglent'
Solution: Ensure the package is installed in the correct Python environment:
# Check which Python you're using
python --version
pip --version
# Install in the correct environment
python -m pip install SCPI-Instrument-Control
GUI Missing Dependencies¶
Problem: ERROR: Missing Required GUI Dependencies
Solution: Install the GUI extras:
Connection Refused¶
Problem: SiglentConnectionError: Failed to connect to 192.168.1.100:5024
Possible causes:
- Incorrect IP address - Verify on oscilloscope settings
- Firewall blocking - Disable firewall temporarily to test
- Wrong network - Ensure computer and oscilloscope are on same subnet
- Port 5024 blocked - Check if another application is using the port
Solutions:
# Test ping first
ping 192.168.1.100
# Check if port is open (Linux/macOS)
nc -zv 192.168.1.100 5024
# Windows: Use Test-NetConnection
Test-NetConnection -ComputerName 192.168.1.100 -Port 5024
Permission Errors (Linux)¶
Problem: Permission denied when accessing network
Solution: Run with sudo or add your user to the dialout group:
Next Steps¶
- Quick Start Guide - Get started with basic usage
- Connection Setup - Detailed connection configuration
- User Guide - Learn all features
Support¶
If you encounter issues not covered here:
- Check the GitHub Issues
- Ask in Discussions
- Report bugs with detailed error messages and Python version