Arduino-HomeKit-ESP8266 icon indicating copy to clipboard operation
Arduino-HomeKit-ESP8266 copied to clipboard

hiding accessories

Open thncode opened this issue 2 years ago • 6 comments
trafficstars

I could'nt find that by searching and experimenting - is it possible to hide accessories at run time?

thncode avatar Nov 03 '23 07:11 thncode

If you change config number value in txt record, the controller will reload accessory information. So, remove accessory or some service from the description, and shift config number

d4rkmen avatar Nov 03 '23 08:11 d4rkmen

Sorry, what is 'config number value in txt record'? Could you please paste a code snippet?

thncode avatar Nov 03 '23 17:11 thncode

@thncode have you managed to figure out how to hide accessories?

arturlukosek avatar Dec 31 '23 15:12 arturlukosek

no - I did'nt understand the comment of @d4rkmen. I had to make a workaround by using two sets of accessories, which of course does not work for all use cases...

thncode avatar Jan 02 '24 16:01 thncode

HomeKit publishes via mdns some info that helps the client app, for example the Apple Home app, discover and use your accessory. Within that mdns record there is information including a config number. I think the suggestion is if you increment that config number then the client will pickup any changes, seem to remember that it mentions this in the homekit spec.

It is stored within the struct you create with arduino_homekit_setup

maccoylton avatar Jan 03 '24 17:01 maccoylton

Controller will reload accessory information when config number changes. This is the way it works

d4rkmen avatar Jan 03 '24 17:01 d4rkmen