IR Sensor Module Circuit

electronics

ByJayant 41

Infrared Sensor Module Circuit Diagram

Sensors are very important part of electronics, especially in Robotics and Automations. Sensors in electronic devices make our life easy by automatically sense and control the devices, without human interaction. There are many kinds of sensors like Fire sensor, humidity sensor, motion sensor, temperature sensor, IR sensor etc. In this article, we will explain about IR sensor (Infrared sensor), how it works and how to build an IR sensor Module.

 

IR sensor is very popular sensor, which is used in many applications in electronics, like it is used in Remote control system, motion detector, Product counter, Line follower Robots, Alarms etc.

 

IR sensor basically consist an IR LED and a Photodiode, this pair is generally called IR pair or Photo coupler. IR sensor work on the principal in which IR LED emits IR radiation and Photodiode sense that IR radiation. Photodiode resistance changes according to the amount of IR radiation falling on it, hence the voltage drop across it also changes and by using the voltage comparator (like LM358) we can sense the voltage change and generate the output accordingly.

 

The placing of IR LED and Photodiode can be done in two ways: Direct and Indirect. In Direct incidence, IR LED and photodiode are kept in front of one another, so that IR radiation can directly falls on photodiode. If we place any object between them, then it stops the falling of IR light on photodiode.

IR Light

And in Indirect Incidence, both the IR LED and Photo diode are placed in parallel (side by side), facing both in same direction. In that fashion, when a object is kept in front of IR pair, the IR light gets reflected by the object and gets absorbed by photodiode. Note that object shouldn’t be black as it will absorb all the IR light, instead of reflect. Generally IR pair is placed in this fashion in IR sensor Module.

IR Working

To build an IR module, we mainly need IR pair (IR LED and Photodiode) and LM358 with some resistors and a LED.

 

IR LED

IR LED emits light, in the range of Infrared frequency. IR light is invisible to us as its wavelength (700nm – 1mm) is much higher than the visible light range. Everything which produce heat, emits infrared like for example our human body. Infrared have the same properties as visible light, like it can be focused, reflected and polarised like visible light.

IR LED

IR LED looks like a normal LED and also operates like a normal LED, it consumes 20mA current and 3vots power.  IR LEDs have light emitting angle of approx. 20-60 degree and range of approx. few centimetres to several feets, it depends upon the type of IR transmitter and the manufacturer. Some transmitters have the range in kilometres.

 

PhotoDiode

Photodiode is considered as Light dependent Resistor (LDR), means it has very High resistance in absence of light and become low when light falls on it. Photodiode is a semiconductor which has a P-N junction, operated in Reverse Bias, means it start conducting the current in reverse direction when Light falls on it, and the amount of current flow is proportional to the amount of Light. This property makes it useful for IR detection.

Photodiode

Photodiode looks like a LED, with a Black colour coating on its outer side. It is used in reversed biased, as showed in circuit diagram below.

 

LM358

LM358 is an operational amplifier (Op-Amp) and in this circuit we are using it as a voltage comparator. The LM358 has two independent voltage comparators inside it, which can be powered by single PIN, so we can use the single IC to build two IR sensor modules. We have used only one comparator here, which have inputs at PIN 2 & 3 and output at PIN 1. Voltage comparator has two inputs, one is inverting input and second is non-inverting input (PIN 2 and 3 in LM358). When voltage at non-inverting input (+) is higher than the voltage at inverting input (-), then the output of comparator (PIN 1) is High. And if the voltage of inverting input (-) is Higher than non-inverting end (+), then output is LOW.

LM358 Pinout

 

IR sensor Module

Components

  • IR pair (IR LED and Photodiode)
  • IC LM358
  • Resistor 100, 10k, 330 ohm
  • Variable resistor – 10k
  • LED

IR Sensor Circuit Diagram

You can see the connections in the IR sensor circuit diagram. Photo diode is connected in reverse bias, inverting end of LM358 (PIN 2) is connected to the variable resistor, to adjust the sensitivity of the sensor. And non-inverting end (PIN 3) is connected to the junction of photodiode and a resistor.

 

When we turn ON the circuit there is no IR radiation towards photodiode and the Output of the comparator is LOW. When we take some object (not black) in front of IR pair, then IR emitted by IR LED is reflected by the object and absorbed by the photodiode. Now when reflected IR Falls on Photodiode, the voltage across photodiode drops, and the voltage across series resistor R2 increases. When the voltage at Resistor R2 (which is connected to the non-inverting end of comparator) gets higher than the voltage at inverting end, then the output becomes HIGH and LED turns ON.

 

Voltage at inverting end, which is also called Threshold Voltage, can be set by rotating the variable resistor’s knob. Higher the voltage at inverting end (-), less sensitive the sensor and Lower the voltage at inverting end (-), more sensitive the sensor.

 

This whole circuit can be placed on PCB to build a proper professional IR sensor Module.

Video

Get Our Weekly Newsletter!

Subscribe below to receive most popular news, articles and DIY projects from Circuit Digest

Comments

  • KATTENS's picture
    KATTENS
    Jun 17, 2016

    waow ..this is good information about IR . I have been searching for something like this

  • Johnny V's picture
    Johnny V
    Jul 16, 2016

    Hello. What is the best material to use as a reflector? Could a normal marble be used for example?

  • ali's picture
    ali
    Sep 12, 2016

    plz..tell me what should be the setting value for variable resistor in this circuit....
    plz help me in this
    l

  • Abhishek's picture
    Abhishek
    Oct 06, 2016

    You can adjust it according to the sensitivity you need. Sensitivity means, from how far it should detect the object.

  • Marie's picture
    Marie
    Oct 14, 2016

    I tried making one but it wasn't working. At certain value of my potentiometer, the LED output is HIGH and becomes LOW when detects an obstacle. What could be the problem? I used all components just similar to yours. Thank you.

  • Arthur Petitjean's picture
    Arthur Petitjean
    Dec 17, 2016

    I tried making one but it wasn't working. At certain value of my potentiometer, the LED output is HIGH and becomes LOW when detects an obstacle. What could be the problem? I used all components just similar to yours. Thank you.

  • Shakeel 's picture
    Shakeel
    Dec 13, 2017

    You should check it inside the room where direct sunlight doesn't fall. There are IR radiations already in sunlight ( and in wi fi router etc). So keep an eye on it.

  • S.M. Bakhtiar's picture
    S.M. Bakhtiar
    Dec 13, 2016

    DEAR CONCERN,

    EXCELLENT TUTORIAL.

    FINALLY I SUCCESSFULLY ASSEMBLED THE PROJECT

    THANKS A LOT ALL OF YOU AND YOUR FAMILY

  • Yameenah's picture
    Yameenah
    Jan 30, 2017

    Thanks alot... It help us great deal ..

  • ilman's picture
    ilman
    Feb 18, 2017

    can this be used in arduino

  • alan's picture
    alan
    Feb 26, 2017

    thank you for the circuit and design part.

  • Praveen T's picture
    Praveen T
    Feb 26, 2017

    what is the function 330ohm resistor here

  • Maddy's picture
    Maddy
    Feb 27, 2017

    Its just a current limiting resistor for LED.

  • brian's picture
    brian
    Mar 06, 2017

    I am currently living in the Philippines and wantedto do a laser tag set up for the neighbor kids. I have a basic knowledge of electronics but do not know how to form the necessary circuitry to both send ir and detect ir to make the plastic guns work. Can you point the way? No need to reinvent the wheel if someone has done this already.

  • omar's picture
    omar
    Mar 21, 2017

    hello my circuit is not working just led is on but I can not do any measurement

  • Bian's picture
    Bian
    May 19, 2017

    This circuit working well but distace of reflection still short, help me to get solution that can make distace of IR LED can longer and reflect more far of distance (ex: 1 meter). I need your help, I wait your reply by email.Thx.

  • rashid's picture
    rashid
    Jun 08, 2017

    is that output pin connected to arduino's digital pin?

  • Mohammad Hussein's picture
    Mohammad Hussein
    Aug 22, 2017

    Hi,
    I really do appreciate your job!!!
    you helped me a lot! Thanks

  • Mohammad Hussein's picture
    Mohammad Hussein
    Aug 23, 2017

    Hey there,
    I think that this sensor has a limited sensibility, am i right?
    if yes how can i increase it?

  • Aswinth Raj's picture
    Aswinth Raj
    Aug 23, 2017

    What do you mean by sensibility here?

    If you are talking about the range, then sorry nothing much can be done to improve it.

  • Sandipan patra's picture
    Sandipan patra
    Sep 13, 2017

    Your circuit is superb . But it detection range is small. How I increase it's range. I mean how I make long range IR module circuit ? Please say.
    I am waiting for your email .

  • Aswinth Raj's picture
    Aswinth Raj
    Sep 14, 2017

    The range of the IR sensor can be controlled by changing the reference voltage of the op-amp. In this circuit, the potentiometer can be varied to change the reference voltage.

  • kk's picture
    kk
    Sep 30, 2017

    what is distance can measred

  • Hritika's picture
    Hritika
    Sep 14, 2017

    Could you please explain me what is the need of ground this circuit.

  • Aswinth Raj's picture
    Aswinth Raj
    Sep 14, 2017

    Hi Hritika,

    Its not just this circuit, every circuit will need a ground. As we know current always flows from positive to negative, this negative potential is usually referred as ground. 

  • Ryuzaki's picture
    Ryuzaki
    Sep 28, 2017

    Hi, can i use a 9v batt here or should i use Lm7805 to decrease my 9v batt to 5v?

  • anonymous's picture
    anonymous
    Oct 04, 2017

    -Is the operational amplifier inverting or non inverting?
    -Would another model of Operational amplifiers work as well? If so which do you recommend. Does the TL084CD work too?
    -Where would be best to obtain these elements?

  • gursewak sigh's picture
    gursewak sigh
    Oct 29, 2017

    Amazing

  • farhan's picture
    farhan
    Feb 06, 2018

    V output when high is equal to Vf LED ~2V
    to send signal to arduino input pin, should take from pin 1 on LM358 where high will be 5V.

  • Nirob's picture
    Nirob
    Feb 09, 2018

    Hi,
    this is superb circuit diagram, but i want to modify it when there is a obstructed the LED goes ON and it goes to OFF only when a reset button is pressed. could you please help me to giving the reference.

    Thank you.

  • Pranay's picture
    Pranay
    Feb 23, 2018

    is there any other ic or any other element that could be used in place of LM-358

  • hiren's picture
    hiren
    Feb 25, 2018

    Hello Jayant,
    That seems great work !!
    i have made it and can work as shown in video :)
    BTW, how can i increase the distance from object to IR photo diode (about 30 cm).?

  • SAIKAT MONDAL's picture
    SAIKAT MONDAL
    Jun 20, 2018

    super explanation.thank you

  • lucky's picture
    lucky
    Jun 23, 2018

    how to set off time even an oscillate in front of the sensor ?

  • dodong's picture
    dodong
    Jun 24, 2018

    can IR be reflected by paper like and envelope? I am trying to install this inside my mailbox to detect if there is a mail inside

  • Jayant's picture
    Jayant
    Jun 25, 2018

    Yes IR will reflect paper and envelop. You can use it for your idea

  • Cess's picture
    Cess
    Jun 30, 2018

    is the IR led a transmiiter or receiver?

  • Yash Vardhan Maheshwari's picture
    Yash Vardhan Ma...
    Jul 13, 2018

    Hi,
    I actually don't understand how the current would flow in the circuit of the IR module using LM358 voltage comparator. It would be very kind and helpful of you if you could tell me the current flow and what is the reason of current flow in one direction and not the other.

    I get a bit confused in parallel circuits.

    Thank You

Log in or register to post Comment