# COMMUNITY : FORUMS : TECH

## Can anyone help with a solar circuit?

Hello!

I'm trying to build a solar powered night light.  What I would like is to have it charge during the day and automatically come on when it senses darkness.  Here is what I've gathered so far, any suggestions are appreciated:

3AA rechargeable batteries (3.4V)
1 4.5 volt solar cell
1 phototransistor
1 transistor
4 White LEDs (20ma)

This is my first posting and I'm a (near) complete novice to electronics!  Can anyone tell me if the photo-transistor or transistor needs a resistor and if so which one???

What resistor do I need for my LEDs???

How do I wire it so that my solar cell can recharge my batteries but not ruin my LED???

Thanks again and please feel free to chime in with your two cents =)

sort by: active | newest | oldest
Orngrimm4 years ago
OK... I did not find the original schematics...
But i recreated one for you! :)

I tried to keep it as simple as possible and used the lowest part-count i was able to make up.
The LED will start glowing weakly (1mA) if the voltage from the solarcells drop to 2.226V.
Then it will gradually increase (Up to 18.3mA) if the solar cell gives 0.0 volts.

Those values are calculated for a red LED with a drop-voltage of 1.8V as following:
You will have around 3V at the "lower exit" of the transistor.

Now the value of the resistor is:
R=(Supply-LEDdrop)/I
where:
Supply = our 3V
LEDdrop = the 1.8V for a red LED
I = 20mA for a normal LED-Current
This gives us:
R=(3V-1.8V)/0.02A=60Ohm
Unfortunately, 60ohm is not part of the common E12-Series of resistors. Very close is the 56Ohm. Lets see the current with this one:
I = (Supply-LEDdrop)/R = (3V-1.8V)/56Ohm = 21.4mA
I think every LED will be able to hold that. :)

Now if you go for another LED like a white one, be aware that they have other Dropvoltages.
Also with a white one, you run into another problem: A normal white needs 3.6V to run normally. And you only have 3V at your disposal after the transistor.
In my build, i was going for 2 LEDs in parallel: one red and one yellow.
Since the yellow one has a lower dropvoltage, it will light uo earlier (if the solarpanel is lowering the voltage) and shine longer (if the solarpanel is raising the voltage). This gives you some kind of sunrise- and sunset-effect with a dimming from red-orange to yellow before it shuts down and gives way to the sun itself. :)

If you have 2 LEDs in parallel, you need twice the current, so 40mA which would half the resistor needed. Just solder 2 of the 56Ohms in parallel to get half the resistance you need.

Attached is the schematic (For my red&yellow-LED-thing).
Have fun :)

4 years ago
Very nice, I've been wanting to do this as well, but for a everlasting LED throwies. I also drew up a schematic as reply lol, but you beat me too it and I have to say that yours is better thought out. Using the solar cell as the light sensor is a much better idea :)

One potentially useful thing I can add is this link to an LED resistor calculator.
http://www.hebeiltd.com.cn/?p=zz.led.resistor.calculator
4 years ago
Hahaha! Yeah. I always wanted to keep the partscount low with such projects. And in the far past, i also used LDRs and phototransistors as sensor for those things... until it dawned me that i had a HUGE FRIGGIN LIGHTSENSOR at my disposal and dont even need ANOTHER one only to tell me that "Since Sensor 2 says 'No light' i suppose also sensor 1 (Solar) doesnt have any light either".
What a paralellism!
So i came up with the solution i posted above: Use the solarcell as solarcell AND lightsensor. :)

And thankls for the link to the res-calc. Such things are handy for the electronic-starter-DIYer.
jayshields (author) 4 years ago
found a good schematic here:

http://www.reuk.co.uk/Use-Solar-Panel-As-Darkness-Detector.htm
jayshields (author) 4 years ago
thanks for the comments guys the parts are on order :)
Orngrimm4 years ago
I made a "sunjar" once myself... google it. It is exactly what you want: A jar which gathers the sun and glows with its energy at night (Charges battery with solar and powers LED at night).
I dont know if i find the schematics, but the basic thing was:

- Use the Solarcell to charge the batteries. I hooked them up directly since i had a 3V-Cell and 2x1.2V rechargeable batteries.
- Use the voltage of the solarcell to determine if there is sun or not. Often this is done with a Lightdepending resistor, but hey: The Solarcell IS a photosensor! Use that! :)
I used a simple darlington-stransistor to switch on of the voltage dropped below a certain point.
- The triggering voltage from the solarcell can be adjusted if you use a potentiometer to for a voltage-divider.

The complete thing fitted perfectly in the top of a small jar. US-people call it a mason's jar i think... Mine was intended to hold mashed berries and has a glass-lid with a rubber-sealing. Perfect to place the hole thing watertight but shinethru.

all those directions may say not much to you since you are (as you wrote) a novice in electronics.
I have to see where i can dig up the schematics for that or make a new for you...
Lyger0004 years ago
You could adapt a Pummer circuit to do what you want , google 'pummer' theres loads of different sites with circuit diagrams and kits.