I need help with Flume and Rachio monitoring flow while irrigation is running

Bear with me here. I’m legally blind and use a screen reader. I’m also no whiz kid when it comes to home assistant and yaml.

I have the Flume and Rachio integrations setup and running. I have a baseline gallons per minute flow rate for each of my irrigation zones. What I would like to get going (but I have zero idea on how), is to have automations for each Rachio irrigation zone. Basically, when Rachio zone (x) runs to poll Flume for the current flow rate and compare to my baseline for that zone. I would prefer this to be gallons per minute flow based (over total gallons) as the runtimes change with the seasons. I’ve noticed the flow rate is typically high for the first minute of flow and then drops and holds steady. So a wait one minute then poll, or average out the flow over the cycle duration, would be necessary.

Im looking to be notified of two conditions really. First condition is a no flow condition where Rachio is watering a zone but no water is flowing.

Second condition are leaks in the irrigation system. I’ve had two different kinds of leaks happen in the past. An instantaneous, larger leak (say an emitter or fitting pops off underground), and a slow pinhole leak that gradually gets worse and worse.

Being blind as a bat, I am not able to tell when things aren’t getting watered (until they’re crispy and totally dead), or when I have water running down the street from a leak.

I have the irrigation set to run at times where nothing else should be running (granted there will be exceptions on occasion). I’d much rather get a false alarm than none at all. I could easily, make sure all water is off and manually run a zone to verify the condition.

For the no flow condition (where Rachio is watering and no flow is detected by Flume) I would like a notification and have the watering cycle for that zone cancelled.

For a larger leak I would like a notification and have the watering cycle for that zone cancelled.

For smaller leaks that tend to get larger over time, I would just like to be notified.

Would anyone be interested in helping me out with a blue print of sorts (if you’ve done something similar already) or just help with a basic code/template I could copy/paste and modify as needed for each zone? It would be greatly appreciated. Thanks for any assistance with this!

How do you have your schedules set up - in the Rachio app or as schedules and actions in Home Assistant?

Not sure it makes much of a difference for what you’re trying to achieve, but probably important to figure out, e.g. why a scheduled task isn’t providing water to your plants.
It hasn’t happened for a while now, but there were periods of time when the HA-Rachio integration just lost the connection, so - while the irrigation task was running according to my Rachio-based schedule - the HA integration didn’t know that it was actually watering, while this could be observed by my Flume reports.

This is also the reason why I’m running the schedules from Rachio - my priority is watering my plants and only after that I’m interested in seeing thing in HA.

The disadvantage of this approach is, that - although the scheduled action is carried out by the Rachio as desired - the Rachio integration doesn’t always report back as quickly as I’d like to. This causes ‘overlaps’ in settings when I run multiple circuits as part of the same schedule, i.e. Rachio turns circuit #3 off and circuit #5 on but HA sees it in the reverse order, and I’ve learned that adding dummy circuit #8 in between helps me out with that.

I guess, this would be another useful notification: checking that during a scheduled event HA shows the Rachio watering with Flume confirming it.

Sorry, for the long intro - you might be aware of most of these items already.

The good news is, that there is a gal/m sensor in Flume, so it should be easier to compare it with your baselined flow rate(s).

With my limited capabilities, I’d probably use the following approach for your first condition (a no flow condition where Rachio is watering a zone, but no water is flowing):

  1. Use each one of the zone entity_ids from the Rachio integration (switch.zone_1, switch.zone_2, switch.zone_x) as a trigger.
  2. Create a wait-2-minutes-action-to allow for the irrigation pipes/hoses to fill up (also needed because it probably takes the Flume often about a minute to report back any flow changes)
  3. Check, if the value of the Flume sensor (something like sensor.flume_sensor_xxxxx_current) is below half of the lowest baseline flow rate.
  4. If not, it’s all good.
  5. If it’s true, turn_off all the switches from the trigger and send a notification with the info which circuit/zone caused the issue.

Example - untested:

alias: Irrigation Error Case 1
description: Scheduled but no flow detected
triggers:
  - trigger: state
    entity_id:
      - switch.zone_1
      - switch.zone_2
    from:
      - "off"
    to:
      - "on"
conditions: []
actions:
  - delay:
      hours: 0
      minutes: 2
      seconds: 0
      milliseconds: 0
  - if:
      - condition: numeric_state
        entity_id: sensor.flume_sensor_xxxxx_current
        below: 0.25
    then:
      - action: switch.turn_off
        metadata: {}
        data: {}
        target:
          entity_id:
            - switch.zone_1
            - switch.zone_2
      - action: notify.mobile_app_xxxxx
        data:
          title: Irrigation Issue!
          message: >-
            Schedule for {{ trigger.to_state.name }} was cancelled due to no
            flow being recorded.
          data:
            ttl: 0
            priority: high
mode: single

Let me know, if that works for you - I’ll think about the 2nd notification condition in the meanwhile.

Might be good to know what your entity_ids look like so that better sample code can be provided.

1 Like

Thank you for this! I’ll try to put some time aside later today to try working on it. I just wanted to post a quick thank you for the response!

1 Like

Keep me posted on how it goes.
I’ve started working on something similar - thanks for the idea!