One or two identical items not appearing in HomeKit,

Hi,

I have two Heating Controls configured (as far as I can tell, identically). One is appears in HomeKit, the other is not.

Apart from HomeKit, the item is working as expected.

With trace mode on: log:set TRACE org.openhab.io.homekit.internal

The item that appears get the following log entries (the item is detected, and the subscription is created).

2022-11-21 15:44:13.748 [TRACE] [mekit.internal.HomekitChangeListener] - Item gDeskHeating is a HomeKit accessory of types [THERMOSTAT=Empty]. Primary type is THERMOSTAT

2022-11-21 15:44:13.750 [TRACE] [.accessories.HomekitAccessoryFactory] - Constructing gDeskHeating of accessory type Thermostat

2022-11-21 15:44:13.754 [TRACE] [.accessories.HomekitAccessoryFactory] - Mandatory characteristics: [Item:item_desk_current_mode (Type=StringItem, State=Off, Label=Desk Current Mode, Category=null, Groups=[gDeskHeating]) HomeKit type: 'Thermostat' characteristic: 'CurrentHeatingCoolingMode', Item:item_desk_target_temp (Type=NumberItem, State=20.0, Label=Desk Target Temp [%.1f C], Category=null, Groups=[gDeskHeating]) HomeKit type: 'Thermostat' characteristic: 'TargetTemperature', Item:item_desk_current_temp (Type=NumberItem, State=18.1, Label=Desk Current Temp [%.1f C], Category=null, Groups=[gDeskHeating]) HomeKit type: 'Thermostat' characteristic: 'CurrentTemperature', Item:item_desk_target_mode (Type=StringItem, State=OFF, Label=Desk Target Mode, Category=null, Groups=[gDeskHeating]) HomeKit type: 'Thermostat' characteristic: 'TargetHeatingCoolingMode']

2022-11-21 15:44:13.759 [TRACE] [.accessories.HomekitAccessoryFactory] - Optional characteristics for item gDeskHeating: [item_desk_threshold_temp (Type=NumberItem, State=NULL, Label=Desk Threshold, Category=null, Groups=[gDeskHeating])]

2022-11-21 15:44:13.762 [TRACE] [ssories.HomekitCharacteristicFactory] - Create characteristic Item:item_desk_threshold_temp (Type=NumberItem, State=NULL, Label=Desk Threshold, Category=null, Groups=[gDeskHeating]) HomeKit type: 'Thermostat' characteristic: 'HeatingThresholdTemperature'

2022-11-21 15:44:19.333 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Received subscription request for item_desk_current_mode (Type=StringItem, State=Off, Label=Desk Current Mode, Category=null, Groups=[gDeskHeating]) / CurrentHeatingCoolingMode

2022-11-21 15:44:19.335 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Adding subscription for item_desk_current_mode (Type=StringItem, State=Off, Label=Desk Current Mode, Category=null, Groups=[gDeskHeating]) / CurrentHeatingCoolingMode

2022-11-21 15:44:19.338 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Received subscription request for item_desk_target_mode (Type=StringItem, State=OFF, Label=Desk Target Mode, Category=null, Groups=[gDeskHeating]) / TargetHeatingCoolingMode

2022-11-21 15:44:19.340 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Adding subscription for item_desk_target_mode (Type=StringItem, State=OFF, Label=Desk Target Mode, Category=null, Groups=[gDeskHeating]) / TargetHeatingCoolingMode

2022-11-21 15:44:19.343 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Received subscription request for item_desk_current_temp (Type=NumberItem, State=18.1, Label=Desk Current Temp [%.1f C], Category=null, Groups=[gDeskHeating]) / CurrentTemperature

2022-11-21 15:44:19.345 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Adding subscription for item_desk_current_temp (Type=NumberItem, State=18.1, Label=Desk Current Temp [%.1f C], Category=null, Groups=[gDeskHeating]) / CurrentTemperature

2022-11-21 15:44:19.348 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Received subscription request for item_desk_target_temp (Type=NumberItem, State=20.0, Label=Desk Target Temp [%.1f C], Category=null, Groups=[gDeskHeating]) / TargetTemperature

2022-11-21 15:44:19.351 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Adding subscription for item_desk_target_temp (Type=NumberItem, State=20.0, Label=Desk Target Temp [%.1f C], Category=null, Groups=[gDeskHeating]) / TargetTemperature

2022-11-21 15:44:19.354 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Received subscription request for item_desk_threshold_temp (Type=NumberItem, State=NULL, Label=Desk Threshold, Category=null, Groups=[gDeskHeating]) / HeatingThresholdTemperature

2022-11-21 15:44:19.356 [TRACE] [kit.internal.HomekitAccessoryUpdater] - Adding subscription for item_desk_threshold_temp (Type=NumberItem, State=NULL, Label=Desk Threshold, Category=null, Groups=[gDeskHeating]) / HeatingThresholdTemperature

For the item which doesn’t appear. It’s it detected, and but there is no subscription.

2022-11-21 15:44:13.797 [TRACE] [mekit.internal.HomekitChangeListener] - Item gLodgeHeating is a HomeKit accessory of types [THERMOSTAT=Empty]. Primary type is THERMOSTAT
2022-11-21 15:44:13.799 [TRACE] [.accessories.HomekitAccessoryFactory] - Constructing gLodgeHeating of accessory type Thermostat
2022-11-21 15:44:13.804 [TRACE] [.accessories.HomekitAccessoryFactory] - Mandatory characteristics: [Item:item_lodge_target_mode (Type=StringItem, State=OFF, Label=Lodge Target Mode, Category=null, Groups=[gLodgeHeating])  HomeKit type: 'Thermostat' characteristic: 'Tar
getHeatingCoolingMode', Item:item_lodge_current_temp (Type=NumberItem, State=10.4, Label=Lodge Current Temp [%.1f C], Category=null, Groups=[gLodgeHeating])  HomeKit type: 'Thermostat' characteristic: 'CurrentTemperature', Item:item_lodge_target_temp (Type=NumberItem, S
tate=20, Label=Lodge Target Temp [%.1f C], Category=null, Groups=[gLodgeHeating])  HomeKit type: 'Thermostat' characteristic: 'TargetTemperature', Item:item_lodge_current_mode (Type=StringItem, State=Off, Label=Lodge Current Mode, Category=null, Groups=[gLodgeHeating]) 
 HomeKit type: 'Thermostat' characteristic: 'CurrentHeatingCoolingMode']
2022-11-21 15:44:13.808 [TRACE] [.accessories.HomekitAccessoryFactory] - Optional characteristics for item gLodgeHeating: [item_lodge_threshold_temp (Type=NumberItem, State=5, Label=Lodge Threshold Temp, Category=null, Groups=[gLodgeHeating])]
2022-11-21 15:44:13.811 [TRACE] [ssories.HomekitCharacteristicFactory] - Create characteristic Item:item_lodge_threshold_temp (Type=NumberItem, State=5, Label=Lodge Threshold Temp, Category=null, Groups=[gLodgeHeating])  HomeKit type: 'Thermostat' characteristic: 'HeatingThresholdTemperature'

There are no obvious error or exception in the logs.

Is there additional logging I could apply? Or any other approaches to take to help diagnose the issue?

configuration and logs look ok.

can you try to create one additional homekit accessory, something like simple light, e.g. just create an openhab item of type switch and mark it as homekit=“Lighting”

will it appear in home app?

HI,

Thank you for the quick reply.

Yes, I did that, and it appeared straight away.

good. the sync is working.
if possible, try to rename gLodgeHeating to something else temporally, e.g. gLodgeHeating2. if you use text based configuration, dont forget to update the group name for the items
this will be considered as new device and force home app sync it again.

if it still does not appear, then something is wrong with the configuration, but from logs file cannot see what.
try followings

  • remove optional attribute item_lodge_threshold_temp from the group
  • change values of item_lodge_current_mode and item_lodge_target_mode (currently they have values “OFF” and “Off”. maybe change them to “AUTO”.

I tried that already (gLodgeHeaterIR) :frowning:

I’m using “Add Items from Textual Definition” from the UI. I might try and create it using files and see if that works.

I have a workaround, but I can’t really explain it.

I was adding child items with the notation {homekit="Thermostat.CurrentTemperature"}

Number          item_lodge_current_temp    "Lodge Current Temp [%.1f C]"   (gLodgeHeating)        {homekit="Thermostat.CurrentTemperature" [minValue=0, maxValue=40]}

switching to {homekit="CurrentTemperature"} (without the `Thermostat’ prefix).

Number          item_lodge_current_temp    "Lodge Current Temp [%.1f C]"   (gLodgeHeating)        {homekit="CurrentTemperature" [minValue=0, maxValue=40]}

resolves the problem.

This works from both the “Add Items from Textual Definition” and when using files.

What is very odd the original item gDeskHeating was added using the {homekit="Thermostat.CurrentTemperature"} format. I did a find and replace to add the second heater.

1 Like

thanks for sharing the workaround.
interesting finding. it sounds like a bug to me, a strange one.
i will try to reproduce it locally on my machine so that i can fix it.