We are Apogeeweb Semiconductor Electronic

WELCOME TO OUR BLOG

Home  Product Technical Articles   LM358 Comparator: IR Sensor Circuit [FAQ]

LM358 Comparator: IR Sensor Circuit [FAQ]

Author: Mia
Date: 20 Feb 2021
 10609
lm358 applications

I Introduction

Infrared sensor circuits have been widely used in modern life. How come? Due to its characteristics of low power consumption, high reliability, and small mutual interference. For example, a bank opens and closes automatically. When a person walks into the bank, the door opens automatically, and the door closes after leaving. Or the faucet in restaurants such as KFC. When our hands placed under the faucet, the water automatically flows out. And when our hands leave the faucet, the water automatically shuts off. All the above scenarios apply infrared sensor technology.

This blog will lead you to understand LM358 infrared sensor circuits that bring convenience to our lives.

lm358

Catalog

I Introduction

II Circuit Sructure and Woking Principle

III Circuit Design

3.1 Infrared Sensor Circuit

3.2 Sampling Comparator Circuit

3.3 Test Result

IV Ways for Infrared Sensor Circuit Debugging

4.1 Observation

4.2 Resistance

4.3 Basic Circuit Analysis

V Conclusion

Component Datasheet

FAQ

Ordering & Quantity

II Circuit Sructure and Woking Principle

The infrared sensor circuit is composed of the following circuits:

  • Infrared Sensor Circuit. Infrared sensor circuit with infrared transmitting tube D1 and infrared receiving tube D2 as the core;
  • Sampling Comparator Circuit. Sampling comparator circuit with adjustable resistance R3 and general operational amplifier LM358 as the core;
  • Sound Output and Display Circuit. A sound output and display circuit with transistor 9012, V1, V2, buzzer Y1, and light-emitting diode D3 as the core components.

The infrared sensor circuit can also realize the situation below. When the hand is close to the infrared transmitting tube and the infrared receiving tube: the buzzer will sound and the LED light will light up. When the hand is removed, the sound will stop and the LED light will go out. From this, we can find that the sensitivity of this circuit is very high. The infrared sensor circuit is applied in many life scenarios. And it is a circuit that circuit designers must master.

III Circuit Design

When we turn on the 5V power supply to the circuit, the infrared emission tube D1 turns on. If there is no obstruction, the infrared receiving tube D2 does not receive infrared light. And the infrared receiving tube D2 is still in the reverse blocking state. The voltage of the negative pole of the infrared receiving tube D2 is still high. And sent to the 3 pins of LM358. When the infrared transmitting tube D1 is approached by hand, the infrared light is blocked. And it reflected to the infrared receiving tube D2. After the infrared receiving tube D2 receives the infrared light, it is turned on immediately. So the voltage of the negative electrode of the infrared receiver tube D2 drops drastically. And this voltage is sent to the 3 pins of the LM358.

3.1 Infrared Sensor Circuit

When we turn on the 5V power supply to the circuit, the infrared emission tube D1 turns on. If there is no obstruction, the infrared receiving tube D2 does not receive infrared light. And the infrared receiving tube D2 is still in the reverse blocking state. The voltage of the negative pole of the infrared receiving tube D2 is still high. And sent to the 3 pins of LM358. When the infrared transmitting tube D1 is approached by hand, the infrared light is blocked. And it reflected to the infrared receiving tube D2. After the infrared receiving tube D2 receives the infrared light, it is turned on immediately. So the voltage of the negative electrode of the infrared receiver tube D2 drops drastically. And this voltage is sent to the 3 pins of the LM358.

3.2 Sampling Comparator Circuit

The voltage of pin 2 of LM358 depends on the adjustable resistor R3. We can adjust the adjustable resistor R3 to a suitable value (the voltage is about 2.5V. So that it can be ensured that the voltage of pin 3 of LM358 is greater than that of pin 2 of LM358. When V+>V-, pin 1 of LM358 will output a high level. And this will be sent to the bases of PNP transistors V1 and V2 through the current limiting resistor R4, causing the transistors V1 and V2 to be cut off. The buzzer Y1 does not sound, and the LED D3 goes out.

If the voltage of pin 3 of LM358 drops to a voltage lower than that of pin 2,it will be a different situation. When V+ <V-, pin 1 of LM358 will output low level and send it through current limiting resistor R4 to PNP transistors V1 and V2. The base makes the transistors V1 and V2 conductive.

lm358

3.3 Test Result

With the above circuit design and analysis, the circuit is ready for the sensing effect. When the hand moves to the top of the infrared emitter D1 and infrared receiver D2, the buzzer sounds and the light-emitting diode lights up. When the hand leaves the top of D1 and D2, the buzzer stops sounding and the light-emitting diode goes out. So far, this infrared sensing circuit design has achieved the effect we wanted!

IV Ways for Infrared Sensor Circuit Debugging

4.1 Observation

Check whether each component is installed correctly. Here, we should pay special attention to the following points:

  1. Positive and negative poles of infrared emitting diode;
  2. Positive and negative poles of infrared receiving diode;
  3. The pin sequence of LM358;
  4. The pin sequence of the transistor 9012.

4.2 Resistance

Check whether the line is connected normally according to the schematic diagram. Here, a multimeter can be used to detect whether each circuit is on. We mainly check the following two places:

  1. Check whether each GND is connected to the negative terminal of the power supply;
  2. Check whether each VCC is connected to the power connector.

4.3 Basic Circuit Analysis

4.3.1 Maintenance of Infrared Transmitting Circuit

The infrared light emitted by the infrared emission circuit is invisible to human eyes. How can we see infrared light? You can use the camera function of your mobile phone. During the maintenance process, you can use the mobile phone to check whether the infrared light-emitting circuit is normal. Here, we mainly check the following two places:

  1. Resistance of current limiting resistor;
  2. Whether the positive and negative polarity of the infrared LED is installed correctly.

4.3.2 Maintenance of Infrared Receiving Circuit

Use a multimeter to measure the cathode of the infrared receiving diode. Here, we need to observe two voltage values:

  1. Observe the voltage value (whether it is a low level) when the infrared emission tube is placed by hand;
  2. The voltage value when the infrared receiver tube is removed by hand (whether it is a high level).

4.3.3 Maintenance of Voltage Sampling Circuit

Test whether the voltage value of the third leg of the adjustable resistor R3 is around 2.5V. Also, when rotating the adjustable resistor, is the voltage value variable?

4.3.4 Maintenance of Voltage Comparator Circuit

Mainly use a multimeter to measure the voltage of pin 1 of LM358. Here, we need to observe two voltage values:

  1. Observe the voltage value of pin 1 of LM358 (whether it is a low level) when the infrared transmitter tube is placed by hand;
  2. Observe the voltage value of pin 1 of LM358 (whether it is a high level) when the hand is removed from the infrared receiving tube.

lm358 comparator circuitFigure 1. LM358 Comparator Circuit

4.3.5 Maintenance of Alarm Circuit and LED Display Circuit

You can directly add the power ground to the base of V1 and V2 to see if the alarm and LED are on. The damaged components may be 9012 and light-emitting diodes.

V Conclusion

This blog has designed a simple and usable infrared sensor circuit. The design of it not only based on the LM358 chips and technology but also using the knowledge of digital and analog circuits. It can also increase the radiation distance by adjusting the resistance of the potentiometer so that the circuit can be used as an alarm.

Of course, this circuit still has some defects. This LM358 infrared sensor circuit is considered to be used in a relatively good external environment. That means, there is not much research on the safety and stability of the circuit, and some protective components are omitted. However, it can be seen from the design process and debugging method of the entire circuit that the circuit is very simple and easy to understand whether it is the basic principle, the complexity of the chip used, the number of various components, and the final wiring layout. Moreover, the devices are very commonly used, cheap, and worthy of promotion.


Component Datasheet

LM358 Datasheet


FAQ

  • What is lm358 op amp?

LM358 is a dual op-amp IC integrated with two op-amps powered by a common power supply. It can be considered as one half of LM324 Quad op-amp which contains four op-amps with common power supply. The differential input voltage range can be equal to that of power supply voltage.

  • What is lm358 used for?

LM358 can be used as transducer amplifier, DC gain block etc. It has large dc voltage gain of 100dB. This IC can be operated on wide range of power supply from 3V to 32V for single power supply or from ±1.5V to ±16V for dual power supply and it also support large output voltage swing.

  • Why lm358 is used in IR sensor?

IC Lm358 is used as a comparator when IR receiver senses IR radiations. When the o/p of lm358 goes high, then LED connected at the o/p turns ON. The output pin of the IC LM358 is used to interface with PIC microcontroller.

  • How does an lm358 work?

IC LM358– LM358 consists of two independent, high gain operational amplifiers in one package. Important feature of this IC is that we do not require independent power supply for working of each comparator for wide range of power supply. LM358 can be used as transducer amplifier, DC gain block etc.

  • What is the difference between lm358n and lm358p?

The suffix denotes the manufacturer's packaging code. The 'N' is used by most manufacturers for the plastic 8-pin package. The 'P' is used by a few manufacturers for the plastic 8-pin package. Raven Luni is right, there is NO difference between the two devices, just the mfgrs.

  • How do I know if my lm358 op amp is broken?

Measure the DC voltage at the +input. then measure the DC voltage at the output. if the results are significantly different, the opamp is most likely shot. if they are the same, the opamp is most likely ok and the problem is something else.

  • What is the difference between lm386 and lm358?

The LM386 is a complete audio power amplifier, the LM358 is a dual operational amplifier. When using the LM358 e.g. as a pre-amplifier, you will have to supply a separate power amplifier.

  • What is a dual op amp?

With a dual supply op amp, the V+ terminal of the op receives a positive voltage and the V- terminal connects to negative voltage. Therefore, any input signal fed into the op amp can swing from the positive voltage supply to the negative voltage supply.

  • What is LM series?

The following is a list of LM-series integrated circuits. ... The LM series originated with integrated circuits made by National Semiconductor. The prefix LM stands for linear monolithic, referring to the analog components integrated onto a single piece of silicon.

  • How to import lm358 into LTspice?

1. Download model file and unzip.
2. Place .cir file in same folder as schematic.
3. Place "opamp2" symbol on schematic.
4. Change "opamp2" value to LMX58_LM2904.
5. Place directive on schematic ". lib LMx58_LM2904. CIR" without quotes.

Ordering & Quality

Photo Mfr. Part # Company Description Package PDF Qty Pricing
(USD)
LM358AD LM358AD Company:Texas Instruments Remark:Operational Amplifiers - Op Amps Dual Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $0.42000
10+: $0.31000
100+: $0.17300
500+: $0.15900
1000+: $0.11900
2500+: $0.11200
5000+: $0.10500
10000+: $0.09600
25000+: $0.09300
Inquiry
LM358ADGKR LM358ADGKR Company:Texas Instruments Remark:General Purpose Amplifier 2 Circuit 8-VSSOP Package:8-TSSOP, 8-MSOP (0.118"", 3.00mm Width)
DataSheet
In Stock:On Order
Buy
Price:
1+: $0.48000
10+: $0.36000
25+: $0.32440
100+: $0.17700
250+: $0.17112
500+: $0.15340
1000+: $0.11800
2500+: $0.10620
5000+: $0.10030
10000+: $0.09145
25000+: $0.08555
62500+: $0.07670
100000+: $0.07552
Buy
LM358ADR LM358ADR Company:Texas Instruments Remark:IC OPAMP GP 2 CIRCUIT 8SOIC Package:8-SOIC (0.154", 3.90mm Width)
DataSheet
In Stock:52500
Inquiry
Price:
2500+: $0.09540
5000+: $0.09010
12500+: $0.08215
25000+: $0.07685
62500+: $0.06890
Inquiry
LM358ADR2G LM358ADR2G Company:ON Semiconductor Remark:General Purpose Amplifier 2 Circuit 8-SOIC Package:8-SOIC (0.154"", 3.90mm Width)
DataSheet
In Stock:On Order
Buy
Price:
1+: $0.40000
10+: $0.30000
25+: $0.27080
100+: $0.14760
250+: $0.14268
500+: $0.12792
1000+: $0.09840
2500+: $0.08856
5000+: $0.08364
12500+: $0.07626
25000+: $0.07134
62500+: $0.06642
Buy
LM358ADRG4 LM358ADRG4 Company:Texas Instruments Remark:General Purpose Amplifier 2 Circuit 8-SOIC Package:8-SOIC (0.154"", 3.90mm Width)
DataSheet
In Stock:On Order
Buy
Price:
1+: $0.43000
10+: $0.32300
25+: $0.29160
100+: $0.15900
250+: $0.15372
500+: $0.13780
1000+: $0.10600
2500+: $0.09540
5000+: $0.09010
10000+: $0.08215
25000+: $0.07685
62500+: $0.06890
100000+: $0.06784
Buy
LM358ADT LM358ADT Company:STMicroelectronics Remark:IC OPAMP GP 2 CIRCUIT 8SO Package:8-SOIC (0.154", 3.90mm Width)
DataSheet
In Stock:7500
Inquiry
Price:
2500+: $0.11082
5000+: $0.10368
12500+: $0.09510
25000+: $0.09152
62500+: $0.08938
125000+: $0.08580
Inquiry
LM358AM LM358AM Company:Texas Instruments Remark:General Purpose Amplifier 2 Circuit 8-SOIC Package:8-SOIC (0.154"", 3.90mm Width)
DataSheet
In Stock:On Order
Buy
Price:
440+: $0.57000
1+: $1.27000
10+: $1.13300
25+: $1.07520
100+: $0.82560
250+: $0.72960
500+: $0.69120
1000+: $0.53760
2500+: $0.51072
5000+: $0.49152
Buy
LM358AM-NOPB LM358AM-NOPB Company:Texas Instruments Remark:General Purpose Amplifier 2 Circuit 8-SOIC Package:8-SOIC (0.154"", 3.90mm Width)
DataSheet
In Stock:On Order
Buy
Price:
1+: $0.94000
10+: $0.83800
25+: $0.79520
100+: $0.61060
250+: $0.53960
500+: $0.51120
1000+: $0.39760
2500+: $0.37772
5000+: $0.36352
Buy
LM358AMX LM358AMX Company:Texas Instruments Remark:General Purpose Amplifier 2 Circuit 8-SOIC Package:8-SOIC (0.154"", 3.90mm Width)
DataSheet
In Stock:On Order
Buy
Price:
2500+: $0.47087
Buy
LM358AMX LM358AMX Company:ON Semiconductor Remark:General Purpose Amplifier 2 Circuit 8-SOIC Package:8-SOIC (0.154"", 3.90mm Width)
DataSheet
In Stock:On Order
Inquiry
Price:
2500+: $0.47087
Inquiry

Related Articles

6 Simple Switching Power Supply Circuit

Iggy 14 Apr 2021  2750

Have you ever wondered what is meant by "switch" in switching power supply? To be specific, what is " switching on" and " switching off"? As the name implies, the switching power supply uses electron...

Continue reading »

LM2596 Adjustable Voltage Regulator Schematic

Irene 14 Oct 2020  7642

I DescriptionThe switching power supply chip LM2596 is compact, low-cost, low-power, high-efficiency and easy to use compared with specialized instruments. The power supply described in this blog is a...

Continue reading »

74HC595 VS 74LS595, 74HC595 VS 74HC164, 74HC595 vs MCP23017

Mia 6 Apr 2021  1479

The 74HC595 is one of the most commonly used shift registers. As a popular component, it has many substitutes whose specifications, applications, and pinout are very much alike.   In today's bl...

Continue reading »

AD603 Variable Gain Amplifier: Pinout, Datasheet, Circuit [FAQ]

Iggy 20 Nov 2020  8789

AD603 IntroductionThe AD603 is a low noise, voltage-controlled amplifier for use in RF and IF AGC systems. It provides accurate, pin-selectable gains of −11 dB to +31 dB with a bandwidth of 90 M...

Continue reading »

LM1875 Circuit: 22W Audio Amplifier

Mia 31 Jul 2020  977

I Description LM1875 is a power amplifier integrated block chip. Its superior performance and attractive tone have been accepted by many enthusiasts, and it was all the rage in the 1990s. LM1875 ado...

Continue reading »

0 comment

Leave a Reply

Your email address will not be published.

 
 
   
 
Rating:

# 0 1 2 3 4 5 6 7 8 9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z