Axis 207 and On-Camera motion detection solved

Anything you want added or changed in future versions of ZoneMinder? Post here and there's a chance it will get in! Search to make sure it hasn't already been requested.
User avatar
kingofkya
Posts: 1110
Joined: Mon Mar 26, 2007 6:07 am
Location: Las Vegas, Nevada

Post by kingofkya »

User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Thanks for that. :D
sipi
Posts: 132
Joined: Wed Feb 14, 2007 5:18 pm

Post by sipi »

Hi kingofkya,

I make set up step-by-step and record works. I use Axis 211 cam and ZM 1.24.1 but have a problem. Axis send TCP notification to ZM when has an event and record start up but it start too late. ZM record start after event. What is problem? Thanks.
sipi
Posts: 132
Joined: Wed Feb 14, 2007 5:18 pm

Post by sipi »

I tried some cam and zm setup for my problem. I think that must increase buffers.

Image Buffer Size=80
Pre Event Image Buffer= 40

It works fine. Who how much more use buffer size?

I made manual trigger on cam same as motion trigger. I use input on cam and made an Event trigger from input to send TCP notification to zm. It work correctly.

Axis can make scheduled triggered TCP notification but I don't know how I use it zm scheduled record.

Sorry my bad english isn't my mother tongue. Thank your advice.
Mr.Ziggy
Posts: 16
Joined: Thu Dec 17, 2009 7:34 am

Axis M1011 and newer cams

Post by Mr.Ziggy »

First, I'd like to express my profound thanks to those of you who have posted such great info on getting this working.

It does appear to me that the Axis camera setting steps are in a different order on the M1011 and 211M cameras I just received. (maybe from newer firmware?)

1. Motion Detection > Create a new window
2. Event Types > Create the ZM-Eventtrigger as stated in the wiki
3. Event Server > Create as in wiki.

There is no motion detection window configured by default on the devices I just purchased. It's a small point of clarification.
Mr.Ziggy
Posts: 16
Joined: Thu Dec 17, 2009 7:34 am

Axis Send Notifications Continously While Event is Active

Post by Mr.Ziggy »

Axis has a new option on the M1011 Cams.

On the Triggered Event Type Setup, bottom:

Send Notifications Continuously While Event is Active



It sounds like a more robust option than "trigger on motion" or the "trigger on motion/trigger off motion" that has been talked about here. Missed triggers wont mean an entire lost event.

I am currently using ZM 1.24, Ubuntu 9.10 with the trigger script updates as described in the wiki.

(Not sure if this should be posted here on on the 1.24 current version forum)

Anyone else using it and have any advice?

Image
xco
Posts: 1
Joined: Tue May 04, 2010 12:28 pm

Re: some tweaks

Post by xco »

neb wrote: The next tweak I did was in the Axis camera itself. Apart from the "on" command on motion start, I also created a separate "cancel" command to be sent on motion stop. The way to do it was via the plain config described in a previous post. Basically, you'd create one event along with its tcp action using the normal event interface (I'd start with the stop/cancel event first), then go to plain config, select event and write down the settings. Then go back to normal config and replace it with the start/on event, and then go to plain config again and select "add event type", which creates event "E1". You can then manually type in what you've written down previously. Note that there's no action setting "E1.A1". The Axis 207 has a hidden link to create it.
Ben
Hello, thanks you very much ! I have just a question, I don't know what to do exactly for this tweak. I have to create an event :
Triggered by "Motion detection" In windows "defaultwindow" when motion detection "starts"
Send TCP notification to "xxx" with message : "1|on+60+5|5|cause|text|showtext"

and an other event with ???
Triggered by "Motion detection" In windows "defaultwindow" when motion detection "????"
Send TCP notification to "xxx" with message : "??????????"

Can someone explain to me ?
Thanks !
xco
leigh 98
Posts: 1
Joined: Mon Jan 24, 2011 8:37 pm

Post by leigh 98 »

Great post. I've been trying to implement the on-camera motion detection with ZM and it looks like I've got it all working now. Thanks.
EdwardHyde
Posts: 1
Joined: Wed Aug 03, 2011 6:41 pm

Re: Axis 207 and On-Camera motion detection solved

Post by EdwardHyde »

Followed the instructions to the letter, however I believe when the ZMTRIGGER.PL file fires off that it is done recording it get and error locally on the server.

The error is Variable is not a string at usr/local/share/perl/5.10.1/ZoneMinder/Memory/Mapped.pm line 109

Looking at the file usr/local/share/perl/5.10.1/ZoneMinder/Memory/Mapped.pm line 109 - this is the results

munmap( ${$monitor->{MMap}} );

Running on Ubuntu Server 11.04. ZoneMinder version 1.25.0.

Thanks for any help!
MichaelTiemann
Posts: 18
Joined: Wed Apr 20, 2011 1:04 am

Re: Axis 207 and On-Camera motion detection solved

Post by MichaelTiemann »

This has been mostly working for me, which is great. However, about half the time, about half of my AXIS 215 cameras will stay in a triggered state for tens of thousands, sometimes hundreds of thousands of frames, usually when the camera flips from night-to-day settings or day-to-night settings. I have tried to set parameters to limit events to a few hundred frames, but I obviously haven't found the real kill switch for ultra-long events. Any clues?
theforce
Posts: 129
Joined: Tue May 11, 2010 5:22 am

Re: Axis 207 and On-Camera motion detection solved

Post by theforce »

I just want to update this thread.

I recently bought an Axis M3203 camera and was wanting to play around with the on board motion detection. After getting Zoneminder configured to accept the trigger input I tried configuring the camera. My camera has the latest firmware as of this writing. Firmware version 5.40.9.2. This camera and firmware will save the "+" sign in the message configuration.

My guess is that if you upgrade the firmware in your Axis camera it should be able to save the "+" now and you will not have to modify the zmtrigger.pl file to get it working. :D

I have updated the Wiki on the Axis motion dection to let future people know about it.
madas
Posts: 1
Joined: Wed Jan 02, 2013 12:21 am

Re: Axis 207 and On-Camera motion detection solved

Post by madas »

I am also getting this
he error is Variable is not a string at usr/local/share/perl/5.10.1/ZoneMinder/Memory/Mapped.pm line 109

Looking at the file usr/local/share/perl/5.10.1/ZoneMinder/Memory/Mapped.pm line 109 - this is the results
Did you ever get this resolved?
ChrisWalker
Posts: 3
Joined: Mon Apr 05, 2021 3:50 pm

Re: Axis Send Notifications Continously While Event is Active

Post by ChrisWalker »

W. wrote: Thu Aug 28, 2008 10:58 am One can set two separate events one that is fired when motion starts and another when motion ends thus imitating behavior of ZM motion detection. In that case no + sign is needed.
I'm using some M2025-LE and P1435-LE cameras and this works like a charm. Using this allowed me to record events until the motion stopped. Using the settings found in the Wiki I was only able to record for the time duration and then the recording would would stop even if the motion was still present.
Mr.Ziggy wrote: Sat Jan 30, 2010 1:30 am Axis has a new option on the M1011 Cams.

On the Triggered Event Type Setup, bottom:

Send Notifications Continuously While Event is Active



It sounds like a more robust option than "trigger on motion" or the "trigger on motion/trigger off motion" that has been talked about here. Missed triggers wont mean an entire lost event.

I am currently using ZM 1.24, Ubuntu 9.10 with the trigger script updates as described in the wiki.

(Not sure if this should be posted here on on the 1.24 current version forum)

Anyone else using it and have any advice?

Image
I wouldn't worry about missing a trigger due to network issues. If you did miss a trigger due to a network issue I wouldn't worry about the cameras, you need to fix something on your network.

The Axis cameras are sending the message via TCP; the trigger can either be on time or late, but not missed. According to the TCP spec, packets are (in theory) guaranteed to be delivered. If the cameras were sending the triggers via UDP then I would be worried if continuous sending weren't an option. I'm assuming that Axis realized this and decided to leverage the TCP spec to guarantee trigger delivery since my cameras don't have the continuous send flag. Trying to bolster the TCP spec with half-baked ideas does nothing but cause congestion (sending additional packets in case the first one didn't make it; basically your camera will bombard the server with triggers and your server will, in turn, bombard the camera with TCP acknowledgments) and delays (Google buffer bloat).

The only other way I can think you would miss a trigger would be if the machine is borked or overloaded, the script crashed, or the machine was offline when the signal was originally sent. Obviously, these things would need to be fixed as well.
mikb
Posts: 586
Joined: Mon Mar 25, 2013 12:34 pm

Re: Axis Send Notifications Continously While Event is Active

Post by mikb »

ChrisWalker wrote: Mon Apr 05, 2021 5:30 pmbasically your camera will bombard the server with triggers and your server will, in turn, bombard the camera with TCP acknowledgments) and delays (Google buffer bloat).
It does sound like "I Denial-Of-Service'd-Myself-In-The-Foot" in the making.
terrymoore
Posts: 1
Joined: Thu May 20, 2021 7:11 pm

Re: Axis Send Notifications Continously While Event is Active

Post by terrymoore »

ChrisWalker wrote: Mon Apr 05, 2021 5:30 pm
W. wrote: Thu Aug 28, 2008 10:58 am One can set two separate events one that is fired when motion starts and another when motion ends thus imitating behavior of ZM motion detection. In that case no + sign is needed.
I'm using some M2025-LE and P1435-LE cameras and this works like a charm. Using this allowed me to record events until the motion stopped. Using the settings found in the Wiki I was only able to record for the time duration and then the recording would would stop even if the motion was still present.
Mr.Ziggy wrote: Sat Jan 30, 2010 1:30 am Axis has a new option on the M1011 Cams.

On the Triggered Event Type Setup, bottom:

Send Notifications Continuously While Event is Active



It sounds like a more robust option than "trigger on motion" or the "trigger on motion/trigger off motion" that has been talked about here. Missed triggers wont mean an entire lost event.

I am currently using ZM 1.24, Ubuntu 9.10 with the trigger script updates as described in the wiki.

(Not sure if this should be posted here on on the 1.24 current version forum)

Anyone else using it and have any advice?

Image
I wouldn't worry about missing a trigger due to network issues. If you did miss a trigger due to a network issue I wouldn't worry about the cameras, you need to fix something on your network.

The Axis cameras are sending the message via TCP; the trigger can either be on time or late, but not missed. According to the TCP spec, packets are (in theory) guaranteed to be delivered. If the cameras were sending the triggers via UDP then I would be worried if continuous sending weren't an option. I'm assuming that Axis realized this and decided to leverage the TCP spec to guarantee trigger delivery since my cameras don't have the continuous send flag. Trying to bolster the TCP spec with half-baked ideas does nothing but cause congestion (sending additional packets in case the first one didn't make it; basically your camera will bombard the server with triggers and your server will, in turn, bombard the camera with TCP acknowledgments) and delays (Google buffer bloat).

The only other way I can think you would miss a trigger would be if the machine is borked or overloaded, the script crashed, or the machine was offline when the signal was originally sent. Obviously, these things would need to be fixed as well.
Chris

I've looked at the original wiki entry which is now about 12 years old, looking at the latest Axis firmwares it's a little confusing as to some of the steps the OP setup.

Would it be possible for you to post your configuration using say a 8+ version axis firmware?

I have about 12 Axis cameras in total on an i7 3770s fedora platform which is starting to 'stretch' the limits of the CPUs capabilities, especially as I'm looking to add some 4K cameras to replace older ones. I'd like to offshift some of the motion detection to the cameras as Axis Motion Detect 4 is now baked into all the firmwares, but as I've never done it that way historically it would help me enormously to see a more up to date config.

Thanks in advance.
Post Reply