Skip to Main Content
Raspberry Pi Cookbook, 2nd Edition
book

Raspberry Pi Cookbook, 2nd Edition

by Simon Monk
June 2016
Beginner to intermediate content levelBeginner to intermediate
508 pages
9h 40m
English
O'Reilly Media, Inc.
Content preview from Raspberry Pi Cookbook, 2nd Edition

Chapter 15. The Internet of Things

15.0 Introduction

The Internet of Things (IoT) is the rapidly growing network of devices (things) connected to the Internet. That doesn’t just mean more and more computers using browsers, but actual appliances and wearable and portable technology. This includes all sorts of home automation from smart appliances and lighting, to security systems and even Internet-operated pet feeders, as well as lots of less practical but fun projects.

In this chapter, you will learn how your Raspberry Pi can participate in the Internet of Things in various ways.

15.1 Controlling GPIO Outputs Using a Web Interface

Problem

You want to control GPIO outputs using a web interface to your Raspberry Pi.

Solution

Use the bottle Python web server library (Recipe 7.17) to create an HTML web interface to control the GPIO port.

To make this recipe, you will need:

The breadboard layout for this is shown in Figure 15-1.

F1400
Figure 15-1. The breadboard layout controlling GPIO outputs from a web page

An alternative to using a breadboard is to attach a Raspberry Squid and Squid Button (see Recipe 9.10 and Recipe 9.11). These can be plugged directly into the GPIO pins of the Raspberry ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Raspberry Pi Cookbook, 3rd Edition

Raspberry Pi Cookbook, 3rd Edition

Simon Monk

Publisher Resources

ISBN: 9781491939093Errata Page