CPMI Laboratory Instrument Controller
Overview
This project is a multithreaded Python application designed to control multiple laboratory instruments simultaneously for plasma-material interaction experiments. The software provides a unified graphical interface for researchers to monitor sensors, control power supplies, and collect experimental data from multiple devices in real time.
Each instrument is implemented as an independent controller that communicates with hardware through either PyVISA or RS-232 COM connections. A central thread manager launches and supervises the instrument controllers, allowing experiments to run while the interface remains responsive.
Architecture
The controller uses a modular structure where each instrument typically has two Python files:
- Screen Module — GUI component that provides user controls and live status updates.
- Communication Module — handles direct communication with the instrument using PyVISA or serial COM ports.
Threads communicate with each other using a shared communications directory. This folder allows instrument controllers to exchange data and status information without blocking other threads. Because it manages inter-thread messaging, modifying the communications folder structure can break the software.
Instrument Controllers
Langmuir Probe Bias
- Controls probe bias voltage through a programmable power supply
- Serial COM communication
- Used for plasma probe measurements
Mass Flow Controller
- Controls gas flow rate during experiments
- Serial COM port interface
- Integrated into automated experiment control
Pressure Gauge
- Reads chamber pressure measurements
- Continuous serial data acquisition
- Live display within GUI
Oscilloscope Interface
- Ethernet communication with oscilloscope
- Live waveform acquisition
- Automatic data storage for experiment logs
Software Components
- Thread Manager — launches and shuts down instrument controller threads.
- GUI Interface — built using Tkinter for user interaction.
- Instrument Drivers — device communication through PyVISA and COM ports.
- Communications Layer — file-based messaging between concurrent threads.
- Timer Application — experiment timing and synchronization tool.
Deployment
The final application is packaged as a standalone executable using PyInstaller. The compiled program is included in the Product folder of the repository and can be run on laboratory computers without installing Python.
- Requires Python 3 environment for development
- Dependencies installed using pip
- Tkinter required for GUI interface
Porting to a New Computer
- Verify Ethernet instrument IP addresses are correct
- Check connected devices using arp -a
- Verify network configuration using ipconfig /all
- Ensure required Python dependencies are installed