tommyjlong/doorvivint-card

WKWebview with WebRTC finally working on iOS 14.3

Closed this issue · 2 comments

Hi!

You are writing that the you never got it to work on Home Assistant Companion App for iOS, right?
Have you tried latest iOS14.3 version?

There have been some improvments in WkWebview component:
https://blog.bitsrc.io/ios-14-3-brings-webrtc-to-wkwebview-closing-gap-on-ios-accessibility-90a83fa6bda2
https://bugs.webkit.org/show_bug.cgi?id=208667
https://developer.apple.com/forums/thread/669011
https://webkit.org/blog/11353/mediarecorder-api/

Concerning audio:
I can see here that the app add the necessary record to request the camera:
https://github.com/home-assistant/iOS/blob/master/Sources/App/Resources/Info.plist#L603

However, I do not see NSMicrophoneUsageDescription in the file.
Thus, the webview in the app will not be able to request microphone access.

You can test it here:
https://webrtc.github.io/samples/

Good news!
The companion app for iOS has added the necessary string to Info.plist yesterday:
home-assistant/iOS#1323

Just tested the card with the fixes from issue #3.
Now it is working with the latest Home Assistant iOS app and two-way audio.