Author Topic: PIR sensitivity adjust in software  (Read 2569 times)

0 Members and 1 Guest are viewing this topic.

Offline HixfieldTopic starter

  • Contributor
  • Posts: 21
  • Country: be
PIR sensitivity adjust in software
« on: February 19, 2017, 05:09:55 pm »
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.html

The 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?
 

Offline sagnikbasu

  • Contributor
  • Posts: 19
  • Country: in
Re: PIR sensitivity adjust in software
« Reply #1 on: February 19, 2017, 06:01:12 pm »
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.
 

Offline HixfieldTopic starter

  • Contributor
  • Posts: 21
  • Country: be
Re: PIR sensitivity adjust in software
« Reply #2 on: February 19, 2017, 07:38:03 pm »
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...
 

Offline Jeroen3

  • Super Contributor
  • ***
  • Posts: 4078
  • Country: nl
  • Embedded Engineer
    • jeroen3.nl
Re: PIR sensitivity adjust in software
« Reply #3 on: February 19, 2017, 08:27:25 pm »
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.
 

Offline bookaboo

  • Frequent Contributor
  • **
  • Posts: 729
  • Country: ie
Re: PIR sensitivity adjust in software
« Reply #4 on: February 19, 2017, 09:12:41 pm »
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-3704
Some 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.
 

Offline HixfieldTopic starter

  • Contributor
  • Posts: 21
  • Country: be
Re: PIR sensitivity adjust in software
« Reply #5 on: February 20, 2017, 06:27:05 am »
@bookakboo iI read your module also has an analogue output could that be connected to the micro adc for reading in?
 

Offline bookaboo

  • Frequent Contributor
  • **
  • Posts: 729
  • Country: ie
Re: PIR sensitivity adjust in software
« Reply #6 on: February 20, 2017, 09:55:33 am »
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/1006209
Loads 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.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf