O'Reilly logo

Internet of Things Programming with JavaScript by Ruben Oliva Ramos

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Building an alarm system using the Raspberry Pi Zero

In this section, we will build a simple alarm system with a PIR sensor connected to the Raspberry Pi Zero. This is an important project as it can be added to the home, including other sensors, in order to monitor it.

Motion sensor with Raspberry Pi Zero

For this project we need the Raspberry Pi Zero, a motion sensor PIR, and some cables. The hardware configuration for this project will actually be very simple. First, connect the VCC pin of the motion sensor to a 3.3V pin on the Raspberry Pi. Then, connect the GND pin of the sensor to one GND pin on the Pi. Finally, connect the OUT pin of the motion sensor to the GPIO17 pin on the Raspberry Pi. You can refer to the previous chapters to find out ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required