RuuviBridge icon indicating copy to clipboard operation
RuuviBridge copied to clipboard

Integration with Homebridge possibility

Open TurtleRad opened this issue 3 years ago • 2 comments

I've been using Ruuvitags individually with Homebridge with great success but now I want to expand my usage area and add the built-in analytics of Ruuvi Gateway. Is there a way to use this platform to accomplish at least adding the tags to the Homebridge environment?

I could, of course, change over to HA but I find HA to be a bit more involved as a standalone service and when I have integrated most of my stuff into HB, and therefore HomeKit, I'm a bit reluctant.

TurtleRad avatar Aug 08 '23 16:08 TurtleRad

Sorry for the late reply. I'm not familiar with Homebridge, but if Homebridge is able to read data from MQTT, then there is a good possibility that it can be done, though it probably requires quite a bit of manual configuration. You can use RuuviBridge to publish ready-parsed measurement data in JSON format to MQTT, then you "just" need to get that from MQTT to Homebridge.

Here is an example of the JSON format that RuuviBridge produces:

{
  "name": "Livingroom",
  "mac": "DA:42:AC:49:94:82",
  "timestamp": 1694020056,
  "data_format": 5,
  "temperature": 25.4,
  "humidity": 41.205,
  "pressure": 102230,
  "accelerationX": 0.004,
  "accelerationY": -0.024,
  "accelerationZ": 1.028,
  "batteryVoltage": 3.091,
  "txPower": 4,
  "rssi": -51,
  "movementCounter": 166,
  "measurementSequenceNumber": 46814,
  "accelerationTotal": 1.0282878974295087,
  "absoluteHumidity": 9.703565644866067,
  "dewPoint": 11.282500189275588,
  "equilibriumVaporPressure": 3243.84008525799,
  "airDensity": 1.18785810237082,
  "accelerationAngleFromX": 89.77712107998035,
  "accelerationAngleFromY": 91.33739158912678,
  "accelerationAngleFromZ": 1.3558426618832133
}

Scrin avatar Sep 06 '23 17:09 Scrin

You can use the mqttthing plugin in Homebridge to create devices from any MQTT topic.

https://github.com/arachnetech/homebridge-mqttthing

barcar avatar Sep 23 '23 21:09 barcar