Join David Ross for an in-depth discussion in this video Explore a script that automates picture taking, part of Raspberry Pi: Home Monitoring and Control.
- What we're going to look at next…is a shell script that actually will allow us to…take a number of pictures.…And you should find this on your exercise files.…It's called take_pics, take underscore pics.…So what I've done is actually just brought it up…over here.…Now there's some things in this file that you should change…if you want.…There's other things you should not change.…Line 1 is one of those things you should not change.…If you change Line 1 it's not going to work.…But you can change other things.…
Now let's take a look at Line 13 here.…This is setting a variable called DATE to equal the output…of date +%D and so on.…And what this is, is this is going to create…a variable that's going to contain a date.…Now you'll see here that there's pipes…and there's sed and there's all these things here…if you don't understand Line 13, I think you…should look at Up and Running with Bash Scripting…and it also, you will see that there's a lot of these…lines here, like Line 13, that has sed in it.…
And if you don't understand how that works,…
This DIY electronics project provides simple directions for getting your home monitoring system up and running. Author David Ross helps you select a power supply, camera, motion detector, enclosure, and other components and accessories, and make your system "smart" by connecting to web services frameworks such as Weaved and WebIOPi. Then he helps you program the logic to make your Pi camera take pictures and stream video, connect to home peripherals, and mount your alarm system. With this training, and a little elbow grease, you can create a fully autonomous system that helps you and your family feel more secure at home and away.
Note: These instructions work with Raspberry Pi B, Raspberry Pi B+, and Raspberry Pi 2 models.
- Selecting hardware, including a Raspberry Pi camera and a Pi Cobbler
- Configuring VNC, SSH, and WebIOPi services
- Sending SMS messages with the Raspberry Pi
- Taking and accessing pictures remotely
- Setting up video streaming with a Raspberry Pi camera
- Connecting the Pi to the development board
- Connecting the relay and motion detector
- Programming the alarm in Python
- Mounting and securing the alarm system