Controlling a 12v Led-Strip with PWM

Go To Last Post
15 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Guyzz

I have bought a 12v led-strip for the summerhouse including a 12v wallwart switcher, and want to control it via the 10bit pwm on a Mega8.

I have attached my eagle schematic , but i don't know if this would do , or if i need the schottkey and/or C1 on the 12v supply.

I have a tonn of IRF520N , but they aren't LogicLevel , so i chose a IRLZ44N.

What PWM speed would be suitable , is 200Hz enough ?

Would it be possible to use this with an IRF520 if PWM freq is 200Hz ?

I can't remember the led-strip effect , but seem to remember the switcher is 12v max 2A.

Would you have a look at the eagle schematic , and come with corrections ?

TIA
Bingo

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

As long as the switching frequency is higher than about 75Hz, it should be fine.

At even 200Hz, slow turn-on and turn-off times will be inconsequential compared to the on or off times. You should be fine even with wimpy gate drive at that frequency.

I am a bit concerned about the lack of current limiting. Is there something built into the LED string so that it will run directly from 12VDC?

What is the purpose of the zener diode in the EAGLE schematic? There should be little or no practical effect from inductive flyback. And, even if the LED string were to fail open, the FET would suffer no consequence. Then again, it hurts nothing.

Jim

 

Until Black Lives Matter, we do not have "All Lives Matter"!

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

top schematic, IRF540:
Add something (~100R) in the gate to stop this becoming an RF transmitter during the turn-off. And 10k in the base will give you plenty base current, no need to waste 4mA.
You need to find the turn-on time: The gate threshold is around 5V, so you are putting 700uA into the gate during the transition. Gate charge will be around 10V*1960pF+12V*40pF=20nC, 20nC/700uA= 29 usec which is pretty slow, but okay. At 5ms that's 0,6% of the period, so even if all of the 29us was transition, and power dissipation was 20W during transition, it would still only be ~100mW in the FET.

Do keep the reverse diode (most anything will work, 1N4148 even). While it is true that there won't be much inductive kickback from the inductance in the wiring going to the LEDs, LEDs very much dislike being reverse biased. Some of them (the strips/modules used for lighting) even have built-in reverse diodes on each led for this reason (both to catch transients, and for ESD).

/Kasper

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Jim

The led strip has built in resistors for each led , and is made/designed to run from 12v.

I'll drop the Schottkey (it's not a Zener) or have i misselected in eagle ? , i just remembered Ossi saying i needed it when i played with a 12v Halogen bulb (But he also mentioned that it was a strange beast).

I'll play with the IRLZ44N as in the eagle schematic, and then later maybe with a BC547 and the IRF520N with 12v gatedrive.

Edit:
@KKP
Ok will keep the Schottkey or would a 1N400x also do at that slow pwm ?

Thanx for the advices

/Bingo

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

At that low PWM frequency, almost any diode will work as the reverse bias protection diode.

Junction diodes "only" have problems when they turn off after being on. There is this thing called "reverse recovery time". Charges get stored in the junction in proportion to the forward current. Those charges have to be removed from the junction before the diode will actually turn off. So, if there is no large current flowing in the diode at the time that things switch, there is no recovery time and the circuit is happy.

On the other hand.... a 1N400x, being designed for 60Hz rectification, has a lot of reverse capacitance. Any diode has this capacitance, but the larger the area, the greater it is. Being a rectifier, these diodes are pretty large in area. This is worst at low bias (that is, near zero volts) and decreases as the reverse voltage increases. Actually, checking on 1N4000 through 1N4007, the worst case junction capacitance at 4V reverse bias is only 15pf - that is not bad at all. At 100mA of drain current, that would only take only a few nanoseconds to charge that to a full 12V, and that is inconsequential compared to the other switching speeds. So, a 1N400x should be just fine.

Jim

 

Until Black Lives Matter, we do not have "All Lives Matter"!

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi !

70Hz doesn't work for me: I can see that pwm frequency. So I prefer a higher frequency.

I use a lot of these led-strips and read on other fora that the pwm freq interferes with f.i. TV. That is why I use a buck converter-like outputstage. As attached.
PWM drive is 30kHz.

Attachment(s): 

A GIF is worth a thousend words   They are called Rosa, Sylvia, Tricia, and Ulyana. You can find them https://www.linuxmint.com/

Dragon broken ? http://aplomb.nl/TechStuff/Dragon/Dragon.html for how-to-fix tips

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Um, so what's the point of the buck converter like output stage? I've missed something.

A friend wants me to add led strip drivers to my (currently fictitious) products at barefootelectronics.com

If you don't know my whole story, keep your mouth shut.

If you know my whole story, you're an accomplice. Keep your mouth shut. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
Um, so what's the point of the buck converter like output stage?
No pwm noise. And comfortable for me eyes ;)

A GIF is worth a thousend words   They are called Rosa, Sylvia, Tricia, and Ulyana. You can find them https://www.linuxmint.com/

Dragon broken ? http://aplomb.nl/TechStuff/Dragon/Dragon.html for how-to-fix tips

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So you read the resistor divider and adjust the pwm to get the v you want. You use this as a dimmer?

If you don't know my whole story, keep your mouth shut.

If you know my whole story, you're an accomplice. Keep your mouth shut. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

HW allows reading the resulting voltage but so far I didn't implement it in SW since the human being, controlling the ledstrip intensity, is part of the feedback loop ;)

So yes, it's a dimmer. I think that's the whole deal with controlling the PWM ...

A GIF is worth a thousend words   They are called Rosa, Sylvia, Tricia, and Ulyana. You can find them https://www.linuxmint.com/

Dragon broken ? http://aplomb.nl/TechStuff/Dragon/Dragon.html for how-to-fix tips

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ok. I have to make one of these. Let's see, when will I have some money again...

If you don't know my whole story, keep your mouth shut.

If you know my whole story, you're an accomplice. Keep your mouth shut. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Nard,

I realise that you connect your led strip between the "WW" pin and ground, but what does "WW" stand for? Presumably something in Dutch.

Seasons greetings,

Ross

Ross McKenzie ValuSoft Melbourne Australia

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Ross,

The ledstrip is connected between +12V and the WW pin.
WW, in both {Dutch} and English, stands for {WarmWit} resp. WarmWhite. There are three more identical output stages: for Red, Grn and Blu.

So why didn't I use "Wht" as designator ? Aha, glad you ask.
A few years back I built a small series RGB controllers for my daughter. To keep it daughter-friendly, the "White" button on the controller selected all three channels. And in the SW I called that "Sel_wht".

These new series have 4 channels. But now the White button should select the white strip, not the three RGB channels in one go. And because I like to recycle SW, I needed to distinguish between these two. And WarmWhite (WW) does that.

Nard :)

A GIF is worth a thousend words   They are called Rosa, Sylvia, Tricia, and Ulyana. You can find them https://www.linuxmint.com/

Dragon broken ? http://aplomb.nl/TechStuff/Dragon/Dragon.html for how-to-fix tips

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

"Warm white" of course ... why didn't this "witless wonder" work that one out? :lol:

Cheers,

Ross

Ross McKenzie ValuSoft Melbourne Australia

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanx guyzz for all the tips.

I'll give them all a shot

Happy New year :-)

/Bingo