Linux Motion Detection
After a search of the web, I was
unable to find any linux software which would could detect motion and
save images when the changes occurred. I did however find a
couple of programs (Nemisis streamer and bttvgrab) which would
capture the images, however you quickly fill up a hard disk if you
capture continueosly and also you have to sift through a lot of
images where nothing happens to find an event.
Fortunately I was able to make use of one of the tools in the netpbm
toolkit to compare two successive images and only store the image if
it had changed based on a defined threshold. I have
written a short script which combines the Nemises streamer and then
Netpbm tool pnmpsnr to record motion. The script is available
from motiondetect
Note, I have had problems getting newer versions of the Nemesis streamer to work (including the one that ships with Redhat 7.1), so you might want to try the version I used source and compiled streamer binary for linux
If you need netpbm you can get it from
the site below, however the version bundled with the later releases
of linux such as Redhat 7.1 work fine.
Netpbm ftp://metalab.unc.edu/pub/Linux/apps/graphics
I have subsequently discovered that
there are a few other programs now available which may be better than
this system. For a start you could check out the links in the Video
Secutity section at http://www.exploits.org/v4l/
I Have also discovered that the streamer binary is now included in the v4ltools package that comes with many distributions
Also I have now used a modified version of the motiondetect script to access images from an AXIS 205 webcam.
Linux Training Presentation – help overcome the fear of the unknown