ONVIF motion events notifications to NVR

Forum for questions and support relating to the 1.30.x releases only.
mattj
Posts: 25
Joined: Sun May 06, 2007 12:49 am

ONVIF motion events notifications to NVR

Post by mattj »

Does anyone know if there are plans to add support for motion event notifications from ONVIF compliant IP cameras? The benefit would be that the cameras handle the work of motion detection, unloading the NVR. Very high res ONVIF cameras are cheap now ($125/ea for 1920p resolution) so this would be a great feature to have.

This guy seems to have figured out how to do it, though I haven't been able to find a copy of his script:

https://altaroca.wordpress.com/2014/11/ ... oneminder/
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: ONVIF motion events notifications to NVR

Post by asker »

I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.

Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
mattj
Posts: 25
Joined: Sun May 06, 2007 12:49 am

Re: ONVIF motion events notifications to NVR

Post by mattj »

Thank you! This made my day. Do you know off-hand if code changes and a re-compile to ZM are necessary to make it work with this perl script?

I have an ONVIF camera coming this weekend and I'm going to try to figure out how to get this working. I'm technical, but brand new to ZM and not yet familiar with how to integrate add-ons like this.
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: ONVIF motion events notifications to NVR

Post by asker »

The fact that this script is not yet in ZM master and is in the author's tree may imply its not fully operational and/or may have gotchas. You may want to directly ask the author.

In general, it looks like this script is registering with the available ONVIF cameras ZoneMinder discovered and is waiting for motion events. If they are received, the author is passing them on to ZM's existing trigger mechanism to start recording. Such operations don't need ZM to be recompiled (see here for a basic tutorial I wrote a long time ago about how ZM triggers work and how your "script" can attach to it, in this case this onvif trigger)
- but I have no idea if this codebase expects certain ONVIF functions in ZM that are not in ZM master.
I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.

Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
mattj
Posts: 25
Joined: Sun May 06, 2007 12:49 am

Re: ONVIF motion events notifications to NVR

Post by mattj »

Thank you very much for the information and the link! I actually stumbled on your pages from the link in your signature and started reading through it, you've got some great info there. I'll dig into it more tonight after work.

I'll upgrade my current 1.29 to 1.30 to get a build with ONVIF features turned on, then see if I can get the script to work. I'm guessing I just execute the script manually after ZM is running? I'm trying to learn as much as I can, maybe I can contribute somehow if I can get it working with the cameras that I ordered.

I sent a note to the author through his wordpress blog, hopefully he will respond. :)

Thanks again!
Khurram
Posts: 46
Joined: Tue Oct 09, 2007 5:29 pm
Location: Lahore, Pakistan

Re: ONVIF motion events notifications to NVR

Post by Khurram »

This thread is very interesting. I just started with adding ip cameras (ONVIF compliant) to my zoneminder system. If the cameras can somehow push motion detection events to zoneminder (instead of zoneminder doing the calcs for modect), it would be excellent.

mattj, I dont think just running the script will do it. If you read through the two articles on Jan's site titled ONVIF Analytics and ONVIF Notifications, you will see that the script is just one part of the bigger picture. Unfortunately, there is no information yet on how to actually implement this. Hopefully, Jan will post more details on this soon.
Khurram
Posts: 46
Joined: Tue Oct 09, 2007 5:29 pm
Location: Lahore, Pakistan

Re: ONVIF motion events notifications to NVR

Post by Khurram »

Has anyone seen http://zgtk9jlvq.xiagao.us/2014/11/24/1 ... 07267.html. The author claims he/she got zoneminder triigers working with ONVIF video analytics as far back as nov 24, 2014. It does not give any details and text in the page is oddly truncated.
User avatar
knight-of-ni
Posts: 2406
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: ONVIF motion events notifications to NVR

Post by knight-of-ni »

That http link you posted is a little weird.
Here is the actual page, from the original author's site:
https://altaroca.wordpress.com/2014/11/ ... oneminder/

The ONVIF probe currently in zoneminder 1.30.0 is a result of alatroca's work. I guess it was a different thread where I stated she has mentioned integrating her work on detecting motion events through onvif in a future pull request. If you want to contribute then the best way to do that currently would be through her blog site.
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
User avatar
knight-of-ni
Posts: 2406
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: ONVIF motion events notifications to NVR

Post by knight-of-ni »

Well, I feel embarrassed. Apparently, Jan is a guy, not a gal.
https://altaroca.wordpress.com/about/
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Khurram
Posts: 46
Joined: Tue Oct 09, 2007 5:29 pm
Location: Lahore, Pakistan

Re: ONVIF motion events notifications to NVR

Post by Khurram »

knnniggett wrote:That http link you posted is a little weird.
Here is the actual page, from the original author's site:
https://altaroca.wordpress.com/2014/11/ ... oneminder/
Yes, the link seems to be copy of Jan's wordpress blog.

I am a little confused by the current state of ONVIF support in 1.30. Jan says that he has gotten ONVIF probing, video analytics (motion detection) and notification to work but we have to build from his repo to get all this. So where do we stand in the 1.3 release as far as these 3 features are concerned?
User avatar
knight-of-ni
Posts: 2406
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: ONVIF motion events notifications to NVR

Post by knight-of-ni »

@Khurram See the 1.30.0 release notes
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Khurram
Posts: 46
Joined: Tue Oct 09, 2007 5:29 pm
Location: Lahore, Pakistan

Re: ONVIF motion events notifications to NVR

Post by Khurram »

knnniggett wrote:@Khurram See the 1.30.0 release notes
I checked the release notes and I see that ONVIF probing is there, but there is no mention of video analytics or notifications. So I guess these 2 features have not yet made it into the release. Am I right?
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: ONVIF motion events notifications to NVR

Post by asker »

knnniggett wrote:Well, I feel embarrassed. Apparently, Jan is a guy, not a gal.
https://altaroca.wordpress.com/about/
:D I was wondering when you'd figure it out
I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.

Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
SteveGilvarry
Posts: 494
Joined: Sun Jun 29, 2014 1:12 pm
Location: Melbourne, AU

Re: ONVIF motion events notifications to NVR

Post by SteveGilvarry »

asker wrote: :D I was wondering when you'd figure it out
I had to give him a hint.
Production Zoneminder 1.37.x (Living dangerously)
Random Selection of Cameras (Dahua and Hikvision)
User avatar
knight-of-ni
Posts: 2406
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: ONVIF motion events notifications to NVR

Post by knight-of-ni »

I'm still wondering if Jan is a guy's name only in Germany, or if I am just a dumb American. I suspect the latter. I guess I need to travel more.
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Locked