start stop time event for modect

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.
Post Reply
linuxfd
Posts: 13
Joined: Mon Apr 19, 2004 1:33 pm

start stop time event for modect

Post by linuxfd »

Hi All,

Is it possible to have web interface to set pre-set times for starting and stopping modect, has anyone been doing this with cron, if so how have you set this for /dev/video0(1) and the like

regards

fred
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

At least two ways you could possibly do this spring to mind! I am assuming that when you don't want 'modect', you want either 'monitor' or nothing at all.

1) Make the monitors you want this to apply to to be 'triggered', then in your cron just do

perl zmdc.pl start (or stop) zma -m 1 (or 2 etc)

this will have the effect of starting and stopping the analysis daemons entirely whilst leaving the capture daemons running.

2) Set all your monitors to the states you want them to be in at one point in the day and click on the 'Running' link in the console. Then save these monitor states with a name of your choice, e.g. 'Modecting'. Change the monitors to be how you'd like them at the other time of day and save that as something else, e.g. 'Monitoring'. Then in your cron you can say

perl zmpkg.pl Modecting (or Monitoring)

which should work as well.

Method (1) is simpler and only the appropriate daemons are started and stopped. Method (2) is a bit neater but the system basically gets restarted each time which may not be what you want.

I'm sure there are probably other ways too (e.g. use X.10 and a timer!).

Phil,
User avatar
lazyleopard
Posts: 403
Joined: Tue Mar 02, 2004 6:12 pm
Location: Gloucestershire, UK

Post by lazyleopard »

I hacked together a script I called zmtrigger.pl which I invoke from cron. I'll try to remember to drop it into the user contributions area when I'm at home and can do so fairly easily....
Rick Hewett
Post Reply