In Progress — Hardware Integration Phase

MPC-1

mycological phenotyping console

What would it take to build a machine that watches a mushroom grow in four dimensions and autonomously adjusts its environment in real time based on what it sees?

MPC-1 is a portable, autonomous robotic laboratory that generates high-fidelity 4D digital twins of fungal morphological development. A volumetric capture system produces continuous spatial models of biological growth while precise environmental telemetry tracks CO₂, temperature, and humidity. A closed-loop biomass feedback pipeline uses that volumetric data as a control variable: the system modifies environmental conditions based on the physical shape of the organism, without human intervention. The goal: structured training corpora for physics-informed neural networks and 4D Gaussian Splatting models that predict growth dynamics in response to environmental stress.

Beyond research, the system functions as a pre-production screening tool for precision agriculture. It enables quantitative characterization of cultivar performance: discovering dynamic environmental recipes, identifying specific temperature fluctuations or humidity cycles that trigger accelerated biomass production, before committing to macro-scale production. The architecture is designed from the outset for fleet deployment: multiple identical units, each supporting its own biological sample, provisioned and managed as infrastructure rather than as individual instruments.

MPC-1 concept render showing the glass containment vessel, aluminum frame chassis, camera array, and environmental control tower
Concept render — final assembly in progress
System Concept · Abstraction Layers
DECISIONS MODELING CONTROL PHYSICAL RECIPE CONDUCTOR Protocol Evaluation Environmental Commands Threshold Logic DIGITAL TWIN ENGINE Visual Hull Proxy Continuous · Edge 4DGS Reconstruction Periodic · Workstation Sensor Self-Diagnostics SCD41 ΔRH · Calibration Each output carries confidence score and data-quality assessment REACTIVE LAYER — BRAINSTEM ESP32-S3 · RTOS · PID · Watchdog Safety Interlocks · Leased Control DELIBERATIVE LAYER — SUPERVISOR Pi 5 · CV Pipeline · SQLite/WAL NiceGUI · Ansible · Docker USB-Serial BIOLOGICAL SPECIMEN · CONTAINMENT Glass Vessel Hermetic seal Organism Fungal specimen Turntable Magnetic coupling Pneumatics HEPA · PTFE · Valves TRANSIENT COMPUTE Workstation Photogrammetry 4D Gaussian Splat SMB API Feedback: biomass → recipe → environment
Design Intent
The Architectural Question

The central architectural question is how to isolate systems that operate on fundamentally different timescales and failure consequences within a single autonomous enclosure.

Environmental life support cannot tolerate the latency, fragility, or reboot cycles of a general-purpose operating system. Computer vision and experiment orchestration cannot run on a microcontroller. And the volumetric reconstruction pipeline that gives the system its defining capability, the ability to close the loop between physical growth and environmental strategy, demands compute that neither the microcontroller nor a single-board computer can provide in real time.

The system therefore divides into three layers: a reactive layer that guarantees biological safety on millisecond timescales, a deliberative layer that orchestrates the experiment on timescales of minutes to hours, and a transient compute resource that performs heavy reconstruction when available but is never a dependency. The boundary between the first two is a hard isolation boundary. A software bug in the photogrammetry pipeline cannot kill the organism. A kernel panic cannot disable the safety interlocks.

Subsystem Architecture · Interactive
CONTAINMENT STACK Glass Vessel SHT40 Probes · Magnetic Turntable Lid (Air Ports · Cable Gland) CHASSIS · OPTICS Stereo Cameras (CPL) LED Panels (Linear Pol.) NEMA 17 Stepper Heating Mat Cross-Polarized Specular Rejection Calibration Fiducial (Continuous) DELIBERATIVE LAYER — SUPERVISOR Raspberry Pi 5 · Linux · Docker · Ansible OpenCV · SQLite/WAL · NiceGUI · 1TB NVMe REACTIVE LAYER — BRAINSTEM ESP32-S3 · RTOS · PID · Watchdog · Leased Control PNEUMATIC CORE HEPA Filter → Selector Valve 12V Diaphragm Pump → Humidity Valve 2× 3-Way Solenoids · Fresh/Recirc · Wet/Dry CONDITIONING MODULES PTFE Filter · Moisture Trap · Bubbler SCD41 CO₂ Sensor · ΔRH Self-Diagnostic TRANSIENT COMPUTE Workstation Photogrammetry · 4DGS USB-Serial · Leased Control R/O SMB API Biomass → Recipe → Env
Hover or tap any subsystem to see details
Current Implementation
Hybrid Deliberative-Reactive Control

The Reactive Layer (Brainstem) runs on an ESP32-S3 (Adafruit Feather) under an RTOS (C++/PlatformIO). It executes deterministic PID control loops for CO₂, temperature, and humidity, and enforces hardware safety interlocks. A hardware watchdog timer ensures life-support defaults to a safe state if the Supervisor crashes. It drives all actuators: stepper, pump, valves, heater.

The Deliberative Layer (Supervisor) runs on a Raspberry Pi 5 under Linux. It orchestrates the experiment, manages the computer vision pipeline (OpenCV background subtraction, programmatic camera pose generation), hosts the SQLite database in WAL mode for high-concurrency sensor logging, and serves the user interface via NiceGUI. A 1TB NVMe SSD stores high-bandwidth imaging data. All services are Dockerized; the entire OS is provisioned via Ansible as infrastructure-as-code, making the system immutable, reproducible, and fleet-deployable without per-device configuration or internet access. A fresh SD card produces a bit-identical system.

The two layers communicate via USB-Serial (JSON/UART) using a Leased Control model: the Supervisor requests temporary actuator control; the Controller grants it but revokes automatically if the Supervisor goes silent.

Bio-Secure Containment and Optics

The specimen sits inside a hermetically sealed glass vessel. The turntable is driven by magnetic coupling through the glass floor: no shaft seals, no penetrations, reducing contamination pathways and simplifying sterilization. Electronics are housed in IP67-rated latching junction boxes, isolating control hardware from both the high-humidity growth environment and the ambient environment.

Cross-polarization solves the glass-wall reflection problem. Linear polarizing film on LED emitters and circular polarizers on camera receivers optically subtract specular reflections from the glass walls. The vision pipeline implements real-time background subtraction and programmatic camera pose generation, inverting the stepper angle to produce clean-plate datasets for photogrammetry plus NeRF and Gaussian Splat training. A fixed-geometry calibration fiducial on the turntable is visible in every capture, allowing the pipeline to verify stereo calibration continuously rather than assuming it holds across thermal cycles and humidity exposure.

Active Pneumatic Conditioning

Fungi require 95%+ RH, but the SCD41 photoacoustic CO₂ sensor degrades rapidly above 70% RH. The pneumatic system reconciles these competing requirements through active air-handling. An inline PTFE membrane filter blocks liquid water and aerosols while allowing the gas stream to pass through. An inline moisture trap (condensation-based, no desiccant) removes water vapor before the sample air reaches the CO₂ sensor. Post-sensor sparging re-saturates exhaust via a water bubbler before returning it to the chamber. Two three-way solenoid valves (selector for fresh/recirculation, humidity for wet/dry path) provide four distinct airflow modes under PID control. A medical-grade 12V diaphragm pump drives all airflow. HEPA filtration provides sterile fresh air.

The SCD41's own humidity output serves as a continuous self-diagnostic of the conditioning path. The delta between the SCD41's reported humidity and the in-chamber SHT40 reading is a direct measure of conditioning effectiveness: if it narrows, the air path is degrading regardless of mechanism.

Closed-Loop Biomass Feedback

The core innovation: volumetric data as a control variable. The Supervisor captures high-resolution stereo image sets and stages them on the NVMe. An occasionally-connected workstation pulls data via read-only SMB, performs photogrammetry and 4D Gaussian Splat reconstruction, calculates biomass volume, and pushes results back via API. The edge device never depends on this connection; it continues capturing, logging, and controlling autonomously.

The Supervisor's Recipe Conductor evaluates new biovolume data against the experimental protocol. A protocol step might specify: induce fruiting conditions when substrate is fully colonized. At that point the Conductor commands a CO₂ spike to 1200ppm and drops temperature to 18°C, triggering the transition from vegetative mycelium to primordia formation. The loop closes between physical growth and environmental strategy, autonomously.

Active Design Frontier
Overview

The implementation above closes several loops: environmental control, sensor logging, image capture, and (when the workstation connects) volumetric reconstruction. What it does not yet do is close those loops at matched timescales, or provide the self-awareness a fleet of autonomous units would need to operate without human oversight. The problems below are active areas of design work.

Decision Cadence vs. Capture Cadence

The biomass/biovolume feedback pipeline is the system's defining capability, but it is also the only subsystem whose latency depends on an external resource. The turntable captures images on every revolution. The workstation performs volumetric reconstruction when it connects. For a single bench prototype serviced daily, this gap is tolerable. For a fleet of units, the workstation services whichever unit it reaches last, and a specimen that crosses a recipe threshold at 2 AM waits until the next connection.

The candidate solution is a lightweight volumetric proxy that runs on the Pi 5 in near-real-time, with the full Gaussian Splat reconstruction serving as periodic ground truth rather than as the sole measurement source. Silhouette-based visual hull is the current leading approach: the turntable provides controlled viewpoints, the background subtraction pipeline already produces clean foreground masks, and the computational cost of cone intersection and voxel counting is well within the Pi 5's budget. Visual hull overestimates volume because it cannot resolve concavities (gill structures, gaps between clustered primordia), but a consistently biased estimate that tracks the growth curve monotonically is a sufficient control variable. The full reconstruction calibrates the proxy's bias periodically rather than replacing it.

Stereo disparity mapping was evaluated and rejected. Fungal tissue has the surface properties that break stereo correspondence: translucency, fine repetitive texture or no texture at all, specular moisture highlights, and thin structures below disparity resolution. Imaging through glass with potential condensation compounds the problem. Vertical laser-line profiling remains a candidate for future iterations where concavity resolution proves operationally necessary, but it introduces hardware that must coexist with the polarization optics and capture sequencing, adding complexity that the first closed-loop experiments do not yet require.

Command Path Resilience

The USB-Serial link between the Supervisor and Controller is a single point of failure. USB enumeration on Linux is not deterministic: it fails after suspend/resume, under load, and occasionally without discernible cause. The Leased Control model handles this correctly on the reactive side; the ESP32 reverts to safe defaults. But the Supervisor is now headless with no recovery path short of physical intervention. For fleet deployment in environments without reliable human access, a secondary communication channel (UART over GPIO, bypassing the USB stack entirely) would provide a fallback that degrades capability without losing contact.

Fleet Observability

Each unit is currently an island. The Ansible provisioning solves the deployment problem (producing N identical units), but not the operational problem (learning from N units simultaneously). For cultivar screening, the value is comparative: which recipe produces faster growth, how does unit 7's curve compare to unit 12's, which environmental perturbation triggers the strongest morphological response across the fleet. A lightweight telemetry aggregation layer (MQTT or similar, publishing when connectivity is available) would open the door to cross-unit dashboards, shared alerting, and the kind of fleet-level pattern recognition that individual units cannot perform.

The data architecture question runs deeper than transport. The system currently logs events sequentially in SQLite, which is sufficient for replay and debugging but does not represent the causal and temporal relationships between environmental states, biological responses, and recipe decisions. The Recipe Conductor's current logic is scalar: biomass exceeds a threshold, trigger a condition change. But the recipes worth discovering are conditional on history, on sequences of states rather than individual measurements. Inducing fruiting when biomass exceeds 50cm³ and growth rate has been accelerating for 48 hours and the last CO₂ perturbation produced a measurable morphological response is a query over a temporal graph of states and causal relationships, not a comparison against a setpoint. A knowledge graph database would make those relationships queryable, both within a single run (what environmental sequence preceded the fastest growth phase) and across units in a fleet (whether the same cultivar responds differently to the same recipe in different thermal envelopes, whether a specific perturbation sequence is reliably causal or merely correlated in a small sample). This is the layer that transforms a fleet of independent instruments into a system that learns.

Thermal Envelope

The current system can heat but cannot actively cool. If the target temperature for fruiting induction is 18°C and the ambient is 24°C, the system cannot reach its setpoint. LEDs and electronics add waste heat inside or near a sealed enclosure. For fleet deployment across varied environments, this constrains the system to climate-controlled facilities, which works against the portable, autonomous design intent. Active cooling (thermoelectric or liquid) is under evaluation for the thermal subsystem revision.

Reference
Technical Specifications
SubsystemComponentNotes
SupervisorRaspberry Pi 5Linux · Docker · 1TB NVMe
ControllerESP32-S3 (Adafruit Feather)RTOS · PID · Watchdog
LinkUSB-Serial (JSON/UART)Leased Control model
CO₂SCD41 (Photoacoustic)Pre-conditioned sample air
Temp/RHSHT40In-chamber probes
TurntableNEMA 17 StepperMagnetic coupling
Pump12V Diaphragm (Medical)All airflow
Valves2× 3-Way SolenoidFresh/Recirc · Wet/Dry
OpticsStereo + CPL + LinPolSpecular rejection
Air PathPTFE + Moisture TrapSensor protection
DataSQLite + WALOffline-first
InfraAnsible + DockerImmutable · fleet-ready
Current Status

Alpha prototype in hardware integration and assembly. Environmental control, sensor array, and reactive layer firmware are functional. Deliberative layer deployed via Ansible. Volumetric capture pipeline in integration; visual hull proxy under development. Air-path redesign (PTFE + condensation trap) in progress. First closed-loop growth experiments planned for 2026.