Hi there, I am currently working on a project where I need to drive a Laser via PWM.
To remove external interference e.g from ambient light, the Laser is driven via PWM at a specific frequency,
Everything is working perfectly so far.
Unfortunately though, I keep killing laser diodes, I am just using these cheap eBay 650nm items, which only state input voltage 3-5v.
My drive circuit is only a 2N2222A under the diode, with a 200ohm resistor on the base, and 5v on the emitter. The PWM is Running at 50% duty cycle.
I assume I need some kind of current control on the laser diode, perhaps with an LM317? Is there some simple circuit that uses an LM317 along with minimal parts that accepts TTL input?
Just like an LED you can't simply switch the voltage on and off you need something to control the current so that the power produced is within the power rating of your diode.
Have you searched for ways of driving them?
Here is one link.
Your description does not describe the connections I would expect. Emitter should be ground and diode should be between the +V and the 2N2222a collector.
Are the diode bodies getting hot? If so could you simply drop the voltage to 3V?
Or make the pwm on 10% and off 90%.
Perhaps this simplification will not work in your system but most interference is 60 Hz and 120 HZ and 20k HZ. if you run the PWM at 1k to 5K you should be able to make a passive band pass filter.
That souds wrong. 0V on the emitter would make sense, the 2222 is an NPN device and should be used as a low-side switch.
Laser diodes are very sensitive to drive current which needs to be controlled, and they must have heatsinking unless used on a low duty cycle.
That makes no sense to me - the Goertzel algorithm measures frequency whereas you want to measure amplitude at a known frequency which is called synchronous detection.
Those cheap laser diodes only have a current limiting series resistor, more seems not required. An external resistor can be used to decrease the current/brightness, and I also tested them up to 8V pulses.
Don't over current laser diodes, the margins are very slim between lasing and frying.
A laser diode is basically an LED optimized for very high current densities and with a quantum well (both required to get a population-inversion). The high current densities are why they need both careful current limiting and good thermal management.