Building a Home Security System with Raspberry Pi
Copyright 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: December 2015
Production reference: 1161215
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78217-527-8
www.packtpub.com
Credits
Author
Matthew Poole
Reviewers
Lihang Li
Cdric Verstraeten
Commissioning Editor
Edward Bowkett
Acquisition Editors
Vivek Anantharaman
Vinay Argekar
Content Development Editor
Sumeet Sawant
Technical Editor
Namrata Patil
Copy Editor
Angad Singh
Project Coordinator
Shweta H. Birwatkar
Proofreader
Safis Editing
Indexer
Rekha Nair
Production Coordinator
Manu Joseph
Cover Work
Manu Joseph
About the Author
Matthew Poole is a systems engineer based near Southampton on the south coast of England with over 20 years of industry experience. After graduating in electronics and communications engineering, he went on to train as and to become an air traffic engineer for the UK Civil Aviation Authority, working on microprocessor-based control and communications systems.
Later, he became a software architect and mobile technology specialist, and worked for several consultancies and global organizations. He is now a partner at UK Mobile Media, a boutique systems consultancy focused on designing Bluetooth and other wireless systems, taking ideas from concept to prototype. He is also the director of technology for Mobile Onboard, a leading UK-based transport technology company that specializes in on-bus connectivity and mobile ticketing.
About the Reviewers
Lihang Li received his MS degree in computer vision from National Laboratory of Pattern Recognition(NLPR) at Institute of Automation of the Chinese Academy of Sciences (CAS). His interests include Linux, open source, cloud computing, virtualization, computer vision algorithms, machine learning and data mining, and a variety of programming languages.
You can find him at his personal website at http://hustcalm.me.
It has been a great opportunity being a part of this book. I have always been a fan of embedded devices and systems. Thanks go to our author and coordinator. Hope the readers will find this book helpful.
Cdric Verstraeten has an MSc in engineering and is primarily active in the C++ community. He works as a software engineer and is a huge open source enthusiast. He spends most of his time on side projects. He's the founder of Kerberos.io, an open source video surveillance system built for the Raspberry Pi, and is the organizer of the Raspberry Pi Belgium meetup group.
I would like to thank Packt Publishing for making me a reviewer of this book. I really think their books can give people an in-depth overview of a particular topic.
www.PacktPub.com
Support files, eBooks, discount offers, and more
For support files and downloads related to your book, please visit www.PacktPub.com.
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at > for more details.
At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters and receive exclusive discounts and offers on Packt books and eBooks.
https://www2.packtpub.com/books/subscription/packtlib
Do you need instant solutions to your IT questions? PacktLib is Packt's online digital book library. Here, you can search, access, and read Packt's entire library of books.
Why subscribe?
- Fully searchable across every book published by Packt
- Copy and paste, print, and bookmark content
- On demand and accessible via a web browser
Free access for Packt account holders
If you have an account with Packt at www.PacktPub.com, you can use this to access PacktLib today and view 9 entirely free books. Simply use your login credentials for immediate access.
Preface
The Raspberry Pi is a powerful, low-cost, credit-card sized computer, which lends itself perfectly as the controller of a sophisticated home security system. Using the available on-board interfaces, the Raspberry Pi can be expanded to allow the connection of a virtually infinite number of security sensors and devices. The Raspberry Pi has the processing power and interfaces available to build a sophisticated home security system but at a fraction of the cost of commercially available systems.
Building a Home Security System with Raspberry Pi starts off by showing you the Raspberry Pi and how to set up the Linux-based operating system. The book then guides you through connecting switch sensors and LEDs to the native GPIO connector safely, and it also shows you how to access these using simple Bash scripts. As you dive further in, you'll learn how to build an input/output expansion board using the I2C interface and power supply, allowing the connection of the large number of sensors needed for a typical home security setup.
The book features clear diagrams and code listing every step of the way to allow you to build a truly sophisticated and modular home security system.
What this book covers
, Setting Up Your Raspberry Pi , starts out by taking our Raspberry Pi out of its box and preparing it for being the centerpiece of our home security system. Along the way, we will install and set up the operating system, connect our Pi to the network, and access it remotely. We'll also secure our Pi and make sure it can keep the right time.
, Connecting Things to Your Pi with GPIO , explores the GPIO port and the various interfaces it features. We'll look at the various things we can connect to the Raspberry Pi using the GPIO including switches and sensors as we start to build our home security system.
, Extending Your Pi to Connect More Things , looks at ways of expanding the number of things we can connect to our Raspberry Pi, overcoming the limitation of having just the eight digital pins available to us on the GPIO by tapping into other interfaces on the GPIO and building our own input/output expansion board.