I have been going back and forth on a few topics trying to find the right settings to enable an ESP32 cam to stream to Frigate so I thought I would summarise my findings here. It’s a very basic camera but I wanted to play around before my proper security cameras arrive from Amazon. To my surprise the detection even on a low res video is quite good for alerts - will think of where I could use this project as I initially thought it to be a throw away…
My setup involves a HAOS on a Proxmox VM and a Frigate Docker image running on a Proxmox LXC container. I then have the Frigate NVR Proxy add on within HA. I’m passing through a Google Coral to enable object detection through to the Frigate container - yes I know, I finally found stock in Berrybase in Germany…
On the ESP32 cam module I’m running ESP Home firmware:
That is not a ‘must’ …benefit (for me) with go2rtc is that I can have multiple end-use from the cam without issues over rtsp direct to cam.
What is not stable?
Yeah, that is why i use go2rtc, too. The streaming to frigate is unstable, including to go2rtc. I am not yet familiar enoigh with the frigate setup to know how your settings are modified for the new use of go2rtc. i was hoping to learn from seeing if you did that. No worries if you have kept this configuration. It is possible that my esp32 cam connection is the caise of the instabiloty. i need to do more debugging.
I’ve not made any configuration changes to my setup despite upgrading Frigate a few times. Still works well and I receive notifications based on people walking through the detection zone.
On the overview frigate cameras
No frame have been received, check error log
log
2023-09-01 19:58:18.405724558 [INFO] Preparing Frigate...
2023-09-01 19:58:18.444797210 [INFO] Starting Frigate...
2023-09-01 19:58:21.640960775 [2023-09-01 19:58:21] frigate.app INFO : Starting Frigate (0.13.0-6801981)
2023-09-01 19:58:21.703655335 [2023-09-01 19:58:21] peewee_migrate.logs INFO : Starting migrations
2023-09-01 19:58:21.713839747 [2023-09-01 19:58:21] peewee_migrate.logs INFO : There is nothing to migrate
2023-09-01 19:58:21.911033476 [2023-09-01 19:58:21] frigate.app INFO : Recording process started: 223
2023-09-01 19:58:21.916387783 [2023-09-01 19:58:21] frigate.app INFO : go2rtc process pid: 100
2023-09-01 19:58:21.967923079 [2023-09-01 19:58:21] frigate.app INFO : Output process started: 234
2023-09-01 19:58:21.989446898 [2023-09-01 19:58:21] detector.cpu INFO : Starting detection process: 233
2023-09-01 19:58:21.990147173 [2023-09-01 19:58:21] frigate.detectors WARNING : CPU detectors are not recommended and should only be used for testing or for trial purposes.
2023-09-01 19:58:21.997940084 [2023-09-01 19:58:21] frigate.app INFO : Camera processor started for hallen: 238
2023-09-01 19:58:22.009930684 [2023-09-01 19:58:22] frigate.app INFO : Camera processor started for kamera2: 240
2023-09-01 19:58:22.024535026 [2023-09-01 19:58:22] frigate.app INFO : Capture process started for hallen: 242
2023-09-01 19:58:22.032814735 [2023-09-01 19:58:22] frigate.app INFO : Capture process started for kamera2: 243
It looks like the configuration has changed: Configuration File | Frigate - namely where the retain is referenced and named.
record:
# Optional: Enable recording (default: shown below)
# WARNING: If recording is disabled in the config, turning it on via
# the UI or MQTT later will have no effect.
enabled: False
# Optional: Number of minutes to wait between cleanup runs (default: shown below)
# This can be used to reduce the frequency of deleting recording segments from disk if you want to minimize i/o
expire_interval: 60
# Optional: Retention settings for recording
retain:
# Optional: Number of days to retain recordings regardless of events (default: shown below)
# NOTE: This should be set to 0 and retention should be defined in events section below
# if you only want to retain recordings of events.
days: 0
# Optional: Mode for retention. Available options are: all, motion, and active_objects
# all - save all recording segments regardless of activity
# motion - save all recordings segments with any detected motion
# active_objects - save all recording segments with active/moving objects
# NOTE: this mode only applies when the days setting above is greater than 0
mode: all
# Optional: Event recording settings
Hi, i’m using your exactly configuration on my setup and it works, but i noticed that esp32 cam use an exagerate amount of processor resources ( on a PC intel i5 with hassos, i also have Coral TPU connected). Is it “normal”?
Hi bro. Is your config still works?
I have a problem, my frigate every time gives error
frigate.video ERROR : camera: Unable to read frames from ffmpeg process.
frigate.video ERROR : camera: ffmpeg process is not running. exiting capture thread...
even I installed allready to esp32 cam firmware supported RTSP stream, still same mistake