This is a nice modification - and I understand it (somewhat) which makes it all the more sweet. When I tested it I was getting much lower currents than I expected (wanted 40ma, got 6ma - emitter resistor = 100ohm). I removed the 10K base resistor and I got the expected current. This makes sense to me since the base is now at 0V, current flows into the emitter until the drop across the emitter resistor drops it down to 0+0.6V, hence (Vdrive-0.6)/R. However, if I drive it from the unregulated supply, it seems that the current will be proportional to the drive voltage - not a current source at all. Am I missing something? I tried putting a 560 ohm resistor on the base and found through experimentation that a 33ohm at the emitter gave me 40ma. With this setup, the current is not so sensitive to varying the emitter resistor. But it is still linear WRT Vdirve. P.S. I am now interested in driving the LED from the unregulated supply because the IR LED can take high currents (up to 1A) for the short transmit pulses and I think having that large current surge before the regulator seems like a good idea. Does that make sense? --BobG -----Original Message----- From: pic microcontroller discussion list [mailto:PICLIST@MITVMA.MIT.EDU]On Behalf Of Russell McMahon Sent: Friday, September 20, 2002 9:55 PM To: PICLIST@MITVMA.MIT.EDU Subject: Re: [EE]: Inverting IR LED driver with 1 transistor Now the men have had their input :-) - there is an interesting variation you can use here. Instead of putting both LED and resistor in the collector lead, place the resistor in the emitter. This then becomes a VERY rough current source as the current is limited to (Vdrive-0.6)/R E --> resistor --> +5V C --> LED --> GND B --> resistor --> TTL output from uP Odds are its not much different in result than the other arrangement in this case. This would be of more affect if you drove the LED from a different voltage source than the cpu - eg with an NPN drive & the LED supplied from the unregulated battery supply while the processor runs on a regulated supply. Have a look at the circuit inside typcal IR remotes and see what they do (will vary no doubt) RM -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu