Ubuntu / Linux news and application reviews.

This tutorial will explain how to turn any webcam (supported by Linux) into a motion-detecting security spy cam. Full credits for this post: tech source from the bohol

1. Install the motion detector software that's appropriately called "Motion".
sudo apt-get install motion

2. After installation, you have officially converted your ordinary webcam into a motion-detecting camera. The only thing that you need to do now is to start tracking movement and capture images by running "Motion" from the terminal:
sudo motion
You can stop "Motion" by pressing CTRL+C.

The captured time stamped images are saved at "/tmp/motion" by default. However, you can configure and change the default settings by navigating to "/etc/motion" and editing "motion.conf". Like if you want to change the directory where the captured images are saved, just find and edit this line: "target_dir /tmp/motion"

You can go here to know about several “Motion” config file options.


3. Set-up "Motion" to send and save the captured images to a remote FTP server.
a) install wput:
sudo apt-get install wput
b) After it, edit “motion.conf” with your favorite text editor, and then add the following line at the end section:
on_picture_save wput ftp://username:password@yourserver %f
If you want to start Motion automatically with your server, just add Motion to your "Startup Programs".

c) You will now be able to open the Motion web interface by typing in localhost:8000 from the server itself or XXX.XXX.X.XXX:8000 from a remote computer's web browser. To view a live stream of your webcam type localhost:8001 from the server or XXX.XXX.X.XXX:8001 from a web browser.

It is also possible to add multiple webcams. You can go HERE for set-up instructions.