New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Event Support #1
Comments
None known, I'll have to dig a little. The app doesn't appear to catch outside state modifications. |
It may be because I’m on HomeKit but the iOS app updates immediately when I make changes via a voice control on a HomePod. |
Interesting. I see the same behavior: the iOS app gets immediate state changes the Android app makes but not vice-versa. A pcap shows the border router doing a CoAP PUT to the iPhone. |
Interesting. I wonder if the iPhone is registering at some point with the BR or elements to receive push updates. |
Bah, it looks like the iOS app is hitting a different CoAP endpoint, /2 (there's also /1 and /0) with a somewhat different packet format. It looks like this is HAP vs the custom Nanoleaf protocol. Not terribly surprising... Initial POST.
And the reply
I wonder if we can just modify the existing HA HomeKit integration to also do UDP... |
CoAP endpoint |
Hacked something together from other HAP projects. Pair-Setup was successful over |
And Pair-Verify over |
Okay, I implemented a fake bulb and had the iOS Home app pair to it. It looks like BLE HAP PDUs...
The first 5 bytes match a HAP PDU reply:
|
The response seems to be a GATT service/characteristic table or whatever you call it. Decoding gives similar data to what is visible over BLE. Repeating this one response to the Home app causes pairing to complete & prompt for a name/room. The Home app goes on to do multiple queries after that in the background, HAP-Characteristic-Read ( |
Every characteristic in the GATT table that is marked as supporting notification gets hit with a |
Last piece of the puzzle, there is a new encryption context for events with a salt
Seems to parse as...
|
Pushed hacktastic python script. It can subscribe to things. Yay. |
Closing for now. HAP has events but it remains to be seen if/when LTPDU will add events. |
This is fantastic work. I can control and get the state of my nanoleaf essentials via the thread network. To integrate fully with home assistant, I think there needs to be some sort of real-time update system. Have you managed to discover how that works yet? I could imagine a few scenarios:
The text was updated successfully, but these errors were encountered: