Author Topic: extra events  (Read 791 times)

secs

  • Regular Poster
  • **
  • Posts: 22
    • View Profile
extra events
« on: November 28, 2008, 09:16:16 pm »
Hi all.

Probably not the best subject heading but I will explain a bit more.

I have my capture card working. Really well actually. I was going to give up but persisted and glad I did. Now I have it firing Linuxmce apparently as I can view the Alerts Log and see images and times of motion detection. So I assume the that motion is passing the info back to Pluto etc ok.

I would like to fire a script to send the captured image etc off site via email and ftp etc. I have added

on_picture_save /usr/bin/send_mail %f
on_movie_end /usr/bin/send_mail %f

to the CONFIGERATION section of the Advance-devices-motionwrapper-camera

bit yet it doesn't seem to fire it.

Can anyone see a mistake or it there another way?

I have checked the cameras conf file in the motion stuff itself and the above has been added to it.

Ideas?

Peter

bulek

  • Administrator
  • wants to work for LinuxMCE
  • *****
  • Posts: 886
  • Living with LMCE
    • View Profile
Re: extra events
« Reply #1 on: November 28, 2008, 09:45:46 pm »
Hi,

maybe for a start, you could try to put in some trivial task, to see if the problem is in motion or in your script...

What version of motion do you use ? I think I always upgrade motion instantly, cause Ubuntu stock one is quite outdated, but I'm speaking this out of memory.... not sure....

I use this one :
Quote
motion Version 3.2.11, Copyright 2000-2005 Jeroen Vreeken/Folkert van Heusden/Kenneth Lavrsen

Maybe it is the stock one - do you have the same ?

Regards,

Bulek.
Thanks in advance,

regards,

Bulek.

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: extra events
« Reply #2 on: November 28, 2008, 09:51:16 pm »
bulek - does Motion support setting of polygons (say a rectangle) to ignore in the image processing? eg pointing a camera at a room with a window in it that has a lot of motion outside. You could describe a polygon to include the window, for Motion to ignore motion in....

elspic

  • Veteran
  • ***
  • Posts: 52
    • View Profile
Re: extra events
« Reply #3 on: November 29, 2008, 12:15:47 am »
colinjones: I'm not sure if that is possible, but I think the inverse is possible using area_detect:

Quote
# Detect motion in predefined areas (1 - 9). Areas are numbered like that:  1 2 3
# A script (on_area_detected) is started immediately when motion is         4 5 6
# detected in one of the given areas, but only once during an event.        7 8 9
# One or more areas can be specified with this option. (Default: not defined)
; area_detect value

I'm not sure if you'd do something like area_detect 1,2,3,4,6,7,8,9 to ignore the center of the image or if it would be multiple statements.

secs: Could you update the wiki or at least post what you did to get motion working so well for you? Do you have a problem with any of your cameras not updating? I've found it easiest to see this issue in a quad view. After a minute one or more of the camera images will stop refreshing. You can actually see the timestamp stuck at the time on the stuck ones while the working ones continue to change.

Bulek: When you say you upgrade motion, do you go through apt or get the newest sources and compile?

secs

  • Regular Poster
  • **
  • Posts: 22
    • View Profile
Re: extra events
« Reply #4 on: November 29, 2008, 01:09:40 am »
Hi all.


I actually program in Delphi for that horrible os Windows and when I get problems, I add stuff so it writes to a log file so I can see where its up to. So just after I posted the above, I did a Google and found you can simly add

logger some type of info

to your scripts and it writes it to the syslog


So yes it is actually running the script.


It seems that the script works if I call it from the command line but doesn't do all it should when called from Motion so it must be a permisions type problem and not a Linuxmce or Motion one.

I will keep you informed. Thanks to all those who helped..

Peter