Go Down

Topic: Current sensing for buck boost converter (Read 3 times) previous topic - next topic

baron-robert

Hi guys,

I'm actually working on a buck-boost led driver to power high brightness LED.
As theses LED must be driven by constant current I wish to monitor the current flowing through the LEDs, and limit it when it reach the operating current i wish for the LEDs

a) can someone comment my schematic, and point me out what's wrong ? I just have some basis in electronics so this schematics is not the best one

b) for the  current sensing application what kind of algorithm should I use to have the most stable current to the leds.
   ie :
  arduino sense voltage out the OpAmp
   while current > xAmp      // derived from OpAmp out
       lower dutyCycle of MOSFET
   end
   set dutyCycle to theoretical value

c) The frequency use for  driving the mofset is ~100khz which king of filter should I use on the OpAmp input ? A simple capacitor ?

Thanks for you time
BR

Note : Rsense =  0,02
          All OpAmp resistors do not have the good value so gain
         
         

dhenry

Your design could not have worked.

The typical design is to put a serial resistor in with the leds. This resistor generates a voltage drop proportional to the current going through the leds. That signal is then compared with a preset threshold to determine if you shut down the switch or not.

This mode of regulation produces a (near) constant current that is irrelevant of the leds' forward voltage drop. And by changing the resistor, you can program the current going through the leds.

Your design does none of that.

tylernt

I don't really have anything to add, except that I think a software-controlled boost-buck driver is a super-cool application for a microcontroller (no need for messing with PWM for dimming, simply vary the switch mode duty cycle, in software, to alter output current). So I'd love to see the final design!

dhenry

Not sure what exactly you are trying to build, and I am sure avrs are completely capable here. But Freescale completely dominates that market (mcu-controlled smps), probably for a good reason. If you are serious about this, you may check those guys out.

Docedison

What you have looks perfectly reasonable. the sensing is... ok but the LM358 isn't a rail to rail device so you loose some range... Possibly. I'd build the current sensor and model it carefully at the rated load and then some, I'd also try it with long wires too first with a dc supply for performance and sensitivity and then go to the switcher and see that it was as stable with the switcher in place.
the issue here is to get the current sensor working first and feeding the correct information back to the Proc.. so the proc can control it
I would also give some thought to the Hall effect current sensors made by Allegro (ACH712) as they will produce a voltage that can be above Vcc/2 or below it at up to 185mV/amp, are inexpensive and don't require a sense resistor. All in all they are at first glance an ideal solution and work off of 5 volts too.  I took the liberty of attaching a data sheet.

Bob
--> WA7EMS <--
"The solution of every problem is another problem." -Johann Wolfgang von Goethe
I do answer technical questions PM'd to me with whatever is in my clipboard

Go Up