-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[homekit] Add (partial) Doorbell Service #17130
Conversation
This is dependent on #17129, even though it doesn't have conflicts. I'll rebase after that merges. |
The DCO failed, previous commits did not, weird. Anyway, this is a step towards doorbell support but incomplete and therefore not adding any value to users yet? Do you know what needs to be done before the doorbell is functional? |
Leaving as draft seems reasonable to me. The comments in the file detail what else needs to be implemented. The Speaker and Microphone services are trivial (the former is already implemented). But the Camera RTSP Service is quite large because it's far more than just a couple characteristics-- it's multiple additional protocols. I have no intentions of tackling it anytime soon, if ever. |
Can you outline the other parts that need to be worked on before this is functional? And if possible the technical difficulties? |
In HomeKit, a Doorbell is a both a Service and a Profile. An Accessory is composed of Services, typically an AccessoryInformationService and a single other service. A Profile is a common configuration of multiple services. The Video Doorbell Profile comprises the Doorbell Service (which is implemented in this PR), at the Camera RTP Stream Management Service, the Speaker Service, and the Microphone Service. The Home App on iOS won't do anything with an accessory that has a Doorbell service, but not those other services. The Speaker and Microphone Services are trivial (just mute and volume), so they are easily implemented. It's the Camera RTP Stream Management where things get complicated. The characteristics you publish are in a different format (TLV) from most other characteristics (simple JSON constructs), and they are various configuration type things describing what audio and video formats are supported, and parameters to negotiate an RTP connection with another service. openHAB doesn't really have the concept of a camera object - the IP Camera binding has a string channel for RTSP URL, but that's different from RTP. The RTP setup characteristic needs things like cryptography settings and encryption keys pre-negotiated. Not to mention that iOS only allows a very very small list of codecs. I have no interest in building all of this infrastructure in openHAB to do transcoding and such. Other projects such as go2rtc and scrypted are far better purpose built applications for handling the media-heavy pieces of exposing generic IP cameras to HomeKit. |
Totally understand that you don't want to spend all that time on transcoding etc to support just the doorbell. Especially as openHAB is juist moving the metadata around and not processing the actual stream and i don;t see that happening anytime soon. In that case i'll just merge it to atleast have this part of the puzzle. |
Nope, no Doorbell lite. You can set up an accessory with just the Doorbell Service (which contains the critical Programmable Switch Event characteristic -- the button), but the Home App will just show it as "unsupported". Best you can do in that case is use a Stateless Programmable Switch accessory on its own. |
Can you fix the build, then i'll merge it |
52ba577
to
ef373c3
Compare
this is _not_ sufficient for HomeKit to present a doorbell. it just shows as an unsupported accessory with the house icon, and you can't have status or program actions on button presses refs openhab#9969 Signed-off-by: Cody Cutrer <cody@cutrer.us>
Signed-off-by: Cody Cutrer <cody@cutrer.us>
ef373c3
to
d2b964f
Compare
I rebased to fix the build, and also added another commit to add it to the readme, and fix the copyright year on the new file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, LGTM.
Note: No label is added as this should not be listed on the release notes. |
* [homekit] add Doorbell Service this is _not_ sufficient for HomeKit to present a doorbell. it just shows as an unsupported accessory with the house icon, Signed-off-by: Cody Cutrer <cody@cutrer.us>
* [homekit] add Doorbell Service this is _not_ sufficient for HomeKit to present a doorbell. it just shows as an unsupported accessory with the house icon, Signed-off-by: Cody Cutrer <cody@cutrer.us>
This is not sufficient for HomeKit to present a doorbell, but it's a start. It just shows as an unsupported accessory with the house icon, and you can't have status or program actions on button presses.
Refs #9969