Jump to content
Electronics-Lab.com Community

Infrared Activated Switch


Recommended Posts


"For a simple 555 monostable, the trigger pulse must be shorter than the output pulse"
Can you please explain this to me? And what are the affects if the beam is blocked for more than 10s?

That is the "it won't time-out when the beam is blocked" problem I mentioned.

Also, I live in the United Arab Emirates. There are Maplin and radioshack stores near where i live. So which transistors do you recommend i use for conducting 1A?

Buy a transistor rated for 1A to 3A.

I dont know if this helps, but the alarm circuit draws arround 850mA which is quite close to the limits of a 1A transistor? any tips on how to avoid damage to anything?

Since the transistor has a minimum gain of 25, supply it with at least 850/25 X 1.3 = 44mA of base current to be certain that it saturates fairly well. ;D
Link to comment
Share on other sites


  • Replies 77
  • Created
  • Last Reply

Top Posters In This Topic

Hi audioguru,

I'll see if i can find the TIP31 in some stores. However, if i cant get my hands on it, can you tell me if this will be equivilent?

http://www.alldatasheet.co.kr/datasheet-pdf/view/STMICROELECTRONICS/BFY51.html

Oh yeh, what are the charastaristics of a General Purpose Transistor?
I once read on a website that the Hfe should be around 100. What you say?

;D

Link to comment
Share on other sites

Hi Hamoodyjamal,
I wouldn't use an old BFY51 transistor to drive 850mA. It is shown in my 1968 Philips databook! :o
It doesn't have much DC current gain, a minimum of only 15 at 1A. Also, it doesn't saturate very well at its max current, its max saturation voltage is 1.6V at 1A even with a huge 100mA of base current. It will melt without some kind of heatsink and your load will receive up to 1.6V less than you want.

Since the hFE of all transistors drops-off at less than their max current rating, I would use a newer transistor rated for a max current of about 3A. Even a fairly old TIP31 has a minimum DC current gain of only 10 at its max current of 3A, but its gain is 25 at 1A. Its saturation voltage is very low so that it will become barely warm.

What is "general purpose"? I dunno.
What is a "typical rating"? A TIP31 has a typical Hfe of 50 at 3A, but its minimum is only 10. You might need to go through a bucket full of them to find one that is typical. I always use the minimum rating that is guaranteed. ;D

Link to comment
Share on other sites

Hi audioguru,

I'll do my best to get the TIP31.

I was reading through the thread and came to your post where you mentioned "Why not use only a transistor to replace the relay?"  And then I thought about it and said, "That’s a darn good idea!” I drew out a schematic for what I plan. The only problem I have is I don’t really know how to calculate the values ??? Of the resistors because their values relate and affect each other (I think). Would you be so kind as to find the values?

The link for the datasheet of the transistor (BC107) is below:

http://www.ortodoxism.ro/datasheets/stmicroelectronics/9293.pdf

Schematic Explanation:

The first transistor is used as an inverter to drive the second transistor which in turn will trigger the 555 monostable circuit depending on the input of the first transistor.

Thank you very much. ;D

post-10092-14279142299105_thumb.gif

Link to comment
Share on other sites

Hi audioguru,

I forgot to mention that the input for the 1st transistor is 5V. If you go back and look through the thread, you'll see a picture of what I plan to do. And you can see that the receiver consists of a 56 KHz IR receiver module which is actually connected to a battery. When it receives IR, it will output 5V (which is the supply voltage) through its Vout junction. I cannot connect all that 5V through the BE. That’s why I need a current limiting resistor.

The first transistor is connected as an inverter. And the second transistor is the replacement of the relay.

I don’t know if this will affect your reply, but what the heck.

BTW, I will be using the picture (attached) to build the monostable circuit. What do you think? I got it from: http://www.eleinmec.com/article.asp?4

As you can see, there is a 10K Ohm resistor near Pin2 and the Vs, is this what you're talking about?

Also, one of the parts is a "0.01uF Metallised Polyester Film Capacitor", can I use a normal ceramic disc if I can’t find a Metallised Polyester Film Capacitor?

Thanks. ;D

PS: I will only be using 5V for everything. Although I have a 12V supply, I prefer lower voltage for IC's.

post-10092-14279142299241_thumb.gif

Link to comment
Share on other sites


If you go back and look through the thread, you'll see a picture of what I plan to do. And you can see that the receiver consists of a 56 KHz IR receiver module which is actually connected to a battery. When it receives IR, it will output 5V (which is the supply voltage) through its Vout junction.

We were both wrong. The receiver's output is active low, when it receives IR. It will be pulled high by an 80k resistor when the beam is blocked.

I cannot connect all that 5V through the BE. That’s why I need a current limiting resistor.

You certainly can connect the base directly to the reciever's output. The output is already an 80k  current-limiting resistor.

The first transistor is connected as an inverter. And the second transistor is the replacement of the relay.

Your 2nd transistor is also an inverter that you do not want.

BTW, I will be using the picture (attached) to build the monostable circuit. What do you think?
As you can see, there is a 10K Ohm resistor near Pin2 and the Vs, is this what you're talking about?

Yes, the 10k resistor in the monostable circuit is the same resistor as the collector resistor.

Also, one of the parts is a "0.01uF Metallised Polyester Film Capacitor", can I use a normal ceramic disc if I can’t find a Metallised Polyester Film Capacitor?

Yes, nearly any capacitor will be OK to filter pin 5.

I will only be using 5V for everything. Although I have a 12V supply, I prefer lower voltage for IC's.

5V for the 555's brings them close to their minimum operating voltage of 4.5V. Also, you won't be able to filter the supply voltage from them for the IR receiver. Therefore it is best to power the 555's from 12V and use a 78L05 to power the receiver and 10k resistor.

I think your circuit should look like this:

post-1706-14279142301692_thumb.png

Link to comment
Share on other sites

Hi audioguru,

I'll Try and get the components for the circuit hopefully tomorrow and will let you know about the results.

However, I did some testing, but with a different NPN transistor (SC945C) and the results where negative. I had a hunch that it was because of the 10K resistor, so I changed it to a much lower value of 100Ohm and the circuit worked like it was supposed to. I guess it was because I didn't use a BC107 transistor. What you say?

Thanks again! ;D

Link to comment
Share on other sites

Hi Hamoodyjamal,
My schematic looks lousy on this page, click on it to open it and it is clear. I used Microsoft Paint to copy, paste and add to the block diagram in the datasheet.

Didn't you use my circuit for your test?
It should work fine with a 10k collector resistor and any little NPN transistor. Your 100 ohm resistor is trying to draw a massive 118mA which is too much for a little transistor. Since the 80k resistor in the output of the receiver provides only 54uA of base current, a transistor would need a current gain of 2200 to saturate poorly. Little transistors have a current gain of only a few hundred and might overheat trying to drive a 100 ohm load from 12V.

Link to comment
Share on other sites

Hi audioguru,

I kind of tested your circuit. What i mean is that i didnt quite use the same components you specified. The reason is that i dont have them. i.e. i didnt add the voltage regulator, nor the capacitors, also i used SC945C trans. instead of BC107.

Hopefully I'll go and buy them tomorrow and let you know how it comes along.

Test result: no inversion!
When there is IR light aimed at the receiver, the ouput at junctions CE are about 5V (HIGH), and when there is no light, output is 0V (LOW). I showed the schematic to my dad and he noticed there is a transistor connected to the GND and OUT of the IR receiver module which is set up like an inverter. So how i see it is your inverting something thats already inverted. What you say?

Chow.

Chow.

Link to comment
Share on other sites

Hi Chow Chow, ;D
I thought you want the 555 to be triggered when the IR beam is blocked. The IR receiver's output is low when there is IR radiation, and goes high when the IR is blocked. That is why I added an inverting transistor to its output, so that it can trigger (low) the 555.
That is what is shown on the datasheet:

post-1706-14279142301821_thumb.png

Link to comment
Share on other sites

Hi audioguru,

I haven’t been getting to build the project because of some problems. First, my soldering iron is kind of busted and I couldn't get one. Well, not yet. Secondly, my sister is here, from another city, so we're spending some quality time.

BTW, I was testing the IR receiver module, and I accidentally burnt it. Not literally, but I applied 9V when the max is 6V. Opps! I went to get a replacement, and the only thing I was looking for was the number 56 on the module. When I came home, I noticed it was TSOP 1156. I used to have TSOP 1756. Will this be a problem? Hope not, because it looks like it functions the same.

What you say?

;D

Link to comment
Share on other sites

Hi Hamoodyjamal,
It's too bad you blew-up your IR receiver. The TSOP1756 and TSOP1156 are almost the same, the TSOP1156 has a slightly quicker data rate.

I noticed that they reduce their sensitivity during continuous IR at 56kHz, since their max number of 56kHz cycles is 70. Your system will have better range if you transmit IR modulated with bursts of no more than 70 cycles (with a gap of at least 10 cycles) of 56Khz IR. Then the output of the receiver will be low during each burst, then high for each gap. You could use a peak detector circuit to blend the bursts together, and its output will be continuously low when your modulated IR beam is shining on the receiver, and high when the beam is blocked. ;D

post-1706-14279142313861_thumb.png

post-1706-14279142314037_thumb.png

Link to comment
Share on other sites


Hi audioguru,

That picture you attached which shows the effects for DATA. Im just sending plain IR light at 56KHz.

See image attached.

BTW, range isn't that important. Probably 1-4 meters is what i'll need. What you say?

;D

Then for your continuous modulation, the receiver's gain is reduced by its AGC. They don't say how much the gain is reduced so you will have to try it to see. ;D
Link to comment
Share on other sites

Hi audioguru,

Problems after Problems!!!! Grrrrrrrrrrrrrrrrrrrrrrrrrrrrrr.

During the testing procedures, I used a 9v battery to power the 555 timers. Everything was OK. Now, I used a 220V-12V transformer to power the 555 timers. Problem. The IC quickly overheats. I checked for wiring errors but all was fine. So I measured the current and it read 220mA which is darn a lot. I went back to using the 9v battery and everything was OK. Current with the 9v is around 35mA. I’m stuck on why the IC overheats when using the transformer (BTW, the transformer output is rectified and decoupled with an electrolytic capacitor of values 16v 1000uF). I asked my dad (who’s an electrical engineer) and said that the battery has internal resistance. I don’t know what he meant by that. What you say?

Also, the TSOP1756 IR receiver turns out to actually be working. I thought it was busted, but it wasn't. I used it for testing, but now I really burnt it. Ahhhhhhhhhhhhhh. A problem with the TSOP1156 is that the output goes low for a split second when there is IR light. Where as the previous one (TSOP1756) kept low when there was IR light. How can I fix this dilemma?

Thanks!  ;D

Link to comment
Share on other sites


Now, I used a 220V-12V transformer to power the 555 timers. Problem. The IC quickly overheats. So I measured the current and it read 220mA which is darn a lot.(BTW, the transformer output is rectified and decoupled with an electrolytic capacitor of values 16v 1000uF).

Did you measure the supply voltage? A 12VAC transformer's output might be 16V when it is not fully loaded, and rectifying and filtering it could result in 21.2V. The absolute max for an ordinary 555 is 18V and only 15V for the Cmos version. What is its load? What is regulating the 5V for the IR receiver?

A problem with the TSOP1156 is that the output goes low for a split second when there is IR light.

The IR receivers are designed to receive data, not continuous nor continuously modulated IR. They have an automatic-gain-contol system to reduce their gain if continuous IR (interference) is received. It probably takes a split second for the AGC to reduce the receiver's gain. The manufacturer doesn't say how much the gain is reduced by the interfering IR, so each one is probably a little different.

Like I said before, modulate the IR in bursts of 56kHz which would keep the AGC at full gain. Then add a peak detector to its output to blend the bursts together into a steady output. Here is an IR receiver kit that does that: 

post-1706-14279142314281_thumb.png

Link to comment
Share on other sites

Hi audioguru,

How can rectifying and filtering a transformer’s o/p increase its voltage? I don’t find it logical.

By the way, I have a NE567 Tone-Decoder IC and am wondering on how to use it to replace those IR receivers that gave me such a headache.

Can I use it to receive IR light, using a phototransistor as the input, oscillated at 56 KHz to drive a relay? Or just give a HIGH or LOW signal?

I took a look at the datasheet and it showed me how to calculate the center frequency. That was Ok. But then I came across how to calculate the detection bandwidth and I was stuck on what it is? I thought it could be something similar to tolerance of the frequency? Am I right?

Thanks! ;D

Link to comment
Share on other sites


How can rectifying and filtering a transformer’s o/p increase its voltage? I don’t find it logical.

Hi Hamoodyjamal,
The 12VAC output of a fully loaded 12V transformer has the same heating power as 12VDC. Since the AC voltage changes polarity, it frequently passes through zero volts when it provides no power. In order for the average power to be the same as with 12VDC, the AC peak voltage is 1.414 times (the root of 2) its 12V RMS value. A rectifier and filter cap charges the cap to the peak voltage, minus a diode drop or two.

By the way, I have a NE567 Tone-Decoder IC and am wondering on how to use it to replace those IR receivers that gave me such a headache.

Can I use it to receive IR light, using a phototransistor as the input, oscillated at 56 KHz to drive a relay? Or just give a HIGH or LOW signal?

The project in our Projects Section http://www.electronics-lab.com/projects/motor_light/030/index.html uses a phototransistor, opamp and LM567 driving a relay. I don't know what frequency or bandwidth it has, and its opamp is obsolete and is incorrectly biased.

I took a look at the datasheet and it showed me how to calculate the center frequency. That was Ok. But then I came across how to calculate the detection bandwidth and I was stuck on what it is? I thought it could be something similar to tolerance of the frequency? Am I right?

Detection bandwidth is how far the incoming frequency is away from the tuning frequency of the LM567, but the LM567 can still lock-on to it. If the bandwidth is too wide, it might lock-on to interference at a different frequency than your 555. If it is too narrow, it might not lock-on to the 555 who's frequency isn't very stable. ;D
Link to comment
Share on other sites

if your looking for an infrared activated switch youll find a really simple one in the topic fairchild photo transistor data and if you want to see how simple it looks look at topic keychain laser power supply as the infrared  switch or light activated realy circuit that uses the fair child photo transistor allso detects laser at a large distance away

Link to comment
Share on other sites

Hi audioguru,

I found out the problem for the 555 timer overheating. I was looking at the datasheet (of the 555) and it said R1 and R2 should be between 1K and 1M. Before i was using, R1 and R2 which added up to 147 Ohm which is way too small. So i changed the components to still give 56KHz and the 555 timer stopped over heating. Great.

BTW, i want to use an LM307 IC to power a Relay (instead of a transistor becasue a transistor is a SEMIconductor which will always trigger the 555 monostable since its very sensative to triggering) from the output of the receiver. I found a circuit on how to set it up. At first it worked. But then after re-setting it up (dont bother to ask why), it didn't work. I double checked for connection errors but everything is fine. Yet, it just doesn't want to work. I drew a picture of the schematic that i set up. Can you spot a problem?

This may help you, im using the same supply to power both the LM307 and the IR receiver, while using a 12v and a 5v regulator for the LM307 and the IR recevier respectavly. Could there be conflict issues?

Thanks! ;D

post-10092-14279142327121_thumb.gif

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
  • Create New...