- Python 99.2%
- Shell 0.4%
- Batchfile 0.4%
| resources | ||
| src | ||
| .gitignore | ||
| Installation.md | ||
| LICENSE | ||
| README.md | ||
| requirements.txt | ||
| setup.bat | ||
| setup.sh | ||
| StimJimGUI.py | ||
StimJimGUI
GUI for the StimJim Open Source electrophysiology stimulator
The GUI offers two modes:
Simple Mode
In "Simple Mode", a rising pulse on TRIG0 triggers the output of a train of stimuli on OUT0, while a rising pulse on TRIG1 triggers OUT1. You can adjust the number and frequency of the output, as well as its intensity and duration of the pulses.
Bipolar mode
Checking the "bipolar checkbox" creates a bipolar pulse such as each stimulus is immediately followed by a stimulus of opposite amplitude. Both pulses have equal duration and their combined duration is equal to the pulse duration shown in the corresponding box.
Threshold
Amplitudes can be expressed in V or A (depending on the chosen output mode), or can be expressed relative to a "threshold"
value. When the threshold amplitude as been measured, click on the threshold button, the value of the threshold amplitude
now appear next to the button, and the pulse amplitude is expressed as a multiple of the threshold value (e.g. If the
threshold were 200mV, 1.5 xT would correspond to a pulse 300 mV in amplitude)
"Full Mode"
In "Full Mode", all the settings can be freely adjusted as described in the StimJim Documentation
Usage
🚀 Installation and Running
📥 Quick Setup (One Command)
Windows (Command Prompt or PowerShell)
setup.bat
macOS / Linux (Terminal)
bash setup.sh
🛠️ These scripts:
- Create and activate a virtual environment called StimJimGUI
- Install all dependencies from
requirements.txt- Optionally launch the application after installation
🛠 Manual Setup (Step-by-Step)
1. Install Python
- Windows/macOS: Download from python.org.
- Linux: Install via:
sudo apt update
sudo apt install python3 python3-venv python3-pip
Verify installation:
python --version
or
python3 --version
2. Clone the Repository
git clone https://github.com/MarinManuel/StimJimGUI.git
cd StimJimGUI
3. Create and Activate the Virtual Environment
Windows:
python -m venv StimJimGUI
.\StimJimGUI\Scripts\activate
macOS/Linux:
python3 -m venv StimJimGUI
source StimJimGUI/bin/activate
4. Install Dependencies
pip install --upgrade pip
pip install -r requirements.txt
5. Run the Application
python main.py
⚙️ Common Problems
pipnot recognized: Make sure Python and pip are added to your PATH.- Linux/macOS permissions: Try adding
sudoif needed. - Alternative (conda environment): Supported if you prefer.
Running
- Activate the environment
- Launch the GUI:
python StimJimGUI.pyThe software attempts to detect the serial port automatically, but you can also specify the port to use using the--portcommand line argument
Other command line arguments:
usage: StimJimGUI [-h] [-p PORT] [-l LOG] [-v]
This software provides a graphical user interface for controlling a StimJim, an open source electrophysiology stimulator for physiology and behavior
optional arguments:
-h, --help show this help message and exit
-p PORT, --port PORT the serial port used to communicate with the StimJim. If not provided, then the software will try to find the port automatically, and/or offer a choice of possible ports
-l LOG, --log LOG save the log file to file FILENAME
-v, --verbose increase verbosity of output (can be repeated to increase verbosity further)
Acknowledgments
This work was supported in part by NIH-NINDS R01NS132487.
scientific_spinbox.py is from pyqt-labutils
Icons by Icons8