Integration with Orbit B-Hyve Irrigation System

I use my Orbit devices in “smart water” mode and would like to be able to show on the dashboard when the next water events are planned.

Switch.front_porch_zone has a value of:

device_name: Front Porch Sprinkler
device_id: 60a685884f0cc23b2fbf5abd
zone_name: Front Porch Zone
smart_watering_enabled: true
manual_preset_runtime: 900
sprinkler_type: oscillator
image_url: >-
  https://s3-us-west-2.amazonaws.com/orbit-irrigation/zone-assets/60a65c054f0cc23b2fbf52fe/2ede5a86-9b31-41f3-bfaf-6e1d5c49d6a6
program_e:
  enabled: true
  name: Smart Watering
  is_smart_program: true
  watering_program:
    - '2022-06-27T05:45:00-05:00'
    - '2022-06-27T06:07:00-05:00'
    - '2022-06-29T05:45:00-05:00'
    - '2022-06-29T06:07:00-05:00'
    - '2022-07-05T05:45:00-05:00'
    - '2022-07-05T06:07:00-05:00'
    - '2022-07-07T05:45:00-05:00'
    - '2022-07-07T06:06:00-05:00'
device_class: switch
entity_picture: >-
  https://s3-us-west-2.amazonaws.com/orbit-irrigation/zone-assets/60a65c054f0cc23b2fbf52fe/2ede5a86-9b31-41f3-bfaf-6e1d5c49d6a6
icon: mdi:water-pump
friendly_name: Front Porch Zone

I can use the Template section of developer tools to retrieve the smart_watering_enabled: true value with this.
{{state_attr(‘switch.front_porch_zone’,‘smart_watering_enabled’)}}

Now I want to get the watering program details

  watering_program:
    - '2022-06-27T05:45:00-05:00'
    - '2022-06-27T06:07:00-05:00'
    - '2022-06-29T05:45:00-05:00'
    - '2022-06-29T06:07:00-05:00'
    - '2022-07-05T05:45:00-05:00'
    - '2022-07-05T06:07:00-05:00'
    - '2022-07-07T05:45:00-05:00'
    - '2022-07-07T06:06:00-05:00'

When I use this in Developer Tools - Templates
{{state_attr(‘switch.front_porch_zone’,‘program_e’)}}
I get the following

{‘enabled’: True, ‘name’: ‘Smart Watering’, ‘is_smart_program’: True, ‘watering_program’: [datetime.datetime(2022, 6, 27, 5, 45, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 6, 27, 6, 7, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 6, 29, 5, 45, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 6, 29, 6, 7, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 7, 5, 5, 45, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 7, 5, 6, 7, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 7, 7, 5, 45, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’)), datetime.datetime(2022, 7, 7, 6, 6, tzinfo=zoneinfo.ZoneInfo(key=‘America/Chicago’))]}

How do I extract this detail in a usable format that can be displayed on a dashboard?

Check out the list-card which can display tabular data. Also the Python script in the integration repository might be helpful with some logic for parsing and displaying localised date/time data.

Also wondering this!

My example:

- id: "150c"
  alias: "Set Irrigation runtime"
  initial_state: true
  trigger:
    - platform: time
      at: "00:05:20"
  condition:
    - condition: template
      # Once a month is enough
      value_template: "{{ now().day == 1 }}"
  action:
    # 1 - In Winter 15 Minutes are good
    - service: bhyve.set_manual_preset_runtime
      data:
        entity_id: switch.zone_1_zone
        minutes: >
          {% set monat = now().month %}
          {% if monat in (1,2,11,12) %}
            15
          {% elif monat in (3,4,9,10) %}
            20
          {% elif monat in (6,7) %}
            30
          {% else %}
            25
          {% endif %}
    - service: logbook.log
      data:
        name: "Irrigation runtime set"
        message: "to {{ state_attr('switch.zone_1_zone','manual_preset_runtime') }}"

I have two BHyve XD water timers, Model HT31BT and just picked up the Gen 2 Hub so I can control them via WiFi and integrate them into HA. My issue is the hub isn’t strong enough to reach both timers. I can only control one of them unless I relocate the hub to the other side of the house so I can talk to the other one. Oddly enough the app shows both timers as connected regardless of where the hub is.

My question - Has anyone successfully added a second hub to your setup to get better range? I’m not even sure this is possible, but thought I’d ask here first. Thanks for any feedback!

Any chance you could share your Node Red flow? Trying to do this same thing.

Here’s the flow for one zone.

[
    {
        "id": "3e2937d631a8eed8",
        "type": "api-call-service",
        "z": "829fc44d0881fb9e",
        "name": "Garden on",
        "server": "753d0826.5edb28",
        "version": 3,
        "debugenabled": false,
        "service_domain": "bhyve",
        "service": "start_watering",
        "entityId": "",
        "data": "{\"entity_id\":\"switch.zone\",\"minutes\":\"{{payload}}\"}",
        "dataType": "json",
        "mergecontext": "",
        "mustacheAltTags": false,
        "outputProperties": [],
        "queue": "none",
        "x": 490,
        "y": 320,
        "wires": [
            []
        ]
    },
    {
        "id": "9e1681bcc91f21ca",
        "type": "api-call-service",
        "z": "829fc44d0881fb9e",
        "name": "Garden off",
        "server": "753d0826.5edb28",
        "version": 3,
        "debugenabled": false,
        "service_domain": "bhyve",
        "service": "stop_watering",
        "entityId": "",
        "data": "{\"entity_id\":\"switch.zone\"}",
        "dataType": "json",
        "mergecontext": "",
        "mustacheAltTags": false,
        "outputProperties": [],
        "queue": "none",
        "x": 490,
        "y": 380,
        "wires": [
            [
                "0088491da9fa831b"
            ]
        ]
    },
    {
        "id": "70eaf8aca5b09667",
        "type": "server-state-changed",
        "z": "829fc44d0881fb9e",
        "name": "Garden zone on",
        "server": "753d0826.5edb28",
        "version": 3,
        "exposeToHomeAssistant": false,
        "haConfig": [
            {
                "property": "name",
                "value": ""
            },
            {
                "property": "icon",
                "value": ""
            }
        ],
        "entityidfilter": "switch.zone",
        "entityidfiltertype": "exact",
        "outputinitially": false,
        "state_type": "str",
        "haltifstate": "on",
        "halt_if_type": "str",
        "halt_if_compare": "is",
        "outputs": 2,
        "output_only_on_state_change": true,
        "for": 0,
        "forType": "num",
        "forUnits": "minutes",
        "ignorePrevStateNull": false,
        "ignorePrevStateUnknown": false,
        "ignorePrevStateUnavailable": false,
        "ignoreCurrentStateUnknown": false,
        "ignoreCurrentStateUnavailable": false,
        "outputProperties": [
            {
                "property": "payload",
                "propertyType": "msg",
                "value": "",
                "valueType": "entityState"
            },
            {
                "property": "data",
                "propertyType": "msg",
                "value": "",
                "valueType": "eventData"
            },
            {
                "property": "topic",
                "propertyType": "msg",
                "value": "",
                "valueType": "triggerId"
            }
        ],
        "x": 100,
        "y": 440,
        "wires": [
            [
                "20a29647c5539afe"
            ],
            [
                "0088491da9fa831b"
            ]
        ]
    },
    {
        "id": "1e1518cc5322bb05",
        "type": "api-call-service",
        "z": "829fc44d0881fb9e",
        "name": "",
        "server": "753d0826.5edb28",
        "version": 3,
        "debugenabled": false,
        "service_domain": "timer",
        "service": "start",
        "entityId": "timer.garden_irrigation",
        "data": "{\"duration\":\"00:{{payload}}:00\"}",
        "dataType": "json",
        "mergecontext": "",
        "mustacheAltTags": false,
        "outputProperties": [],
        "queue": "none",
        "x": 440,
        "y": 460,
        "wires": [
            []
        ]
    },
    {
        "id": "0088491da9fa831b",
        "type": "api-call-service",
        "z": "829fc44d0881fb9e",
        "name": "",
        "server": "753d0826.5edb28",
        "version": 3,
        "debugenabled": false,
        "service_domain": "timer",
        "service": "finish",
        "entityId": "timer.garden_irrigation",
        "data": "",
        "dataType": "json",
        "mergecontext": "",
        "mustacheAltTags": false,
        "outputProperties": [],
        "queue": "none",
        "x": 440,
        "y": 520,
        "wires": [
            [
                "0e49e0d7fed98609"
            ]
        ]
    },
    {
        "id": "3ddcd3c68b32cc37",
        "type": "server-state-changed",
        "z": "829fc44d0881fb9e",
        "name": "",
        "server": "753d0826.5edb28",
        "version": 3,
        "exposeToHomeAssistant": false,
        "haConfig": [
            {
                "property": "name",
                "value": ""
            },
            {
                "property": "icon",
                "value": ""
            }
        ],
        "entityidfilter": "input_boolean.garden_timer",
        "entityidfiltertype": "exact",
        "outputinitially": false,
        "state_type": "str",
        "haltifstate": "on",
        "halt_if_type": "str",
        "halt_if_compare": "is",
        "outputs": 2,
        "output_only_on_state_change": true,
        "for": 0,
        "forType": "num",
        "forUnits": "minutes",
        "ignorePrevStateNull": false,
        "ignorePrevStateUnknown": false,
        "ignorePrevStateUnavailable": false,
        "ignoreCurrentStateUnknown": false,
        "ignoreCurrentStateUnavailable": false,
        "outputProperties": [
            {
                "property": "payload",
                "propertyType": "msg",
                "value": "",
                "valueType": "entityState"
            },
            {
                "property": "data",
                "propertyType": "msg",
                "value": "",
                "valueType": "eventData"
            },
            {
                "property": "topic",
                "propertyType": "msg",
                "value": "",
                "valueType": "triggerId"
            }
        ],
        "x": 200,
        "y": 240,
        "wires": [
            [
                "adfdfc8d123e010c"
            ],
            [
                "9e1681bcc91f21ca"
            ]
        ]
    },
    {
        "id": "adfdfc8d123e010c",
        "type": "api-current-state",
        "z": "829fc44d0881fb9e",
        "name": "Minutes",
        "server": "753d0826.5edb28",
        "version": 2,
        "outputs": 1,
        "halt_if": "",
        "halt_if_type": "str",
        "halt_if_compare": "is",
        "entity_id": "input_select.garden_timer_values",
        "state_type": "num",
        "blockInputOverrides": false,
        "outputProperties": [
            {
                "property": "payload",
                "propertyType": "msg",
                "value": "",
                "valueType": "entityState"
            },
            {
                "property": "data",
                "propertyType": "msg",
                "value": "",
                "valueType": "entity"
            }
        ],
        "override_topic": false,
        "state_location": "payload",
        "override_payload": "msg",
        "entity_location": "data",
        "override_data": "msg",
        "x": 300,
        "y": 300,
        "wires": [
            [
                "3e2937d631a8eed8"
            ]
        ]
    },
    {
        "id": "0e49e0d7fed98609",
        "type": "api-call-service",
        "z": "829fc44d0881fb9e",
        "name": "switch off",
        "server": "753d0826.5edb28",
        "version": 3,
        "debugenabled": false,
        "service_domain": "input_boolean",
        "service": "turn_off",
        "entityId": "input_boolean.garden_timer",
        "data": "",
        "dataType": "jsonata",
        "mergecontext": "",
        "mustacheAltTags": false,
        "outputProperties": [],
        "queue": "none",
        "x": 520,
        "y": 600,
        "wires": [
            []
        ]
    },
    {
        "id": "20a29647c5539afe",
        "type": "api-current-state",
        "z": "829fc44d0881fb9e",
        "name": "Minutes",
        "server": "753d0826.5edb28",
        "version": 2,
        "outputs": 1,
        "halt_if": "",
        "halt_if_type": "str",
        "halt_if_compare": "is",
        "entity_id": "input_select.garden_timer_values",
        "state_type": "num",
        "blockInputOverrides": false,
        "outputProperties": [
            {
                "property": "payload",
                "propertyType": "msg",
                "value": "",
                "valueType": "entityState"
            },
            {
                "property": "data",
                "propertyType": "msg",
                "value": "",
                "valueType": "entity"
            }
        ],
        "override_topic": false,
        "state_location": "payload",
        "override_payload": "msg",
        "entity_location": "data",
        "override_data": "msg",
        "x": 258,
        "y": 380,
        "wires": [
            [
                "1e1518cc5322bb05"
            ]
        ]
    },
    {
        "id": "753d0826.5edb28",
        "type": "server",
        "name": "Home Assistant",
        "version": 2,
        "rejectUnauthorizedCerts": true,
        "ha_boolean": "y|yes|true|on|home|open",
        "connectionDelay": true,
        "cacheJson": true,
        "heartbeat": false,
        "heartbeatInterval": 30
    }
]

Did you ever get the answer?

Hi Samuel,

No sorry. I haven’t bought mine either.

Regards,
Sam

I have two of this model. I bought two hubs because I didn’t think their bluetooth would reach to both the front and back yard. The front timer is paired to the front hub, and the back timer is paired to the back hub. The two hubs integrate fine into HA.

1 Like

What am I doing wrong?

I installed the integration today and all went well. I have two Gen 2 Hubs in the house and two XD water timers outside. One in the front yard and another in the backyard. The front yard works as expected when I toggle the Zone on and off. However, the backyard will toggle on for a second or two and then toggle off…but the water does turn on…yet the sensor trips back off. Once the water is on, I can’t get the integration to shut it off…If I flip over to the app I see the water has been turned on and can shut it off without any issue. This makes me think it has something to do with the integration.

I tried resetting each device and reinstalling the integration and unfortunately I get the same results.

Any thoughts?!

Edit: After playing with it a little more, it.appears both timers are now not turning the off when prompted through HA. I’m so confused.

I have both of mine of “off mode” in the app - do you? Then I’m using start_watering in Node Red to start it manually. I also wait a minute and check the status changes to “manual”. Similarly I wait for a minute after it’s supposed to finish and check it’s “off”. This handles when the batery dies, or there’s some other issue.

But I’ve never had it turn itself off straight away - mind you I updated to v3 in HACS recently and it’s winter here, so it only tried to water once a few days ago.

Hmmmm…what do you mean by “off mode”? Both timers are off and the app is closed when I attempt to use the HA switches.

Under “My B-Hyve > Devices > timer device”, I set “Timer Run Mode” to “Off”. Then on the Home page it says “Your controller is in off mode and automatic watering is disabled”. Not sure if it’s required, but that’s what is working for me.

https://github.com/sebr/bhyve-home-assistant/ works nicely with Smart B-hyve Irrigation Timer (WT24-0001) 4 zone indoor irrigation timer:
WT24-0001
by Orbit BHyve
Firmware: 0051
Hardware: WT24-0001

So here’s what it’s come down to for me…If I reload the integration before turning the Bhyve XD timers on or off, they work flawlessly. If they sit for too long they become unresponsive. Is there a way to poll these devices to keep them from losing their connection?

@sebr thanks so much for this integration. One thing I’m not clear on though: what would you recommend is the easiest way to see how much time is left on a zone? For example, I manually turn on a zone for 40 minutes and want to be able to see X minutes left. Do I need to do the math, leveraging the “start time” attribute on the zone? Or, is there an easier way? I was hunting the docs for a similar attribute for time remaining or a service call I could leverage. Would appreciate any tips - thanks!

Newbie warning!
Will this integration support multiple B-Hyve 57946 Timer/Controllers?

I have two regions at my house (one an old RainBird installation and the other another DIY set of valves on the other side of my house).
These could be served nicely if I can install two independent Bhyve 57946 6 zone timers.
Will this integration support that?
If so, any ‘tricks’ I need to know to set them up?
TIA

I am using the 12 zone version of what you want and it works fine

as far as two units are concerned if they are both on the same account online it stands a decent chance

though running control wires across to the otherside and using a single 12 zone would be cheaper

1 Like

I have 2 12 zone B-hyve controllers and both work perfectly in HA.When you install the integration you can select which controllers in your account that you want to include.

1 Like