Youless - monitoring water meter on S0 port

I would indeed ask to add it to the integration. The value is there. In the mean time it is possible to add it yourself as a rest sensor. I’ll try to put one together for you when I’m behind a pc. Remind me in a while if I forget to.

1 Like

I would greatly appreciate your help. thank you so much !

Assuming you already have a sensors.yaml file, put this in there to add support for the Youless P1 water meter. Don’t forget to replace your youless ip adress after resouce:

- platform: rest
  name: Youless P1 water meter
  scan_interval: 12
  resource: http://192.168.1.100/e
  headers:
    User-Agent: Home Assistant
    Content-Type: application/json
  method: GET
  value_template: "{{ value_json[0].wtr }}"
  state_class: total_increasing
  device_class: water
  unit_of_measurement: m³
  icon: "mdi:water"

Then make sure to press the button to check if your configuration is ok. If it is reboot. Then you should have a new sensor.

It’s working perfectly now thank you so much for your help !

1 Like

You can adjust the polling frequency by changing the scan interval. I put it on a rather arbitrary 12 seconds (5 times per minute). If you look at how often the youless app updates water values you can get an idea of how responsive the sensor is, and figure out if you can go faster or slower. Don’t set it to fast though if you don’t need super fast responses, because the original youless integration is also constantly polling the same interface.

1 Like