s60sc / ESP32-CAM_MJPEG2SD

ESP32 Camera motion capture application to record JPEGs to SD card as AVI files and stream to browser as MJPEG. If a microphone is installed then a WAV file is also created. Files can be uploaded via FTP or downloaded to browser.
GNU Affero General Public License v3.0
871 stars 209 forks source link

[FEATURE REQUEST] ONVIF support? #480

Open TheWISPRer opened 4 days ago

TheWISPRer commented 4 days ago

I was wondering if y'all had tried adding ONVIF support so that these cameras can be added to common NVR platforms. It would allow greater flexibility and integration into larger systems using a standard protocol.

I am trying to integrate this myself, but think that this is beyond my skillset. Figured I'd go ahead and open a feature request issue JIC. Will update if I am able to succeed in this or not.

s60sc commented 3 days ago

could try using go2rtc to convert mjpeg/wav to onvif https://github.com/s60sc/ESP32-CAM_MJPEG2SD#stream-to-nvr

TheWISPRer commented 3 days ago

Very interesting. Did not notice that before. The repo for go2rtc that I found (https://github.com/AlexxIT/go2rtc) does seem to support ONVIF/declare a SOAP endpoint. Handy that it's already built in.

Will give this a try this week and update with findings.

TheWISPRer commented 2 days ago

Well, looks like that will not fit in the use case examples of this request. ONVIF is really just a discovery protocol that provides endpoint information to the main unit from the camera. It typically utilizes an RTSP stream, but ONVIF can support direct MJPEG on most clients, so would not necessarily need conversion. That go2rtc library adds a bunch of nice, but unnecessary bloat for this particular application requirement.

Attempting to add WSD and SOAP so that it is natively discoverable through ONVIF without any middleware. Will update on progress. Definitely not my typical wheelhouse, so don't hold your breath.