Skip to content
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

Re-using homekit URL from HomeAssistant results in ffmpeg initialization error #1082

Open
visigoth opened this issue May 3, 2024 · 3 comments
Labels
question Further information is requested

Comments

@visigoth
Copy link

visigoth commented May 3, 2024

I am using Frigate's builtin go2rtc running in a docker instance. I have a HomeAssistant docker instance on the same box. The config path for HomeAssistant is mapped into the Frigate docker instance at /hass_config.

I have go2rtc configured like this inside the frigate configuration, and the frigate configuration is below that


go2rtc:
  rtsp:
    username: "camera"
    password: "XXXXXXXXX"
  hass:
    config: "/hass_config"
  streams:
    doorbell:
      - homekit://192.168.0.71:49152?client_id=...&client_private=...&device_id=...&device_public=...


cameras:
  doorbell:
    ffmpeg:
      output_args:
        record: preset-record-generic-audio-copy
      inputs:
        - path: rtsp://127.0.0.1:8554/doorbell
          input_args: preset-rtsp-stream
          roles:
            - detect
            - record
      hwaccel_args: preset-intel-qsv-h264

note i have a number of other plain PoE RTSP cameras that are working fine with go2rtc + frigate doing both detection and recording. the above snippet just shows the one HomeKit camera i have for the doorbell. also note that i tried hass:camera.doorbell as well for the URL but i kept getting no entity_id and 404 errors in the log. i manually formatted the homekit:// URL as above.

when i start things up, i get Could not find codec parameters for stream 0 (Video: h264, 1 reference frame, none): unspecified size

i tried increasing the analyzeduration and probesize values as suggested, but that didn't work either.

the information ffmpeg is able to get out of go2rtc is:

[tcp @ 0x557adb5cd580] Successfully connected to 127.0.0.1 port 8554
[rtsp @ 0x557adb5ca540] SDP:
v=0
o=- 1 1 IN IP4 0.0.0.0
s=go2rtc/1.8.4
c=IN IP4 0.0.0.0
t=0 0
m=video 0 RTP/AVP 96
a=rtpmap:96 H264/90000
a=fmtp:96 profile-level-id=4D001F
a=control:trackID=0
@AlexxIT AlexxIT added the question Further information is requested label May 3, 2024
@AlexxIT
Copy link
Owner

AlexxIT commented May 3, 2024

Is the Frigate container running with the network host setting?

@visigoth
Copy link
Author

apologies for taking a while to respond, but i don't get a lot of time to look into home networking issues.

for my case, i am running frigate along with other containers on a MAC VLAN network - i.e. each container has its own virtual NIC that shows up on the physical network.

@AlexxIT
Copy link
Owner

AlexxIT commented May 14, 2024

Go2rtc should run in the host network to get the HomeKit protocol working

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants