-
Assemble the PCB:
- Order the PCB from JLCPCB for ~$150 using the
gerber.zip,bom.csv, andlaser_controller-top-pos.csvfiles. - Use compatible JST cables.
- Order the PCB from JLCPCB for ~$150 using the
-
Install MicroManager 2.0:
- Download and install MicroManager 2.0.
-
Copy Files:
- Copy the precompiled
EMUfolder andmmgr_dal_GrussmayerLab-LaserController.dllinto the root directory of MicroManager.
- Copy the precompiled
-
Hardware Configuration:
- Run MicroManager and open your hardware configuration.
- Add the
GrussmayerLab-LaserControllerdriver in your configuration and make sure to select a baudrate of 115200. - Make sure maxVolts is set to 5.0 for DAC0 to DAC5 and 1.0 for PWM.
-
Use the LaserControlGUI Plugin:
-
Open the LaserControlGUI plugin from EMU.
-
Configure the properties of the EMU plugin as follows:
Lasers
UI Property Device Property lasern enable LaserController-DACn State lasern enable – On value — 1 lasern enable – Off value — 0 lasern power percentage LaserController-DACn Volts lasern power percentage slope — 0.05 lasern power percentage offset — 0.0 Motor
UI Property Device Property lasern enable LaserController-PWM State lasern enable – On value — 1 lasern enable – Off value — 0 lasern power percentage LaserController-PWM Volts lasern power percentage slope — 0.01 lasern power percentage offset — 0.0
-
This repository consists of the hardware, firmware, and software design for the Laser Controller system. It is divided into four main sections:
- Electronics: Schematic and PCB design files for the laser controller.
- LaserControlFirmware: C/C++ firmware for the Raspberry Pi Pico.
- GrussmayerLab-LaserController: C++ Micromanager Device Adapter to drive the laser controller.
- LaserControlGUI: Java-based plugin for Micromanager, built upon the EMU plugin.
The Laser Controller project integrates hardware and software components to control a laser system. It consists of:
- Hardware: Electronics, including a schematic and PCB design, for laser control.
- Firmware: Raspberry Pi Pico firmware (C/C++) managing communication with the hardware.
- Software: A Java plugin for MicroManager, based on the EMU plugin framework, along with a C++ Device Adapter for MicroManager.
This folder contains the hardware designs for the laser controller:
- Schematic: Electrical design for the laser control system.
- PCB Design: Printed circuit board design files created using KiCAD.
Files in this folder:
schematic.kicad_sch: Schematic file.pcb.kicad_pcb: PCB design file.
For more details, refer to the KiCAD Documentation.
Firmware for the Raspberry Pi Pico, written in C/C++, responsible for controlling the laser system.
Files in this folder:
main.cpp: Main program code.CMakeLists.txt: CMake configuration.README.md: Firmware setup instructions.
Java-based plugin for Micromanager, allowing control of the laser system.
Files in this folder:
LaserPanel.java: Laser slide panel code.MyFrame.java: Main plugin UI containing multiple LaserPanel instances.MyPlugin.java: Main plugin class implementing the UIPlugin interface.
- Review Hardware Files: Use KiCAD to view schematic and PCB design files in the
Electronicsfolder. - Assemble the PCB: Using
gerber.zip,bom.csv, andlaser_controller-top-pos.csv, you can assemble your PCB at JLCPCB for approximately $100. - Connect Components: The board has JST S3B-PH-K-S (LF)(SN) connectors. Buy compatible cables and modify them as needed.
-
Flashing Precompiled Firmware:
- The compiled UF2 firmware is already included in the repository.
- Hold the BOOTSEL button on the Raspberry Pi Pico, connect it to a PC via USB, and it will appear as a USB drive.
- Copy the UF2 file to the drive, and the Pico is programmed.
-
Optional: Building from Source: If you wish to modify the firmware, install the following tools:
Clone the repository and build:
git clone https://github.com/GrussmayerLab/LaserController.git cd LaserControlFirmware mkdir build cd build cmake .. make
-
Install MicroManager 2.0:
- Download and install the latest version of MicroManager 2.0. Copy the precompiled
EMUfolder (provided) into the root directory of MicroManager.
- Download and install the latest version of MicroManager 2.0. Copy the precompiled
-
Install the EMU Plugin (for source code editing):
- If you wish to modify or extend the plugin, follow the instructions on how to install EMU:
-
Install LaserControlGUI Plugin:
- To enable the LaserControlUI plugin, export the Java project from Eclipse into the EMU folder in MicroManager.
-
Install the Device Adapter:
- Copy the
mmgr_dal_GrussmayerLab-LaserController.dllfile in the root directory of MicroManager. - If you need to configure or extend the device adapter, follow the MicroManager Visual Studio setup guide. After setting up your project, place
.hfiles in the header folder and.cppfiles in the source folder. Compile the project, and place the resulting.dllfile in the root directory of MicroManager.
- Copy the
-
Hardware Configuration:
- Run MicroManager and open your hardware configuration.
- Add the
GrussmayerLab-LaserControllerdriver in your configuration and make sure to select a baudrate of 115200. - Make sure maxVolts is set to 5.0 for DAC0 to DAC5 and 1.0 for PWM.
-
Use the LaserControlGUI Plugin:
-
Open the LaserControlGUI plugin from EMU.
-
Configure the properties of the EMU plugin as follows:
Lasers
UI Property Device Property lasern enable LaserController-DACn State lasern enable – On value — 1 lasern enable – Off value — 0 lasern power percentage LaserController-DACn Volts lasern power percentage slope — 0.05 lasern power percentage offset — 0.0 Motor
UI Property Device Property lasern enable LaserController-PWM State lasern enable – On value — 1 lasern enable – Off value — 0 lasern power percentage LaserController-PWM Volts lasern power percentage slope — 0.01 lasern power percentage offset — 0.0
-
Contributions are welcome. Whether you're enhancing firmware stability, refining hardware design, or extending the MicroManager plugins, focused pull requests with clear explanations help keep the project maintainable. Open an issue if you'd like to discuss a feature or improvement before implementing it.
- Start MicroManager.
- Open the LaserControlGUI plugin.
- The plugin will interface with the Raspberry Pi Pico, allowing laser control via MicroManager.
- Use the sliders to set the lasers and motor.
Software in this project is licensed under the MIT License and hardware is licensed under CERN OHL - see LICENSE file for details in the licenses folder.