Giter Club home page Giter Club logo

particle-hap's Introduction

particle-hap

Particle HAP is a proof-of-concept tested and working TCP server, which allows you to connect Particle devices to HomeKit, directly, without any in-the-middle HAP JS server. I am successfully using it to control my Window shutters, Lights, Nixie Clocks, Roomba (using serial link) and I've created simple weather station (temperature, humidity, light). Every device works just fine and stable.

BIG THANKS TO:

I've used lot of inspiration and code from these repositories. I would really like to thank:

Video

Example video of pairing and handling.

Watch the video

Configuration

//TCP for handling server port
#define TCP_SERVER_PORT 5115
//Maximum pairings available. Apple recommends 16. But be aware, one pairing needs (36+32)B of your EEPROM
#define MAX_PAIRINGS 16
//if you are using EEPROM, you can set offset for HomeKit to store pairings
#define EEPROM_STORAGE_ADDRESS_OFFSET 512
//Apple requires 8 connections at least and must accommodate a new ones. Photon can handle up to 10 connections, but one is cloud connection.
//So allow 8 connections, every 9th will be closed send HTTP 503 and closed.
//It seems that even 2 connections are working just fine, if you need to use sockets for something else.
#define MAX_CONNECTIONS 8

Also, be aware that there's constant ACCESSORY_KEY (in HKConsts.h). Should be unique per device. I've used constant just to save memory. But it can be a security leak. If you need to really generate accessory key, look for 'generateAccessoryKey' method and store that key somehow in EEPROM.

Integration

This project is available as a Community Library, particle-hap, which you can import into your project.

Please see the example projects in the examples folder for a better idea of how to use particle-hap in your project.

Troubleshooting

If your Particle device isn't showing up in HomeKit, try resetting the HKPersistor.

HKPersistor().resetAll();
System.reset();

If there are too many instances of your Particle device showing up in HomeKit, you may want to restart your iPhone/iPad, and if it doesn't work you need to flush your iOS device's DNS cache. Unfortunately, this also means you will lose any WiFi networks you have set up, and you'll need to re-enter those passwords. Go to Settings, General, Reset and choose Reset Network Settings.

Dependencies

There are no library dependencies. All the crypto is based on WolfSSL, but highly customized to work on DeviceOS.

Known major issues

  • no major issues currently known

Limitations

I had to use static shared memory buffers for processing request and response of HomeKit TCP server. Dynamic allocations of memory causes fragmentation and instability. So currently SHARED_REQUEST_BUFFER_LEN=1024 bytes and SHARED_RESPONSE_BUFFER_LEN=5000 bytes is used. You may reach the response buffer limit if you create some complex composite accessory (more than 5 services).

Troubleshooting

Q: I am not able to see a device in pairing. Why? A: You need to be exactly on same Wifi network. Photon connects to 2.4Ghz and your iPhone connects to 5Ghz network by default. Devices not see each other.

Q: How to debug HomeKit accessory discovery? A: Download Discovery app from AppStore (Bonjour Discovery) and look for _hap._tcp node in that app. You should see your device in there.

Q: Is there any logs? A: Yes, of course. I am using standard Serial log. I log only the warnings (let's say, the negative branches of IFs :-) )

Q: I can see device ready for pairing, but pairing fails. A: Mostly you have an error in describing your devices or characteristics values are bad/not in range etc. HomeKit accessory must be described using Apple defined Services. Each service must be described using mandatory and optional characteristics. All can be found in HAP-Specification-Non-Commercial-Version.pdf document.

What's planned:

  • more accessory types in examples (programmable switch, sensors). What do you need?

Goal:

  • integration with Nixie Clocks so it will support Non-commercial HAP.

Compiling project

When you're ready to compile your project, make sure you have the correct Particle device target selected and run particle compile <platform> in the CLI or click the Compile button in the Desktop IDE. The following files in your project folder will be sent to the compile service:

  • Everything in the /src folder, including your .ino application file
  • Everything in the /lib folder (which includes the particle-hap library)
  • The project.properties file for your project

Contribution

Any contributions are more than welcomed. I would prefer to create PR instead of just posting as issues.

Hire us:

We are two guys, freelancers. We develop Android, iOS applications mostly. We also did some parts of FW for Nixie Clock and of course its iOS app. Just contact me at [email protected]

Licence

Copyright 2019 Lukas Jezny

Licensed under the MIT license.

particle-hap's People

Contributors

amanvell avatar danielo avatar darrylhodgins avatar gdev avatar ljezny avatar lmartu68 avatar morzack avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

particle-hap's Issues

Device has error being added

A particle photon I have onboarded fine to start with, but after a 2nd remove, it stopped adding.
I tried the same code on another particle. The Particle itself runs and is on Wifi just fine.
(I'm basically trying to build a motion sensor using a Particle Photon, PIR and your SW -- thought this would be a fairly simple exercise... and initially it was... but data from PIR wasn't making into characteristic... at least that's what it looked like)

I've checked the Particle events list... and it looks correct (see below) (I've removed my printouts which were interspersed).

homekit/close 192.168.1.174 motion-1 3/16/20 at 6:46:56 pm
homekit/accessory 192.168.1.174 motion-1 3/16/20 at 6:46:54 pm
homekit/accessory 192.168.1.174 motion-1 3/16/20 at 6:46:53 pm
homekit/pair-verify 192.168.1.174 motion-1 3/16/20 at 6:46:49 pm
homekit/pair-verify 192.168.1.174 motion-1 3/16/20 at 6:46:47 pm
homekit/accept 192.168.1.174 motion-1 3/16/20 at 6:46:47 pm
homekit/pair-setup 192.168.1.174 motion-1 3/16/20 at 6:46:44 pm
homekit/pair-setup 192.168.1.174 motion-1 3/16/20 at 6:46:39 pm
homekit/pair-setup 192.168.1.174 motion-1 3/16/20 at 6:46:34 pm
homekit/accept 192.168.1.174 motion-1 3/16/20 at 6:46:34 pm
spark/device/diagnostics/update {"device":{"system":{"uptime":2,"memory":{"total":82944,"used":38792}},"network":{"connection":{"status":4,"error":0,"disconnects":0,"attempts":1,"disconnect":0},"signal":{"rssi":-47,"strength":100,"quality":100,"qualityv":45,"at":1,"strengthv":-47}},"cloud":{"connection":{"status":1,"error":0,"attempts":1,"disconnect":0},"disconnects":0,"publish":{"rate_limited":0},"coap":{"unack":0}}},"service":{"device":{"status":"ok"},"coap":{"round_trip":101},"cloud":{"uptime":0,"publish":{"sent":4}}}} motion-1 3/16/20 at 6:46:27 pm

I don't see any errors, but I get the following non-helpful screen on my iPhone.
(any thoughts?)
"
Erorr Screen

Device unresponsive more often in the last few days

Not really an issue, but I was wondering if perhaps something had changed on the Apple side recently that intermittently broke this library? I have a Photon that's been running as a heating thermostat very happily for months, only needing the occasional restart, but over the past three days it now struggles to stay responsive when viewed from the Home app on my phone, sometimes requiring multiple resets before it comes back. I was just wondering if anyone else had seen that?

Device goes unresponsive after some days of usage

Hi!

I am running on a Particle Photon with 2.1.0 and particle-hap 1.0.16. I am using the Door example code with some modifications to control a relay that interacts with a window.

I have the issue that the device goes unresponsive after some time, sometimes 24h, sometimes a couple of days. Is there a known issue to this or a way to debug this remotely?

My settings in code are currently set to

#define MAX_PAIRINGS 16
#define MAX_CONNECTIONS 8

Pairing stopped working unexpectedly - error -219

I have a thermostat device set up that was working fine (thanks!) but after updating some stuff (this library from 1.0.12 to 1.0.16, and the device OS up to 1.5.2 but issue replicated with 1.4.4), pairing no longer works. Here's a sample of the log:

0000020116 [homekit] INFO: Bonjour advertised
0000021117 [homekit] INFO: Bonjour advertised
0000022118 [homekit] INFO: Bonjour advertised
0000023119 [homekit] INFO: Bonjour advertised
0000024120 [homekit] INFO: Bonjour advertised
0000024750 [homekit] INFO: Client connected.
0000024752 [homekit] INFO: Request Message read length: 128 
0000024753 [homekit] INFO: Handling Pair Setup...
0000024754 [homekit] INFO: State: 1
0000024754 [homekit] INFO: Homekit progress callback: 1
0000024754 [homekit] INFO: State_M1_SRPStartRequest
0000028688 [homekit] INFO: Homekit progress callback: 2
0000028689 [homekit] INFO: writeData responseLen:489
0000028693 [homekit] INFO: Bonjour advertised
0000028935 [homekit] INFO: Request Message read length: 581 
0000028936 [homekit] INFO: Handling Pair Setup...
0000028937 [homekit] INFO: State: 3
0000028938 [homekit] INFO: State_M3_SRPVerifyRequest
0000028938 [homekit] INFO: Homekit progress callback: 3
0000031995 [homekit] WARN: wc_SrpComputeKey: r:-2
0000031996 [homekit] WARN: wc_SrpVerifyPeersProof: r:-219
0000031996 [homekit] WARN: INCORRECT PASSWORD
0000031996 [homekit] INFO: Homekit progress callback: 999
0000031997 [homekit] INFO: writeData responseLen:84
0000032361 [homekit] INFO: Bonjour advertised
0000032363 [homekit] INFO: Request Message read length: 128 
0000032364 [homekit] INFO: Handling Pair Setup...
0000032365 [homekit] INFO: State: 1
0000032365 [homekit] INFO: Homekit progress callback: 1
0000032365 [homekit] INFO: State_M1_SRPStartRequest
0000036297 [homekit] INFO: Homekit progress callback: 2
0000036298 [homekit] INFO: writeData responseLen:489
0000036301 [homekit] INFO: Bonjour advertised
0000037301 [homekit] INFO: Bonjour advertised
0000038303 [homekit] INFO: Bonjour advertised

Error -219 is RP_VERIFY_E = -219, /* SRP proof verification failed. */

I've tried setting the password to various different values, confirmed that it's correct by logging hkServer->getPasscode().c_str() on startup, restarted my phone, reset the HKPersistor and even cleared the EEPROM, with no success.

I'm 100% certain that the number I'm supplying to HKServer is the same as the one I'm entering into the phone. Any ideas what I can try next?

OK, so here's how I did get it to work: instead of tapping on the accessory discovered by Bonjour, if I selected "Enter code" under "Manual code" and typed it in, and then selected the accessory, the pairing seemed to work. I'm pretty sure I didn't have to do this before -- hopefully this is useful to someone else.

Brightness issue on Photon RGB

Im using latest version as of 05/2020.

While using the Photon onboard RGB, and when setting the color it works fine, but if I change the brightness it affect the brightness and the color, if I select a predefined color, then it set is correctly, both the color ut to a predefined brightness.

It seems that there was a similar issue with LED strip, but this is still happening.

Can't Add Accessory using iOS 13

Hi everyone!

After flashing my photon with the lightbulb example, I am trying to pair it with Home App.
The PhotonLED is discoverable by the app, but when I tap it and enter the code I get a Couldn't add PhotonLED; Home couldn't connect to this accessory.

Hardware: Photon
Device OS: 1.3.0-rc.

Device:
iPhone X iOS 13.0 GM

Here are the events captured by Particle Console

event: homekit/accept
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:16.464Z","coreid":"310023001447343338333633"}

event: homekit/pair-setup
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:16.694Z","coreid":"310023001447343338333633"}

event: homekit/pair-setup
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:20.625Z","coreid":"310023001447343338333633"}

event: homekit/close
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:23.690Z","coreid":"310023001447343338333633"}

event: homekit/accept
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:26.419Z","coreid":"310023001447343338333633"}

event: homekit/pair-setup
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:26.612Z","coreid":"310023001447343338333633"}

event: homekit/pair-setup
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:30.639Z","coreid":"310023001447343338333633"}

event: homekit/pair-setup
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:33.741Z","coreid":"310023001447343338333633"}

event: homekit/close
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:37.677Z","coreid":"310023001447343338333633"}

event: homekit/accept
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:37.845Z","coreid":"310023001447343338333633"}

event: homekit/pair-setup
data: {"data":"192.168.0.20","ttl":60,"published_at":"2019-09-14T20:22:37.845Z","coreid":"310023001447343338333633"}

"Max connections reached" after pairing

Hi,
I can pair fine in iOS 13 but after the pairing process it starts complaining there are too many connections (eg 'Identify' doesn't work).

This is with the relay example.

I've attached the jumbo log, sorry it's so huge :(

[Havok 22:07] ~ >cu -l /dev/cu.usbmodem14324201 -s 115200
Connected.
0000004287 [homekit] INFO: Persistor: load
0000004289 [homekit] INFO: Server started at port 5556
0000004289 [homekit] INFO: Persistor: save
0000004292 [homekit] INFO: Bonjour advertised
0000004295 [homekit] INFO: Bonjour advertised
0000005295 [homekit] INFO: Bonjour advertised
0000005369 [homekit] INFO: Client connected.
0000005371 [homekit] INFO: Request Message read length: 162
0000005372 [homekit] INFO: Handling Pair Verify...
0000005373 [homekit] INFO: Homekit progress callback: 8
0000005373 [homekit] INFO: Pair Verify M1
0000006870 [homekit] INFO: Homekit progress callback: 9
0000006871 [homekit] INFO: writeData responseLen:220
0000006874 [homekit] INFO: Bonjour advertised
0000006874 [homekit] INFO: Client connected.
0000006875 [homekit] INFO: Request Message read length: 162
0000006876 [homekit] INFO: Handling Pair Verify...
0000006877 [homekit] INFO: Homekit progress callback: 8
0000006877 [homekit] INFO: Pair Verify M1
0000008369 [homekit] INFO: Homekit progress callback: 9
0000008370 [homekit] INFO: writeData responseLen:220
0000008371 [homekit] INFO: Client removed.
0000008389 [homekit] INFO: Bonjour advertised
0000008389 [homekit] INFO: Client connected.
0000008391 [homekit] INFO: Request Message read length: 162
0000008392 [homekit] INFO: Handling Pair Verify...
0000008393 [homekit] INFO: Homekit progress callback: 8
0000008393 [homekit] INFO: Pair Verify M1
0000009885 [homekit] INFO: Homekit progress callback: 9
0000009885 [homekit] INFO: writeData responseLen:220
0000009886 [homekit] INFO: Client removed.
0000009888 [homekit] INFO: Bonjour advertised
0000009889 [homekit] INFO: Client connected.
0000009891 [homekit] INFO: Request Message read length: 162
0000009892 [homekit] INFO: Handling Pair Verify...
0000009893 [homekit] INFO: Homekit progress callback: 8
0000009893 [homekit] INFO: Pair Verify M1
0000011385 [homekit] INFO: Homekit progress callback: 9
0000011386 [homekit] INFO: writeData responseLen:220
0000011386 [homekit] INFO: Client removed.
0000011389 [homekit] INFO: Bonjour advertised
0000011448 [homekit] INFO: Client removed.
0000012390 [homekit] INFO: Bonjour advertised
0000013392 [homekit] INFO: Bonjour advertised
0000014392 [homekit] INFO: Bonjour advertised
0000015393 [homekit] INFO: Bonjour advertised
0000016394 [homekit] INFO: Bonjour advertised
0000017395 [homekit] INFO: Bonjour advertised
0000017997 [homekit] INFO: Client connected.
0000018001 [homekit] INFO: Request Message read length: 129
0000018002 [homekit] INFO: Handling Pair Setup...
0000018003 [homekit] INFO: State: 1
0000018003 [homekit] INFO: Homekit progress callback: 1
0000018003 [homekit] INFO: State_M1_SRPStartRequest
0000021917 [homekit] INFO: Homekit progress callback: 2
0000021918 [homekit] INFO: writeData responseLen:489
0000021920 [homekit] INFO: Bonjour advertised
0000022118 [homekit] INFO: Request Message read length: 582
0000022119 [homekit] INFO: Handling Pair Setup...
0000022120 [homekit] INFO: State: 3
0000022121 [homekit] INFO: State_M3_SRPVerifyRequest
0000022121 [homekit] INFO: Homekit progress callback: 3
0000026425 [homekit] INFO: Password is correct.
0000026425 [homekit] INFO: Homekit progress callback: 4
0000026425 [homekit] INFO: Client removed.
0000026429 [homekit] INFO: Bonjour advertised
0000026997 [homekit] INFO: Client connected.
0000027001 [homekit] INFO: Request Message read length: 162
0000027002 [homekit] INFO: Handling Pair Verify...
0000027003 [homekit] INFO: Homekit progress callback: 8
0000027003 [homekit] INFO: Pair Verify M1
0000028495 [homekit] INFO: Homekit progress callback: 9
0000028495 [homekit] INFO: writeData responseLen:220
0000028498 [homekit] INFO: Bonjour advertised
0000028560 [homekit] INFO: Client removed.
0000029499 [homekit] INFO: Bonjour advertised
0000030500 [homekit] INFO: Bonjour advertised
0000030810 [homekit] INFO: Client connected.
0000030812 [homekit] INFO: Request Message read length: 129
0000030813 [homekit] INFO: Handling Pair Setup...
0000030814 [homekit] INFO: State: 1
0000030814 [homekit] INFO: Homekit progress callback: 1
0000030814 [homekit] INFO: State_M1_SRPStartRequest
0000034750 [homekit] INFO: Homekit progress callback: 2
0000034750 [homekit] INFO: writeData responseLen:489
0000034753 [homekit] INFO: Bonjour advertised
0000034905 [homekit] INFO: Request Message read length: 582
0000034906 [homekit] INFO: Handling Pair Setup...
0000034907 [homekit] INFO: State: 3
0000034908 [homekit] INFO: State_M3_SRPVerifyRequest
0000034908 [homekit] INFO: Homekit progress callback: 3
0000039217 [homekit] INFO: Password is correct.
0000039217 [homekit] INFO: Homekit progress callback: 4
0000039217 [homekit] INFO: writeData responseLen:148
0000039220 [homekit] INFO: Bonjour advertised
0000039276 [homekit] INFO: Request Message read length: 284
0000039277 [homekit] INFO: Handling Pair Setup...
0000039278 [homekit] INFO: State: 5
0000039278 [homekit] INFO: State_M5_ExchangeRequest
0000039278 [homekit] INFO: Homekit progress callback: 5
0000039281 [homekit] INFO: wc_ChaCha20Poly1305_Decrypt: r:0
0000039281 [homekit] INFO: Persistor: resetPairings
0000039281 [homekit] INFO: Persistor: save
0000039300 [homekit] INFO: Persistor: adding key
0000039300 [homekit] INFO: Persistor: save
0000039303 [homekit] INFO: Persistor: key added
0000040854 [homekit] INFO: Homekit progress callback: 7
0000040855 [homekit] INFO: writeData responseLen:220
0000040855 [homekit] INFO: Pairing completed.
0000040858 [homekit] INFO: Bonjour advertised
0000040933 [homekit] INFO: Client removed.
0000040943 [homekit] INFO: Client connected.
0000040945 [homekit] INFO: Request Message read length: 162
0000040946 [homekit] INFO: Handling Pair Verify...
0000040947 [homekit] INFO: Homekit progress callback: 8
0000040947 [homekit] INFO: Pair Verify M1
0000042438 [homekit] INFO: Homekit progress callback: 9
0000042439 [homekit] INFO: writeData responseLen:220
0000042442 [homekit] INFO: Bonjour advertised
0000042489 [homekit] INFO: Request Message read length: 251
0000042490 [homekit] INFO: Handling Pair Verify...
0000042491 [homekit] INFO: Pair Verify M3
0000042491 [homekit] INFO: Homekit progress callback: 10
0000042492 [homekit] INFO: Persistor: key get
0000042492 [homekit] INFO: Persistor: key found
0000043538 [homekit] INFO: Pair verified, secure connection established
0000043539 [homekit] INFO: Homekit progress callback: 11
0000043539 [homekit] INFO: writeData responseLen:81
0000043539 [homekit] INFO: Persistor: save
0000043543 [homekit] INFO: Bonjour advertised
0000043546 [homekit] INFO: Bonjour advertised
0000043597 [homekit] INFO: Request Message read length: 64
0000043598 [homekit] INFO: Handling message request: accessories
0000043598 [homekit] INFO: Homekit progress callback: 12
0000043599 [homekit] INFO: Path: /accessories
0000043599 [homekit] INFO: Ask for accessories info
0000043601 [homekit] INFO: Accessories description len:686
0000043602 [homekit] INFO: Homekit progress callback: 13
0000043602 [homekit] INFO: writeEncryptedData responseLen:814
0000043703 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000043819 [homekit] INFO: Request Message read length: 174
0000043820 [homekit] INFO: Handling message request: characteristics
0000043820 [homekit] INFO: Homekit progress callback: 12
0000043821 [homekit] INFO: Path: /characteristics
0000043821 [homekit] INFO: Characteristics
0000043821 [homekit] INFO: PUT characteristics: {"characteristics":[{"aid":1,"iid":10,"ev":true}]}
0000043822 [homekit] INFO: 1 . 10
0000043822 [homekit] INFO: Ask to notify one characteristics: 1 . 10 -> true
0000043823 [homekit] INFO: Homekit progress callback: 13
0000043823 [homekit] INFO: writeEncryptedData responseLen:128
0000043923 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


0000044009 [homekit] INFO: Request Message read length: 174
0000044010 [homekit] INFO: Handling message request: characteristics
0000044010 [homekit] INFO: Homekit progress callback: 12
0000044011 [homekit] INFO: Path: /characteristics
0000044011 [homekit] INFO: Characteristics
0000044011 [homekit] INFO: PUT characteristics: {"characteristics":[{"aid":1,"iid":10,"ev":true}]}
0000044012 [homekit] INFO: 1 . 10
0000044012 [homekit] INFO: Ask to notify one characteristics: 1 . 10 -> true
0000044012 [homekit] INFO: Homekit progress callback: 13
0000044013 [homekit] INFO: writeEncryptedData responseLen:128
0000044113 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


0000044186 [homekit] INFO: Request Message read length: 203
0000044187 [homekit] INFO: Handling message request: pairings
0000044187 [homekit] INFO: Homekit progress callback: 12
0000044188 [homekit] INFO: Path: /pairings
0000044189 [homekit] INFO: 3
0000044189 [homekit] INFO: Add new user
0000044189 [homekit] INFO: Persistor: adding key
0000044190 [homekit] INFO: Persistor: save
0000044193 [homekit] INFO: Persistor: key added
0000044193 [homekit] INFO: Homekit progress callback: 13
0000044193 [homekit] INFO: writeEncryptedData responseLen:131
0000044294 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000044366 [homekit] INFO: Request Message read length: 203
0000044367 [homekit] INFO: Handling message request: pairings
0000044367 [homekit] INFO: Homekit progress callback: 12
0000044368 [homekit] INFO: Path: /pairings
0000044369 [homekit] INFO: 3
0000044369 [homekit] INFO: Add new user
0000044369 [homekit] INFO: Persistor: adding key
0000044369 [homekit] INFO: Persistor: save
0000044373 [homekit] INFO: Persistor: key added
0000044373 [homekit] INFO: Homekit progress callback: 13
0000044373 [homekit] INFO: writeEncryptedData responseLen:131
0000044474 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000044546 [homekit] INFO: Bonjour advertised
0000044854 [homekit] INFO: Request Message read length: 64
0000044855 [homekit] INFO: Handling message request: accessories
0000044855 [homekit] INFO: Homekit progress callback: 12
0000044856 [homekit] INFO: Path: /accessories
0000044856 [homekit] INFO: Ask for accessories info
0000044858 [homekit] INFO: Accessories description len:686
0000044859 [homekit] INFO: Homekit progress callback: 13
0000044859 [homekit] INFO: writeEncryptedData responseLen:814
0000044960 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000045078 [homekit] INFO: Request Message read length: 174
0000045079 [homekit] INFO: Handling message request: characteristics
0000045079 [homekit] INFO: Homekit progress callback: 12
0000045080 [homekit] INFO: Path: /characteristics
0000045080 [homekit] INFO: Characteristics
0000045080 [homekit] INFO: PUT characteristics: {"characteristics":[{"aid":1,"iid":10,"ev":true}]}
0000045081 [homekit] INFO: 1 . 10
0000045081 [homekit] INFO: Ask to notify one characteristics: 1 . 10 -> true
0000045082 [homekit] INFO: Homekit progress callback: 13
0000045082 [homekit] INFO: writeEncryptedData responseLen:128
0000045182 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


0000045548 [homekit] INFO: Bonjour advertised
0000046086 [homekit] INFO: Request Message read length: 76
0000046087 [homekit] INFO: Handling message request: characteristics?id=1.10
0000046087 [homekit] INFO: Homekit progress callback: 12
0000046088 [homekit] INFO: Path: /characteristics?id=1.10
0000046088 [homekit] INFO: Characteristics
0000046088 [homekit] INFO: Get characteristics 1.10 with len 4
0000046089 [homekit] INFO: Get characteristics 1.10 with len 4
0000046089 [homekit] INFO: Get temp  with len 0
0000046089 [homekit] INFO: Get characteristics  with len 0
0000046090 [homekit] INFO: Ask for one characteristics: 1 . 10
0000046090 [homekit] INFO: Homekit progress callback: 13
0000046091 [homekit] INFO: writeEncryptedData responseLen:181
0000046191 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 53

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 53

{"characteristics":[{"aid":1,"iid":10,"value":true}]}
0000046451 [homekit] INFO: Request Message read length: 62
0000046452 [homekit] INFO: Client removed.
0000046549 [homekit] INFO: Bonjour advertised
0000046676 [homekit] INFO: Client connected.
0000046677 [homekit] INFO: Request Message read length: 162
0000046678 [homekit] INFO: Handling Pair Verify...
0000046679 [homekit] INFO: Homekit progress callback: 8
0000046679 [homekit] INFO: Pair Verify M1
0000048171 [homekit] INFO: Homekit progress callback: 9
0000048172 [homekit] INFO: writeData responseLen:220
0000048175 [homekit] INFO: Bonjour advertised
0000048175 [homekit] INFO: Client connected.
0000048177 [homekit] INFO: Request Message read length: 162
0000048178 [homekit] INFO: Handling Pair Verify...
0000048179 [homekit] INFO: Homekit progress callback: 8
0000048179 [homekit] INFO: Pair Verify M1
0000049671 [homekit] INFO: Homekit progress callback: 9
0000049671 [homekit] INFO: writeData responseLen:220
0000049673 [homekit] INFO: Request Message read length: 251
0000049674 [homekit] INFO: Handling Pair Verify...
0000049675 [homekit] INFO: Pair Verify M3
0000049675 [homekit] INFO: Homekit progress callback: 10
0000049676 [homekit] INFO: Persistor: key get
0000049676 [homekit] INFO: Persistor: key found
0000050724 [homekit] INFO: Pair verified, secure connection established
0000050724 [homekit] INFO: Homekit progress callback: 11
0000050725 [homekit] INFO: writeData responseLen:81
0000050727 [homekit] INFO: Bonjour advertised
0000050728 [homekit] INFO: Client connected.
0000050730 [homekit] INFO: Request Message read length: 162
0000050731 [homekit] INFO: Handling Pair Verify...
0000050732 [homekit] INFO: Homekit progress callback: 8
0000050732 [homekit] INFO: Pair Verify M1
0000052224 [homekit] INFO: Homekit progress callback: 9
0000052225 [homekit] INFO: writeData responseLen:220
0000052226 [homekit] INFO: Request Message read length: 251
0000052227 [homekit] INFO: Handling Pair Verify...
0000052228 [homekit] INFO: Pair Verify M3
0000052229 [homekit] INFO: Homekit progress callback: 10
0000052229 [homekit] INFO: Persistor: key get
0000052229 [homekit] INFO: Persistor: key found
0000053276 [homekit] INFO: Pair verified, secure connection established
0000053277 [homekit] INFO: Homekit progress callback: 11
0000053277 [homekit] INFO: writeData responseLen:81
0000053279 [homekit] INFO: Request Message read length: 64
0000053280 [homekit] INFO: Handling message request: accessories
0000053280 [homekit] INFO: Homekit progress callback: 12
0000053281 [homekit] INFO: Path: /accessories
0000053281 [homekit] INFO: Ask for accessories info
0000053283 [homekit] INFO: Accessories description len:686
0000053284 [homekit] INFO: Homekit progress callback: 13
0000053284 [homekit] INFO: writeEncryptedData responseLen:814
0000053385 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000053392 [homekit] INFO: Bonjour advertised
0000053394 [homekit] INFO: Request Message read length: 251
0000053395 [homekit] INFO: Handling Pair Verify...
0000053396 [homekit] INFO: Pair Verify M3
0000053396 [homekit] INFO: Homekit progress callback: 10
0000053397 [homekit] INFO: Persistor: key get
0000053397 [homekit] INFO: Persistor: key found
0000054446 [homekit] INFO: Pair verified, secure connection established
0000054446 [homekit] INFO: Homekit progress callback: 11
0000054447 [homekit] INFO: writeData responseLen:81
0000054449 [homekit] INFO: Request Message read length: 64
0000054450 [homekit] INFO: Handling message request: accessories
0000054451 [homekit] INFO: Homekit progress callback: 12
0000054451 [homekit] INFO: Path: /accessories
0000054452 [homekit] INFO: Ask for accessories info
0000054454 [homekit] INFO: Accessories description len:686
0000054454 [homekit] INFO: Homekit progress callback: 13
0000054454 [homekit] INFO: writeEncryptedData responseLen:814
0000054556 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000054561 [homekit] INFO: Request Message read length: 203
0000054562 [homekit] INFO: Handling message request: pairings
0000054562 [homekit] INFO: Homekit progress callback: 12
0000054563 [homekit] INFO: Path: /pairings
0000054564 [homekit] INFO: 3
0000054564 [homekit] INFO: Add new user
0000054564 [homekit] INFO: Persistor: adding key
0000054565 [homekit] INFO: Persistor: save
0000054568 [homekit] INFO: Persistor: key added
0000054568 [homekit] INFO: Homekit progress callback: 13
0000054569 [homekit] INFO: writeEncryptedData responseLen:131
0000054670 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000054674 [homekit] INFO: Bonjour advertised
0000054674 [homekit] INFO: Client connected.
0000054676 [homekit] INFO: Request Message read length: 162
0000054677 [homekit] INFO: Handling Pair Verify...
0000054678 [homekit] INFO: Homekit progress callback: 8
0000054678 [homekit] INFO: Pair Verify M1
0000056170 [homekit] INFO: Homekit progress callback: 9
0000056171 [homekit] INFO: writeData responseLen:220
0000056173 [homekit] INFO: Request Message read length: 64
0000056174 [homekit] INFO: Handling message request: accessories
0000056174 [homekit] INFO: Homekit progress callback: 12
0000056175 [homekit] INFO: Path: /accessories
0000056175 [homekit] INFO: Ask for accessories info
0000056178 [homekit] INFO: Accessories description len:686
0000056178 [homekit] INFO: Homekit progress callback: 13
0000056178 [homekit] INFO: writeEncryptedData responseLen:814
0000056279 [homekit] INFO: Response to: 10.0.2.38, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000056285 [homekit] INFO: Request Message read length: 203
0000056286 [homekit] INFO: Handling message request: pairings
0000056286 [homekit] INFO: Homekit progress callback: 12
0000056287 [homekit] INFO: Path: /pairings
0000056288 [homekit] INFO: 3
0000056288 [homekit] INFO: Add new user
0000056288 [homekit] INFO: Persistor: adding key
0000056289 [homekit] INFO: Persistor: save
0000056292 [homekit] INFO: Persistor: key added
0000056293 [homekit] INFO: Homekit progress callback: 13
0000056293 [homekit] INFO: writeEncryptedData responseLen:131
0000056393 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000056396 [homekit] INFO: Request Message read length: 203
0000056397 [homekit] INFO: Handling message request: pairings
0000056397 [homekit] INFO: Homekit progress callback: 12
0000056398 [homekit] INFO: Path: /pairings
0000056399 [homekit] INFO: 3
0000056399 [homekit] INFO: Add new user
0000056400 [homekit] INFO: Persistor: adding key
0000056400 [homekit] INFO: Persistor: save
0000056404 [homekit] INFO: Persistor: key added
0000056404 [homekit] INFO: Homekit progress callback: 13
0000056404 [homekit] INFO: writeEncryptedData responseLen:131
0000056505 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000056509 [homekit] INFO: Bonjour advertised
0000056510 [homekit] INFO: Request Message read length: 251
0000056511 [homekit] INFO: Handling Pair Verify...
0000056512 [homekit] INFO: Pair Verify M3
0000056512 [homekit] INFO: Homekit progress callback: 10
0000056513 [homekit] INFO: Persistor: key get
0000056513 [homekit] INFO: Persistor: key found
0000057559 [homekit] INFO: Pair verified, secure connection established
0000057560 [homekit] INFO: Homekit progress callback: 11
0000057560 [homekit] INFO: writeData responseLen:81
0000057563 [homekit] INFO: Request Message read length: 203
0000057564 [homekit] INFO: Handling message request: pairings
0000057565 [homekit] INFO: Homekit progress callback: 12
0000057565 [homekit] INFO: Path: /pairings
0000057567 [homekit] INFO: 3
0000057567 [homekit] INFO: Add new user
0000057567 [homekit] INFO: Persistor: adding key
0000057567 [homekit] INFO: Persistor: save
0000057571 [homekit] INFO: Persistor: key added
0000057571 [homekit] INFO: Homekit progress callback: 13
0000057571 [homekit] INFO: writeEncryptedData responseLen:131
0000057672 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000057677 [homekit] INFO: Bonjour advertised
0000057678 [homekit] INFO: Request Message read length: 64
0000057679 [homekit] INFO: Handling message request: accessories
0000057679 [homekit] INFO: Homekit progress callback: 12
0000057680 [homekit] INFO: Path: /accessories
0000057680 [homekit] INFO: Ask for accessories info
0000057682 [homekit] INFO: Accessories description len:686
0000057682 [homekit] INFO: Homekit progress callback: 13
0000057683 [homekit] INFO: writeEncryptedData responseLen:814
0000057784 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000058159 [homekit] INFO: Request Message read length: 203
0000058160 [homekit] INFO: Handling message request: pairings
0000058160 [homekit] INFO: Homekit progress callback: 12
0000058161 [homekit] INFO: Path: /pairings
0000058162 [homekit] INFO: 3
0000058162 [homekit] INFO: Add new user
0000058162 [homekit] INFO: Persistor: adding key
0000058163 [homekit] INFO: Persistor: save
0000058166 [homekit] INFO: Persistor: key added
0000058167 [homekit] INFO: Homekit progress callback: 13
0000058167 [homekit] INFO: writeEncryptedData responseLen:131
0000058268 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000058274 [homekit] INFO: Request Message read length: 203
0000058275 [homekit] INFO: Handling message request: pairings
0000058275 [homekit] INFO: Homekit progress callback: 12
0000058276 [homekit] INFO: Path: /pairings
0000058277 [homekit] INFO: 3
0000058277 [homekit] INFO: Add new user
0000058277 [homekit] INFO: Persistor: adding key
0000058278 [homekit] INFO: Persistor: save
0000058281 [homekit] INFO: Persistor: key added
0000058282 [homekit] INFO: Homekit progress callback: 13
0000058282 [homekit] INFO: writeEncryptedData responseLen:131
0000058383 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000058394 [homekit] INFO: Request Message read length: 174
0000058395 [homekit] INFO: Handling message request: characteristics
0000058395 [homekit] INFO: Homekit progress callback: 12
0000058396 [homekit] INFO: Path: /characteristics
0000058396 [homekit] INFO: Characteristics
0000058396 [homekit] INFO: PUT characteristics: {"characteristics":[{"aid":1,"iid":10,"ev":true}]}
0000058397 [homekit] INFO: 1 . 10
0000058397 [homekit] INFO: Ask to notify one characteristics: 1 . 10 -> true
0000058398 [homekit] INFO: Homekit progress callback: 13
0000058398 [homekit] INFO: writeEncryptedData responseLen:128
0000058499 [homekit] INFO: Response to: 10.0.2.60, data:HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


HTTP/1.1 204 OK
Content-Type: application/hap+json
Content-Length: 0


0000058680 [homekit] INFO: Bonjour advertised
0000059681 [homekit] INFO: Bonjour advertised
0000060683 [homekit] INFO: Bonjour advertised
0000061685 [homekit] INFO: Bonjour advertised
0000062687 [homekit] INFO: Bonjour advertised
0000063689 [homekit] INFO: Bonjour advertised
0000064691 [homekit] INFO: Bonjour advertised
0000064817 [homekit] INFO: Request Message read length: 203
0000064818 [homekit] INFO: Handling message request: pairings
0000064819 [homekit] INFO: Homekit progress callback: 12
0000064819 [homekit] INFO: Path: /pairings
0000064820 [homekit] INFO: 3
0000064820 [homekit] INFO: Add new user
0000064820 [homekit] INFO: Persistor: adding key
0000064821 [homekit] INFO: Persistor: save
0000064824 [homekit] INFO: Persistor: key added
0000064825 [homekit] INFO: Homekit progress callback: 13
0000064825 [homekit] INFO: writeEncryptedData responseLen:131
0000064926 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000065694 [homekit] INFO: Bonjour advertised
0000066696 [homekit] INFO: Bonjour advertised
0000066926 [homekit] INFO: Request Message read length: 203
0000066927 [homekit] INFO: Handling message request: pairings
0000066928 [homekit] INFO: Homekit progress callback: 12
0000066928 [homekit] INFO: Path: /pairings
0000066929 [homekit] INFO: 3
0000066929 [homekit] INFO: Add new user
0000066929 [homekit] INFO: Persistor: adding key
0000066930 [homekit] INFO: Persistor: save
0000066934 [homekit] INFO: Persistor: key added
0000066934 [homekit] INFO: Homekit progress callback: 13
0000066934 [homekit] INFO: writeEncryptedData responseLen:131
0000067035 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000067230 [homekit] INFO: Request Message read length: 203
0000067231 [homekit] INFO: Handling message request: pairings
0000067232 [homekit] INFO: Homekit progress callback: 12
0000067232 [homekit] INFO: Path: /pairings
0000067233 [homekit] INFO: 3
0000067233 [homekit] INFO: Add new user
0000067233 [homekit] INFO: Persistor: adding key
0000067234 [homekit] INFO: Persistor: save
0000067238 [homekit] INFO: Persistor: key added
0000067238 [homekit] INFO: Homekit progress callback: 13
0000067238 [homekit] INFO: writeEncryptedData responseLen:131
0000067339 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000067598 [homekit] INFO: Request Message read length: 62
0000067599 [homekit] INFO: Client removed.
0000067697 [homekit] INFO: Bonjour advertised
0000068356 [homekit] INFO: Request Message read length: 203
0000068357 [homekit] INFO: Handling message request: pairings
0000068358 [homekit] INFO: Homekit progress callback: 12
0000068358 [homekit] INFO: Path: /pairings
0000068359 [homekit] INFO: 3
0000068359 [homekit] INFO: Add new user
0000068359 [homekit] INFO: Persistor: adding key
0000068360 [homekit] INFO: Persistor: save
0000068364 [homekit] INFO: Persistor: key added
0000068364 [homekit] INFO: Homekit progress callback: 13
0000068364 [homekit] INFO: writeEncryptedData responseLen:131
0000068465 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000068701 [homekit] INFO: Bonjour advertised
0000069703 [homekit] INFO: Bonjour advertised
0000070705 [homekit] INFO: Bonjour advertised
0000071707 [homekit] INFO: Bonjour advertised
0000072064 [homekit] INFO: Client connected.
0000072066 [homekit] INFO: Request Message read length: 162
0000072067 [homekit] INFO: Handling Pair Verify...
0000072068 [homekit] INFO: Homekit progress callback: 8
0000072068 [homekit] INFO: Pair Verify M1
0000073562 [homekit] INFO: Homekit progress callback: 9
0000073563 [homekit] INFO: writeData responseLen:220
0000073568 [homekit] INFO: Bonjour advertised
0000073569 [homekit] INFO: Client connected.
0000073570 [homekit] INFO: Request Message read length: 62
0000073571 [homekit] INFO: Client removed.
0000073576 [homekit] INFO: Client connected.
0000073577 [homekit] INFO: Request Message read length: 162
0000073578 [homekit] INFO: Handling Pair Verify...
0000073579 [homekit] INFO: Homekit progress callback: 8
0000073579 [homekit] INFO: Pair Verify M1
0000075076 [homekit] INFO: Homekit progress callback: 9
0000075076 [homekit] INFO: writeData responseLen:220
0000075078 [homekit] INFO: Request Message read length: 251
0000075079 [homekit] INFO: Handling Pair Verify...
0000075080 [homekit] INFO: Pair Verify M3
0000075080 [homekit] INFO: Homekit progress callback: 10
0000075081 [homekit] INFO: Persistor: key get
0000075081 [homekit] INFO: Persistor: key found
0000076128 [homekit] INFO: Pair verified, secure connection established
0000076128 [homekit] INFO: Homekit progress callback: 11
0000076129 [homekit] INFO: writeData responseLen:81
0000076135 [homekit] INFO: Bonjour advertised
0000076135 [homekit] INFO: Client connected.
0000076137 [homekit] INFO: Request Message read length: 162
0000076138 [homekit] INFO: Max connections reached, sending response to 10.0.2.60 data: HTTP/1.1 503 Service Unavailable


0000076139 [homekit] INFO: writeData responseLen:36
0000076139 [homekit] INFO: Client removed.
0000076141 [homekit] INFO: Request Message read length: 251
0000076142 [homekit] INFO: Handling Pair Verify...
0000076143 [homekit] INFO: Pair Verify M3
0000076143 [homekit] INFO: Homekit progress callback: 10
0000076144 [homekit] INFO: Persistor: key get
0000076144 [homekit] INFO: Persistor: key found
0000077192 [homekit] INFO: Pair verified, secure connection established
0000077192 [homekit] INFO: Homekit progress callback: 11
0000077193 [homekit] INFO: writeData responseLen:81
0000077194 [homekit] INFO: Request Message read length: 64
0000077195 [homekit] INFO: Handling message request: accessories
0000077195 [homekit] INFO: Homekit progress callback: 12
0000077196 [homekit] INFO: Path: /accessories
0000077196 [homekit] INFO: Ask for accessories info
0000077198 [homekit] INFO: Accessories description len:686
0000077199 [homekit] INFO: Homekit progress callback: 13
0000077199 [homekit] INFO: writeEncryptedData responseLen:814
0000077300 [homekit] INFO: Response to: 10.0.2.55, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000077309 [homekit] INFO: Bonjour advertised
0000077309 [homekit] INFO: Client connected.
0000077311 [homekit] INFO: Request Message read length: 162
0000077312 [homekit] INFO: Max connections reached, sending response to 10.0.2.70 data: HTTP/1.1 503 Service Unavailable


0000077313 [homekit] INFO: writeData responseLen:36
0000077313 [homekit] INFO: Client removed.
0000077315 [homekit] INFO: Request Message read length: 64
0000077316 [homekit] INFO: Handling message request: accessories
0000077316 [homekit] INFO: Homekit progress callback: 12
0000077317 [homekit] INFO: Path: /accessories
0000077317 [homekit] INFO: Ask for accessories info
0000077319 [homekit] INFO: Accessories description len:686
0000077320 [homekit] INFO: Homekit progress callback: 13
0000077320 [homekit] INFO: writeEncryptedData responseLen:814
0000077421 [homekit] INFO: Response to: 10.0.2.44, data:HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{~
HTTP/1.1 200 OK
Content-Type: application/hap+json
Content-Length: 686

{"accessories":[{"services":[{"iid":1,"type":"3E","characteristics":[{"value":"Switch","perms":["pr"],"type":"23","iid":2,"format":"string"},{"value":"ljezny","perms":["pr"],"type":"20","iid":3,"format":"string"},{"value":"Switch","perms":["pr"],"type":"21","iid":4,"format":"string"},{"value":"1","perms":["pr"],"type":"30","iid":5,"format":"string"},{"value":"1.0.0","perms":["pr"],"type":"52","iid":6,"format":"string"},{"perms":["pw"],"type":"14","iid":7,"format":"bool"}]},{"iid":8,"type":"49","characteristics":[{"value":"Relay Switch","perms":["pr"],"type":"23","iid":9,"format":"string"},{"value":true,"perms":["pr","pw","ev"],"type":"25","iid":10,"format":"bool"}]}],"aid":1}]}
0000077431 [homekit] INFO: Client connected.
0000077432 [homekit] INFO: Request Message read length: 162
0000077433 [homekit] INFO: Max connections reached, sending response to 10.0.2.106 data: HTTP/1.1 503 Service Unavailable


0000077433 [homekit] INFO: writeData responseLen:36
0000077434 [homekit] INFO: Client removed.
0000077440 [homekit] INFO: Client connected.
0000077441 [homekit] INFO: Request Message read length: 162
0000077442 [homekit] INFO: Max connections reached, sending response to 10.0.2.70 data: HTTP/1.1 503 Service Unavailable


0000077442 [homekit] INFO: writeData responseLen:36
0000077443 [homekit] INFO: Client removed.
0000077641 [homekit] INFO: Client connected.
0000077642 [homekit] INFO: Request Message read length: 162
0000077643 [homekit] INFO: Max connections reached, sending response to 10.0.2.106 data: HTTP/1.1 503 Service Unavailable


0000077643 [homekit] INFO: writeData responseLen:36
0000077644 [homekit] INFO: Client removed.
0000077782 [homekit] INFO: Client connected.
0000077783 [homekit] INFO: Request Message read length: 62
0000077784 [homekit] INFO: Client removed.
0000077796 [homekit] INFO: Client connected.
0000077798 [homekit] INFO: Request Message read length: 162
0000077799 [homekit] INFO: Max connections reached, sending response to 10.0.2.60 data: HTTP/1.1 503 Service Unavailable


0000077800 [homekit] INFO: writeData responseLen:36
0000077800 [homekit] INFO: Client removed.
0000078312 [homekit] INFO: Bonjour advertised
0000079316 [homekit] INFO: Bonjour advertised
0000079965 [homekit] INFO: Client connected.
0000079966 [homekit] INFO: Request Message read length: 162
0000079967 [homekit] INFO: Max connections reached, sending response to 10.0.2.25 data: HTTP/1.1 503 Service Unavailable


0000079968 [homekit] INFO: writeData responseLen:36
0000079968 [homekit] INFO: Client removed.
0000080318 [homekit] INFO: Bonjour advertised
0000081322 [homekit] INFO: Bonjour advertised
0000082326 [homekit] INFO: Bonjour advertised
0000083330 [homekit] INFO: Bonjour advertised
0000084099 [homekit] INFO: Client connected.
0000084100 [homekit] INFO: Request Message read length: 162
0000084101 [homekit] INFO: Max connections reached, sending response to 10.0.2.60 data: HTTP/1.1 503 Service Unavailable


0000084102 [homekit] INFO: writeData responseLen:36
0000084102 [homekit] INFO: Client removed.
0000084115 [homekit] INFO: Client connected.
0000084116 [homekit] INFO: Request Message read length: 162
0000084117 [homekit] INFO: Max connections reached, sending response to 10.0.2.60 data: HTTP/1.1 503 Service Unavailable


0000084117 [homekit] INFO: writeData responseLen:36
0000084118 [homekit] INFO: Client removed.
0000084335 [homekit] INFO: Bonjour advertised
0000085339 [homekit] INFO: Bonjour advertised
0000086343 [homekit] INFO: Bonjour advertised
0000087347 [homekit] INFO: Bonjour advertised
0000088351 [homekit] INFO: Bonjour advertised
0000088628 [homekit] INFO: Client connected.
0000088629 [homekit] INFO: Request Message read length: 162
0000088630 [homekit] INFO: Max connections reached, sending response to 10.0.2.60 data: HTTP/1.1 503 Service Unavailable


0000088631 [homekit] INFO: writeData responseLen:36
0000088631 [homekit] INFO: Client removed.
0000088650 [homekit] INFO: Client connected.
0000088651 [homekit] INFO: Request Message read length: 162
0000088652 [homekit] INFO: Max connections reached, sending response to 10.0.2.60 data: HTTP/1.1 503 Service Unavailable


0000088652 [homekit] INFO: writeData responseLen:36
0000088653 [homekit] INFO: Client removed.
0000089357 [homekit] INFO: Bonjour advertised
0000089658 [homekit] INFO: Client connected.
0000089659 [homekit] INFO: Request Message read length: 162
0000089660 [homekit] INFO: Max connections reached, sending response to 10.0.2.106 data: HTTP/1.1 503 Service Unavailable


0000089661 [homekit] INFO: writeData responseLen:36
0000089661 [homekit] INFO: Client removed.
0000089680 [homekit] INFO: Client connected.
0000089681 [homekit] INFO: Request Message read length: 162
0000089682 [homekit] INFO: Max connections reached, sending response to 10.0.2.106 data: HTTP/1.1 503 Service Unavailable


0000089682 [homekit] INFO: writeData responseLen:36
0000089683 [homekit] INFO: Client removed.
0000090363 [homekit] INFO: Bonjour advertised
0000091367 [homekit] INFO: Bonjour advertised
0000092371 [homekit] INFO: Bonjour advertised
0000093374 [homekit] INFO: Bonjour advertised
0000094378 [homekit] INFO: Bonjour advertised
0000095279 [homekit] INFO: Request Message read length: 203
0000095280 [homekit] INFO: Handling message request: pairings
0000095280 [homekit] INFO: Homekit progress callback: 12
0000095281 [homekit] INFO: Path: /pairings
0000095282 [homekit] INFO: 3
0000095282 [homekit] INFO: Add new user
0000095282 [homekit] INFO: Persistor: adding key
0000095283 [homekit] INFO: Persistor: save
0000095286 [homekit] INFO: Persistor: key added
0000095287 [homekit] INFO: Homekit progress callback: 13
0000095287 [homekit] INFO: writeEncryptedData responseLen:131
0000095387 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000095392 [homekit] INFO: Bonjour advertised
0000096395 [homekit] INFO: Bonjour advertised
0000097399 [homekit] INFO: Bonjour advertised
0000097860 [homekit] INFO: Request Message read length: 203
0000097861 [homekit] INFO: Handling message request: pairings
0000097861 [homekit] INFO: Homekit progress callback: 12
0000097862 [homekit] INFO: Path: /pairings
0000097863 [homekit] INFO: 3
0000097863 [homekit] INFO: Add new user
0000097863 [homekit] INFO: Persistor: adding key
0000097864 [homekit] INFO: Persistor: save
0000097867 [homekit] INFO: Persistor: key added
0000097868 [homekit] INFO: Homekit progress callback: 13
0000097868 [homekit] INFO: writeEncryptedData responseLen:131
0000097968 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000098405 [homekit] INFO: Bonjour advertised
0000098914 [homekit] INFO: Request Message read length: 203
0000098915 [homekit] INFO: Handling message request: pairings
0000098915 [homekit] INFO: Homekit progress callback: 12
0000098916 [homekit] INFO: Path: /pairings
0000098917 [homekit] INFO: 3
0000098917 [homekit] INFO: Add new user
0000098917 [homekit] INFO: Persistor: adding key
0000098918 [homekit] INFO: Persistor: save
0000098921 [homekit] INFO: Persistor: key added
0000098922 [homekit] INFO: Homekit progress callback: 13
0000098922 [homekit] INFO: writeEncryptedData responseLen:131
0000099023 [homekit] INFO: Response to: 10.0.2.95, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000099169 [homekit] INFO: Request Message read length: 203
0000099170 [homekit] INFO: Handling message request: pairings
0000099170 [homekit] INFO: Homekit progress callback: 12
0000099171 [homekit] INFO: Path: /pairings
0000099172 [homekit] INFO: 3
0000099172 [homekit] INFO: Add new user
0000099172 [homekit] INFO: Persistor: adding key
0000099173 [homekit] INFO: Homekit progress callback: 13
0000099173 [homekit] INFO: writeEncryptedData responseLen:131
0000099274 [homekit] INFO: Response to: 10.0.2.47, data:HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


HTTP/1.1 200 OK
Content-Type: application/pairing+tlv8
Content-Length: 3


0000099409 [homekit] INFO: Bonjour advertised
0000100413 [homekit] INFO: Bonjour advertised
0000101417 [homekit] INFO: Bonjour advertised

Multiple devices using Particle-HAP

Has anyone actually tried creating multiple devices using Particle-HAP, within the same HomeKit network/environment?

The readme briefly mentions changing the static key, but this doesn't seem to be enough, as I can't get additional accessories connected.

Right now I have separate sensor modules, which I'd like to deploy 4-5 of in the same environment/network, but I don't know if this is even possible with Particle-HAP, or if I should instead implement it so that one device is the master HomeKit device, while the others are simply communicating with over the network, creating new accessories when necessary?

Updated services

Hi,
I am interesting in using this to control my sprinkler system but it seems the constants predate Apple's addition of irrigation valves.

For now I have just added some extra enums in my project header file but I am wondering if you have any plans on updating it?

Thanks.

CO sensor keeps "updating" in home app

Hi!

First of all thank you for the amazing work. Do you guys have an idea what can I do wrong if my carbon monoxide service with one current value characteristic always shows "updating" in the home app? My other air quality sensor service works fine. Note that in HKAccessory.h the servicetype_airQualitySensor should be 0x8D not 0x8C, becouse 0x8C is for window cover.

Thank you guys,
Levi

Fix Brightness with LED Strip

Hey man! Great work!

One issue though: setting the brightness on an LED is not working as it should; it just gets dim and really bright again when changing the brightness, not setting the actual wanted brightness

irrigation system

Hi Lucas,
I'm not sure if the implementation of an irrigation system is still of interest.
I made some edits/enhancements (eg. linked services-> edit of the service class) of your code and it seems to run pretty fine. So if you want to take a look let me know.
Best, Michael

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.