This project uses the same hardware as Adafruit's Raspberry Pi Lesson 12. Sensing Movement, minus a breadboard and the Pi Cobbler. On a Pi model B with the Pi Cobbler, that setup looks like this:

Instead, I did the following (which should work with a B+ or a Pi 2):

From the PIR sensor to the Pi, connect:

  • Power (red wire) → 5V
  • GND (black wire) → GND
  • Signal (yellow wire) → GPIO 18

From the door switch to the Pi, connect one end to a GND pin and the other to GPIO 23.

This guide was first published on May 01, 2015. It was last updated on May 01, 2015.

This page (Sensor Setup) was last updated on Apr 28, 2015.

Text editor powered by tinymce.