Flow Meter Addon for reef-pi

Hi Rob - looking at two of these.
https://h2oprotech.com/products/ha-1044-flow-meter-3-wire?variant=7121431593018

is this correct?
these are 3/4inch.
thanks
Hi @Dukereefnz, those look and sound like the correct type however they don't say Hall Effect so I'm not 100%, not really sure if there's different types. It talks about pulses per gallon, plus they mention it's just general purpose and show pic of connecting to a microcontroller so it should be ok.

This is the type I recommend, as you can see they are very similar to the H2Opro.

 
Wish there was a 1" meter. theirs get a tad expensive.
May look at an adapter for this to be implemented.. Following along
 
There are cheaper ones on Amazon up to 1.5” I think. You need to check their ratings though. They often give a gallon per minute rating but most f the hobby works in gallon per hour. Just be mindful of that and do the conveersion
 
There are cheaper ones on Amazon up to 1.5” I think. You need to check their ratings though. They often give a gallon per minute rating but most f the hobby works in gallon per hour. Just be mindful of that and do the conveersion
I've seen the cheap ones up to 2" but just a few minutes ago I read in some reviews that the 1" goes down to 0.5" internally so there will be some back pressure which might not be good for a pump. I've been looking around for large ones that don't tapper but haven't found any that say that.
 
I forgot to explain how to connect a flow meter directly to a Raspberry Pi. Flow meters need 5v to operate, the Pi is only 3.3v so you need to add a couple resistors to drop the 5v to 3.3v.

The +5v goes to your power supply and the ground to the Pi.

flow8.png
Something very special:
I will have a 4-channel level shifter anyway (BSS138, has 10k pull-up resistors, so I might have to add another 10k to bring it to the ~5k from the Adafruit Guide), so I'm thinking about putting this on one of them next to the temperature probes on the other channels. That by itself should do the trick of level shifting for the PI.

That way, however, the sensor almost always pulls the signal to GND and I have almost permanent current flow through the pull-up resistors. Does anybody know whether I could invert that logic ?

I'm thinking about putting a MOSFET between pull-up and GND, triggered by the flow sensor signal. That pulls the signal line to GND every time a pulse comes in. The program should still work, since it only looks for either a rising or falling flank, which is still there, just inverted.
 
Last edited:
Something very special:
I will have a 4-channel level shifter anyway (BSS138, has 10k pull-up resistors, so I might have to add another 10k to bring it to the ~5k from the Adafruit Guide), so I'm thinking about putting this on one of them next to the temperature probes on the other channels. That by itself should do the trick of level shifting for the PI.

That way, however, the sensor almost always pulls the signal to GND and I have almost permanent current flow through the pull-up resistors. Does anybody know whether I could invert that logic ?

I'm thinking about putting a MOSFET between pull-up and GND, triggered by the flow sensor signal. That pulls the signal line to GND every time a pulse comes in. The program should still work, since it only looks for either a rising or falling flank, which is still there, just inverted.
The BSS138 won't work with DS18B20 sensors, the signal seems to get lost through them but you can use them for I2C. I think the flows don't like them either as they use interrupts but I could be wrong about that one, the voltage divider works for sure though. Not sure about using the mosfet for that, guess there's one way to find out. :)
 
The BSS138 won't work with DS18B20 sensors, the signal seems to get lost through them but you can use them for I2C. I think the flows don't like them either as they use interrupts but I could be wrong about that one, the voltage divider works for sure though. Not sure about using the mosfet for that, guess there's one way to find out. :)
Thx for the input !
I'll have to testit in a dry run with header pins for example. Maybe you really need to bring the pull up down to ~5k to make it work. I'll keep you updated :)
 
Thx for the input !
I'll have to testit in a dry run with header pins for example. Maybe you really need to bring the pull up down to ~5k to make it work. I'll keep you updated :)
Just as an update: the BSS138 level shifter works with both the DS18B20 temperature sensor and the Seedstudio flow meter I have.
 
That's all I need and things could get pretty interesting quick. I was playing with Node.js, if I run the js file with node in terminal it does what it should but I wasn't able to fire it from the web page using ajax.
I hope you did well and gained valuable experience with Node.js I usually go to a friend who is very good at it he said that to work in Node he goes to a company that build him everything, he even showed https://zenbit.tech/services/nodejs-development-company/ not sure how relevant it is but I'll leave it!
 
I hope you did well and gained valuable experience with Node.js I usually go to a friend who is very good at it he said that to work in Node he goes to a company that build him everything, he even showed https://zenbit.tech/services/nodejs-development-company/ not sure how relevant it is but I'll leave it!
Thanks, I didn't do a lot with Node.js, was able to work it out with c++, I'm by far most comfortable with it. C++, php, javascript, html, css and mysql is plenty enough for me to keep track of. At one time I was messing with python which I found the most difficult as it basically goes against everything I know with c++.
 
Thanks, I didn't do a lot with Node.js, was able to work it out with c++, I'm by far most comfortable with it. C++, php, javascript, html, css and mysql is plenty enough for me to keep track of. At one time I was messing with python which I found the most difficult as it basically goes against everything I know with c++.
I admire the amount of knowledge you have of languages, I think that now you can be called a polyglot in a sense!))
 
Hey @robsworld78 I have been using 4 flow sensor that the calibration factor is 7.5 just bought 2 large diameter one and the is 4.5 .in your program it only allows for one. If I stay with the 7.5 what equation would I use to calculate the 4.5 into gallons per hour. Thank you for all your help.
 
Hey @robsworld78 I have been using 4 flow sensor that the calibration factor is 7.5 just bought 2 large diameter one and the is 4.5 .in your program it only allows for one. If I stay with the 7.5 what equation would I use to calculate the 4.5 into gallons per hour. Thank you for all your help.
If you set the script to output gallons per hour, just with the calibration factor of 7.5 instead of 4.5, you need a factor of 1.6666667 ( ~ 7.5 / 4.5 )
E.g. Correct Value = 1.666667*Incorrect Value
 
If you set the script to output gallons per hour, just with the calibration factor of 7.5 instead of 4.5, you need a factor of 1.6666667 ( ~ 7.5 / 4.5 )
E.g. Correct Value = 1.666667*Incorrect Value
So for Dummies like me just multiple the reading I get by 1.666667 and that the correct flow reading. Thank you again my friend.
 

IF YOU HAD TO TAKE A REEFING EXAM, WOULD YOU PASS?

  • Yes!

    Votes: 32 45.7%
  • Not yet, but I have one that I want to buy in mind!

    Votes: 9 12.9%
  • No.

    Votes: 26 37.1%
  • Other (please explain).

    Votes: 3 4.3%
Back
Top