DIY Arduino Aquarium Monitor Build Guide: Temp pH and Float
Commercial aquarium controllers like the Apex by Neptune Systems start at SGD 600 and climb past SGD 1500 once probes and add-ons are factored in. For HDB hobbyists running a single planted tank, that price is hard to justify when an Arduino Uno or ESP32 microcontroller paired with three sensors does 80 per cent of the same job for under SGD 90. DIY Arduino aquarium monitor builds read tank temperature, pH, and water-level float status, display them on an OLED screen, and optionally push alerts to your phone via WiFi. This guide from Gensou Aquascaping at 5 Everton Park covers the parts list, the wiring map, and the starter code that brings the whole rig online in one weekend.
Materials and Tools
One Arduino Uno R3 (SGD 18 from Sim Lim level 3) or ESP32 dev board for WiFi support (SGD 14). One DS18B20 waterproof temperature probe (SGD 6). One SEN-0161 analogue pH probe with BNC and signal board (SGD 28-35). One float switch sensor (SGD 4). One 0.96-inch I2C OLED display (SGD 8). A breadboard, jumper wires, and a 4.7kΩ pull-up resistor (SGD 5). Optional — a small project enclosure (SGD 6). Total SGD 60-90.
Why This DIY Saves Money
The Apex Jr base controller starts at SGD 600 and only includes one temperature probe. Adding a pH probe (SGD 180), float switch (SGD 80) and OLED interface brings it to SGD 900-1100. The Arduino route delivers comparable monitoring for SGD 90, a saving of SGD 800-1000. The trade-off is build time — about eight hours including code tweaks — and the lack of automated outlet control unless you add relay modules later (SGD 8 each).
Step 1: Wire the DS18B20 Temperature Probe
The DS18B20 has three wires — red (5V), black (GND) and yellow (data). Connect red to the Arduino 5V pin, black to GND, and yellow to digital pin D2. Place a 4.7kΩ pull-up resistor between the data line and 5V — the OneWire protocol needs this resistor to function. The waterproof probe goes directly into the tank water; rated to 60°C with epoxy-sealed tip.
Step 2: Wire the pH Probe
The SEN-0161 ships with a small signal-conditioning board. Connect the BNC plug from the probe to the board, then wire the board’s three pins — V+ to 5V, GND to GND, and Po (analogue output) to Arduino analogue pin A0. The probe itself sits in the tank, ideally near the filter outflow for fresh water sampling. Calibrate against pH 4.0 and pH 7.0 buffer solutions (SGD 12 the pair) at the start.
Step 3: Wire the Float Switch
Float switches are simple — two wires, normally open or normally closed depending on water level. Connect one wire to digital pin D3 and the other to GND. Mount the float at your target water-line minus 10mm so it triggers when evaporation drops the level. Use a HIGH read on D3 with internal pull-up to detect a low-water condition.
Step 4: Wire the OLED Display
The 0.96-inch I2C OLED has four pins — VCC, GND, SDA and SCL. Connect VCC to 5V (or 3.3V on ESP32), GND to GND, SDA to A4 on Uno (or GPIO21 on ESP32), and SCL to A5 (or GPIO22 on ESP32). The I2C address is typically 0x3C — confirm with an I2C scanner sketch if your unit differs.
Step 5: Load the Starter Sketch
Install the OneWire, DallasTemperature, and Adafruit_SSD1306 libraries through the Arduino IDE library manager. The starter sketch reads temperature in Celsius, calculates pH from the analogue voltage with a calibrated slope, reads float status, and renders all three values to the OLED in 10-point font. Sample code blocks are widely shared on Arduino forums and the DFRobot wiki for SEN-0161. Upload at 9600 baud.
Step 6: Calibrate the pH Probe
Rinse the pH probe in distilled water and submerge in pH 7.0 buffer. Wait sixty seconds for the reading to stabilise. Note the analogue value — typically around 2.5V midpoint. Repeat in pH 4.0 buffer; the reading should drop. Plug both points into the slope and intercept variables in the sketch. Re-calibrate every two months because the glass membrane drifts over time.
Sealing and Finishing
House the Arduino, breadboard and OLED in a small project enclosure with cable glands for the probe wires. The enclosure protects the electronics from the inevitable splash and condensation around an aquarium. Drill cable gland holes carefully with a step bit. Apply silicone around the gland threads to seal water out. Allow seven days silicone cure before deploying near the tank.
Aquasafe Test Before Use
The DS18B20 waterproof probe is rated for permanent submersion. The pH probe glass membrane is inert. Test the entire rig dry first — power on, watch the OLED show probe values when the temperature probe is held in your hand (temperature rises, you see the change in real time). Then submerge the temperature probe in dechlorinated water at known temperature and verify the reading. Any electrical malfunction at this stage is harmless. Browse compatible tank gear in the aquarium equipment range.
Maintenance, Pi Alternative and Pitfalls
The DS18B20 probe lasts five to ten years in tank water. The pH probe glass membrane lasts twelve to eighteen months before drift becomes too large to calibrate out — plan to replace annually for SGD 25-30. The Arduino board itself lasts indefinitely if kept dry. Pair the monitor with quality water conditioning supplies from the water care range to act on what the sensors report.
For livestream camera, web dashboard and cloud logging, swap the Arduino for a Raspberry Pi Zero 2W (SGD 25) running a Python script. The Pi handles network connectivity natively, supports a small camera module for daily timelapse capture, and pushes data to MQTT or Home Assistant. The same probes and wiring work; only the code platform changes. Budget SGD 80-110 total for the Pi build with camera and case.
Common pitfalls — skipping the 4.7kΩ pull-up resistor on the DS18B20 data line means the temperature probe returns -127°C error readings constantly. Wiring the pH probe BNC connector incorrectly (signal and ground reversed) gives constant 0 reading. Submerging the Arduino itself rather than just the probes destroys the board within seconds; keep the microcontroller in the dry enclosure with only sealed probe cables passing through cable glands.
Related Reading
emilynakatani
Still Have Questions About Your Tank?
Drop by Gensou Aquascaping — most walk-in questions get answered in under 10 minutes by someone who has set up hundreds of tanks.
5 Everton Park #01-34B, Singapore 080005 · Open daily 11am – 8pm
