Dies ist eine alte Version des Dokuments!
Linux Webcam
Live Image
- motion saves image every 15 seconds to
/var/www/webcam/lastsnap.jpg
- after that
on_picture_save
command from motion.conf runs/home/pi/webcam-cleanup.sh
- this script copys
lastsnap.jpg
tolive.jpg
, writes a timestamp to/var/www/webcam/lastsnap.txt
and sets the rights so the webserver can accesslive.jpg
- index.html displays the
live.jpg
on load and every 15 seconds thelastsnap.txt
is fechted via ajax. If this timestamp changed, the life.jpg reloades
Archiving
- crontab runs
webcam-archiv.sh
every 15 minutes from 5 to 21 o'Clock - it copys the
live.jpg
to thearchiv/<current-timestamp>.jpg