PIR sensitivity adjust in software - Page 1
Forum section: electronics / general

author: Hixfield
author_rank: Contributor
timestamp: February 19, 2017, 05:09:55 pm
content: What would be the best and easist way to be able to adjust the sensitivity of a PIR module using a microcontroller ( I am using an ESP8266 module)? I am using these cheap modules from aliexpress :http://www.aliexpress.com/item/32249488993/32249488993.htmlThe have a manual potentiometer for sensitivity adjust...Thing I consider:1. Feed the "raw"? signal into the adc of the microcontroller? And let the micro handle the detection thresholding?2. Replace the sensitivity trimmer by an electronic potentiometer chip?

author: sagnikbasu
author_rank: Contributor
timestamp: February 19, 2017, 06:01:12 pm
content: Angle of detection of a PIR sensor is dictated by the shape and construction of its lens. There is no way to modify it in software or in the electronics.Distance depends on the power of the IR source as well as the sensitivity of the IR sensor. This may be able to be tweaked, but the specifics will depend on the schematic as well as the components in use.

author: Hixfield
author_rank: Contributor
timestamp: February 19, 2017, 07:38:03 pm
content: Thanks for the feedback. I dont want any angle or anything I just want to controle the potentiometer (that sets it's sensitivity) on the module with my microcontroller...

author: Jeroen3
author_rank: Super Contributor
timestamp: February 19, 2017, 08:27:25 pm
content: The trigger level is the rate of change. You can make this in software.But you'd have to buy raw pirs, since all modules will have some comparator on them.

author: bookaboo
author_rank: Frequent Contributor
timestamp: February 19, 2017, 09:12:41 pm
content: Most PIR sensors have two elements, one swings positive and the other negative but you will need some amplification to be able to read this. With some software you can determine with fair rate of accuracy the direction of movement. The amplitude and pulse width of the signal are also proportional to the amount of heat movement in the area (hard to quantify this exactly but the distance at which a person is detected can be changed via algorithm).In a current project I use one of these as it has fast digital outputs that can be filtered.https://www.rapidonline.com/b-b-sensors-pir-t1-m1-l0-smd-3-12v-pir-motion-detector-50-3704Some more useful info here:http://www.instructables.com/id/PIR-Motion-Sensor-Tutorial/My projects are simpler in that they don't use a fresnel but suspect the principle is the same.

author: Hixfield
author_rank: Contributor
timestamp: February 20, 2017, 06:27:05 am
content: @bookakboo iI read your module also has an analogue output could that be connected to the micro adc for reading in?

author: bookaboo
author_rank: Frequent Contributor
timestamp: February 20, 2017, 09:55:33 am
content: Yeah I think it can be, I was able to see the traces on the scope but I can't recall the amplitude, should be fine. As we are going for volume and a custom enclosure we've decided to build our own PIR amplifier using a standard element:http://uk.farnell.com/murata/ira-e700st0/sensor-infrared-15v/dp/1006209Loads of example schematics out there, just need some opamp magic.Using a quad opamp the plan is to experiment to find the best detection settings, probably will all get done in the ADC but it may end up easier to set the threshold of one of the comparitors or something..... should be fun.