OpenFlexure Microscope
An open-source, 3D-printable, laboratory-grade robotic digital microscope designed for automated high-resolution imaging, whole-slide scanning, and telepathology. Conceived and developed by Dr. Richard W. Bowman, Julian Stirling, and colleagues across the University of Bath, the University of Cambridge, and an international open-science consortium, the OpenFlexure project replaces costly, precision-machined mechanical translation stages with a monolithic 3D-printed flexure stage capable of sub-100 nm positioning resolution.
Project Website: openflexure.org/projects/microscope
Documentation & Build Guide: openflexure.org/projects/microscope/build
Source Repositories: rwb27/openflexure_microscope (GitHub mirror) | openflexure/openflexure-microscope (GitLab upstream)
Software Daemon & API: openflexure/openflexure-microscope-server
Client Application: OpenFlexure Connect
Foundational Paper: Collins JT, Knapper J, Stirling J, MD-Ahmad J, Chagas AM, Beale A, Bowman RW. Robotic microscopy for everyone: the OpenFlexure Microscope. Biomedical Optics Express 11(5), 2447–2460 (2020). DOI: 10.1364/BOE.385729
Mechanics Genesis Paper: Sharkey JP, Foo DCW, Kabla A, Baumberg JJ, Bowman RW. A one-piece 3D printed flexure translation stage for open-source microscopy. Review of Scientific Instruments 87, 025104 (2016). DOI: 10.1063/1.4941068
Literature Review Clipping: [[Robotic microscopy for everyone: the OpenFlexure Microscope]]
The Challenge: Hardware Accessibility in Digital Pathology & Diagnostics
While computational pathology algorithms ([[HoVer-NeXt]], [[CellQuant-Net]], [[NuClick]], and foundation models like [[CytoFormer: A Molecularly Supervised Cell Foundation Model for Histopathology Cell Classification]]) have advanced rapidly, their real-world clinical deployment faces a prohibitive physical barrier: the cost and fragility of automated whole-slide scanners:
Capital Expenditure Barrier: Commercial whole-slide scanners (Hamamatsu NanoZoomer, Leica Aperio, 3DHISTECH) cost between $50,000 and $250,000, restricting automated digital pathology to well-funded academic medical centers in high-income countries.
Maintenance & Supply-Chain Bottlenecks: In low- and middle-income countries (LMICs) or decentralized rural field clinics, motorized microscopes with precision ground sliding rails, lead screws, and proprietary optical encoders frequently fail due to dust, humidity, or mechanical wear, remaining unusable for months due to a lack of specialized local technicians.
Friction, Backlash, and Stick-Slip in Cheap Hardware: Attempting to build budget motorized stages using conventional sliding dovetails or cheap linear ball bearings invariably introduces mechanical backlash, stick-slip friction, and tilt when reversing direction, making repeatable sub-micron autofocus and whole-slide tiling impossible.
The OpenFlexure Microscope solves this fundamental engineering challenge by exploiting compliant mechanisms (flexure hinges) that can be printed as a single monolithic block on a standard desktop 3D printer for under $250 in total materials.
Architectural Blueprint & System Overview
Core Engineering Innovations
1. The Monolithic Flexure Mechanism
Frictionless Motion: Rather than relying on sliding surfaces, the OpenFlexure stage uses deformable plastic hinges (parallelogram linkages) printed monolithically in polylactic acid (PLA).
Sub-100 nm Precision: Driven by inexpensive 28BYJ-48 stepper motors (costing ~$3 each) coupled to standard M3 stainless steel machine screws and brass captive nuts, the flexure delivers a mechanical positioning resolution of ~50 to 100 nm per half-step.
Zero Backlash and Zero Stick-Slip: Because the mechanical joints bend elastochemically without sliding contact, motion is completely free of mechanical play or friction stalls, ensuring micro-stepping fidelity under high-magnification immersion lenses ($100\times$, NA 1.25).
Thermal & Temporal Stability: Despite being constructed from thermoplastic PLA, the symmetrical mechanical design demonstrates minimal drift ($<5\ \mu\text{m}$ over multi-hour imaging sessions at constant room temperature).
2. Optical Subsystems: Finite Conjugate vs. High-Resolution Infinity
OpenFlexure supports modular, interchangeable optical trains:
High-Resolution RMS DIN Optics: Uses industry-standard RMS-threaded microscope objectives (4× scanning, 10× low power, 40× high dry, 100× oil immersion) mounted into a 160 mm tube-length barrel or coupled to a 50 mm achromatic doublet tube lens for infinity-corrected optics.
Sensor Optimization: Paired with the Raspberry Pi High Quality (HQ) Camera (Sony IMX477 1/2.3" 12.3 MP back-illuminated CMOS, $1.55\ \mu\text{m}$ pixel pitch) or Camera Module 3. In a 40× dry setup, this delivers diffraction-limited resolving power ($\approx 0.6\ \mu\text{m}$ lateral optical resolution), cleanly resolving nuclear chromatin texture, nucleoli, and red blood cell borders.
Epifluorescence Capability: Modular drop-in filter cubes with high-power excitation LEDs (e.g., 450 nm Royal Blue for auramine O or GFP, 365 nm UV for DAPI), dichroic beamsplitters, and emission barrier filters enable fluorescence microscopy for tuberculosis screening and immunofluorescence.
3. Sangaboard & Low-Power Field Electronics
Open Motor Controller: The Sangaboard (Stirling et al., HardwareX 2020) provides an open-source hardware driver designed specifically for the unipolar 28BYJ-48 stepper motors.
Power Efficiency: Operates entirely from a single 5V USB power supply (drawing $<15\text{ W}$ during active scanning), allowing continuous full-day operation in off-grid field clinics powered by a standard consumer USB power bank or small solar panel.
Software Ecosystem & Automated Scanning
Embedded REST API & WebSockets
The microscope runs an embedded Linux daemon (openflexure-microscope-server) exposing a complete REST API:
POST /api/v2/actions/stage/move: Precise XYZ relative or absolute stepping.POST /api/v2/actions/camera/autofocus: Automated z-stack sweep evaluating gradient variance sharpness.POST /api/v2/actions/scan/fast_grid_scan: Automated 2D raster scanning over user-defined bounding boxes.GET /api/v2/streams/mjpeg: Low-latency live video streaming for real-time telepathology.
Self-Contained Python Automation Example
Developers can automate whole-slide or multi-ROI acquisition using Python:
Diagnostic & Pathology Applications
1. Automated Malaria & Parasitology Screening in LMICs
In field trials conducted in Bagamoyo and Dar es Salaam, Tanzania (in partnership with the Ifakara Health Institute and STICLab), OpenFlexure microscopes were deployed for automated scanning of Giemsa-stained thick and thin blood smears:
Overcame diagnostic fatigue associated with manual 100× oil immersion examination of hundreds of fields per patient.
Paired with lightweight edge neural networks to perform automated identification and counting of Plasmodium falciparum trophozoites and ring stages.
2. Decentralized Whole-Slide Imaging (DIY WSI)
Commercial WSI scanners rely on continuous line-scan sensors or high-speed piezo stages. OpenFlexure implements a stop-and-stare tile acquisition workflow:
Automated tile grids are acquired with 10–20% spatial overlap.
Tiles are stitched into standard pyramidal OME-TIFF files using open-source tools such as Ashlar or Fiji’s BigStitcher.
Stitched whole-slide images can be imported directly into [[Cytomine]] or QuPath for pathologist sign-out, algorithmic cell segmentation ([[NuClick]]), and spatial quantitative analysis ([[CellQuant-Net]]).
3. Telepathology & Second-Opinion Triage
In remote primary-care clinics lacking resident pathologists:
Local technicians mount biopsy or cytology specimens.
A remote pathologist connects via the web interface or VPN to review live video, navigate the stage in real time, or trigger automated z-stacks over suspicious lesions.
Directly supports the conceptual framework of [[The pathology report as a boundary object: From clinical communication to computational representation]], enabling clinical communication across geographically distributed healthcare sites.
Technical Comparison: OpenFlexure vs. Alternatives
BOM Cost
~$200 – $350
$2,000 – $10,000
$50,000 – $250,000+
~$1 – $5
Stage Mechanics
Monolithic 3D flexure (PLA)
Precision sliding dovetail / brass rack
Precision linear encoded servo/piezo
Paper origami flexure
Positioning Resolution
Sub-100 nm (0.05–0.1 µm)
Manual (calibrated fine knob)
Sub-50 nm closed loop
Manual thumb friction
Motorization
Fully motorized XYZ (3-axis)
Manual (optional motor upgrade: $5k+)
Fully robotic automated
Purely manual
Whole-Slide Tiling
Automated via software script
Manual or expensive add-on
Dedicated high-throughput engine
No
Local Manufacturing
Yes (FDM 3D printer anywhere)
No (specialized factory optics)
No (proprietary cleanroom)
No (mass injection/die-cut)
Optics
Standard RMS DIN 4×–100×
Standard RMS/UIS2
Custom telecentric imaging
Single ball lens
Digital Connectivity
Native REST API, Web, Linux
Separate camera attachment
Proprietary enterprise server
Mobile phone camera
Field Portability
High (5V USB power bank)
Heavy benchtop AC mains
Huge fixed benchtop AC mains
Ultra-portable pocket
Related Notes & Ecosystem Links
Microscope Hardware & Automation: [[Micro-Manager]], [[Openmicroscopy]], [[Digital Pathology Software]]
Digital Pathology Infrastructure: [[Digital Pathology]], [[Telepathology]], [[Cytomine]], [[Considerations for digital pathology displays]], [[NPIC Quality Coordination Centre: Digital Pathology Quality Assurance and Metrology]]
Quantitative Image Analysis: [[Image Analysis]], [[NuClick]], [[CellQuant-Net]], [[HoVer-NeXt]], [[HistoPLUS: Towards Comprehensive Cellular Characterisation of H&E Slides]], [[CytoFormer: A Molecularly Supervised Cell Foundation Model for Histopathology Cell Classification]]
Theory & Context: [[The pathology report as a boundary object: From clinical communication to computational representation]], [[What AI Can and Cannot Do in Pathology]]
Last updated