Water flow meter - pulse meter included - esphome

Sorry for later reply.
Could you post your esp code?
Thanks

Thanks for posting this! This looks just what I’m after, too. However, I’m going to locate this outside, to monitor water supply to livestock (and so tell me if there are leaks or a faulty water-trough, etc).

My question: do you know the total power of your system? Am wondering what size solar PV would be needed to power it continually.

Hello Chris, mine is connected to the grid with an old iPhone charger plug

Thanks. I was really asking whether you knew the actual power draw. (I’m hoping to attach this to a standpipe in a field, but not sure whether it’ll be feasible as WiFi is clearly more power-hungry than zwave or ZigBee, and will require a fairly large solar panel and power storage for nighttime, I suspect.)

Hi. this is what i am looking for.
I need some help. I have a watermeter installed by my landlord, it uses a simple reed switch and send out pulses with +22v to the system they use. I want to tap into this pulse and send it to HA.
According o the specification on the watermeter it is sending out one puls every 10L.
How can i change this code to work with 10L per pulse that my meter will give out?
Thank you.

Hi @Peppe66

This is what I’ve done with a Shelly Uni instead of the Plus Addon.
Maybe it help’s you.
https://community.home-assistant.io/t/water-meter-with-shelly-uni/567365

With the Addon it could work too but if you use an inducive sensor you need another power source for the higher voltages of the sensor. The Addon only provides 3.3V.

d.k

The code at the beginning of the threat is giving 1L every 87 pulses
The following code should be fine for 10L every pulse

sensor:
  - platform: pulse_meter
    pin: GPIO12
    name: "Instant water consumption"
    unit_of_measurement: "L/min"
    icon: "${ha_icon}"
    timeout: 1s
    accuracy_decimals: 3
    filters:
      - lambda: return (x / 0.1);
    total:
      name: "Total water consumption"
      unit_of_measurement: "m³"
      device_class: water
      state_class: total_increasing
      accuracy_decimals: 3
      icon: "${ha_icon}"
      filters:
        - lambda: return (x / 100.0);

Please check and let me know

Hi, i think this works. just have to figuring out some other problems i have. as i dont really have a GND connecton to my landlords system so it is a Little hit and miss atm.
Thanks for the help.

HI everybody,

I have a question.

Background: I’ve successfully got my flow meter providing data when the internal impeller is spinning, i assume its correct (i’m just blowing though it currently as its on a bench). I also have it reading zero when it’s not spinning. I used the internal pull up resistor function, i’m using an ESP32Thing.

My question is: My flow meter has the following specifications: 1Hz – 0.98 LPM Square wave. I am happy with litres per minute. Is there any additional filtering I need to do? How often should I update?

sensor:
  - platform: pulse_counter
    name: "Flow rate"
    pin:
      number: GPIO23
      mode: INPUT_PULLUP
      inverted: true
    update_interval: 60s
    filters:
    unit_of_measurement: "L/min"

hello, I have problem that I have to use a battery for that sensor, any experience?

I have a similar problem as the mete is outside without any electricity to easily connect to.
Wifi/esp has mixed feedback on powerusage and I did not want to install a large(r) battery pack as all of this is accessible from the road by anyone.
So, I ordered a zigbee module c2530 which one can program and tested that with a pulse sensor I already had…now I ordered the one for the water meter, will keep you posted
Not sure if this helps your case though

@vingerha please keep me updated…

Ping me on the side in a 4-6 weeks (the time my Ali order seems to take)

but it is possible to program CC2530 with esphome?
there is not a version zigbee of esp?

did you just order or you have to do it? in case can you take another one? because I have no programmer, that’s the reason I ask if there was someone usb that I can program with esphome

like this one? ESP32-C6

HI, esphome is wifi and (see earlier comment) I was/am not confident that a simple battery would hold up long enough. Adding costly lithium stuff for outside open to all is too much of a risk so I aim to turn zigbee with low battery use. The c2530 one can program to have the pins measure the pulse sensor (not explaining details but happy to share just ask). When connected via Z2M it shows me the pulses with which I can do whatever I like…The target is to have low energy use with a simple AAA battery powered c2530…qed

look on this:
https://it.aliexpress.com/item/1005005087127863.html?pdp_npi=2%40dis!EUR!9%2C50€!9%2C50€!!!!!%40211b600b16848622620832712e3f6a!12000031593805410!btf&_t=pvid%3Abf8625e2-6b3c-4773-bf58-03160f76c1f5&afTraceInfo=1005005087127863__pc__pcBridgePPC__xxxxxx__1684862262&spm=a2g0o.ppclist.product.mainProduct&gatewayAdapt=glo2ita

I have a couple of zigbee sensors for my garage and main gate.
Both are with battery (2032) and the battery life is very poor as related to the number of openings closings
I’m not sure a battery solution can be reliable for a weather meter unless you are single or away from home most of the time

I too have 12 zigbee sensors and most last >1 year, the odd one is poor but then…cheap.
For measuring water well enough, this is not at all critical and any power/connection failure can easily be adjusted manually by aligning meter/ticks.
@platini76 yes, I know these things and have a few too but they consume a lot, hence no esp/wifi for now…If zigbee does not work then I will have no option to go back to (current) manual readings
EDIT: “know these things” meaning that I have a few ESP different cards 32/8266 and all require to be plugged in

if I buy the zigbee sensor that I link. can you help me with the code to set up it?

the sensor I link is zigbee… not wifi.