I have set up a couple of tapo c320ws cameras with frigate like this, as indicated by the frigate docs:
go2rtc:
streams:
tapo_test:
- rtsp://xx:xx@ip:554/stream1
- "ffmpeg:tapo_test#audio=opus"
tapo_test_sub:
- rtsp://xx:xx@ip:554/stream2
cameras:
tapo_test:
ffmpeg:
output_args:
record: preset-record-generic-audio-copy
inputs:
- path: rtsp://127.0.0.1:8554/tapo_test
input_args: preset-rtsp-restream
roles:
- record
- path: rtsp://127.0.0.1:8554/tapo_test_sub
input_args: preset-rtsp-restream
roles:
- detect
live:
stream_name: tapo_test
I have audio when watching the video in the frigate UI, when the dropdown is set to webrtc
I have video feed but without audio in feed that is passed through to my main home assistant machine. Same for the recordings in Frigate, correct video but without audio.
Here is the info screen from the go2rtc page:
{
"producers": [
{
"type": "RTSP source",
"url": "rtsp://IP:554/stream1/",
"remote_addr": "IP:554",
"user_agent": "go2rtc/1.2.0",
"medias": [
"video, sendonly, 96 H264/90000",
"audio, sendonly, 8 PCMA/8000"
],
"tracks": [
"96 H264/90000, sinks=1",
"8 PCMA/8000, sinks=0"
],
"recv": 2934365
},
{
"url": "ffmpeg:tapo_test#audio=opus"
}
],
"consumers": [
{
"type": "RTSP client",
"url": "rtsp://127.0.0.1:8554/tapo_test",
"remote_addr": "127.0.0.1:48408",
"user_agent": "FFmpeg Frigate/0.12.1-367d724",
"medias": [
"video, recvonly, 96 H264/90000",
"audio, recvonly, 0 MPEG4-GENERIC/0"
],
"tracks": [
"96 H264/90000, sinks=1"
],
"send": 2404263
}
]
}
It seems to like the MPEG4 codec, although input is in pcma.
I have also tried "ffmpeg:tapo_test#audio=pcma"
which does not work unfortunately.
Adding the codecs at the end of the stream name like this:
inputs:
- path: rtsp://127.0.0.1:8554/tapo_test?video=h264&audio=pcma
This works momentarily, i see the correct stream in the go2rtc info screen but frigate keeps crashing.
Has anyone managed to set it up, or can help me out looking at my code?