afterware
Saved
Hardware · build

AlgaeSense, a microscope-driven algae grower

Original

An autonomous photobioreactor built on the Arduino UNO Q that periodically samples its algae culture into a viewing chamber, images it with a USB microscope, and uses OpenCV to track growth and flag contaminants.

Build sheet
Board
Arduino UNO Q
Sensor
USB microscope
Method
OpenCV contour analysis
Actuators
Peristaltic pump, aerator, LEDs
Can I build this?Advanced · AI 4/5
Difficulty
Advanced
AI-buildability
4/5

Most of the difficulty is software on an off-the-shelf board, though the printed pump, plumbing and optics need hands-on work.

Time
20 hours
Tools
3D printerlaser cuttersoldering iron
Starter prompt

Based on "AlgaeSense, a microscope-driven algae grower" on Afterware: https://afterware.xyz/p/algaesense-a-microscope-driven-algae-grower

Write a Python program for an Arduino UNO Q that captures frames from a USB microscope, enhances contrast, applies thresholding and morphological filtering, and counts filament contours to estimate algae coverage. Have it send serial commands such as PUMP_SAMPLE 3000, AERATOR OFF and LIGHT 180 to the MCU side, and log each measurement with a timestamp. Run the cycle GROW, stop aeration, sample, settle, image, analyse, and repeat at a set interval.

Estimates based on the original write-up. Building with an AI assistant? Connect it to Afterware (free MCP server).

Story

AlgaeSense is a cube-shaped 3D printed housing that sits above an algae tank and holds the electronics. Growth LEDs are embedded in the housing. A 3D printed peristaltic pump pulls a small sample through silicone tubing into a microscope viewing chamber. Aeration pauses before each sample so bubbles and water movement do not interfere with imaging.

The Arduino UNO Q splits the work. Its MCU side drives the pumps, aerator, LEDs and sensors using simple commands such as LIGHT, AERATOR and PUMP_SAMPLE. The Linux side runs the USB microscope, an OpenCV pipeline (contrast enhancement, thresholding, morphological filtering, contour detection), logging and control decisions.

The author describes the system as an early warning tool rather than a toxin detector. It tracks filament density, contour size and morphology changes between samples, and it does not detect microcystins or dissolved chemicals directly. The prototype demonstrates automated sampling, imaging, detection, actuator control and logging as one repeating cycle.

Resources · 2
More like this
More like this