HomeKit Integration - Pairing Problems

I’m having trouble with the update procedure. When I complete the procedure I get the following error in the console.

openhab> bundle:restart 306
Error executing command: Error restarting bundles:
Unable to start bundle 306: Could not resolve module: org.openhab.io.homekit [306]
Unresolved requirement: Import-Package: javax.json; version="[1.0.0,2.0.0)"

I’m running 2.5M5 on Windows.

Did you install HomeKit before? Please show bundle:list.

This was on a fresh install of M5 and I hadn’t installed HomeKit yet. I used bundle:install with the url you provided.

I manually added javax.json v1.0 to my addons folder and homekit resolved. I’m still having issues, but I’m about to try the process again. Should I install through PaperUI then run the bundle update as you suggested?

So I got it to work by manually adding javax.json v1.0.4 and restarting the bundle. It wouldn’t work with javax.json v1.0. HomeKit wouldn’t start without me adding javax.json to the addons folder.

Thanks for the good work Jan!

Hi Jan,
I can confirm this version works with latest openHAB milestone 5. (using Docker version)
This solved all Homekit issues I was having. (unable to pair using iOS 13 devices)
Thanks!
Regards,
Geert-Jan

1 Like

With OH 2.5 snapshot latest and HomeKit bindings not all devices from items file show up in home app (32/70), while no problems with 2.3 and same items file before. Hue emulation works fine, all items show up. Any solution for this?

Which devices?

For example, those items do not show up in Home App:

*Switch          Wandlampe_Studio            "Wandlampe Studio"        <light>     (F3_Studio, light_studio)    ["Switchable"]    { mqtt=">[mosquitto:cmnd/wandlampe_studio/POWER:command:*:default],<[mosquitto:stat/wandlampe_studio/POWER:state:default]" }*
*Switch          Stehlampe_Studio           "Stehlampe Studio"     <light>    (F3_Studio, light_studio) ["Switchable"]   {mqtt=">[mosquitto:cmnd/stehlampe_studio/POWER1:command:*:default],<[mosquitto:stat/stehlampe_studio/POWER1:state:default]"}*
*Switch          FF_Living_Light_1         "Licht eins Wohnzimmer"     <light>    (FF_LivingDining, gLight, light_living, light_EG) ["Switchable"]   {mqtt=">[mosquitto:cmnd/licht_wohnzimmer/POWER1:command:*:default],<[mosquitto:stat/licht_wohnzimmer/POWER1:state:default]"}*
*Switch          FF_Living_Light_2         "Licht 2 Wohnzimmer"     <light>    (FF_LivingDining, gLight, light_living, light_EG) ["Switchable"]   {mqtt=">[mosquitto:cmnd/licht_wohnzimmer/POWER2:command:*:default],<[mosquitto:stat/licht_wohnzimmer/POWER2:state:default]"}*
*Switch          Stehlampe                 "Stehlampe"     <light>    (FF_LivingDining, gLight, light_EG) ["Switchable"]   {mqtt=">[mosquitto:cmnd/stehlampe/POWER1:command:*:default],<[mosquitto:stat/stehlampe/POWER1:state:default]"}*
*Switch          Lampe_Garderobe           "Lampe Garderobe"     <light>    (FF_LivingDining, gLight, light_EG) ["Switchable"]   {mqtt=">[mosquitto:cmnd/licht_garderobe/POWER1:command:*:default],<[mosquitto:stat/licht_garderobe/POWER1:state:default]"}*

while these items show up and work flawlessly:

*Switch          FF_Sprinkling             "Beregnung"        <poweroutlet>     (FF_LivingDining, gPower)    ["Switchable"]    { mqtt=">[mosquitto:cmnd/garten/POWER2:command:*:default],<[mosquitto:stat/garten/POWER2:state:default]" }*
*Switch          FF_Kitchen_Power              "Kaffeemaschine"        <poweroutlet>     (FF_Kitchen, gPower)    ["Switchable"]    { mqtt=">[mosquitto:cmnd/ecm/POWER:command:*:default],<[mosquitto:stat/ecm/POWER:state:default]" }*
*Switch          FF_Garden_light            "Gartenlicht"        <light>     (FF_LivingDining, gPower)    ["Switchable"]    { mqtt=">[mosquitto:cmnd/garten/POWER1:command:*:default],<[mosquitto:stat/garten/POWER1:state:default]" }*
*Switch          Ladegeraet_Ebike		          "Ladegerät Ebike"    <poweroutlet>     (GF_Boiler, gPower)    ["Switchable"]  { mqtt=">[mosquitto:cmnd/ladegerät_ebike/POWER:command:*:default],<[mosquitto:stat/ladegerät_ebike/POWER:state:default]" }*
*Group:Switch light_EG         "Licht Erdgeschoss" <light>  ["Switchable"]*
*Group:Switch light_living      "Licht Wohnzimmer" <light>  ["Switchable"]*

Dont understand this behaviour. When copying the item and playing around with the groups (e.g., FF_LivingDining, gLight, light_living, light_EG), its possible that the item shows up in home app. Any ideas how to solve this problem?

Thanks a lot!

no idea why this happens in latest 2.5 snapshot? Everything worked perfect with OH2.3, my items have not changed since then.

Hey Jan, any idea how to solve this? Would be great. Many thanks!

@J-N-K with the release of 2.5 I’m unable to add openhab to my home on iOS 13.3
it still be necessary to install the jar you mentioned earlier (Nov 16) to get this working as expected?

Thanks

No. Did you try clearing the pairing and delete HomeKit.json?

What I’ve done is

  • upgrade to 2.5 via Apt
  • remove an old homekit-test feature (from another thread that was working in 2.5 pre-release some time ago)
  • install homekit via paperUI
  • attempt to add to IOS - didnt work

Based on your note here now I have

  • deleted /var/lib/openhab2/jsondb/homekit.json
  • smarthome:homekit clearPairings
  • restart openhab
  • reboot phone
  • attempt to add OH to the Home App on IOS 13.3

It worked!

Thank you.

Hello. I have the same problem of Cuse.
After the last openhab update, Homekit can only display one item out of 29.
I tried to perform clear pairing, rm homekit.json and reinstall but it continues to display only 1 items. Some idea?
Thank you

Hello. I solved the problem in this way.
From Paper UI> Configuration>Things, I’ve deleted and added all things. In my case, the address had changed from before. So I updated the address in “home.items” in the Terminal.
Now everything works as before.

Based on OH 2.5.1. and homekit 2.5.1 I am not able to pair with iOS 13.3.1
Several times I have removed the homekit integration via paper UI and also the depending files as already discussed.

  • sudo rm -r /var/lib/openhab2/jsondb/homekit.json
  • sudo rm -r /var/lib/openhab2/jsondb/backup/*

After this I have reboot OH and try to connect - without success.
I can see the homekit bridge in the iOS home app, but it will not pair together. Later it will give a timeout message that the bridge could not be saved.

Could somebody give me a tip to solve this issue?
Maybe I have to use another homekit integration except the original version 2.5.1?

In the meantime i was able to try out different constellations. Deactivate ipv6, another wlan, another openhab server. The result is always the same. The homebridge cannot be loaded, see photo. At the moment I’m absolutely at a loss.

Thomas, please try with a smaller set of device, e.g. only with one “light” device

home app loads all devices/items at once and if there is an issue with one device it stops the binding completely with a generic error. once you connect with one device you can add all others

Thank you @kolcun, I was able to reproduce your results.

Updated OH to Stable 2.5.1-2, with Homekit Integration 2.5.1, and iPhone7 running iOS 13.3.1.
Added without trouble.

Hello Eugen, thanks for the tip. I found and deleted some hidden ‘homekit’ files in the config folder. Now pairing works again. This is really very tricky.