This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Typical resistor value for a 5 mm IR LED

I'm doing a project IR control project.  I'm controlling the LED with a transistor.  I've had no luck so far getting the forward voltage and current for the IR LED from the ebay seller (lesson learned, ask for specs before buying.) So I played it safe and connected a 150 ohm resistor but it appears that the LED is not getting enough current to do its job.  I've done a resistor calculation based on what some people said that an typical IR LED runs at 100mA and an forward voltage of 1.2v and came up with 22 ohms. Is this a good estimate?

  • Nick LeClair said:
    22 ohms. Is this a good estimate?

    That depends on supply voltage and drive circuit details.

  • I'm using the vcc pin as the current supply. Transistor used is a 2N2222.

  • Come on, it's Ohm's law, R = V/I

    For VCC  = 3V and 2n2222 assumed CE saturation voltage at 100mA  = 0.2V calculation is as follows:

    R = (3 - 1.2 - .2)/0.1 = 16 ohms

  • Ilmars said:

    Come on, it's Ohm's law, R = V/I

    For VCC  = 3V and 2n2222 assumed CE saturation voltage at 100mA  = 0.2V calculation is as follows:

    R = (3 - 1.2 - .2)/0.1 = 16 ohms

    Yes, I understand Ohm law.  I was checking to verify that those were typical specs for an IR LED. I read the VCC was 3.3V. I didn't also take into account CE saturation of the transistor in the calculation (still learning about transistors.)

  • Nickl said:
    I was checking to verify that those were typical specs for an IR LED

    IR LEDs differ and there are no such thing as "typical IR LED specs". Better refer to datasheet than forum :)

  • I think at this point I can rule out a power issue as I did apply a resistance of 16 ohm and still having issues with the project.  I did the same project on my Arduino and gave the IR LED alot less current and it worked fine.  There must still be problems with Engeria's IRremote library implementation.

  • 'why don't you connect directly. It is not so much power consuming that you need a 2n2222 transistor.

    I think it is make for power ckts. You can use other bc547. 

    Still i advice you to connect directly as it makes ckt less complex and as it has less power consumption so won't affect working of controller.

  • The MSP port pins can directly drive 10-20mA and the FET in the output drive acts as a current-dependent resisor. For one LED it's okay. (but don't stuff all ports with LEDs directly - this would exceed maximum power dissipation)

  • vikas dabas said:
    'why don't you connect directly. It is not so much power consuming that you need a 2n2222 transistor.

    This is right decision to use transistor because many IR LEDs happen to be too powerful (50..100mA) to be driven by (single) pin of the controller in case max power needed. As an consumer I would throw away TV remote having IR LED driven just by 10mA current - because range will be miserable.

  • I was considering a simple IR LED available in market.

    If there is nothing marked on IR led then how would know the rating of led that it is 100mA or 10 mA.

  •                  "This is right decision to use transistor because many IR LEDs happen to be too powerful (50..100mA) to be driven by (single) pin of the controller in case max power needed. As an consumer I would throw away TV remote having IR LED driven just by 10mA current - because range will be miserable.

    I was considering a simple IR LED available in market.

    If there is nothing marked on IR led then how would know the rating of led that it is 100mA or 10 mA.

  • vikas dabas said:
    If there is nothing marked on IR led then how would know the rating of led that it is 100mA or 10 mA.

    Most of 5mm IR LEDs are rated 100mA, some (one out of 10) are 20mA either 50mA. Consider 20mA and you will be fine. Better go to arrows or farnell or SparkFun and order LED with known specs.

  • Ilmars said:
    As an consumer I would throw away TV remote having IR LED driven just by 10mA current - because range will be miserable.

    And with 100mA, the battery life would be miserable, sucking them dry in a snap. Unless you have rechargable batteries which can stand a sudden high current (btu have a bad capacity and life cycle if stressing them this way), normal battreries will drop their output voltage significantly as soon as they are partially depleted, when such a current is drawn. Especially button cells, which usually aren't specified for sucha high current at all.

    Of course it depends on what you want to do with your remote. If you want to control your neighbours garage door through the closed wall, then you'll surely need a high-power LED. Or if you want to control your TV or HiFi around a corner (no direct sight, no mirrors). :)

  • Jens-Michael, what's typical current of TV remote IR led? Which respectable manufacturer uses button cells for TV remotes? Name one.

  • Ilmars said:
    Jens-Michael, what's typical current of TV remote IR led?

    Might I observe that it really isn't that hard to use Google to find some manufacturers of IR LEDs and go to the manufacturer's websites and look up the datasheets yourself?

    Manufacturer's original sources are always the most reliable source of information.

  • Brian Boorman said:
    Might I observe that it really isn't that hard to use Google to find some manufacturers of IR LEDs and go to the manufacturer's websites and look up the datasheets yourself?

    Please name single google search where I can see Sony or Panasonic TV remote IR led current.

  • The original poster in this thread had obtained IR leds without knowing mfr and specs. My comment merely suggested you could look up specs for a part that suits your needs and buy that mfr's part (via Digikey or other distributor).

    If you want the current spec for an IR LED in some TV manufacturer's supplied remote, then you can either a) ask them directly via their support site (good luck) or b) open the thing up and measure the voltage across the limit resistor and divide by the resistor value.

    http://lmgtfy.com/?q=IR+LED+5mm

  • Brian Boorman said:
    My comment merely suggested you could look up specs for a part that suits your needs

    *My* needs? Did you read whole conversation? It was me who earlier said that most 5mm IR LED's have 100mA nominal current. My comment was to Jens-Michael who claimed that I was wrong about claiming that 10mA is insufficient for TV remote IR LED. So please either know topic or stop giving [....] advices.

  • Jens-Michael Gross said:
    And with 100mA, the battery life would be miserable

    http://en.wikipedia.org/wiki/AAA_battery

    Typical AAA alkaline battery capacity is around 1000 mAh. Think again ;)

  • Ilmars said:
    Jens-Michael, what's typical current of TV remote IR led? Which respectable manufacturer uses button cells for TV remotes? Name one.

    Well, 'respectable' adds a new qualifyer to the discussion. However, many remotes for PC TV receivers aren't even as big as required to hold a single AAA cell. And most people use their PC for TV (saving space for a second display, and the big monitors are often large enough and way cheaper than LCD TVs - and the 'firmware' is much more comfortable)

    Ilmars said:
    Typical AAA alkaline battery capacity is around 1000 mAh.

    Did you also check the conditions under which this capacity is specified? Sloooow discharge. If you treat them with 100mA, the ourput voltage will break down looong before you come even near that amount. Especially if you're a 'zapper' and use the remote more often than just to switch the TV on and off.

    Also, the main problem with IR transmission is not the range of the transmitter (and therefore needed power) but the influence of surrounding irritation on the receiver (which could be simply eliminated by a little bit better electronics to eliminate static infrared radiation and increase sensitivity to the digital dynamic signal).
    Imagine, a cell phone only sends a few mW into all directions (not focused into one direction) and can still reach an antenna many hundred meters away through walls and with lots of electromagnetic noise around. And with a baudrate that is a multiple of what an IR LED has to transmit. But of course nobody has an interest in improving IR receiver :)

  • Jens-Michael Gross said:
    Well, 'respectable' adds a new qualifyer to the discussion.

    You avoided to give answer anyway ;) I said "respectable" to exclude "made in china" keychain universal remotes that does not work well anyway. All TV/audio remotes I know (had experience with) are driven using 100mA or even higher current pulses. Actually I answered to this thread because I have practical knowledge fixing remote while ago, had to research to find replacement IR LED.

    Jens-Michael Gross said:
    And most people use their PC for TV

    *Most* LOL :D Joking, right? Trying to draw discussion away from TV remote IR LED current as far as possible? :D

    Jens-Michael Gross said:
    Did you also check the conditions under which this capacity is specified?

    Did you know that IR remote protocols uses short pulses with duty cycle in range 20..30%? Are you familiar with component named "capacitor" and how it can help reducing ESR of supply, reducing average peak current drawn from battery? Well, ok. I am checking capacity specification conditions of CR2032 Energizer button cell: 6.8mA 2sec pulses = 200mAh (final voltage 2.4V), 23mA 1msec pulses with ~10% duty cycle = ~130mAh (final voltage 2.4V). If we assume that 100mA IR LED transmission is 25ms long with half of time transmitting "mark" using 25% duty cycle pulses, then IR Led is on for 25/2/4 = 3.125 ms during this transmission. Assuming that effective capacity for our button-cell remote is just 50mAh, we have charge for 30minutes/3.125ms = 576000 transmissions. Right?

    Further reading: (pay attention to current-limiting resistor value here):

    http://www.ti.com/general/docs/litabsmultiplefilelist.tsp?literatureNumber=slla175

    .. and here (download datasheet, look typical application circuit):

    http://www.holtek.com.tw/english/docum/consumer/622xA.htm

    Jens-Michael Gross said:
    Also, the main problem with IR transmission is not the range of the transmitter (and therefore needed power) but the influence of surrounding irritation

    Exactly. Sun shining into your living room creates broad spectrum of IR radiation which falls into wavelength of IR LED too. Signal have to be stronger than noise/interference. So, yes - most IR remotes indeed are capable to control TV set of your neighbor across a street, especially during night.

    Jens-Michael Gross said:
    Imagine, a cell phone only sends a few mW into all directions (not focused into one direction) and can still reach an antenna many hundred meters away

    Cell phone sens up-to 1 Watt. Actually it's bad example - because cell phones uses licensed spectrum frequencies, sunlight heat radiation cannot create interference in cell frequencies, only interference source is cosmic radiation (which is comparably low noise level) or artificial sources which are eliminated by frequency regulators as they appear - rapidly.

    Jens-Michael Gross said:
    But of course nobody has an interest in improving IR receiver :)

    It will stay as it is - till it's death. Actually RF remotes are already there and IR in hi- &mid-end consumer segment most probably will die out.

  • Ilmars said:
    Trying to draw discussion away from TV remote IR LED current

    I don't see why TV remotes should be treated differently (as in 'requiring higher currents to reliably work) than any other remotes. Except if yuo want to say that TV sets are generally more IR blind than any other IR controlled device?

    Ilmars said:
    Did you know that IR remote protocols uses short pulses with duty cycle in range 20..30%? Are you familiar with component named "capacitor" and how it can help reducing ESR of supply,

    And if you want to raise/lower volume? You keep the button pressed and send a long chain of pulses, depleting the capacitor unless it is rather large. Not to mention that such a capacitor increases costs for the remote :)

    Ilmars said:
    Assuming that effective capacity for our button-cell remote is just 50mAh, we have charge for 30minutes/3.125ms = 576000 transmissions.

    The calculation is correct, but the assumptions that are made for it are naive fallacy. The CR2032 Energizer is a nice thing but most people (and even more manufactures) don't put an Energizer in. Even "respectable" manufacturers place no-name China cells in the remotes.

    BTW, I do have a remote that is driven by 3*AAA rechangable batteries with 750mAh (measured!). And it doesn't stand 8,64M transmissions. Rather a few thousands. But I don't think there is a 10A diode inside :)

    Ilmars said:
    Signal have to be stronger than noise/interference.

    No. signal modulation needs to be stronger than the noise. Constant sun has almost no noise (the sun doesn't flicker with 3ms pulses). So it could be easy to filter the change and ignore the static level. But nobody does this. Well, it makes some sense: the receiver would have to do it all the time whiel the transmitter only has to bring th epower when transmitting. And since the standby current is an issue...

    Ilmars said:
    sunlight heat radiation cannot create interference in cell frequencies

    But gazillions of other cellphones do. Actually with the same modulation too. As you said, there are methods to filter this.

    Ilmars said:
    Actually RF remotes are already there and IR in hi- &mid-end consumer segment most probably will die out.

    I don't think so. RF equipment is already suffering from the congested environment. Existing RF microphones are blown by new LTE transmissions, 433MHz is clobbered with babyphones and construction size transmissions (high power), and, and, and. I don't think cosumer will accept a concept that stops working when a neighbour connects to the internet or so.
    The advantage of IR transmissions is that they are blocked by walls, even if this is from time to time considered a disadvantage.

    My companies main field of operation is in RF based metering devices for industrial environment. And I'm doing the hardware and firmware, so I know what I'm talking about. Sometimes I really long for the simplicity of an IR light barrier.

  • Jens-Michael Gross said:
    I don't see why TV remotes should be treated differently

    Typo. Please don't pretend you did not get that I am talking about IR remotes as such.

    Jens-Michael Gross said:
    And if you want to raise/lower volume? You keep the button pressed and send a long chain of pulses, depleting the capacitor unless it is rather large.

    Your PC TV remote most probably can't do rapid volume changes but your 3*AAA remote - can. Because it's capacitor gets full charge for each IR pulse.

    Jens-Michael Gross said:
    BTW, I do have a remote that is driven by 3*AAA rechangable batteries with 750mAh (measured!). And it doesn't stand 8,64M transmissions. Rather a few thousands. But I don't think there is a 10A diode inside :)

    Rechargeable batteries self-discharge - that's why. Fine! You got IR remote you can rewire for 10mA LED current to test and admit (at last) that you was wrong ;))

    Jens-Michael Gross said:
    Constant sun has almost no noise (the sun doesn't flicker with 3ms pulses). So it could be easy to filter the change and ignore the static level

    You just did greatest invention in human history -  prove that Shannon is wrong. Now we know how to send infinite amount of information over noisy channels :)

    Jens-Michael Gross said:
    sunlight heat radiation cannot create interference in cell frequencies

    But gazillions of other cellphones do.[/quote]

    They don't. Base station controller manages communications such a way that there's no two phones transmitting at same time on same channel in the same area. More detailed description of cell network internals would be out of scope here in particular forum. If you are interested in further chat about this - feel free to write me privately.

    Jens-Michael Gross said:
    RF equipment is already suffering from the congested environment.

    Well.. yes and no. Answer to problem is - free space loss and frequency reuse and "transmit stronger than interferer" alltogether. Disregarding how much congested is 2.4GHz spectrum, two phones always are able to make BlueTooth connection. If they don't do at 5m, then come closer until they do. You know why? - Strong enough signal (over noise) together with frequency hopping (find less congested freq).

  • Ilmars said:
    I don't see why TV remotes should be treated differently


    Typo. Please don't pretend you did not get that I am talking about IR remotes as such.[/quote]
    Sorry, I really have no way to determine when to take your words literally and when to read between the lines.
    And if you're really talking about IR remotes as such (which makes the reference to 'respectabel TV manufacturers' obsolete and also your complaint of me moving from TV to PC-TV as example), then I can tell you that the vast majority of any-type-IR remotes won't use diodes with high currents.

    Ilmars said:
    Rechargeable batteries self-discharge

    I use the very good Sanyo Eneloop rechargeable batteries. The ones I have still have above nominal capacity after about 50 or more charge cycles (most other brands are down to just a fraction of the original ultra-high capacity after 20-30 cycles, even with a high-tech charger) and they have a self-discharge rate of less than 10% per year. So self-discharge is surely not the reason for the fast battery depletion. And yes, this specific remote does have a high-power IR LED (actually two).

    Ilmars said:
    Constant sun has almost no noise (the sun doesn't flicker with 3ms pulses). So it could be easy to filter the change and ignore the static level

    You just did greatest invention in human history -  prove that Shannon is wrong. Now we know how to send infinite amount of information over noisy channels :)[/quote]Re-read my words. I was talkign about static IR level. not noise. Sunlight, as it isn't flickering in the frequency range of the IR protocol, adds just a static offset to the signal. The modulation level stays the same. Proper filtering removes the static offset and leaves just the change. Simples implementation is a primitive high-pass filter.
    This is why e.g. X10 protocol can send information through powerlines even though the power lines have a voltage of +-320Vpp and the signal itself is only a few mV.

    Ilmars said:
    They don't. Base station controller manages communications such a way that there's no two phones transmitting at same time on same channel in the same area.

    And they automagically know when tand where to send? And have such a small-banded transmitter that the won't interfrere with adjacent frequencies?
    After all, these mechanisms are the type of 'optimization' I was talking about, and which aren't done for IR communication because nobody cares.

    Ilmars said:
    Disregarding how much congested is 2.4GHz spectrum, two phones always are able to make BlueTooth connection. If they don't do at 5m, then come closer until they do. You know why? - Strong enough signal (over noise) together with frequency hopping (find less congested freq).

    Sure, and if you really have problem then let the devices touch each other for near-field communication (why don't use a cable right away?). Same for the remote. If the TV is not reacting, go closer to it until it works. Solution found! :)
    No, moving closer or raising power isn't a solution in amny cases. Especially in high-quality audio equipment. Wireless microphones in an opera hall or such. You really won't liek to hear the connection attemps of a cell phone or the internet traffic of an LTE smartphone in the speakers. Sure you could use digital transmission (and raise the operating frequency by the sampling bitsize). Just being louder won't help if you haev analog signals. And for the frequencies that allow digital transmissions, you'll need a license, pay for it everty year and also have to update your existing equipment for an unbearable sum.

    However, this discussion doesn't lead anywhere and - most importantly - is far too much off-topic now.

    P.s.: I read the applicaiton note. I noticed that the capacitor charge and discharge rate is on a 100:1 level. So this remote may be able to send a short pulse but then has to remain silent for a long time until the cap recharges. Not suitable for adjusting light or sound level or something like that. Well, you simply can't have everything at once and need different solutions for different preferences of use.
    P.p.s:I have several IR LEDs in my collection that have a nominal current of only 10 or 20mA. They may stand a current pulse of 100mA for a short time without taking permanent damage, as diodes usually do, but repeated currents...

  • Jens-Michael Gross said:
    Sanyo Eneloop rechargeable

    Agree. They are good indeed. And don't self-discharge less. I have no clue why your Eneloops does not deliver in remote because they handle high currents with ease. Thou I use only alakaline batteries in remote and Eneloop's - in Photoflash (which is different story and usage pattern too).

    Jens-Michael Gross said:
    And they automagically know when and where to send?

    Yes. On purpose :D - GSM BST controller allocate dedicated time slot for each transmission. Thou, CDMA is different story and offtopic w/o doubt ;)

    Jens-Michael Gross said:
    Same for the remote. If the TV is not reacting, go closer to it until it works.

    LOL :) It was just illustration, not solution. Here's another example: I live in apartment building which is crowded with 2.4GHz WiFi access-points, building across a street too. - I can "see" (receive) more than 30 SSID's (and most of them are on factory-default channel, LOL). And yet level of 2.4GHz interference in my room is so low that my WiFi is capable to transmit at full speed. At the same time ez430-rf2500 works well too, especially using slow transmission speed. I am more or less sure that in any living room RF remote that uses same transceiver and frequency-hopping can find reliable channel/frequency to work well. If you think that 2.4GHz is too crowded, then use 5.8GHz (but not 433/800/900 MHz because they penetrate walls too well). Very nice ISM freq for "over the room" communication is 24GHz, in most countries you are getting whooping 200MHz band - hopefully low-cost transceivers are coming. To be honest - disregarding what's written in telecomm magazines, I still believe that radio spectrum is heavily underused and misused too. Mostly because lot of freq's are reserved to .mil for occasional use that most probably never happens in most areas. Check spectrum power density graphs here: http://spectrum-observatory.cloudapp.net/. And those go just up to 6 GHz!

    Jens-Michael Gross said:
    Especially in high-quality audio equipment.

    This is completely different story. Audio needs assured transmission and million times bandwidth compared to remote. Agree that this is tough to get reliable audio transmission using ISM frequencies. In the middle of nowhere it possibly works, but in the city - most probably not. Nowadays professionals shall use licensed spectrum.

    Jens-Michael Gross said:
    However, this discussion doesn't lead anywhere and - most importantly - is far too much off-topic now.

    Fully agree about off-topic, we talk about radios again :D Anyway it was good to chat with you.

    Thank you for good input!

  • vikas dabas said:
    If there is nothing marked on IR led then how would know the rating of led that it is 100mA or 10 mA.

    That is exactly why it is important to know what you're buying (part number; specification) before parting with your hard-earned cash!!

     

  • It sounds like this may be the same project and Nickl is still having some LED issues with his hardware. Linking the threads to give the full picture: http://e2e.ti.com/support/microcontrollers/msp430/f/166/p/248795/871426.aspx#871426

**Attention** This is a public forum