blakeblackshear / frigate

NVR with realtime local object detection for IP cameras
https://frigate.video
MIT License
18.18k stars 1.66k forks source link

[Camera Support]: KD110 Kasa doorbell camera #8020

Closed duindain closed 11 months ago

duindain commented 11 months ago

Describe the problem you are having

I'm trying to integrate this camera KD110 into Frigate to use it with HomeAssistant, I've managed to get it working in HomeAssistant using Scrypted but it seems thats for HomeKit not Frigate, so I'm retrying with just adding the camera into frigate first then i can use the existing plugin for frigate in HomeAssistant

Using this string in scripted for FFMPEG camera config it connects and can stream

-headers "Authorization: Basic ***[Base 64 encoded password the rebase64 encoded email]***" -f h264 -i https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd

The camera doesn't work with username:password@ip in the url unfortunately but with the header injected does work

Adding into the Frigate config doesn't work so far

doorcam: 
      - "ffmpeg:https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd#video=h264#hardware#audio=g711#header=Authorization: Basic ***[Base 64 encoded password the rebase64 encoded email]***"

I got the pattern for header injection from https://github.com/AlexxIT/go2rtc/issues/64 for go2rtc

I'm not sure if its failing on the go2rtc config or the separate camera config lower, I've tried quite a few combinations so far without any luck

I suspect I'm configuring it completely wrong as its a combination of things that were already working and random help doco and camera configs from various googling

Would be great to hear any other pointers about my config too, i am waiting for shipping on a google coral so don't have that in there yet, and no gpu in this system, the other 6 cameras are reolink 811A's and they show up ok

Thanks

Version

0.12.1-367d724

Frigate config file

mqtt:
  enabled: False

database:
  path: /db/frigate.db

go2rtc:
  streams:
    username: "viewer"
    password: "acamerapassword"

    camera1:
      - rtsp://viewer:acamerapassword@192.168.3.101:554/h265Preview_01_main
      - "ffmpeg:camera1#video=h264#hardware#audio=copy#audio=opus"
    camera2:
      - rtsp://viewer:acamerapassword@192.168.3.102:554/h265Preview_01_main
      - "ffmpeg:camera2#video=h264#hardware#audio=copy#audio=opus"
    camera3: 
      - rtsp://viewer:acamerapassword@192.168.3.103:554/h265Preview_01_main
      - "ffmpeg:camera3#video=h264#hardware#audio=copy#audio=opus"
    camera4:
      - rtsp://viewer:acamerapassword@192.168.3.104:554/h265Preview_01_main
      - "ffmpeg:camera4#video=h264#hardware#audio=copy#audio=opus"
    camera5:
      - rtsp://viewer:acamerapassword@192.168.3.105:554/h265Preview_01_main
      - "ffmpeg:camera5#video=h264#hardware#audio=copy#audio=opus"
    camera6:
      - rtsp://viewer:acamerapassword@192.168.3.106:554/h265Preview_01_main
      - "ffmpeg:camera6#video=h264#hardware#audio=copy#audio=opus"
    doorcam: 
      - "ffmpeg:https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd#video=h264#hardware#audio=g711#header=Authorization: Basic ***[Base 64 encoded password the rebase64 encoded email]***"

birdseye:
  enabled: True
  mode: continuous
  restream: False
  width: 1920
  height: 1080
  quality: 4

rtmp:
  enabled: false

snapshots:
  enabled: True
  clean_copy: False
  bounding_box: True
  retain:
    default: 60

timestamp_style:
  format: "%d/%m/%Y %H:%M:%S"

detect:
  fps: 5
  enabled: true

record:
  enabled: True
  retain:
    days: 7
    mode: motion
  events:
    retain:
      default: 14
      mode: active_objects

cameras:
  camera1:
    ffmpeg:
      inputs:
        - path: rtsp://127.0.0.1:8554/camera1?video=copy&audio=aac
          roles:
            - detect   
            - record
    detect:
      width: 3840
      height: 2160
  camera2:
    ffmpeg:
      inputs:
        - path: rtsp://127.0.0.1:8554/camera2?video=copy&audio=aac
          roles:
            - detect   
            - record
    detect:
      width: 3840
      height: 2160
  camera3:
    ffmpeg:
      inputs:
        - path: rtsp://127.0.0.1:8554/camera3?video=copy&audio=aac
          roles:
            - detect   
            - record
    detect:
      width: 3840
      height: 2160
  camera4:
    ffmpeg:
      inputs:
        - path: rtsp://127.0.0.1:8554/camera4?video=copy&audio=aac
          roles:
            - detect   
            - record
    detect:
      width: 3840
      height: 2160
  camera5:
    ffmpeg:
      inputs:
        - path: rtsp://127.0.0.1:8554/camera5?video=copy&audio=aac
          roles:
            - detect   
            - record
    detect:
      width: 3840
      height: 2160
  camera6:
    ffmpeg:
      inputs:
        - path: rtsp://127.0.0.1:8554/camera6?video=copy&audio=aac
          roles:
            - detect   
            - record
    detect:
      width: 3840
      height: 2160
  doorcam:
    ffmpeg:
      inputs:
        - path: "https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd#video=h264#hardware#audio=g711#header=Authorization: Basic ***[Base 64 encoded password the rebase64 encoded email]***"
          roles:
            - detect   
            - record
    detect:
      width: 1920
      height: 1080

Relevant log output

2023-10-02 10:51:24.454512272  [2023-10-02 10:51:24] frigate.app                    INFO    : Capture process started for doorcam: 768
2023-10-02 10:51:25.824997666  [2023-10-02 10:51:25] frigate.video                  ERROR   : doorcam: Unable to read frames from ffmpeg process.
2023-10-02 10:51:25.825067928  [2023-10-02 10:51:25] frigate.video                  ERROR   : doorcam: ffmpeg process is not running. exiting capture thread...
2023-10-02 10:51:37.519961139  [2023-10-02 10:51:37] frigate.util                   ERROR   : Unable to poll intel GPU stats: No device filter specified and no discrete/integrated i915 devices found
2023-10-02 10:51:37.519963844  
2023-10-02 10:51:44.463721475  [2023-10-02 10:51:44] watchdog.doorcam               ERROR   : Ffmpeg process crashed unexpectedly for doorcam.
2023-10-02 10:51:44.463812445  [2023-10-02 10:51:44] watchdog.doorcam               ERROR   : The following ffmpeg logs include the last 100 lines prior to exit.
2023-10-02 10:51:44.463908906  [2023-10-02 10:51:44] ffmpeg.doorcam.detect          ERROR   : [https @ 0x557c8785b140] HTTP error 401 Unauthorized
2023-10-02 10:51:44.463996971  [2023-10-02 10:51:44] ffmpeg.doorcam.detect          ERROR   : https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd#video=h264#hardware#audio=g711#header=Authorization: Basic ***[Base 64 encoded password the rebase64 encoded email]***: Server returned 401 Unauthorized (authorization failed)

FFprobe output from your camera

ffprobe -headers "Authorization: Basic ***[Base 64 encoded password the rebase64 encoded email]***" -f h264 -i https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd
[https @ 0x5586ff5e1bc0] No trailing CRLF found in HTTP header. Adding it.
[https @ 0x5586ff5e1bc0] HTTP error 503 Service Unavailable
https://192.168.2.26:19443/https/stream/mixed?video=h264: Server returned 5XX Server Error reply

Frigate stats

{"camera1":{"camera_fps":5.1,"capture_pid":738,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":743,"pid":727,"process_fps":5.1,"skipped_fps":0.0},"camera2":{"camera_fps":5.0,"capture_pid":742,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":748,"pid":729,"process_fps":5.0,"skipped_fps":0.0},"camera3":{"camera_fps":5.0,"capture_pid":746,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":753,"pid":730,"process_fps":5.0,"skipped_fps":0.0},"camera4":{"camera_fps":5.0,"capture_pid":752,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":758,"pid":732,"process_fps":5.0,"skipped_fps":0.0},"camera5":{"camera_fps":5.1,"capture_pid":759,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":764,"pid":734,"process_fps":5.1,"skipped_fps":0.0},"camera6":{"camera_fps":5.0,"capture_pid":763,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":770,"pid":735,"process_fps":5.0,"skipped_fps":0.0},"cpu_usages":{"%Cpu(s):":{"cpu":"id,","mem":"0.1"},"1":{"cpu":"0.0","mem":"0.0"},"110":{"cpu":"0.0","mem":"0.0"},"134":{"cpu":"0.0","mem":"0.0"},"135":{"cpu":"0.0","mem":"0.0"},"136":{"cpu":"0.0","mem":"0.0"},"137":{"cpu":"0.0","mem":"0.0"},"145":{"cpu":"0.0","mem":"0.0"},"15":{"cpu":"0.0","mem":"0.0"},"158":{"cpu":"0.0","mem":"0.0"},"17":{"cpu":"0.0","mem":"0.0"},"184":{"cpu":"0.0","mem":"0.0"},"1906":{"cpu":"0.0","mem":"0.0"},"1943":{"cpu":"0.0","mem":"0.0"},"1947":{"cpu":"0.0","mem":"0.0"},"225":{"cpu":"0.0","mem":"0.0"},"24":{"cpu":"0.0","mem":"0.0"},"25":{"cpu":"0.0","mem":"0.0"},"26":{"cpu":"0.0","mem":"0.0"},"27":{"cpu":"0.0","mem":"0.0"},"275":{"cpu":"0.0","mem":"0.0"},"28":{"cpu":"0.0","mem":"0.0"},"29":{"cpu":"0.0","mem":"0.0"},"30":{"cpu":"0.0","mem":"0.0"},"31":{"cpu":"0.0","mem":"0.0"},"32":{"cpu":"0.0","mem":"0.0"},"321":{"cpu":"0.0","mem":"0.0"},"356":{"cpu":"0.0","mem":"0.0"},"392":{"cpu":"0.0","mem":"0.0"},"41":{"cpu":"0.0","mem":"0.0"},"42":{"cpu":"0.0","mem":"0.0"},"420":{"cpu":"0.0","mem":"0.0"},"455":{"cpu":"0.0","mem":"0.0"},"493":{"cpu":"0.0","mem":"0.0"},"533":{"cpu":"0.0","mem":"0.0"},"716":{"cpu":"0.0","mem":"0.2"},"721":{"cpu":"0.0","mem":"0.0"},"722":{"cpu":"0.0","mem":"0.5"},"724":{"cpu":"4.7","mem":"0.5"},"727":{"cpu":"0.7","mem":"0.5"},"728":{"cpu":"0.0","mem":"0.1"},"729":{"cpu":"1.0","mem":"0.5"},"730":{"cpu":"0.7","mem":"0.5"},"731":{"cpu":"0.0","mem":"0.1"},"732":{"cpu":"0.3","mem":"0.5"},"733":{"cpu":"0.0","mem":"0.1"},"734":{"cpu":"0.7","mem":"0.5"},"735":{"cpu":"0.3","mem":"0.5"},"736":{"cpu":"0.0","mem":"0.1"},"737":{"cpu":"0.0","mem":"0.4"},"738":{"cpu":"6.6","mem":"0.5"},"741":{"cpu":"0.0","mem":"0.1"},"742":{"cpu":"7.6","mem":"0.5"},"743":{"cpu":"25.6","mem":"0.3"},"746":{"cpu":"7.6","mem":"0.5"},"747":{"cpu":"0.0","mem":"0.1"},"748":{"cpu":"29.6","mem":"0.3"},"752":{"cpu":"6.6","mem":"0.5"},"753":{"cpu":"27.6","mem":"0.3"},"757":{"cpu":"0.0","mem":"0.1"},"758":{"cpu":"26.9","mem":"0.3"},"759":{"cpu":"7.0","mem":"0.5"},"763":{"cpu":"8.0","mem":"0.5"},"764":{"cpu":"28.2","mem":"0.3"},"768":{"cpu":"0.0","mem":"0.1"},"769":{"cpu":"0.3","mem":"0.4"},"770":{"cpu":"29.2","mem":"0.3"},"80":{"cpu":"0.0","mem":"0.0"},"81":{"cpu":"0.0","mem":"0.0"},"82":{"cpu":"0.0","mem":"0.0"},"89":{"cpu":"21.3","mem":"0.1"},"97":{"cpu":"0.0","mem":"0.0"},"98":{"cpu":"2.0","mem":"0.6"},"MiB":{"cpu":"18474.1","mem":"avail"},"PID":{"cpu":"%CPU","mem":"%MEM"},"Tasks:":{"cpu":"stopped,","mem":"0"},"top":{"cpu":"0","mem":"users,"}},"detection_fps":0.0,"detectors":{"cpu":{"detection_start":0.0,"inference_speed":31.95,"pid":722}},"doorcam":{"camera_fps":0.0,"capture_pid":769,"detection_enabled":1,"detection_fps":0.0,"ffmpeg_pid":1925,"pid":737,"process_fps":0.0,"skipped_fps":0.0},"service":{"last_updated":1696206953,"latest_version":"0.12.1","storage":{"/dev/shm":{"free":708.7,"mount_type":"tmpfs","total":786.4,"used":77.8},"/media/frigate/clips":{"free":1994188.3,"mount_type":"btrfs","total":2000398.9,"used":5113.4},"/media/frigate/recordings":{"free":1994188.3,"mount_type":"btrfs","total":2000398.9,"used":5113.4},"/tmp/cache":{"free":943.3,"mount_type":"tmpfs","total":1000.0,"used":56.7}},"temperatures":{},"uptime":604,"version":"0.12.1-367d724"}}

Operating system

Debian

Install method

Docker Compose

Coral version

CPU (no coral)

Network connection

Wired

Camera make and model

Kasa KD110

Any other information that may be helpful

This is the console output from Scrypted FFMPEG camera plugin where the camera successfully connects and streams, though the audio is broken it seems

linux x64 #1 SMP PREEMPT_DYNAMIC Wed Aug 16 18:11:54 UTC 2023 server version: 0.55.0 plugin version: @scrypted/ffmpeg-camera 0.0.22 full ######################## 10/1/2023, 2:06:26 PM ######################## [HomeKit]: Device is in accessory mode and is online. HomeKit services are being published. Rebroadcast Plugin: prebuffer sessions starting in 5 seconds Rebroadcast Plugin: Stream 1 prebuffer session started Rebroadcast Plugin: Stream 1 prebuffer session starting Rebroadcast Plugin: -hide_banner -fflags +genpts -headers Authorization: Basic [Base 64 encoded password the rebase64 encoded email] -f h264 -i https:[REDACTED] -rtsp_transport tcp -vcodec copy -acodec copy -f rtsp rtsp://127.0.0.1:35977/56cde26392c964a4 Rebroadcast Plugin: https @ 0x561332797340: No trailing CRLF found in HTTP header. Adding it. Rebroadcast Plugin: Input #0, h264, from 'https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd': Rebroadcast Plugin: Duration: N/A, bitrate: N/A Rebroadcast Plugin: Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1920x1080, 15 fps, 15 tbr, 1200k tbn, 30 tbc Rebroadcast Plugin: No audio stream detected. Rebroadcast Plugin: Output #0, rtsp, to 'rtsp://127.0.0.1:35977/56cde26392c964a4':

Rebroadcast Plugin: encoder : Lavf58.76.100 Rebroadcast Plugin: Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1920x1080, q=2-31, 15 fps, 15 tbr, 90k tbn, 15 tbc Rebroadcast Plugin: Stream mapping: Rebroadcast Plugin: Stream #0:0 -> #0:0 (copy) Rebroadcast Plugin: Press [q] to stop, [?] for help Rebroadcast Plugin: [rtsp @ 0x561332ac0040] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly Rebroadcast Plugin: frame= 1 fps=0.0 q=-1.0 size=N/A time=00:00:00.00 bitrate=N/A speed=N/A Rebroadcast Plugin: video/audio detected, discarding further input ######################## 10/1/2023, 2:25:15 PM ######################## Rebroadcast Plugin: sending prebuffer 6000 Rebroadcast Plugin: Stream 1 active rebroadcast clients: 1 Rebroadcast Plugin: Stream 1 active rebroadcast clients: 0 ######################## 10/1/2023, 2:50:49 PM ######################## Rebroadcast Plugin: sending prebuffer 6000 Rebroadcast Plugin: sending prebuffer 6000 ######################## 10/1/2023, 3:12:08 PM ######################## Rebroadcast Plugin: sending prebuffer 6000 ######################## 10/2/2023, 2:00:15 AM ######################## Rebroadcast Plugin: prebuffer sessions starting in 5 seconds Rebroadcast Plugin: Stream 1 prebuffer session started Rebroadcast Plugin: Stream 1 prebuffer session starting Rebroadcast Plugin: -hide_banner -fflags +genpts -headers Authorization: Basic [Base 64 encoded password the rebase64 encoded email] -f h264 -i https:[REDACTED] -rtsp_transport tcp -vcodec copy -acodec copy -f rtsp rtsp://127.0.0.1:42875/980411646ee4cf15 Rebroadcast Plugin: [https @ 0x561cc8996340] No trailing CRLF found in HTTP header. Adding it. Rebroadcast Plugin: Input #0, h264, from 'https://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd': Rebroadcast Plugin: Duration: N/A, bitrate: N/A Rebroadcast Plugin: Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1920x1080, Rebroadcast Plugin: 14 fps, 14 tbr, 1200k tbn, 28 tbc Rebroadcast Plugin: No audio stream detected. Rebroadcast Plugin: Output #0, rtsp, to 'rtsp://127.0.0.1:42875/980411646ee4cf15':

Rebroadcast Plugin: encoder : Lavf58.76.100 Rebroadcast Plugin: Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1920x1080, q=2-31, 14 fps, 14 tbr, 90k tbn, 14 tbc Rebroadcast Plugin: Stream mapping: Rebroadcast Plugin: Stream #0:0 -> #0:0 (copy) Rebroadcast Plugin: Press [q] to stop, [?] for help Rebroadcast Plugin: [rtsp @ 0x561cc8ce0880] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly Rebroadcast Plugin: frame= 1 fps=0.0 q=-1.0 size=N/A time=00:00:00.00 bitrate=N/A speed=N/A Rebroadcast Plugin: video/audio detected, discarding further input ######################## 10/2/2023, 10:56:04 AM ######################## Rebroadcast Plugin: sending prebuffer 6000 ######################## 10/2/2023, 11:18:19 AM ######################## Rebroadcast Plugin: sending prebuffer 6000 [WebRTC Plugin]: signalingState have-remote-offer [WebRTC Plugin]: iceGatheringState gathering [WebRTC Plugin]: signalingState stable [WebRTC Plugin]: connectionState connecting [WebRTC Plugin]: iceConnectionState checking [WebRTC Plugin]: waiting ice connected [WebRTC Plugin]: iceConnectionState completed [WebRTC Plugin]: iceGatheringState complete [WebRTC Plugin]: iceConnectionState connected [WebRTC Plugin]: connectionState connected [WebRTC Plugin]: ice transport { ipv4: true, isLocalNetwork: true, destinationId: '192.168.2.31' } [WebRTC Plugin]: Connection is local network: true [WebRTC Plugin]: done waiting ice connected Rebroadcast Plugin: Selected stream Stream 1 Rebroadcast Plugin: sending prebuffer 3995.5 Rebroadcast Plugin: Stream 1 active rebroadcast clients: 1 RTC Connection Bridge: Client Stream Profile { RTC Connection Bridge: transcodeBaseline: false, RTC Connection Bridge: sessionSupportsH264High: true, RTC Connection Bridge: maximumCompatibilityMode: false, RTC Connection Bridge: userAgent: 'Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/118.0', RTC Connection Bridge: capabilities: { RTC Connection Bridge: audio: { codecs: [Array], headerExtensions: [Array] }, RTC Connection Bridge: video: { codecs: [Array], headerExtensions: [Array] }

RTC Connection Bridge: screen: { devicePixelRatio: 1, width: 2560, height: 1440 }

RTC Connection Bridge: rtsp/tcp h264 RTC Connection Bridge: a/v h264 opus found h264 undefined RTC Connection Bridge: audio section not found in sdp. RTC Connection Bridge: bypassing ffmpeg, perfect codecs RTC Connection Bridge: first video packet 730 [WebRTC Plugin]: signalingState closed [WebRTC Plugin]: connectionState closed [WebRTC Plugin]: iceConnectionState closed Rebroadcast Plugin: Stream 1 active rebroadcast clients: 0

I've tested access through the frigate docker container using

docker run -it --net container:frigate nicolaka/netshoot f51e51c4b7d0  ~  ping 192.168.2.26 PING 192.168.2.26 (192.168.2.26) 56(84) bytes of data. 64 bytes from 192.168.2.26: icmp_seq=1 ttl=63 time=3.07 ms 64 bytes from 192.168.2.26: icmp_seq=2 ttl=63 time=2.96 ms 64 bytes from 192.168.2.26: icmp_seq=3 ttl=63 time=2.30 ms 64 bytes from 192.168.2.26: icmp_seq=4 ttl=63 time=2.01 ms

nmap shows port 9999 open from the host to the camera and from the docker container to the camera, i suspect thats ok as authenticating within scripted still works on port 19443 regardless

NickM-27 commented 11 months ago

You can not use the ffmpeg: for this as that is the ffmpeg source, meanwhile the issue you linked said the #headers parameter is only supported for the http/https source

duindain commented 11 months ago

Thanks @NickM-27 I didn't notice that when reading it yesturday

I had to change the version of go2rtc to support https stream with insecure cert using the httpx protocol

Ive changed the config a few times this morning the latest is this

doorcam: 
      - "kasa://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd#header=Authorization: Basic Base 64 encoded password the rebase64 encoded email]"
      - "ffmpeg:doorcam#video=h264#audio=opus"

I did try this first

doorcam: 
      - "httpx://192.168.2.26:19443/https/stream/mixed?video=h264&audio=g711&resolution=hd#header=Authorization: Basic Base 64 encoded password the rebase64 encoded email]"
      - "ffmpeg:doorcam#video=h264#audio=opus"

I'm currently getting in the go2rtc logs

2023-10-03 07:27:04.704917922  [INFO] Preparing go2rtc config...
2023-10-03 07:27:04.862217433  [WARN] Using go2rtc binary from '/config/go2rtc' instead of the embedded one
2023-10-03 07:27:04.862221591  [INFO] Starting go2rtc...
2023-10-03 07:27:04.920456907  07:27:04.920 INF go2rtc version 1.7.1 linux/amd64
2023-10-03 07:27:04.920614674  07:27:04.920 INF [api] listen addr=0.0.0.0:1984
2023-10-03 07:27:04.920803279  07:27:04.920 INF [rtsp] listen addr=0.0.0.0:8554
2023-10-03 07:27:04.920898017  07:27:04.920 INF [webrtc] listen addr=0.0.0.0:8555/tcp
2023-10-03 07:27:11.058046652  07:27:11.057 WRN [rtsp] error="streams: unexpected EOF, exec: exit status 1" stream=doorcam
2023-10-03 07:27:14.705443818  [INFO] Starting go2rtc healthcheck service...
2023-10-03 07:27:16.171171378  07:27:16.171 WRN [rtsp] error="streams: unexpected EOF, exec: exit status 1" stream=doorcam
2023-10-03 07:30:55.918648675  07:30:55.918 WRN github.com/AlexxIT/go2rtc/internal/rtsp/rtsp.go:225 > error="write tcp 127.0.0.1:8554->127.0.0.1:55400: write: broken pipe"

The frigate logs show invalid data error

2023-10-03 07:27:05.470760115  [2023-10-03 07:27:05] frigate.app                    INFO    : Capture process started for doorcam: 769
2023-10-03 07:27:10.614914040  [2023-10-03 07:27:10] frigate.video                  ERROR   : doorcam: Unable to read frames from ffmpeg process.
2023-10-03 07:27:10.615572810  [2023-10-03 07:27:10] frigate.video                  ERROR   : doorcam: ffmpeg process is not running. exiting capture thread...
2023-10-03 07:27:25.486941488  [2023-10-03 07:27:25] watchdog.doorcam               ERROR   : Ffmpeg process crashed unexpectedly for doorcam.
2023-10-03 07:27:25.487003545  [2023-10-03 07:27:25] watchdog.doorcam               ERROR   : The following ffmpeg logs include the last 100 lines prior to exit.
2023-10-03 07:27:25.487052187  [2023-10-03 07:27:25] ffmpeg.doorcam.detect          ERROR   : rtsp://127.0.0.1:8554/doorcam?video=copy: Invalid data found when processing input

I've tried removing all the audio config from the stream to decomplicate it but that had the same issue and log messages on both sections

NickM-27 commented 11 months ago

I don't think kasa:// is a supported protocol / input type in go2rtc? I'd suggest posting logs with httpx://

duindain commented 11 months ago

Its new and the logs were the same between both https://github.com/AlexxIT/go2rtc#source-kasa

NickM-27 commented 11 months ago

I see, regardless these errors are occurring in go2rtc so I think it would be best to make an issue on that repo

duindain commented 11 months ago

Thanks, I've posted the issue there now, fingers crossed Ill close this with info to help others if its solved soon, thx for your help @NickM-27

Spectre5 commented 11 months ago

Looks like this is working now per the linked issue.

duindain commented 11 months ago

Yes its working thanks to troubleshooting from @AlexxIT Thanks everyone for taking a look