These little PIRs are great, each year I've used them at Christmas, I run a set of small xmas trees along our drive/pathway, put a PIR in each one, so as you walk up the drive they light in sequence, a nice little effect and cheapo!
+Andy Brown Replying to myself is always a bit strange, but anyway, the method of adding the transistor as +bigclivedotcom shows is a much better way than I'd done in the past. My method fed each individual xmas tree set of LEDs back, and the output of the PIR, so each tree had 4 wires to it (+ve -ve LED-trigger PIR-output) which made it quite a mess wiring back 10 of these to my garage! Back in the garage I then used an Arduino (overkill!) to read the inputs coming from the PIRs and then switch a relay bank for the output. It was a bit heavy-handed approach, but gave me the advantage I could do a sequenced display on them when nobody was in front of them triggering the PIRs. I'll do a video myself shortly with my plans this year as Clive has given me a bit of inspiration!
Instructive video explaining electronic circuits that are triggered by PIR modules. Thank you for explaining this popular and widespread application so nicely !
I have been experimenting with logic level mosfets with these PIR sensors due to low current output but they usually didn't work for me , my only option was to use arduino to trigger a transistor but with this circuit design you have made my day sir.. I guess there always is something to learn after all :-) Thanks a lot again for sharing and making the world a better place , at least for me :)
Great video to get me started on PIR in many places. I probably drive a relay with them to power various lighting needs and setups. The sensors also fit almost anywhere. Perfect.
Excellent tutorial anyone who didn't study electronics will find this informative. These pir modules didn't exist when I studied, shows my ancient age.
Another totally Awesome BIG CLIVE production ! ;-) love Your vids Clive ... takes me back to when I should have been listening in School ! My Fave Project I made for my exam was A Bc108 trans circuit used as a water detector then applied to a window frame to close when rain detected of course .. back in 86 this was cutting edge stuff ! lol.. Look forward to more great vids Clive ..
Was really hoping a new video came out soon. I really find them interesting. This one is one of your best, add you actually went through some (additional) circuit design. Nice job. I always thought that the lens columnated what the PIR "sees" (in theory making it possible to walk around the beams) but your explanation makes sense. You are a natural teacher. Keep up the good work. BTW... What's up with the one hater on all your videos? 10 minutes after any video you post there is one hater who posts a "thumbs down". You would think he would just stop watching if he feels that strongly. Thumbs up from here. ☝
+Rich Booth dont worry about the thumbs down, apparently its all user involvement to youtube, also weirdly, from PC you can thumbs down a comment, but not from ipad or cell phone. thumbs up or nothing! weird, not that thumbing down a comment does anything useful anyway
Ive used loads of these modules in the past, if you look closely on the front of the board next to the pir sensor itself there's two pads there for a standard ldr to fit under the fresnel lens for night only operation!
I use this PIR as a movement sensor light. 3 X 1.5 Alkaline batteries with almost the same circuit you have there. I fitted an LDR and it works a treat. In our bathroom the batteries last about a year. I put all the electronics in under the Fresnel lens and used a 5630 LED with about 15mA drive. That lights up the whole room. Cost here on eBay was around $1.20 each for the PIR and the LEDs were $3.15 for 100 on a tape.
Bought one of these for €0.70 (£0.52) after watching this video a while back. Been experimenting with it as a cat-on-kitchen-worktop-detector (soon to be deterrent once I find a suitable motor to hook up to this tambourine!) and it works rather well. For some reason with the jumper in the default (L) position the output stayed high constantly, no matter what I did. Removing the jumper entirely gave me the desired functionality. Thanks for the video.
Just got a few of these modules to play with and with no documentation, was wondering what the jumper and the pots did, then this turned up in suggested videos. Thank you for a good explanation of it all.
I watch your videos regularly, but it's very handy to dip into "classic clive" from 7 years ago. I bought my first PIR module (noob alert) and confidently wired it to my ESP32 microcontroller. It detects movement ALL the time. Thought it was a dud, but MAYBE it just needs the transistor you mention in this video, as the ESP32 must be fluctuating quite a bit based on what I have already connected to it, the voltage/current to the PIR must be all over the place...I shall experiment!...BUT NEVER EXPERIMENT WITH 240V...again. Glad I didn't throw it away, it may work perfectly fine with the correct knowledge!
I bought a bunch of these HC-SR501's, and they all go off all the time, every few seconds. Completely useless. I've done more research, and they are crap. Many people complain of the same issue. Pull up or down resistors, extra capacitors, do not work. These super cheap PIR's are just no good. One place suggested getting Panasonic PIR's, in the EKMB or EKMC series. I got several for about $10 each from DigiKey, and these work perfect. They take either 3.3 or 5 volts in, but the output is 0.5 volts less that the VIN, so I supplied them with 3.3v so I don't overload the input on my ESP32. They are working perfectly, no false alarms.
This video tittle literally describes word for word exactly what I was looking for. Thanks ! Also I found those LED lights to be called 'Copper String Lights'
Great video and box idea. I used one of these modules, buffered by a BC109 transistor and a reed relay to control a DFPlayer mini, to play an mp3 file from a micro-sd card. Run from 6 D-cell batteries. Strange problem, it played permanently except when somebody got close; it turned out the speaker magnet (external field) was opposing the reed relay coil's field causing the reed relay to operate as NC instead of NO! Moved it away from the magnet and now the module works fine, and my visitors will have ghost sounds at Halloween!
VERY interesting article, and plenty of food for thought where device incorporation is concerned. Living in the Southern Hemisphere we don't bother with PIR when we have the Christmas (solar) lights out on the garden bushes, etc., 'cause we have no shortage of "Aussie Strength" midsummer sunshine during the day :-)
I'd add to your description that PIR window is silicon, the FET is usually connected externally as a source follower buffer with the drain heavily decoupled, and you can implement a simple detector with an LM358 dual op-amp and a discrete transistor threshold detector. Also they detect far infra-red around 10 micron not the near infra-red as used in remote controls, two-element PIRs need to be mounted so the target movement is across the two elements one after the other - they're nowhere near as sensitive to movement at 90º. Due to the two elements in opposition they detect moving changes in temperature* which can mean colder as well as warmer, and the Fresnel lenses are moulded in HDPE. * Actually it's changes in IR energy received, which can be down to temperature and/or emissivity of the target.
Hi Graham. Found your comment very interesting. I want to make a simple PIR circuit for Arduino that sends a pulse or toggles a digital line every time movement is sensed (with no retriggering - the arduino code will handle that). You mentioned an LM358 and a transistor. How simple can the circuit be that connects to an Arduino's digital input? Are we talking three components?
+Mat Smith It's a lot more than just three components. The LM358 etc is just the starting point - there's something like 20-30 other components needed. Believe me you're far better off using one of these modules than rolling your own.
Along with the pyroelectic sensor is a bunch of supporting circuitry, resistors and capacitors. It seems that most small hobbyist sensors use the BISS0001 ("Micro Power PIR Motion Detector IC"), undoubtedly a very inexpensive chip. This chip takes the output of the sensor and does some minor processing on it to emit a digital output pulse from the analog sensor.
you can increase the input impedance of the transisitor buffer by bootstrapping the input terminal of the transistor thus minimizing the loading effect on the pir module or better yet employ a complementary feedback pair where there is 100% feed back to the emiiter and base of the driver transistor taken from the collector current of the second transistor of the CFP resulting in an even much higher input impedance
Evening, I’m trying to use MP2307 Adjustable Mini360 DC-DC Converter Step Down Buck Voltage Regulator but I’m getting lost as on your diagram only one wire come out the bottom, but on my regulator there are two outputs, can you offer any help? Happy to put a video up on my channel if needed
Your videos have inspired me to learn something about electronics. I love the way you showed the development of the circuit and I realize that you posted this a year ago, but I really want to know how you chose the value of the two resistors.
The base resistor was selected experimentally based on supplying enough current to turn the transistor on fully without loading the PIR module too much. The series resistor for the LEDs was chosen to provide enough current to make the LEDs glow at a decent intensity, but not draw too much current to maximise the battery life. Both can be adjusted within reason.
hello clive,i have big problem my pir sensor.when i switch on pir sensor active nicely.no any motion continue activating again and again.can u tell what is the reason.i checked 3,4 sensor same problem
I just got one of these sensors. I plan to use it with my Raspberry Pi and a camera module to: A) sense motion B) take a photo and C) email the photo to me.
I found this video while searching for the chip on that tiny PIR module. It's sold as hc-sr505 but the chip markings on the 8-pin are removed. That's stupid, what are they trying to hide?
China is ahead of you! i bought a while back, a pir 8 led light, takes 2xaa (which i like, esp as it works fine with nimh) not waterproof though, but might do as you suggest and put in a cheap tupperware, its been running reliably for about 3 months on same batteries, i probably activate it 30 times a day, (it also has the light sensor so no activation in bright light) it was meant for my garage, but i leave it in the kitchen on these dark evenings to save me always turning the light on. can post ebay number if anyone intersted.
+jusb1066 I found a retriggeable PIR cabinet light from Lidl, it uses 1 AAA battery and some sort of step-up regulator to drive the PIR circuit and a single LED. It has a LDR to not trigger in daylight and lasts a few weeks on the same battery, even when triggered multiple times every night. I use it as a night light to see my way into the bathroom.
An area of pirs not covered well is the effects of external temperature. Early thermal imagers and perhaps still used gadolinium lenses cooled down with liquid nitrogen. Another site says that pirs will not work in hot climates. Space is made for a thermistor on some pirs. Pirs work much better in winter in the UK and not so well in the summer. Can this be sorted with a thermistor? Does cooling the unit increase the sensitivity or does the range extend in a cooler environment or both? Just a thought or two. Great learning opportunity you provide, many thanks
Nice video Clive - I just received 3 of these modules by mistake instead of the buck boost converters I ordered. Now I know what they are, I'll have to find something to make with them... The 3.3V output probably won't be enough to trigger a mosfet to switch a couple of 100W LEDs @ 32-34V, but a transistor should be able to bump it up.
I just found out that those big PIR's false trigger when using 3.7v. I just removed the protection diode & directly connected it to 3.7v. It works fine!!!!
+A B I D They do. It defeats the voltage regulation, so they constantly re-trip when they turn off and the voltage changes slightly. That diode does buy you an extra half volt of operating voltage.
i have 12v LED chip connected with 12v battery throw a resistor witch can be light up with on / off button now i have sr501 motion sensor .so plz tell me how to make the conetion will i need any thing else.
Hi sir Thank you for your interesting video and I am thinking applying it for my car. How is schematic looks like to use 12v car battery as a source to drive a horn (similar car's horn) as a siren? Thank you in advance for your advice.
I finally got my Raspberry Pi wired up with one of these PIR modules. It sends a signal to my Raspberry Pi to take a photo and email it to myself. I added an LED to let me know when it senses motion. It is so sensitive, I can just smile and it will trigger. The two potentiometers don't seem to change the sensitivity. I guess I could partially cover the lens to lessen sensitivity.
Can you tell me how to change the delay on the HC-SR505. It is 8 sec and I wand about 0.5 sec. i can solder surface mount if needed. No one seems to have tried this in the net yet!
I wired mine the same way as your drawing, but without the transistor. It' working just the opposite. The led stays on and goes out when I put my hand in front of the sensor. I'm waiting on transistors to arrive in the mail. Will using the transistor make this work right?
I would have never guessed that these work by sensing body heat. I see them all the time in my classrooms, and at the local supermarkets to turn the lights on in the coolers when you're in front of the door.
HAY? I am in the USA.... Is there a way to connect one of these to the door's light fixture, so it will utilize the 110V to power the sensor and activate the bulb when there is motion? I am not that great with electronics, but I can understand clear instructions.. THANKS
Hi Clive, I'm sure you are aware of those PIR sensor built in LED light Bulbs (E27 and B22). I have bought some but they stop to work after about a week of use. Do you what what could be causing them to fail?
They have a differential arrangement inside that is only really suited to detecting a difference between the two sensors. If you covered one it might work to a degree, but not as well as a proper thermal camera.
bigclivedotcom good to know. I might have a play... I only need about an 8x8 pixel resolution for what I'm trying. Thanks dude. Worth a shot at. Never know I might accidentally learn something too 😎
rundata I haven't checked, but I'm pretty sure you could buy IR sensitive photodiodes for your matrix. They're contained in some proximity and beam-break sensors. If your camera needs a lens then it mustn't be normal glass, as clive shows. Maybe quartz or fluorite? Dunno. Maybe pricey.
I don't know much about electronics, but where can you get an emitter (the one you connected the output, negative and LEDs negative with)? I have had no luck so far
You're looking for an NPN transistor. Depending where you are in the world it may be able to get a BC547 or 2N3904. These are very cheap and common low power transistors. You can also buy them on eBay. Note that different transistors have the emitter, collector and base on different pins so you have to check online to see which pinout your transistor style has.
I have to ask you. I send in 11,1v lipoly. but I dont get more out than around 2v. I want it to turn on an led stripe. What do I wrong. It function normal but dont give me more than those 2v.
Hi I have a Question. Can I use this with the home outlet 110V instead of the battery? Should I used a bigger Transistor and if so how big? Also Can I use a 5 watts light bulb instead of a bunch of LEDs? If I use batteries can it be 9 Volts or 6 Volts is the maximum? I have very limited knowledge on electronics but I am learning a lot here.Thanks for your help.
You can get outdoor PIR units for security lights that do work from mains voltage and allow the switching of larger lights. You can also get inline 12V ones that allow switching 12V lights or LED tape run from a plug-in 12V power supply.
Hello, thanks for the video. I am trying to use this sensor to light a strip of 5v leds. I am using 5v power supply. I am doing exactly what you have showed but the problem is that Leds lit very dim. I have checked the output voltage and it is around 3 volts. I am using BC547 transistor. How do I fix it and get full brightness from Leds? Btw I do not anything about electronics :)
Seems non-retriggerable mode would be good if you were, for example, counting the number of movements in front of the PIR, and once a threshold was reached, you then set a flag to send a message such as: "there seems to be a lot of movement in front of your car - it might be being stolen".
Can this be done with Halloween or Christmas animatronics? Most of my units run on 3.75v to 6v (3 to 4 AA batteries). I would be using the "TRY ME" wire, removing the pressure button. This is usually just a completion of circuit function to run the animatronics 1 time. I purchased the same small PIR as you are showing from Amazon... 5 for $16. Mine are rated to run on 2.7v to 12v but have the same VCC, V-Out, & GND connections.
Hello, thank you for nice explanation but i have an issue. I use 4 batteries AAA and the lights still turning on and off without any motion in area. How to fix this issue?
Hi Big Clive! :) Very interesting info here! I have a question: did you manage to compare and/or change the response time, and/or the retriggering time after detection in these models? For what the models i have is concerned, i see a minimun HIGH time of about 3 seconds, and then about 5 seconds of stopped time to retrigger (in single triggering mode). In autoretriggering, as you explain, device is in HIGH continuously if there is a motion detection, but then, again 5 seconds of 'stop' time. I tried to make some hacks on resistor in order to decrease this time, unsuccesfully. Have you got any info or results in this way? thanks so mucho! Javi
Sir, I have a question regarding my project. I am using PIR motion sensor and it is detection a movement and for 5 seconds and after that it is showing no motion even though motion is still occurring and then it shows motion. So is there any way to decrease the delay?
I brought one of this pir module and it was written on its description that its timing can be adjusted from 3 seconds to 5 minutes but when i adjusted its timing to maximum it stayed on for about 11 seconds and no more then that. This really disappointed me. Do you know whats the problem?
I recently installed an LED sensor light for my sister. It has an awful sensitivity. It doesn't turn on till you're right in front of it. I'm wondering if there's a way to make it more sensitive?
+Siskin's Bits and Bobs Aside from the suggestion of repositioning it (it will see more movement if not pointing directly at the target) you may be able to adjust its sensitivity. The outdoor lighting sensors often have three adjustments. Dusk sensor, time and sensitivity.
+bigclivedotcom I tried quite a few postions. I've fiddled with all the adjustment potentiometers to no avail. I just can't make it happy. I've done my back in at the mo' so I can't try any new ideas for a while. Thanks for the reply.
hey clive, if you want to control a relay with this, can you just connect the pir output to the relay coil using a resistor? I don't know if the pir output current is too low or what but I've never seen anyone doing that. thx.
Hello! Is it unwise to change the Fresnell lens to use a larger one? I want to use these cheap Ebay modules in a repurposed (previously 240v) ceiling mount and get a low voltage signal out of it. But the ceiling mount obviously has its own lens, slightly larger
The polythene lens just provides a series of sharp infrared contrasts to the sensor. As long as the new sensor is in the same place as the original one in the unit it will have the same coverage and sensitivity.
Thanks for that detailed description and pointer to the datasheet...I got 3 of these from Aliexpress and one from Amazon...the jumper between high and low was missing on the ones from China but the rest of the boards look identical. The purpose of the potentiometers was also a mystery but your video clarified that. I still need to look at the output voltage to figure out if its linear or just switches on to a high voltage. The current draw is also a concern, will it be enough to drive a large NPN into saturation for a 500 ma load (12V LED string) or should I use a Darlington UL2003 to not worry about current multiplication factors.
Clive, I've had issues getting these to work. I connect to a 5V supply and ground, and the pots are set to minimum sensitivity and minimum time, it just cycles through the output high -> output low for built in delay -> output high, cycle, and repeats. Any idea what causes this?
Dave Pye if I set it to high, then the output just remains high for ever. Initially thought it was just really sensitive, but it still does the same, even when the module is in my desk drawer...
OK Peter, just checked out the timing controls on the scope. It's very sensitive and the smallest tweak increases the hold on time significantly. It appears to have a logarithmic response. Try this, with the pots facing down, turn the left dial fully anticlockwise and see what happens. Let me know the result.
Dave Pye that's how I've had it set. The turning it to the left sets the output high for about 3' seconds, before it goes low for 5, and then repeats. Turning it all the way to the right makes the output high for a few (agonizing without clips for my multimeter) minutes. I've just tries another module from the batch of ten that I bought, and this one seems to work, the first four all do the high low dance I described earlier. Anyway, looks like I'm sorted, thanks for the help!
Heyy Clive, You talked a bit about the chip supporting a LDR and you where not sure if the trigger disable pin was just connected to 5V. If you look closely at the big PIRs you can spot two trough hole solder pads in the middle. That's so you can add a LDR yourself ;) The pull up resistor (R2 in the schematic) is already there.
top bananas, thanks Clive, just got mine working working on trying to connect it to another light source but that one has a switch on it maybe bypass the switch all together.
How to connect a 12V LED strip light directly to the sensor without using any resistor or transistor or a relay. The LED strip light will be powered by 12V 5A driver. The setup will be mounted underneath the kitchen platform. The LED strip light should turn ON when the drawer is opened. Why are transistor and resistor mandatory? What would happen if remove them and connect LED strip light directly? Please respond.
@@bigclivedotcomi created the ckt using this Sensor supported by BC547 transistor and 1k resistor. While I get 12V output from this ckt, but the LED strip light is too Dim. I removed the resistor and the brightness increased a bit. IMO the brightness of the strip after connecting to this ckt would 5% of the regular one. What should I now?
Could an LED circuit fitted with the smaller model PIR be driven by just x2 AAA NiMh batteries (2.4V) or would it need some sort of step up to 4.8V? If so what would you need?
The modules have a 3.3V voltage regulator which could possibly be bypassed to allow lower voltage operation, but the LEDs may not be bright at a voltage so close to their forward voltage.
Thanks for the useful info Clive - I've been wondering how to make best use of my PIR to make a hallway night light. I hooked up the output and ground driving various LEDs, which always seemed to be under-driven by a few tenths of Vs from getting full brightness. Am I right in thinking there's some sort of LED voltage detector built into the PIR module (mine is very similar to the larger square one with 2 orange presets you show in your video).
These units are not designed to drive a load. They can only put out a small current for other circuitry to use. Hence why I added a transistor to allow them to drive a higher load in one of the videos.
Assuming the LED is 1W you then choose a transistor for 1W for this application? Instea of a transistor, Could I put a 3vdc relay to manage higher AC or DC currents? Thanks
Dear Clive, I watched this vid sometime ago and it was/is excellent. Now I would like to link this sensor to the 130lm camping/solar light system you have also reviewed. Would the voltage be OK?
Might be possible to use only three nimh batteries by bipassing the 3.3 voltage regulator inside the pir, and soldering a wire directly from the battery pack to the pir 3.3v pad
Hi Clive great vid ! I have an outdoor PIR which has stopped working ( started to just flash on and then go off ,now not working at all ) question is can I just replace the module ? I suppose they are all different sizes so I would have to get the correct one , many thanks , Nick .
Thanks Clive for the quick reply , yes I would normally replace the whole PIR but I never have seen another like this one , worth a try as a new module can be bought for so little .
I have the same issue. When it got cold out, it stopped working. Took it inside and when it warmed up, it started working again. Using some cold spray, it appears that the PIR sensor is at fault. If I hit it with cold spray, the light stops working. I would like to just replace the sensor but am not sure how to source a new one.
I have been using a outdoor solar charged security light with pir sensor - it is as bright as the sun but even on the most sensitive setting it is fairly dumb. I have to jump up and down waving my arms at it to get it to fire. Guess that's why it was $20 us
These little PIRs are great, each year I've used them at Christmas, I run a set of small xmas trees along our drive/pathway, put a PIR in each one, so as you walk up the drive they light in sequence, a nice little effect and cheapo!
+Andy Brown Replying to myself is always a bit strange, but anyway, the method of adding the transistor as +bigclivedotcom shows is a much better way than I'd done in the past.
My method fed each individual xmas tree set of LEDs back, and the output of the PIR, so each tree had 4 wires to it (+ve -ve LED-trigger PIR-output) which made it quite a mess wiring back 10 of these to my garage! Back in the garage I then used an Arduino (overkill!) to read the inputs coming from the PIRs and then switch a relay bank for the output. It was a bit heavy-handed approach, but gave me the advantage I could do a sequenced display on them when nobody was in front of them triggering the PIRs.
I'll do a video myself shortly with my plans this year as Clive has given me a bit of inspiration!
Instructive video explaining electronic circuits that are triggered by PIR modules. Thank you for explaining this popular and widespread application so nicely !
I have been experimenting with logic level mosfets with these PIR sensors due to low current output but they usually didn't work for me , my only option was to use arduino to trigger a transistor but with this circuit design you have made my day sir.. I guess there always is something to learn after all :-)
Thanks a lot again for sharing and making the world a better place , at least for me :)
ua-cam.com/video/ZC_sEW3_694/v-deo.html
Clive, ur videos stand among the crowd..clear,educating, no BS...you re the man bro.
I like your use of standard connectors to build devices. Lots of people spew about lego building blocks. But you build things. Bravo.
Great video to get me started on PIR in many places. I probably drive a relay with them to power various lighting needs and setups. The sensors also fit almost anywhere. Perfect.
Excellent tutorial anyone who didn't study electronics will find this informative. These pir modules didn't exist when I studied, shows my ancient age.
Thanks for the video, been looking for a tutorial for using pir sensors without a microprocessor, lots of help!
Another totally Awesome BIG CLIVE production ! ;-) love Your vids Clive ... takes me back to when I should have been listening in School ! My Fave Project I made for my exam was A Bc108 trans circuit used as a water detector then applied to a window frame to close when rain detected of course .. back in 86 this was cutting edge stuff ! lol.. Look forward to more great vids Clive ..
Was really hoping a new video came out soon. I really find them interesting. This one is one of your best, add you actually went through some (additional) circuit design. Nice job.
I always thought that the lens columnated what the PIR "sees" (in theory making it possible to walk around the beams) but your explanation makes sense. You are a natural teacher. Keep up the good work.
BTW... What's up with the one hater on all your videos? 10 minutes after any video you post there is one hater who posts a "thumbs down". You would think he would just stop watching if he feels that strongly. Thumbs up from here. ☝
+Markus Bates I've just given it a thumbs down myself to stop it looking lonely.
+Rich Booth dont worry about the thumbs down, apparently its all user involvement to youtube, also weirdly, from PC you can thumbs down a comment, but not from ipad or cell phone. thumbs up or nothing! weird, not that thumbing down a comment does anything useful anyway
+jusb1066 I actually just did it from my iPad, but in the desktop version of UA-cam.
bigclivedotcom
ahah, yeah i forgot you can from that side, i actually hate the app becuase its so hard to navigate
+Rich Booth yes i love the vid
Ive used loads of these modules in the past, if you look closely on the front of the board next to the pir sensor itself there's two pads there for a standard ldr to fit under the fresnel lens for night only operation!
Lewis Wilson LDR?
A photoresistor (or light-dependent resistor, LDR, or photo-conductive cell)
Neat stuff
I use this PIR as a movement sensor light. 3 X 1.5 Alkaline batteries with almost the same circuit you have there. I fitted an LDR and it works a treat. In our bathroom the batteries last about a year. I put all the electronics in under the Fresnel lens and used a 5630 LED with about 15mA drive. That lights up the whole room. Cost here on eBay was around $1.20 each for the PIR and the LEDs were $3.15 for 100 on a tape.
but is the voltage enough for the PIR sensor?
Bought one of these for €0.70 (£0.52) after watching this video a while back. Been experimenting with it as a cat-on-kitchen-worktop-detector (soon to be deterrent once I find a suitable motor to hook up to this tambourine!) and it works rather well. For some reason with the jumper in the default (L) position the output stayed high constantly, no matter what I did. Removing the jumper entirely gave me the desired functionality. Thanks for the video.
Just got a few of these modules to play with and with no documentation, was wondering what the jumper and the pots did, then this turned up in suggested videos. Thank you for a good explanation of it all.
Excellent explanation of the break down of the PS! I've got some work to do to understand all the components. But, now I have a great road map!
I watch your videos regularly, but it's very handy to dip into "classic clive" from 7 years ago. I bought my first PIR module (noob alert) and confidently wired it to my ESP32 microcontroller. It detects movement ALL the time. Thought it was a dud, but MAYBE it just needs the transistor you mention in this video, as the ESP32 must be fluctuating quite a bit based on what I have already connected to it, the voltage/current to the PIR must be all over the place...I shall experiment!...BUT NEVER EXPERIMENT WITH 240V...again. Glad I didn't throw it away, it may work perfectly fine with the correct knowledge!
i think you can just add a pull down resistor to make it work
I bought a bunch of these HC-SR501's, and they all go off all the time, every few seconds. Completely useless. I've done more research, and they are crap. Many people complain of the same issue. Pull up or down resistors, extra capacitors, do not work. These super cheap PIR's are just no good. One place suggested getting Panasonic PIR's, in the EKMB or EKMC series. I got several for about $10 each from DigiKey, and these work perfect. They take either 3.3 or 5 volts in, but the output is 0.5 volts less that the VIN, so I supplied them with 3.3v so I don't overload the input on my ESP32. They are working perfectly, no false alarms.
Ofcourse when I'm looking for something obscure like this you've done a video on it😂
Great video. The diagram of the PIR you drew looked like you were going to draw a portrait of BOB ROSS. LOL.
Very nice presentation - you set the standard for factual YT videos.
This video tittle literally describes word for word exactly what I was looking for. Thanks !
Also I found those LED lights to be called 'Copper String Lights'
Light emitting diode
Fantastic description of how PIR works. Now it makes sense! Thanks!
Koray
Great video and box idea. I used one of these modules, buffered by a BC109 transistor and a reed relay to control a DFPlayer mini, to play an mp3 file from a micro-sd card. Run from 6 D-cell batteries. Strange problem, it played permanently except when somebody got close; it turned out the speaker magnet (external field) was opposing the reed relay coil's field causing the reed relay to operate as NC instead of NO! Moved it away from the magnet and now the module works fine, and my visitors will have ghost sounds at Halloween!
Nice, it is this sort of magic that make projects worthwhile
Great Video Dude. Keep up the great work. & Happy New Year. Nick.
thanks Big Clive, that was pretty cool, I also bought some of those and this was a very helpful video for understanding them!
VERY interesting article, and plenty of food for thought where device incorporation is concerned. Living in the Southern Hemisphere we don't bother with PIR when we have the Christmas (solar) lights out on the garden bushes, etc., 'cause we have no shortage of "Aussie Strength" midsummer sunshine during the day :-)
I'd add to your description that PIR window is silicon, the FET is usually connected externally as a source follower buffer with the drain heavily decoupled, and you can implement a simple detector with an LM358 dual op-amp and a discrete transistor threshold detector.
Also they detect far infra-red around 10 micron not the near infra-red as used in remote controls, two-element PIRs need to be mounted so the target movement is across the two elements one after the other - they're nowhere near as sensitive to movement at 90º. Due to the two elements in opposition they detect moving changes in temperature* which can mean colder as well as warmer, and the Fresnel lenses are moulded in HDPE.
* Actually it's changes in IR energy received, which can be down to temperature and/or emissivity of the target.
Hi Graham. Found your comment very interesting. I want to make a simple PIR circuit for Arduino that sends a pulse or toggles a digital line every time movement is sensed (with no retriggering - the arduino code will handle that).
You mentioned an LM358 and a transistor. How simple can the circuit be that connects to an Arduino's digital input? Are we talking three components?
+Mat Smith It's a lot more than just three components. The LM358 etc is just the starting point - there's something like 20-30 other components needed. Believe me you're far better off using one of these modules than rolling your own.
Along with the pyroelectic sensor is a bunch of supporting circuitry, resistors and capacitors. It seems that most small hobbyist sensors use the BISS0001 ("Micro Power PIR Motion Detector IC"), undoubtedly a very inexpensive chip. This chip takes the output of the sensor and does some minor processing on it to emit a digital output pulse from the analog sensor.
you can increase the input impedance of the transisitor buffer by bootstrapping the input terminal of the transistor thus minimizing the loading effect on the pir module or better yet employ a complementary feedback pair where there is 100% feed back to the emiiter and base of the driver transistor taken from the collector current of the second transistor of the CFP resulting in an even much higher input impedance
I have come across units that use LM324 chips. Those ones always have a relay.
Serendipity as I have been thinking on doing just this. Superb.
Evening, I’m trying to use MP2307 Adjustable Mini360 DC-DC Converter Step Down Buck Voltage Regulator but I’m getting lost as on your diagram only one wire come out the bottom, but on my regulator there are two outputs, can you offer any help? Happy to put a video up on my channel if needed
Good simple explanation on PIR's
Your videos have inspired me to learn something about electronics. I love the way you showed the development of the circuit and I realize that you posted this a year ago, but I really want to know how you chose the value of the two resistors.
The base resistor was selected experimentally based on supplying enough current to turn the transistor on fully without loading the PIR module too much. The series resistor for the LEDs was chosen to provide enough current to make the LEDs glow at a decent intensity, but not draw too much current to maximise the battery life. Both can be adjusted within reason.
hello clive,i have big problem my pir sensor.when i switch on pir sensor active nicely.no any motion continue activating again and again.can u tell what is the reason.i checked 3,4 sensor same problem
At 7:08, why not an N-channel MOSFET? You'd have lower on resistance and wouldn't be loading the PIR down with base current.
I just got one of these sensors. I plan to use it with my Raspberry Pi and a camera module to:
A) sense motion
B) take a photo
and C) email the photo to me.
I found this video while searching for the chip on that tiny PIR module. It's sold as hc-sr505 but the chip markings on the 8-pin are removed. That's stupid, what are they trying to hide?
I need to buy this guys notebook that he keeps drawing in.
China is ahead of you! i bought a while back, a pir 8 led light, takes 2xaa (which i like, esp as it works fine with nimh) not waterproof though, but might do as you suggest and put in a cheap tupperware, its been running reliably for about 3 months on same batteries, i probably activate it 30 times a day, (it also has the light sensor so no activation in bright light) it was meant for my garage, but i leave it in the kitchen on these dark evenings to save me always turning the light on. can post ebay number if anyone intersted.
+jusb1066 > can post ebay number if anyone interested.
Please do!
+ehjones 301679278314 from ebay uk , i bought 1 of these, and have ordered a couple more
+jusb1066 I found a retriggeable PIR cabinet light from Lidl, it uses 1 AAA battery and some sort of step-up regulator to drive the PIR circuit and a single LED. It has a LDR to not trigger in daylight and lasts a few weeks on the same battery, even when triggered multiple times every night. I use it as a night light to see my way into the bathroom.
An area of pirs not covered well is the effects of external temperature. Early thermal imagers and perhaps still used gadolinium lenses cooled down with liquid nitrogen. Another site says that pirs will not work in hot climates. Space is made for a thermistor on some pirs. Pirs work much better in winter in the UK and not so well in the summer. Can this be sorted with a thermistor? Does cooling the unit increase the sensitivity or does the range extend in a cooler environment or both? Just a thought or two.
Great learning opportunity you provide, many thanks
The PIR sensors detect thermal difference. You can adjust the sensitivity in the summer.
Nice video Clive - I just received 3 of these modules by mistake instead of the buck boost converters I ordered.
Now I know what they are, I'll have to find something to make with them...
The 3.3V output probably won't be enough to trigger a mosfet to switch a couple of 100W LEDs @ 32-34V, but a transistor should be able to bump it up.
I just found out that those big PIR's
false trigger when using 3.7v.
I just removed the protection diode & directly connected it to 3.7v.
It works fine!!!!
+A B I D They do. It defeats the voltage regulation, so they constantly re-trip when they turn off and the voltage changes slightly. That diode does buy you an extra half volt of operating voltage.
i have 12v LED chip connected with 12v battery throw a resistor witch can be light up with on / off button
now i have sr501 motion sensor .so plz tell me how to make the conetion
will i need any thing else.
They're like a giant compound eye.
Hi sir
Thank you for your interesting video and I am thinking applying it for my car. How is schematic looks like to use 12v car battery as a source to drive a horn (similar car's horn) as a siren?
Thank you in advance for your advice.
every time I watch a movie again I learn something, good work m8 Thank you and make more PLz :)
I finally got my Raspberry Pi wired up with one of these PIR modules. It sends a signal to my Raspberry Pi to take a photo and email it to myself. I added an LED to let me know when it senses motion. It is so sensitive, I can just smile and it will trigger. The two potentiometers don't seem to change the sensitivity. I guess I could partially cover the lens to lessen sensitivity.
Just the circuit I was looking for. 👍
Can you tell me how to change the delay on the HC-SR505. It is 8 sec and I wand about 0.5 sec. i can solder surface mount if needed. No one seems to have tried this in the net yet!
I wired mine the same way as your drawing, but without the transistor. It' working just the opposite. The led stays on and goes out when I put my hand in front of the sensor. I'm waiting on transistors to arrive in the mail. Will using the transistor make this work right?
I would have never guessed that these work by sensing body heat. I see them all the time in my classrooms, and at the local supermarkets to turn the lights on in the coolers when you're in front of the door.
I really enjoyed this video.
HAY?
I am in the USA....
Is there a way to connect one of these to the door's light fixture, so it will utilize the 110V to power the sensor and activate the bulb when there is motion?
I am not that great with electronics, but I can understand clear instructions..
THANKS
You do get outdoor sensors designed to work with 110V.
THANKS! lol
Hi Clive, I'm sure you are aware of those PIR sensor built in LED light Bulbs (E27 and B22). I have bought some but they stop to work after about a week of use. Do you what what could be causing them to fail?
If they are effected by a warm body passing in front of the sensors why then does moving grass etc. set them off?
Anything that can cause a heat disturbance or reflect heat can trigger a PIR. But it usually requires a large temperature difference like an animal.
Nice neat detectors, and if you want to drive the leds harder then replace the npn with a darlington type.
That tiny one is really neat :-)
Are there discussions of what goes into designing and building the actual PIR modules themselves?
Could it be possible to make a matrix of the IR sensors to create a rudimentary heat camera?
They have a differential arrangement inside that is only really suited to detecting a difference between the two sensors. If you covered one it might work to a degree, but not as well as a proper thermal camera.
bigclivedotcom good to know. I might have a play... I only need about an 8x8 pixel resolution for what I'm trying. Thanks dude. Worth a shot at. Never know I might accidentally learn something too 😎
rundata I haven't checked, but I'm pretty sure you could buy IR sensitive photodiodes for your matrix. They're contained in some proximity and beam-break sensors. If your camera needs a lens then it mustn't be normal glass, as clive shows. Maybe quartz or fluorite? Dunno. Maybe pricey.
I don't know much about electronics, but where can you get an emitter (the one you connected the output, negative and LEDs negative with)? I have had no luck so far
You're looking for an NPN transistor. Depending where you are in the world it may be able to get a BC547 or 2N3904. These are very cheap and common low power transistors. You can also buy them on eBay. Note that different transistors have the emitter, collector and base on different pins so you have to check online to see which pinout your transistor style has.
I have to ask you. I send in 11,1v lipoly. but I dont get more out than around 2v. I want it to turn on an led stripe. What do I wrong. It function normal but dont give me more than those 2v.
Getting so many spooky halloween ideas. :-)
Could you tell me the type of transistor you use in this project and how to connect it ? Thanks in advance
Very useful video I ordered 1 of these and it's just come in the post.
play time ;-)
Hi I have a Question. Can I use this with the home outlet 110V instead of the battery? Should I used a bigger Transistor and if so how big? Also Can I use a 5 watts light bulb instead of a bunch of LEDs? If I use batteries can it be 9 Volts or 6 Volts is the maximum? I have very limited knowledge on electronics but I am learning a lot here.Thanks for your help.
You can get outdoor PIR units for security lights that do work from mains voltage and allow the switching of larger lights.
You can also get inline 12V ones that allow switching 12V lights or LED tape run from a plug-in 12V power supply.
Hello, thanks for the video. I am trying to use this sensor to light a strip of 5v leds. I am using 5v power supply. I am doing exactly what you have showed but the problem is that Leds lit very dim. I have checked the output voltage and it is around 3 volts. I am using BC547 transistor. How do I fix it and get full brightness from Leds? Btw I do not anything about electronics :)
The transistor is only rated to run about 100mA. If the strip has built in resistors then the one shown in series with the LED would not be needed.
Thanks. I'll try some other resistor.
Seems non-retriggerable mode would be good if you were, for example, counting the number of movements in front of the PIR, and once a threshold was reached, you then set a flag to send a message such as: "there seems to be a lot of movement in front of your car - it might be being stolen".
Can this be done with Halloween or Christmas animatronics? Most of my units run on 3.75v to 6v (3 to 4 AA batteries). I would be using the "TRY ME" wire, removing the pressure button. This is usually just a completion of circuit function to run the animatronics 1 time. I purchased the same small PIR as you are showing from Amazon... 5 for $16. Mine are rated to run on 2.7v to 12v but have the same VCC, V-Out, & GND connections.
great vids! Aside from using 4 batteries what is another solution for dealing with the FP flickering? I'm plugging in through 12V
Hello, thank you for nice explanation but i have an issue. I use 4 batteries AAA and the lights still turning on and off without any motion in area. How to fix this issue?
Are you trying to drive LEDs directly from the module?
Is there any reason you don't use 18650's in place of the nimh batteries? obviously the voltage differs but that's easy enough to get over
Hi Big Clive! :)
Very interesting info here! I have a question: did you manage to compare and/or change the response time, and/or the retriggering time after detection in these models?
For what the models i have is concerned, i see a minimun HIGH time of about 3 seconds, and then about 5 seconds of stopped time to retrigger (in single triggering mode). In autoretriggering, as you explain, device is in HIGH continuously if there is a motion detection, but then, again 5 seconds of 'stop' time. I tried to make some hacks on resistor in order to decrease this time, unsuccesfully. Have you got any info or results in this way?
thanks so mucho!
Javi
Sir, I have a question regarding my project. I am using PIR motion sensor and it is detection a movement and for 5 seconds and after that it is showing no motion even though motion is still occurring and then it shows motion. So is there any way to decrease the delay?
Got me thinking of a project in mind.
Thanks BC!
I brought one of this pir module and it was written on its description that its timing can be adjusted from 3 seconds to 5 minutes but when i adjusted its timing to maximum it stayed on for about 11 seconds and no more then that. This really disappointed me. Do you know whats the problem?
I recently installed an LED sensor light for my sister. It has an awful sensitivity. It doesn't turn on till you're right in front of it. I'm wondering if there's a way to make it more sensitive?
+Siskin's Bits and Bobs PIR sensors have better response on sideways motion across the sensor, instead of head on movement. Reposition the sensor.
+Siskin's Bits and Bobs Aside from the suggestion of repositioning it (it will see more movement if not pointing directly at the target) you may be able to adjust its sensitivity. The outdoor lighting sensors often have three adjustments. Dusk sensor, time and sensitivity.
+bigclivedotcom I tried quite a few postions. I've fiddled with all the adjustment potentiometers to no avail. I just can't make it happy. I've done my back in at the mo' so I can't try any new ideas for a while. Thanks for the reply.
hey clive, if you want to control a relay with this, can you just connect the pir output to the relay coil using a resistor? I don't know if the pir output current is too low or what but I've never seen anyone doing that.
thx.
It would require a transistor to switch the relay.
Hello! Is it unwise to change the Fresnell lens to use a larger one? I want to use these cheap Ebay modules in a repurposed (previously 240v) ceiling mount and get a low voltage signal out of it. But the ceiling mount obviously has its own lens, slightly larger
The polythene lens just provides a series of sharp infrared contrasts to the sensor. As long as the new sensor is in the same place as the original one in the unit it will have the same coverage and sensitivity.
Thanks for that detailed description and pointer to the datasheet...I got 3 of these from Aliexpress and one from Amazon...the jumper between high and low was missing on the ones from China but the rest of the boards look identical.
The purpose of the potentiometers was also a mystery but your video clarified that.
I still need to look at the output voltage to figure out if its linear or just switches on to a high voltage. The current draw is also a concern, will it be enough to drive a large NPN into saturation for a 500 ma load (12V LED string) or should I use a Darlington UL2003 to not worry about current multiplication factors.
Hi BigClive. Thank you for your video. Very instructive. Is there a way to change the detection distance of the mini PIR detector? Thank you.
The bigger ones have an adjustment the smaller ones don't.
+bigclivedotcom Thank you for replying and for posting this tutorial.
Clive, I've had issues getting these to work. I connect to a 5V supply and ground, and the pots are set to minimum sensitivity and minimum time, it just cycles through the output high -> output low for built in delay -> output high, cycle, and repeats. Any idea what causes this?
Hi Peter, check your re-triggerable/triggerable mode select on pin 1. Clive covers this in the video. It should be set to high.
Dave Pye if I set it to high, then the output just remains high for ever. Initially thought it was just really sensitive, but it still does the same, even when the module is in my desk drawer...
OK Peter, just checked out the timing controls on the scope. It's very sensitive and the smallest tweak increases the hold on time significantly. It appears to have a logarithmic response. Try this, with the pots facing down, turn the left dial fully anticlockwise and see what happens. Let me know the result.
Dave Pye that's how I've had it set. The turning it to the left sets the output high for about 3' seconds, before it goes low for 5, and then repeats. Turning it all the way to the right makes the output high for a few (agonizing without clips for my multimeter) minutes.
I've just tries another module from the batch of ten that I bought, and this one seems to work, the first four all do the high low dance I described earlier.
Anyway, looks like I'm sorted, thanks for the help!
Is it a stable power supply, and are you driving a load directly with the output pin?
What is the source for the small PIR and do you have a model number. Thanks.
Heyy Clive,
You talked a bit about the chip supporting a LDR and you where not sure if the trigger disable pin was just connected to 5V. If you look closely at the big PIRs you can spot two trough hole solder pads in the middle. That's so you can add a LDR yourself ;) The pull up resistor (R2 in the schematic) is already there.
I learned a lot from this video, thanks
top bananas, thanks Clive, just got mine working working on trying to connect it to another light source but that one has a switch on it maybe bypass the switch all together.
How to connect a 12V LED strip light directly to the sensor without using any resistor or transistor or a relay. The LED strip light will be powered by 12V 5A driver. The setup will be mounted underneath the kitchen platform. The LED strip light should turn ON when the drawer is opened.
Why are transistor and resistor mandatory? What would happen if remove them and connect LED strip light directly?
Please respond.
The circuit can't drive high loads. It absolutely needs a buffer. That also avoids false retriggering caused by high current fluctuation.
@@bigclivedotcomi created the ckt using this Sensor supported by BC547 transistor and 1k resistor. While I get 12V output from this ckt, but the LED strip light is too Dim. I removed the resistor and the brightness increased a bit. IMO the brightness of the strip after connecting to this ckt would 5% of the regular one. What should I now?
Interface with small relays and switch line voltage lights
What distance will PIR's work? Are the same ones used with Arduino?
Need a Darlington pair, output current of pir is tiny and light wont fully turn on
The circuit shown is for a small transistor with good gain, and low LED loads. A Darlington would allow higher loads, as would an A2SHB MOSFET.
Coool, Thanks Mr.C, .... always wondered about them :~)
Could an LED circuit fitted with the smaller model PIR be driven by just x2 AAA NiMh batteries (2.4V) or would it need some sort of step up to 4.8V? If so what would you need?
The modules have a 3.3V voltage regulator which could possibly be bypassed to allow lower voltage operation, but the LEDs may not be bright at a voltage so close to their forward voltage.
Thanks for the useful info Clive - I've been wondering how to make best use of my PIR to make a hallway night light. I hooked up the output and ground driving various LEDs, which always seemed to be under-driven by a few tenths of Vs from getting full brightness. Am I right in thinking there's some sort of LED voltage detector built into the PIR module (mine is very similar to the larger square one with 2 orange presets you show in your video).
These units are not designed to drive a load. They can only put out a small current for other circuitry to use. Hence why I added a transistor to allow them to drive a higher load in one of the videos.
Assuming the LED is 1W you then choose a transistor for 1W for this application? Instea of a transistor, Could I put a 3vdc relay to manage higher AC or DC currents? Thanks
Hello! I was wondering if this would work the same way if I use neopixels instead of those led strings? Thank you!
+Victoria Davalos Neopixels need a controller to send them data.
Thanks so much for your answer. What kind of controller? I'm sorry, I'm not (yet) that familiar with arduino:)
How much current PIR Sensor takes ?
Dear Clive, I watched this vid sometime ago and it was/is excellent. Now I would like to link this sensor to the 130lm camping/solar light system you have also reviewed. Would the voltage be OK?
I could use your skills on our team :) Very interesting, thanks for posting
Might be possible to use only three nimh batteries by bipassing the 3.3 voltage regulator inside the pir, and soldering a wire directly from the battery pack to the pir 3.3v pad
That could result in instability due to the voltage fluctuations when the lights were switching.
Thanks for the reply :D I'm a big fan
Thanks. Very helpful!
Hi Clive great vid ! I have an outdoor PIR which has stopped working ( started to just flash on and then go off ,now not working at all ) question is can I just replace the module ? I suppose they are all different sizes so I would have to get the correct one , many thanks , Nick .
It's usually best to replace the whole PIR unit. If it's built onto a floodlight you may be able to get one that utilises the same mounting hole.
Thanks Clive for the quick reply , yes I would normally replace the whole PIR but I never have seen another like this one , worth a try as a new module can be bought for so little .
I have the same issue. When it got cold out, it stopped working. Took it inside and when it warmed up, it started working again. Using some cold spray, it appears that the PIR sensor is at fault. If I hit it with cold spray, the light stops working. I would like to just replace the sensor but am not sure how to source a new one.
I have been using a outdoor solar charged security light with pir sensor - it is as bright as the sun but even on the most sensitive setting it is fairly dumb. I have to jump up and down waving my arms at it to get it to fire. Guess that's why it was $20 us