Need help to light up 8 LEDs with different color

Thread Starter

jenovauh

Joined Jul 4, 2013
246
Here is a photo of my solderless breadboard. Notice that I put one blue LED on the output of the BS170 MOSFET to test the circuit. And in the photo, you can see that the blue LED is lit because of the flash on the camera, so the response is quite fast.

All black wires are ground, and all red wires are Vcc. All resistors are .25w. I didn't label the components, but you can probably figure out which is which. If you have questions, just ask.
Hi Tracecom, I follow the schematic but I could not clearly see how to attached the LED into the circuit. Never use a BS170 before, can you advise on that? Thanks.
 
Last edited:

tracecom

Joined Apr 16, 2010
3,944
Look at the schematic drawing and find the pin numbers on the BS170. Then, look at the attached drawing to see which pin has which number. Connect by the numbers.
 

Attachments

Thread Starter

jenovauh

Joined Jul 4, 2013
246
Look at the schematic drawing and find the pin numbers on the BS170. Then, look at the attached drawing to see which pin has which number. Connect by the numbers.
Yes I actually google and find out on the picture you had attached too. My question is the LED diode need to connect on the Drain(1) leg of the BS190 right? I connect the Anode side of the LED diode to Drain leg of BS170, the LED light up very dim even if the surrounding environment is bright or not.
 

Attachments

Last edited:

tracecom

Joined Apr 16, 2010
3,944
Yes I actually google and find out on the picture you had attached too. My question is the LED diode need to connect on the Drain(1) leg of the BS190 right? I connect the Anode side of the LED diode to Drain leg of BS170, the LED light up very dim even if the surrounding environment is bright or not.
Cathode of the LED goes to the drain and anode to plus voltage. But you need a current limiting resistor in series with the LED. For a supply voltage of 12V, 1k should work.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
Cathode of the LED goes to the drain and anode to plus voltage. But you need a current limiting resistor in series with the LED. For a supply voltage of 12V, 1k should work.
I am using a 9V battery. Even without the resistor the blue led is so dim as you can see on my previous attachment. I had try resistor from 100 ohm, 500 ohm and 1k ohm. All are as dim like nothing lol. No idea what went wrong.
 

tracecom

Joined Apr 16, 2010
3,944
I am using a 9V battery. Even without the resistor the blue led is so dim as you can see on my previous attachment. I had try resistor from 100 ohm, 500 ohm and 1k ohm. All are as dim like nothing lol. No idea what went wrong.
Post another photo or two of your entire breadboard, so I can look for wiring errors.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
In the first two photos you posted, I don't see any connection between pin 7 of the 741 and +V. Is it there?
You are right. I forget the pin 7 connection to +V. So sorry, but after I plug that in the LED light up when I tune the VR1. The LDR1 does not seem to have any effect on the environment. I took pictures from anti clockwise direction. You can take a look if there are any error. Thanks a lot.
 

Attachments

tracecom

Joined Apr 16, 2010
3,944
I can see it better, and didn't see any errors.

If I remember correctly, I had to be very careful to cover the top of the LDR in order to make the LED go out. The tiniest bit of light would keep the LED on. Try again, and this time, hold your finger or thumb tightly against the top of the LDR. Maybe you also want to dim the lights in the room.

If that doesn't work, change R1 to 10k and try, and then change R1 to 100k and try.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
I can see it better, and didn't see any errors.

If I remember correctly, I had to be very careful to cover the top of the LDR in order to make the LED go out. The tiniest bit of light would keep the LED on. Try again, and this time, hold your finger or thumb tightly against the top of the LDR. Maybe you also want to dim the lights in the room.

If that doesn't work, change R1 to 10k and try, and then change R1 to 100k and try.
Okay thank, I will try that tomorrow and update again. Also do i need to tune VR1 to make it work? It's 3:30am now, gonna rest. :)
 

tracecom

Joined Apr 16, 2010
3,944
I think I actually turned VR1 until the LED went out in room light, and then I used a flashlight pointed at LDR1 to turn it back on. But, it has been a while, and my memory isn't great. We will make it work. Good night.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
I think I actually turned VR1 until the LED went out in room light, and then I used a flashlight pointed at LDR1 to turn it back on. But, it has been a while, and my memory isn't great. We will make it work. Good night.
Hi Tracecom, I follow what you mention and it works. :D Using VR1 to tune to the environment brightness to light it up. I do notice the LED is always lite up with a very very dim grow. Is that correct or do you experience it? It does not really shutoff the whole circuit.
 

tracecom

Joined Apr 16, 2010
3,944
Congratulations. I am happy for you.

Regarding the dim glow, I did not experience that, but maybe we can stop it. The BS170 must be conducting slightly, so the first thing I would try is to reduce the value of R3 from 100k to 10k. Let me know if that works.

Also try connecting another color and see if it glows. It is also possible that when you connect all the LEDs, the glow will stop.

I will not have much access to the internet for a few days, so don't be surprised if I don't post often. I will be back.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
Congratulations. I am happy for you.

Regarding the dim glow, I did not experience that, but maybe we can stop it. The BS170 must be conducting slightly, so the first thing I would try is to reduce the value of R3 from 100k to 10k. Let me know if that works.

Also try connecting another color and see if it glows. It is also possible that when you connect all the LEDs, the glow will stop.

I will not have much access to the internet for a few days, so don't be surprised if I don't post often. I will be back.
Hi tracecom, thanks a lot. I will try to change R3 and let you know the result later. Before you replied, I had connected 2 string of 2 Red LED, 1 string of 2 blue LED, 1 string of 1 UV LED and 1 string of 1 Orange LED. Each string I use a 220 ohm resistor. I don't know how to calculate the right resistor size. All seem to work except the very very dim grow when switch off. Which I will try later as you suggested when I am home later.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
Hi tracecom, somehow the very dim grow does not happen anymore. I have no idea what cause it to happen the previous time when I connected only 1 blue LED. Now that I had connected with 8 LEDs in the circuit, I do not see the very dim grow at all. I tried to replicate using only 1 blue LED but still did not see the dim grow.

I had used up all my 9V alkaline batteries to test how long the circuit can last. So right now I am using 2 X 3.7V 4500mAh Lithium battery to test run the circuit. It is able to run for 13 hours nonstop until the blue LEDs start to goes off.

I think maybe after calculating the correct resistor, the battery life might last longer or any other way can the circuit be tweak for longer battery life? I am using all LEDs that draw 20mA to make it simple, except different color with various forwarding voltage.
 

Bernard

Joined Aug 7, 2008
5,288
Example of R calc. Red LED Vf =2.2 V @ 2 in string = 4.4V, with 2 batteries of 3.7V ea. = 7.4V, subtract Vf's of 4.4V = 3V. R= V/I, so 3V/ .02A = 150 Ω. Try it with other LEDs.
 

Thread Starter

jenovauh

Joined Jul 4, 2013
246
Example of R calc. Red LED Vf =2.2 V @ 2 in string = 4.4V, with 2 batteries of 3.7V ea. = 7.4V, subtract Vf's of 4.4V = 3V. R= V/I, so 3V/ .02A = 150 Ω. Try it with other LEDs.
Hi Benard, thank you so much. I had figured that calculation yesterday while reading some other post here. :). I am trying to calculate with the battery size, how long in theory can the lithium battery drive the LEDs. I notice that the blue and UV LEDs always dim out first due to the higher forward voltage leaving the red and orange LEDs only.

Is there anyway to shutoff the circuit when the power in the battery have drop to a certain voltage around 2.5 voltage per cell. I read that it is not good to drop the lithium battery too low.
 

tracecom

Joined Apr 16, 2010
3,944
jenovauh,

I am glad you are making progress. Bernard has much more knowledge than I have, and can give better advice on battery chargers.

May I know what is the purpose of your LEDs?

Bernard,

Thanks for your help.

I will be back on more regularly in a few days.
 
Top