Need help for Infrared indicator

Thread Starter

nobody0608

Joined Aug 4, 2012
28
Reply to Allen,



The component in red rectangle is the slotted opto-coupler, am I correct?
If not, please ignore my questions below....



Is the circuit I draw with yellow colour correct?
Btw, how much should I set for R2? I saw 000 on R32 (near to CN3) =(


Reply to Markd77,

I had also tried to cover the sensor with a black cotton material (the possible material that can cover whole sensor), still cannot get 0V.
Tried again just now and it's night time in our country, still fail to obtain the 0V.

So I can get the IR pair from the PC mouse as well?
 
Last edited:

THE_RB

Joined Feb 11, 2008
5,438
The little optical device in the CD player is a standard 3-pin infra red remote receiver module, which needs 5v, gnd and the other pin is signal out. It needs to be driven with modulated infra red at about 40kHz (from the remote control).
 

Thread Starter

nobody0608

Joined Aug 4, 2012
28
Reply to Markd77,

I tried to remove the CN3 and use in my circuit to test, and it worked =)
I also added a LED at V(out).

Result:
When R2 = 750Ω and there is an obstacle, the V(out) is about 1.95V.
When R2 = 10kΩ and there is an obstacle, the V(out) is about 1.78V and the current from pin 3 to LED is about 0.3mA.

The result seem good but too bad I don't know what is the model of the component, if can obtain the datasheet would be better.

Thank for Mark77, Austin Clark, vk6zgo, Allen, Audioguru and THE_RB
Finally, it's seem like this had solved my current problems =)
A great thank for those spend their time and efforts to help me to solve my problem =)


Reply to THE_RB,

If I use the IR LED from the remote controller and 3-pin IR remote module, and place them same with the schematic in my first post, is it possible to measure the voltage drop from the signal pin? Or additional circuit required for it?
 
Last edited:

Markd77

Joined Sep 7, 2009
2,806
Reply to Markd77,

I tried to remove the CN3 and use in my circuit to test, and it worked =)
I also added a LED at V(out).

Result:
When R2 = 750Ω and there is an obstacle, the V(out) is about 1.95V.
When R2 = 10kΩ and there is an obstacle, the V(out) is about 1.78V and the current from pin 3 to LED is about 0.3mA.
Great news, presumably the circuit is laid out as in post #1, with an LED to ground from V(out).
To explain your results the 1.95V and 1.78V are the forward voltage of the output LED you are using (it varies with current). You would see about the same voltages and currents if you only had R2 and the LED. If you remove the LED you will see the voltage at Vout rise.
 

Thread Starter

nobody0608

Joined Aug 4, 2012
28
Great news, presumably the circuit is laid out as in post #1, with an LED to ground from V(out).
To explain your results the 1.95V and 1.78V are the forward voltage of the output LED you are using (it varies with current). You would see about the same voltages and currents if you only had R2 and the LED. If you remove the LED you will see the voltage at Vout rise.
Indeed, the V(out) is 4.80V without the LED @ R2 = 10KΩ.
Is it because of the ohmic properties of the LED and phototransistor? (I assume the slotted opto coupler are made by separated IR LED and phototransistor pair)

Usually, is there a way to calculate the V(out)? (For example in my situation, with and without LED)
 
Last edited:

Markd77

Joined Sep 7, 2009
2,806
Not easily, sometimes LED datasheets have graphs like these, but individual LEDs will vary from the curves, which are just for typical LEDs.

There is also a similar curve for the phototransistor, but when the IR is blocked from the sensor you can assume that most of the current just flows through the LED and resistor. You can then use the normal calculation of LED current if you have the right graphs and you get an approximate value.
 

Attachments

Audioguru

Joined Dec 20, 2007
11,248
An IR receiver IC used for remotes uses an IR beam that pulses on and off at 38kHz and some at other frequencies. It does not work properly with a continuous IR beam.
Then it rejects interference from sunlight and incandescent lights.
 

Thread Starter

nobody0608

Joined Aug 4, 2012
28
Not easily, sometimes LED datasheets have graphs like these, but individual LEDs will vary from the curves, which are just for typical LEDs.

There is also a similar curve for the phototransistor, but when the IR is blocked from the sensor you can assume that most of the current just flows through the LED and resistor. You can then use the normal calculation of LED current if you have the right graphs and you get an approximate value.
Thank for your guide again, now I saw it clearer.
Thus, when the sensor being block, the current actually select the path that go through the R2 and LED.

In the case of no LED, so I just using the case of normal BJT calculation.


From this, I can obtain the V(out) which is equal to V(ce).
But the Ic is depend on the Ib, so I still need to know its model and refer to the datasheet.


An IR receiver IC used for remotes uses an IR beam that pulses on and off at 38kHz and some at other frequencies. It does not work properly with a continuous IR beam.
Then it rejects interference from sunlight and incandescent lights.
Thank for your guide, now I understand the function of the IR receiver IC. That is why it won't get affected easily.
So if I going to using it, I have to apply PWM to the IR LED and send it to the IR receiver IC, am I correct?




Once again, why the kids in that video @ post#15 can set up the distance such far? May I know what kinds of phototransistor he used?
Today, when I went to the electronics shop, I asked for the maximum distance between the IR LED and phototransistor. I thought it could be far as the video shown, but the shop owner answered me about 4cm only (from his experience).
 

Audioguru

Joined Dec 20, 2007
11,248
now I understand the function of the IR receiver IC. That is why it won't get affected easily.
So if I going to using it, I have to apply PWM to the IR LED and send it to the IR receiver IC, am I correct?
No.
The datasheet for the IR receiver IC shows how to use it. The 38kHz from the IR LED must have a burst of 38khz pulses for a defined duration then a pause for a defined duration. This is to avoid interference from compact fluorescent light bulbs that send IR in addition to visible light and pulse continuously at 38kHz.

Once again, why the kids in that video @ post#15 can set up the distance such far? May I know what kinds of phototransistor he used?
Some IR LEDs are focussed into a very narrow angle which makes them very bright. The video shows it not working when the IR LED is moved a little.
Some IR photo-transistors are extremely sensitive.
 

Thread Starter

nobody0608

Joined Aug 4, 2012
28
No.
The datasheet for the IR receiver IC shows how to use it. The 38kHz from the IR LED must have a burst of 38khz pulses for a defined duration then a pause for a defined duration. This is to avoid interference from compact fluorescent light bulbs that send IR in addition to visible light and pulse continuously at 38kHz.
Just done searching for some informations on the burst waveform.

Please forgive me if I misunderstanding the statement.
Please tell me if I am wrong. Your efforts will be appreciated.

If I choose TSOP 18... as reference,

In suitable data format,

It stated that
"Burst length should be 6 cycles/burst or longer".
"After each burst, a gap time of at least 9 cycles is neccessary."
"The data format should not make a continuous
signal transmission. There must be a Signal Gap Time
(longer than 14ms) at least each 90ms."


For my understanding,
The burst length are formed by the data bits, and it required 6 cycles and longer. 1 cycle represent 1 data bit. Thus 1 burst required 6 data bits at least. (If true, then what is the time for 1 cycle? Is it counted in nanosecond?)

After completed the burst, the pause that having same period should be proceed.
So the length of the burst is 1/38kHz = 26.31μs, and the pause should have the same length as the burst.

After each burst, a signal gap time(longer than 14ms) must be give within each 90ms. (But the length of the burst is in μs, how come it require ms for signal gap?)




Some IR LEDs are focussed into a very narrow angle which makes them very bright. The video shows it not working when the IR LED is moved a little.
Some IR photo-transistors are extremely sensitive.
So the problem lied on the IR LED.
Thank for pointing out.
 
Last edited:

Audioguru

Joined Dec 20, 2007
11,248
Just done searching for some informations on the burst waveform.

Please forgive me if I misunderstanding the statement.
Please tell me if I am wrong. Your efforts will be appreciated.

If I choose TSOP 18... as reference,

In suitable data format,

It stated that
"Burst length should be 6 cycles/burst or longer".
"After each burst, a gap time of at least 9 cycles is neccessary."
"The data format should not make a continuous
signal transmission. There must be a Signal Gap Time
(longer than 14ms) at least each 90ms."


For my understanding,
The burst length are formed by the data bits, and it required 6 cycles and longer. 1 cycle represent 1 data bit. Thus 1 burst required 6 data bits at least. (If true, then what is the time for 1 cycle? Is it counted in nanosecond?)
No.
One cycle of 38kHz is 26.31μs. One burst of 10 cycles plus a gap of 20 cycles is one data bit and has a duration of 0.789.3ms.

Then the code sent by an IR remote is fairly slow at about 1200 bits per second.

After completed the burst, the pause that having same period should be proceed.
So the length of the burst is 1/38kHz = 26.31μs, and the pause should have the same length as the burst.
No.
One burst of 10 cycles of 38kHz is 263.1μs.
After each burst, a signal gap time(longer than 14ms) must be give within each 90ms. (But the length of the burst is in μs, how come it require ms for signal gap?)
Because one data bit has a duration of almost 1ms to a few ms and there must be a fairly long gap time before the next data bit.
 

Thread Starter

nobody0608

Joined Aug 4, 2012
28
No.
One cycle of 38kHz is 26.31μs. One burst of 10 cycles plus a gap of 20 cycles is one data bit and has a duration of 0.789.3ms.

Then the code sent by an IR remote is fairly slow at about 1200 bits per second.
Reading for the informations about protocol and trying to understand it.

Below is the figure developed based on my understanding.
Please tell me again if I was wrong. Thank you.



If the data bit is 1, the pause will be having first, and then the burst would be start. If it is 0, the burst will be having first and then continue by the pause. Am I correct?

Does the waveform look like figure above? (If use TSOP 18..., the 10 cycles can reduced to 6 cycles?)
Does the "gap of 20 cycles" represent as the waveform above? Or it stay logic high for (20 x 38kHz) 667μs? (But why must the gap be 20 cycles?)


Because one data bit has a duration of almost 1ms to a few ms and there must be a fairly long gap time before the next data bit.
So the long gap refer to the "gap of 20 cycles"?
 
Last edited:

Audioguru

Joined Dec 20, 2007
11,248
The 10 cycles burst of 38kHz begins first then a gap of 10 cycles or more follows to make the first data bit. The gap following a long burst must be as long as the long burst duration.

There are many types of IR remote control codes. Some use the length of the burst to determine if the data bit is 1 or 0. Look at them in Google.
 

Thread Starter

nobody0608

Joined Aug 4, 2012
28
The 10 cycles burst of 38kHz begins first then a gap of 10 cycles or more follows to make the first data bit. The gap following a long burst must be as long as the long burst duration.

There are many types of IR remote control codes. Some use the length of the burst to determine if the data bit is 1 or 0. Look at them in Google.
If using the burst length method, let's say I let
1 be 20 cycles burst and 10 cycles gap, and
0 be 10 cycles burst and 10 cycles gap, what is the length of the pause I supposed to defined? Same length with 20 cycles or 30 cycles?

Other than that, some manipulate the length of pause to determine the data bit. If manipulating the pause length, the pause length has to be n times the burst length, where n = 1 and 2. Am I have the correct understanding?



Really a great thank for you, you show and guide me to discover a lot of knowledge(it's new for me).
Your efforts will be appreciated.
 
Last edited:

Audioguru

Joined Dec 20, 2007
11,248
The datasheet says that if the burst length is 1.8ms or more then a gap of at least 1.8ms must be made.

IR remote control is new to me too. I never made one. I just looked at the datasheets.
 

hexreader

Joined Apr 16, 2011
581
You seem to be close to re-inventing Sony IR protocol.

I would recommend that you read all about IR here:

http://www.sbprojects.com/knowledge/ir/index.php

Then click on the Sony SIRC tab at the left of the page.

Sony protocol is one of the simplest around, so you would do well to copy it. It already meets the requirements of most 3-pin receiver chips.

If you have a Sony remote available, then the transmitting part of the project is done for you.

Note that Sony use 40kHz modulation, but sending 40kHz and receiving with a 38kHz 3-pin receiver module always worked perfectly well for my projects, just with slightly shorter range.

.... just adding ideas for you to consider, though maybe not of use in your application, since you are not interesting in transmitting any data....

I seem to remember that simply transmitting 38kHz for 250us, transmitting nothing for 250us then repeating forever (modulating 38kHz with 2kHz) worked with my 3-pin receiver, and gave a good 2kHz signal out.... but maybe my receiver did not need the "pause" time that seems to be quoted in some datasheets.
 
Last edited:
Top