ewilken / hap-rs

Rust implementation of the Apple HomeKit Accessory Protocol (HAP)
Apache License 2.0
196 stars 33 forks source link

Raspbian speed #70

Closed soundprojects closed 2 years ago

soundprojects commented 2 years ago

Hi

Did you get this managed to work on a fresh raspbian installation on a pi 3? I am running one of your examples but there is much lag in the responses when pairing it seems, both in debug and release...

Any ideas?

ewilken commented 2 years ago

Since you closed, what was the resolution to this?

soundprojects commented 2 years ago

I closed this because I ran into some things I mentioned in the other issues. Now that I have unique configurations for both my development Mac and the raspberry (By generating a unique hostname and unique ID) the adding accesory behavior works correct. However: There is general instability in the TCP connections on both machines. Sometimes things work perfectly in the first go. But mostly when adding the accessory, I see in the debug: 'TCP reading stream' but controlling hap-rs using the Homekit app gives no response.

Then close and restart IOS Home app a few times and suddenly the controls do work. Then, randomly, it stops working after some time.

Do you have any approach on how to debug this further? My Dnssd discovery shows the services as correct all the time, except for the part that the libmdns doesn't send goodbye packets, so services linger on a bit longer than they have to.

But that does not explain the instable connection behavior I experience...