Question about seeedstudio water flow sensor 3-4 inch (See-169) for an R-Pi-3

Hi everyone!

I require help regarding connecting up this flow sensor.

Most of these sensors where hall effect is used, have the same operational parameters: Typically 5 to 18v applied and a square wave with peaks and valleys the same as the applied +V and common (Ov).

Has anyone connected this sensor to a Raspberry Pi 3? I aim/expect to have an Optoisolator + Voltage divider in the circuit to a GPIO pin to keep the Pi safe, and use a dedicated thread in software to do the counting. Am I On the right track?

Thanks in advance for your help!

Hello there!

Seeedstudio seems to have removed almost everything related to this product on their website so it can be hard to find some guides.
I however found this! : http://wiki.seeedstudio.com/G1_and_2_inch_Water_Flow_Sensor/
There’s a wiring diagram in this link that shows that only a simple pull-up resistor in needed in order to operate the device.

Since the Raspberry Pi GPIOs work with 3.3v logic, you will need to use a logic converter like this one: https://www.robotshop.com/en/logic-level-converter-bidirectional.html

As for the programming part, a dedicated thread seems like a good idea!

Good luck!

Many thanks for you help Magmator.