Book Image

Building Smart Homes with Raspberry Pi Zero

By : Marco Schwartz
Book Image

Building Smart Homes with Raspberry Pi Zero

By: Marco Schwartz

Overview of this book

The release of the Raspberry Pi Zero has completely amazed the tech community. With the price, form factor, and being high on utility—the Raspberry Pi Zero is the perfect companion to support home automation projects and makes IoT even more accessible. With this book, you will be able to create and program home automation projects using the Raspberry Pi Zero board. The book will teach you how to build a thermostat that will automatically regulate the temperature in your home. Another important topic in home automation is controlling electrical appliances, and you will learn how to control LED Lights, lamps, and other electrical applications. Moving on, we will build a smart energy meter that can measure the power of the appliance, and you’ll learn how to switch it on and off. You’ll also see how to build simple security system, composed of alarms, a security camera, and motion detectors. At the end, you will integrate everything what you learned so far into a more complex project to automate the key aspects of your home. By the end, you will have deepened your knowledge of the Raspberry Pi Zero, and will know how to build autonomous home automation projects.
Table of Contents (17 chapters)
Building Smart Homes with Raspberry Pi Zero
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

Accessing your home automation system from anywhere


In the last section of this chapter, we are going to learn how you can access the interface of your home automation system from anywhere in the world. This way, you will be able to monitor and even to control your home when you are not around.

For that, we are going to use a tool called Ngrok, which will allow us to access the server running on our Raspberry Pi or computer from anywhere in the world.

If like me you deployed the server on another Raspberry Pi (as my computer is switched off when I am away from home), type the following command:

wget https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-arm.zip

This will download Ngrok on your computer. Then, unzip the file with this command:

unzip ngrok-stable-linux-arm.zip

Finally, start Ngrok using the following command:

./ngrok 3000

This will basically create a web tunnel to the web server that is running on port 3000. Inside the window that appeared on your Raspberry Pi, you should now be...