Integration with Orbit B-Hyve Irrigation System

While we’re waiting does anyone know whether it’s possible to have bothered the B-hyve sprinkler system AND b-hyve smart faucet and trigger the faucet via Alexa? I can start/ stop a sprinkler zone but have a misting irrigation system setup to the smart faucet device and can’t seem to find a way to trigger it via Alexa.

Appreciate any thoughts!

Would love to see this working… Have the orbit in the back yard, and somewhat tempted to get for the front if we can get this going

Please, if you are looking for testers, I am a willing participant. I would really like to have my B-Hyve sprinkler system integrated with Hass.io. While I lack a lot of the technical skills of programming, I am a critical thinker, and good at problem solving.

So many things are going one, I won’t have time til end of May.

I have something working. But it is a bit of a hack. I have an echo dot sitting right near the pc running Home Assistant. I’m using google_translate_say and VLC media player to tell my orbit to run Program A. I use meteorological season to decide how often to run. I use Dark_Sky precipitation prediction and current temperature as conditions so I won’t water below 40 degrees or if the rain chance is above 50%. If anyone is interested I can post code.Like I said it’s a hack but it does work…

I can’t seem to get this to work. I used Postman to establish the session and got back the “orbit_session_token” along with other info just fine. Then I used the Chrome “Smart Websocket Client” to connect to “wss://api.orbitbhyve.com/v1/events” and then send the event “app_connection” as you said, using the session token from the first connection. I got no reply. I continued, however, and sent the “ping” event. No reply. Finally, the socket closed. Any ideas?

I started a project for mqtt integration with BHyve.

Can see the details there, might help.

9 Likes

Thanks for this! I’ve been meaning to integrate my BHyve system, and this is a great start.

I would personally much prefer direct integration rather than go through mqtt broker. But good work nonetheless. Thanks!

That’s certainly nice work, but I have to say, a little over my head for setup.
I do have MQTT installed, but never did any integrations, so I would have no idea where to start to implement this.

Today I researched the bluetooth communication as an alternative of the web socket connection.

The bluetooth side communication is not that simple to reverse engineer… The bluetooth packets are encrypted with mCrypCipher using AES algorithm (from what I gather reading the unpacked source code from .apk). I can recommend @billchurch to look at the unpacked source code for the mqtt integration as it was a big help for understanding the bluetooth communication :slight_smile:

Message to B-Hyve==>Encrypt ==> Send
Receive==>Decrypt==>Message from B-Hyve

try {i = this.mCryptCipher.doFinal(updateIv(i)); for (int i2 = 0; i2 < bArr2.length; i2++) { bArr2[i2] = (byte) (bArr[i2] ^ i[i2]); }

where bArr2 is the message to send and i=mEncryptionCounter or i=mDecryptionCounter starts at 0 and corresponds to the sent/received message count. mCryptCipher is the cryptography class

1 Like

Count me in please. I’d love to integrate my Orbit to HA on Pi. Thanks in advance!

+1 - I’m in for testing.

Hello from Brazil! I am in for testing too!

Hello from Brazil, Bill!

I have checked your project and it is awesome! Congratulations!

I am using Home Assistant on Raspberry.
Can you please tell me how to install your project on Home Assistant? I did not get it…

Thank you very much,
José Henrique.

Any new updates?

Hi everyone,

I managed to get this running last night (bhyve-mqtt).

Building the docker image wasn’t too too bad, just had to figure out the .env file variables and repackage each time. May look into setting a volume with the file so that it can exist outside of the image.

After you clone the github repository, edit the /app/.env-sample file and add your details, then save it as .env in that same /app directory. For the MQTT_BROKER_ADDRESS value, if you’re running mqtt as a docker image, you should be able to refer to it as the container’s name. I’m running my mqtt as “mosquitto-mqtt”, so the MQTT_BROKER_ADDRESS=mqtt://mosquitto-mqtt. No port, the “mqtt://” at the beginning is required. Once all your info is in, go back the the root directory of the project and do a “docker build”. This will create the image for you to deploy. There are a tone of blogs out there with the steps to follow, but my docker-compose is very simple:

bhyve:
image:
depends_on:
- “mosquitto-mqtt”

I haven’t played around with commands yet, but I was at least able to see my device info in the container log. :slight_smile: Looking forward to playing around with this. Thanks!

1 Like

Great news! We’re you able to get commands working yet?

Not quite yet, been focusing more on a video/NVR solution for us which was more pressing.
But hope to do some work on it soon! I’ll keep this thread posted.

Count me in as a tester!