ioBroker / ioBroker.ham

Supports homebridge plugins in ioBroker
MIT License
32 stars 15 forks source link
homebridge homekit iobroker smarthome

Logo

ioBroker Homebridge accessories manager

Number of Installations Number of Installations NPM version

Test and Release Translation status Downloads

Use Homebridge plugins in ioBroker or run a global installed Homebridge as ioBroker adapter. All States from Homebridge will be available in ioBroker too and can also be controlled there.

Description

This adapter provides three different modes:

Default (Wrapper) Mode

In the default mode the adapter allows you to use homebridge Plugin Modules directly. You can explore all available plugins at the NPM website by searching for the keyword homebridge-plugin.

You simply add the list of modules to the Adapter configuration and provide the configuration in the JSON-editor (see Plugin descriptions). After this, all Homebridge objects will be created in ioBroker too and all writable objects can be changed too.

IMPORTANT: This mode allows to use the device integrations of the provided homebridge plugins. No "bridge" is provided that can be used by the Home App!

A link of successfully tried plugins with examples can be found here: https://forum.iobroker.net/viewtopic.php?f=20&t=15021

Local-Homebridge-Mode

If you want to have a published bridge to be used by the Home App and want to also interact with it from ioBroker and get the data, but do not already have homebridge installed then use this mode.

The Local mode installs the current compatible version of homebridge and runs it as ioBroker user. You provide the complete homebridge configuration using ioBroker. The installation of the homebridge modules is also done via ioBroker.

IMPORTANT: When using child bridges (new homebridge feature since 1.3.x) the adapter CAN NOT access the data provided by these child bridges! Only the main bridge is accessible!

Global-Homebridge-Mode

If you already use Homebridge (Apple OpenSource SmartHome) as a global installation on the host where also ioBroker runs on, then you can use this existing Homebridge installation and start this Homebridge installation as ioBroker process. In this case the Homebridge server is started by ioBroker.

IMPORTANT: You need to make sure the global service is NOT started by the system or such. ioBroker itself will do the start! See below for best practice setup details.

IMPORTANT: Because ioBroker starts the Homebridge also the logging is done by ioBroker. YOu can set the loglevel from the instance to silly to also see all Homebridge logs, else it will be filtered for the important stuff.

Additionally, all states from Homebridge are available as states in ioBroker and allow to be controlled from ioBroker.

For this to work you need to provide the location of the systems global node-modules folder. For this call npm root -g. Additionally, you need to provide the path of the homebridge configuration directory (usually .homebridge in the "users" folder).

IMPORTANT: ioBroker runs as user "iobroker", but homebridge normally as root or homebridge user (depending on how you installed it). You need to make sure that the homebride "persistance" folder can be accessed by the ioBroker user, else you will see errors that the file can not be saved (which can crash the adapter!)

IMPORTANT: When using child bridges (new homebridge feature since 1.3.x) the adapter CAN NOT access the data provided by these child bridges! Only the main bridge is accessible!

Install as Global Bridge details

Thanks to @Anzic23 here some details on how to set up homebridge ideally for global mode:

  1. sudo npm install -g --unsafe-perm homebridge homebridge-config-ui-x
  2. install hb-service (sudo hb-service install --user homebridge) This step is needed to create the necessary files and directories
  3. uninstall hb-service (sudo hb-service uninstall)
  4. after installing homebridge
    sudo chmod 777 -R /var/lib/homebridge/
    sudo chmod 777 -R /usr/lib/node_modules/homebridge

    in iobroker Global Homebridge Path: /usr/lib/node_modules/homebridge

Global Homebridge Config Directory Path: /var/lib/homebridge

Following plugins were tested in Default mode

TODO

Changelog

WORK IN PROGRESS

5.3.1 (2022-09-28)

5.3.0 (2022-09-15)

5.2.4 (2022-09-15)

5.2.3 (2022-09-14)

5.2.2 (2022-09-14)

5.2.1 (2022-09-12)

5.1.0 (2022-08-17)

5.0.2 (2022-07-20)

5.0.1 (2022-06-28)

5.0.0 (2022-06-27)

4.0.4 (2022-06-07)

4.0.3 (2022-03-20)

4.0.2 (2021-05-08)

4.0.1 (2021-03-24)

3.0.2 (2020-11-29)

3.0.1 (2020-08-08)

3.0.0 (2020-08-04)

1.1.2 (2019-07-08)

1.1.1 (2019-07-05)

1.0.1 (2019-01-16)

1.0.0 (WIP)

0.4.5 (2018.08.21)

0.4.4 (2018.08.07)

0.4.2 (2018.06.25)

0.4.1 (2018.06.21)

0.3.1 (2018.06.20)

0.3.0 (2018.06.20)

0.2.6 (2018.06.19)

0.2.5 (2018.06.18)

0.2.4 (2018.06.18)

0.2.3 (2018.06.17)

0.2.2 (2018.06.17)

0.2.0/0.2.1 (2018.06.17)

0.1.0 (2018.06.09)

0.0.1 (2018.03.24)

License

The MIT License (MIT)

Copyright (c) 2018-2022 Apollon77 ingo@fischer-ka.de

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.