Accurate fluid level sensor by Stoney 3d model
Warning. This content is not moderated and could be offensive.
smoke
3dmdb logo
Thingiverse
Accurate fluid level sensor by Stoney

Accurate fluid level sensor by Stoney

by Thingiverse
Last crawled date: 3 years, 4 months ago
Uses a float to rotate a pin holding a small 5mm magnet. magnet angle detected by a low cost GY-273 compass module, liquid depth calculated based on length of float arm and angle.
Float arm I used 4mm oak dowel. Float halves filled with high density foam the superglued together, then I coated my float with a varnish for added waterproofing.
Magnet is held in 5mm hole in hine_pin part with hot melt glue,
GY-273 fits into pcb_holder then also sealed in place with glue.
Accuracy with a 300mm arm seems better than 1mm, certainly very repeatable.with low noise.
Code is a modified example of the adafruit sensor library which adds
Added some screengrabs after adding a few parts for clarity. the 2 blue parts are glued together with the pivot in between and there are a couple of 2mm holes to add some printer filament into as a dowel and guide.
the silver part is the magnet and shows the hole it goes into and orientation, the black part is the edge of the tub that the bracket was designed to clip onto and I want to measure the depth in.
The green part is GY272 mag sensor and shows the hole it fits into, the magnet centre axis is then directly over the centre part of the pcb, needed for accuracy.
The orange rod is the 4mm oak dowel and in my case is 300mm long not the short length shown here.
I printed mine in black so it does not photograph well.
The yellow part is obviously for my specific tub so you might need to design your own clamp, the blue holder is superglued to the yellow part, I only wanted to make one of these so did not spend much time on clever mounting systems. No need.
The large graph screenshot is from the provided code and the serial plotter, the blue and red are the X and Y sensors and the green is the calculated water depth while swinging the float around.
The small screenshot is showing the water level logged every 30 seconds on my mqtt broker. added more water at the end.

Tags