GainSec/AutoProber: Hardware hacker’s flying probe automation stack for agent-driven target discovery, microscope mapping, safety-monitored CNC motion, probe review, and controlled pin probing. · GitHub

AutoProber is Hardware Hacker’s Flying Probe automation stack that lets your agent do everything from “there’s a new target on the plate” to securely probing individual PINs.

autoprober assembly

Demo video: https://gainsec.com/autoprober-demo-mp4/

  1. Ask the agent to swallow the project.
  2. Connect all hardware.
  3. Ask the agent to confirm that all parts are working.

Autoprober at the top of the web dashboard

  1. Run it homing and then calibration.
  2. Attach custom probes and microscope headers.
  3. Tell the agent there is a new target on the plate.
  4. It will figure out where the target is on the plate, then take individual frames, keeping record of XYZ, noting pads, pins, chips and other interesting features.

Label and target features detected

  1. This will join the frames together and annotate the map, including pins and identified interesting components.

Annotated Map View

  1. This will add the investigation target to your web dashboard for approval or disapproval.

Inquiry Review Dashboard Section

  1. It will examine the approved targets and submit a report.

All hardware can be controlled via a web dashboard, Python script, or the agent itself.

Manual Controls and Hardware Panel

This repo is a self-contained source-available release candidate. It includes the Python control code, dashboard, CAD files, and documentation needed to build your own autoprober.

This project can move physical hardware. Treat it as a machine-control system, not a generic web app.

The essential security design is:

  • grbl Pn:P Is ignored. The CNC probe pin is not a reliable endstop.
  • The independent safety endstop is read from oscilloscope channel 4.
  • Channel 4 must be continuously monitored during any motion.
  • Any channel 4 trigger, unexplained voltage, CNC alarm, or actual X/Y/Z limit pin is a stop condition.
  • Agent/Operator must stop and report. Recovery speed is not automatic.

Read docs/safety.md and docs/operations.md before operating hardware.

apps/                 Operator-facing scripts and Flask dashboard entrypoint
autoprober/           Reusable Python package for CNC, scope, microscope, logging, safety
dashboard/            Single-page web dashboard
docs/                 Architecture, device references, operations, and safety guidance
cad/                  Printable STL files for the current custom toolhead
config/               Example environment/configuration files
AGENTS.md             Agent/operator safety rules
LICENSE               PolyForm Noncommercial 1.0.0 license and commercial contact
pyproject.toml        Python project metadata
uv.lock               Locked Python dependency resolution

The tested project architecture uses:

  • GRBL-Compatible 3018-Style CNC Controller over USB Serial
  • Served by USB Microscope mjpg_streamer
  • Signalant Oscilloscope over LAN/SCPI for channel 4 security monitoring and channel 1 measurement
  • The optical endstop is connected to an external 5V supply and oscilloscope channel 4
  • Optional network-controlled outlet for lab power control
  • Current Printable Custom Toolhead Part cad/

Default runtime assumptions are documented in the device documentation. Replace them with your laboratory settings before use.

For a purchasing-oriented hardware list, see docs/BOM.md.

These are specific parts or part classes used for prototype release. Verify current listing, dimensions, voltage and connector compatibility before purchasing.

My creation:

Alternative/Interchangeable:

flowchart LR
    Operator[Operator] --> Dashboard[Web Dashboard]
    Dashboard --> Apps[Python Apps]
    Apps --> CNC[GRBL CNC over USB serial]
    Apps --> Microscope[USB Microscope via mjpg-streamer]
    Apps --> Scope[Oscilloscope over LAN / SCPI]
    Apps --> Outlet[Optional LAN Power Outlet]

    Endstop[Optical Endstop] --> ScopeC4[Scope C4 Safety Voltage]
    Pogo[Pogo Measurement] --> ScopeC1[Scope C1 Measurement]
    ScopeC4 --> Apps
    ScopeC1 --> Apps



It’s loading


flowchart TD
    Preflight[Preflight] --> SafetyCheck{Channel 4 clear?}
    SafetyCheck -- no --> Stop[STOP State]
    SafetyCheck -- yes --> Motion[Monitored Motion]
    Motion --> Monitor[EndstopMonitor thread >= 10 Hz]
    Monitor --> C4{C4 clear?}
    C4 -- yes --> Capture[Microscope Capture]
    C4 -- no --> FeedHold[Immediate feed hold]
    FeedHold --> Stop
    Capture --> Stitch[Stitch / Map]
    Stitch --> Review[Manual Probe Review]
    Review --> Approved{Approved target and measured probe offset?}
    Approved -- no --> Stop
    Approved -- yes --> Probe[Bounded probe motion]



It’s loading


stateDiagram-v2
    [*] --> Running
    Running --> STOP: C4 triggered / C4 fault / CNC alarm / real limit pin
    STOP --> Report: log voltage, status, action
    Report --> WaitForOperator: no automatic recovery motion
    WaitForOperator --> Running: operator explicitly clears condition



It’s loading


Install dependencies:

Start the dashboard on the configured hardware host:

PYTHONPATH=. python3 apps/dashboard.py

Dashboard is ported by default 5000.

Start with config/autoprober.example.env. Do not publish lab-specific IPs, hostnames, credentials, calibration files, or captured target images unless you intend to release them.

Important runtime values ​​are configurable:

  • AUTOPROBER_LOG_PATH:runtime log path
  • AUTOPROBER_RUNTIME_ROOT:Calibration, flat-field, and runtime status guides
  • AUTOPROBER_MICROSCOPE_SNAPSHOT_URL:microscope snapshot endpoint
  • AUTOPROBER_SCOPE_HOST / AUTOPROBER_SCOPE_PORT:oscilloscope scpi endpoint
  • Dashboard: flask on port 5000

Do not create local environment files that contain lab-specific host, path, or target data.

  1. Run pre-flight check.
  2. Verify that Channel 4 is clear.
  3. Home and calibrate only when the physical setup is ready.
  4. Capture microscope frames with monitoring motion.
  5. Import or generate target map artifacts for review.
  6. Approve test candidates manually.
  7. Perform any probe motion only after measuring and storing the microscope-to-probe offset.

This release candidate intentionally excludes:

  • The test microscope captures and stitches target images
  • Reference images uploaded
  • Local Backup and Archive
  • .venv, __pycache__playwright artworks
  • Runtime logs, calibration cache, flat-field images
  • Machine-specific SSH/deployment status

See RELEASE_MANIFEST.md for details.

This project is available source-available under the Polyform Non-Commercial License 1.0.0.

You can use, modify, and share this project for non-commercial purposes.

Commercial use requires a separately paid commercial license.

For commercial license contact: autoprober@gainsecmail.com

  • The microscope-to-pogo XY offset must be measured before the actual investigation.
  • The calibration should not be fudged; The runtime calibration file must be generated on the machine it will run on.
  • The dashboard is a laboratory-control tool and should not be exposed to untrusted networks.

This project is for controlled laboratory work on equipment and targets that you are authorized to test. Do not use it to probe, damage, or analyze the system without permission.

John ‘Gainsek’ Gaines



<a href

Leave a Comment