SØNDAG
2026-08-09

Too many projects, too many ideas, too few hours — one learning a day anyway

Sightglass

part of Maracaibo

A camera that reads the diesel sight glass, because the tanks predate sensors.

A tank camera frame through the vision reader: two vertical sight-glass tubes against a backlit panel with a handwritten litre scale running up to a '460 voll' mark, a green detection box drawn around the left tube, an amber column filling the tube from the bottom up to a red line across the detected diesel surface, and an overlay label reading 20.4 percent.
FIG. 1 What the reader sees — detection box, amber fluid column, and the red line it calls the level.
The Sightglass fuel board: a banner reading that a level only falls and a refuelling must be declared first, above two tank cards — Port Diesel Tank at 21.3 percent, 98 of 460 litres, plus or minus 1 percent, marked OK, and Starboard Diesel Tank at 20.4 percent, 94 of 460 litres, plus or minus 3 percent, marked CHECK because that camera's read quality is low.
FIG. 2 Two tanks that share a pipe, reading within a point of each other — starboard marked CHECK on low image quality.

The boat’s fuel tanks are older than the idea of a fuel sensor — but they have a sight glass, and a sight glass can be looked at. So a small camera watches both glasses, a vision model reads the level off the image, and the result publishes as an ordinary MQTT sensor. One safeguard worth stealing: a diesel level only falls, so when the camera suddenly reads higher the number freezes until a refill is declared — a wrong reading is worse than no reading.

CODE
POSTS