Open curtishall opened 7 months ago
@curtishall is that https://github.com/agsh/onvif/blob/master/examples/example6.js ? Do you have your own patches on top of that?
Let's take this https://github.com/agsh/onvif/blob/master/examples/example6.js ,
And then some frontend magic.
@curtishall is that https://github.com/agsh/onvif/blob/master/examples/example6.js ? Do you have your own patches on top of that?
I do not
Let's take this https://github.com/agsh/onvif/blob/master/examples/example6.js ,
- tweak to take command line arguments for HOSTNAME, PASSWORD etc
- make it figure out intelligently EVENT_RECEIVER_IP_ADDRESS, EVENT_RECEIVER_PORT from the host it's running on
- give it a sensible name and put the changed script into misc/onvif/ alongside getRtspUrls.js and others
And then some frontend magic.
I'll get started working on that 👍🏾
Currently the (old) onvif_tool (out of spec) only supported motion events. Edge based motion events (camera triggered motion events) are overly sensitive and really not that useful for customers when they can use our own motion detection built into our software already.
However more and more cameras, even cheap ones, are starting to support basic AI (person / vehicle / catdog / etc). We should expand on our existing nodejs onvif code base and detect the available event subscription options and return that when queried. In the web UI the end user can select the event type(s) to start recording (respecting the pre/post recording that we have now for onvif triggering (https://github.com/bluecherrydvr/bluecherry-apps/blob/31fdffcd61fc178c05da566cc66887937cf004f8/www/template/ajax/deviceschedule.php#L43)
The nodejs code returns the following when connecting to a ONVIF supported camera that has multiple event types:
When a person is detected:
When the person is no longer detected:
Note: The camera also throws motion detection too....we would encourage users NOT to select motion. Here is the motion alerts from the same event above:
Full log (all events pulled):