- Get link
- X
- Other Apps
Posts
Showing posts with the label HC-SR501
PIR Sensor (Part 2)
- Get link
- X
- Other Apps
In this tutorial we will connect our HC-SR501 PIR (movement) Sensor to an Arduino UNO. The PIR sensor will be powered by the Arduino and when movement is detected, the PIR sensor will send a signal to Digital Pin 2. The Arduino will respond to this signal by illuminating the LED attached to Pin 13. PIR Sensor (Part 1) : Showed that this sensor can be used in isolation (without an Arduino). However, I will still demonstrate how you can attach this sensor to the Arduino so that we can move forward to more advanced objectives and concepts. Video Parts Required Mini Breadboard 4.5cm x 3.5cm PIR Motion sensor (HC-SR501) LED and 330ohm resistor Breadboard Jumper Wire Arduino UNO (or compatible board) Fritzing Sketch Arduino Sketch 1 2 3 4 5 6 7 8 9 10 11 12 13 14 /*Simple PIR sketch: Written by ScottC, 19th Dec 2013 http://arduinobasics.blogspot.com/ ----------------------------------------------------*/ void setup (){ pinMode(13,OUTPUT); pinMode(2,INPUT); } void loop ...
PIR Sensor (Part 1)
- Get link
- X
- Other Apps
PIR sensors are pyroelectric or “passive” infrared sensors which can be used to detect changes in infrared radiation levels. The sensor is split in half, and any significant difference in IR levels between the two sections of the sensor will cause the signal pin to swing HIGH or LOW. Hence it can be used as a motion detector when IR levels move across and trigger the sensor (eg. human movement across a room). The potentiometers are used to adjust the amount of time the sensor remains “on” and “off” after being triggered. Essentially the delay between triggered events. Here are a couple of pictures of the PIR sensor. The sensor used in this tutorial is HC-SR501 PIR sensor. You can get more information about this sensor here . Parts Required Mini Breadboard 4.5cm x 3.5cm PIR Motion sensor (HC-SR501) LED and 330ohm resistor Breadboard Jumper Wire Battery (9V or equivalent) and battery clip Sketch Video Sketch Explanation The s...