Bukit Mertajam, Penang

Raspberry Pi with PIR Sensor

Introduction

In this lesson, we will learn on how to use a PIR sensor module with Raspberry Pi. It’s simple and easy project to detect a motion. 

Hardware Preparation

This tutorial use :

  1. Raspberry Pi
  2. Maker Hat
  3. USB Micro B Cable
  4. Low Cost PIR Sensor Module

You can make the hardware connection based on the diagram and table below.

Figure 1 : Hardware connection.

Sample Code

This is the sample code used for this tutorial. Try it!

Thank you

Thank you for reading this tutorial and we hope it helps your project development. If you have any technical inquiry, please post at Cytron Technical Forum.

Leave a comment

Loading...