Currently, I did not have those parts you mentioned.
I just tried two methods. One worked and the other did't work.
The work one:
Connect DIM- (white) to Arduino ground.
Connect DIM+ (blue) to Arduino 5V.
Write 0-255 to the PWM pin for dimming.
Not working one:
I used SparkFun MOSFET Power Control Kit.
Connect 9Vdc power supply + and - to MOSFET + and -.
Connect MOSFET c to Arduino PWM pin.
Connect DIM- (white) to breakout board -.
Connect DIM+ (blue) to breakout board +.
Write 0-255 to the PWM pin, but it did not work.
I just tried to connect dim+ to Arduino pin3 and dim- to Arduino GND.
LEDs ramped up and down.
However, I measured the Vo on the power supply outlet end. It went up to 41.2V and gradually down to ~17V.
why the Vo did not go down to 0V? How can I switch off LEDs using PWM in this case?
why the Vo can go up to ~42V? The manual said that I need to dim the LEDs based on 10V PWM control. I think I am just using 5V on board.
Thanks a lot. Learn a lot from you.
ps. dim+ and dim- are two wires for dimming function on the LED power supply.
Here is the code for testing the dimming function.
int ledControlPin = 3; // Must be a PWM pin -- 3, 5, 6, 9, 10, 11
// Setup the LED control pin as output, start low
for (int i=0; i<=255; i+=1) // Sweep LED on
delay(1000); // Hold at full brightness
for (int i=255; i>=0; i-=1) // Sweep LED off
You can't measure PWM with a multimeter, only with a scope.
PWM is full on, or full off.
With PWM you control the time that the lights are on or off.
The repeat frequency depends on the pin used. Pin 3 is ~500herz.
PWM switches the lights on/off so fast that our eyes/brain think the LEDs are dimming.
Remember that this is a constant current supply, not a constant voltage supply. 17volt means nothing.
Max voltage you will measure (with 100% PWM) is the forward voltage of the LEDs.
10volt is the control voltage. Nothing to do with the LED voltage.
You are now using 5volt PWM from the Arduino.
That limits dimming to 0-50%, because it's a mix of PWM and voltage control.
A transistor, as explained in post#1, fixes this.
Do the LEDs turn off when PWM is 0.
Maybe have a longer delay in your code to SEE if they turn off.
I am building a research project in school.
I am testing LED ramping up/down that looks similar to light intensity of sunrise and sunset.
I cannot find BC547 around me.
Can I use 2N2222A instead of BC547?
Here is the spec comparison:
Type Package Ic(mA) Vce Vcb hfe@Ic FT(MHz)
BC547 TO-92 100 45 50 110-800 2
2N2222 TO-18 800 40 75 100-300 150
I will post what I got.
I tried last night to connect DIM + and DIM - to a bench power supply stepping down from 10V to open state. I also read Vo from a meter.
Here is what I got the varying voltage for DIM vs. Vo:
DIM 10V —> Vo 42.1V
DIM 9V —> Vo 42.1V
DIM 8V —> Vo 42.1V
DIM 7V —> Vo 42.1V
DIM 6V —> Vo 42.1V
DIM 5V —> Vo 41.1V
DIM 4V —> Vo 40.0V
DIM 3V —> Vo 38.9V
DIM 2V —> Vo 37.6V
DIM 1V —> Vo 36.0V
DIM power off —> Vo 36.9V
Can you please let me know why Vo in this case did not follow the 0 ~ 10V dimming function?
What is the 0 ~ 10V and 10V PWM signal dimming function here? I thought that I need to either varying voltage for DIM or controlling PWM when Arduino Board is powered by 12V.
Yes, almost any small signal NPN transistor can be used here.
As I told you before, this is a constant current LED driver.
Voltage has no meaning.
To test this 600watt driver, you have to connect a bunch of LEDs to it.
At least SEVEN in a string and at least SEVEN of those strings if the LEDs are 3watt each.
That is at least 47 3watt LEDs, mounted on a heatsink with forced cooling.
Or get COB (chip-on-board) LEDs.
Try to find 10-string or 12-string (30-40volt) COB LEDs
Don’t think of trying a 200watt LED without the best heatsink paste and a big (CPU) heatsink with fan.
Running it bare will destroy it in 2 seconds.
The remote pin can switch the supply into standby (< 0.5watt), by connecting RC+ to RC-
You can’t use BOTH functions, RC and PWM, if you don’t share Dim- and RC-
But the manual is NOT clear if you can share DIM- and RC-
I would not try.
If… you want to use both, and power the Arduino from this suppy…
Connect RC-/ground to Arduino ground.
Connect +5SB to Arduino 5volt
Connect RC+ to an Arduino output pin.
Do NOT use the transistor circuit I gave you.
Use an opto instead.
Opto transistor emitter to DIM- and collector to DIM+
Opto LED cathode to Arduino ground.
Opto LED anode via 1k current limiting resistor to an Arduino PWM pin.
Before you change to this, measure the resistance between DIM- and RC-/ground.
If it’s ZERO ohms, the whole story changes.