Hello,
I'm new to this so I'm asking. If I connect a solar cell to a battery bank, can I use a resistor of whatever rating to act as a overcharge prevention for the batteries?
I'm talking about tiny scale configuration, which consist of 5V 0.2W cell and 2-4AA 2050mAh batteries in series (I have enough sunlight to fully charge them during the day if I'm not mistaken).
I thought that maybe I can put some sort of a resistor or something like that to work as a overcharge prevention.
Am I even close? or I got it all wrong?
Thanks in advance.
For a lead acid battery if you keep the charge amperage low you can get away with overcharging.
The better solution would be to implement some kind of shunt regulator. And of course if you've already got an Arduino in the mix you can simply monitor the battery voltage and turn on a lightbulb (or just send the current back to GND) when the voltage goes over a certain threshold.
It depends on the battery technology. [
Here](http://data.energizer.com/PDFs/charger_appman.pdf) is some information about charging NiMH cells.
2-4AA 2050mAh
What? 2 or 4? 4 AA batteries in series is (nominally) 6V so you
aren't going to charge 4 batteries with 5V.
(I have enough sunlight to fully charge them during the day if I'm not mistaken).
Not if they are dead... Power (Watts) is Voltage x Current.
2.050 x 2 x 1.5 is 6 Watt Hours. With 0.2W from your solar cell, that's 30 hours to recharge under ideal conditions, assuming 100% charging efficiency, and you're probably only going to get 0.2W at noon in the summer on the equator. 
I'm not going to use an arduino for this project.
And I have NiMH batteries so I do need to figure something out right?
About the shunt regulator, the circuit in the post is what I should follow? or should I read everything everyone has to say about it there?
@DVDdoug I meant to charge 2 sets in parallel of 2 batteries in linear, or I can get another tiny panel for the other 2. sorry for not making myself clear. 
Thanks a lot for the response.
should I read everything everyone has to say about it there?
I suggest consulting a reliable source of battery information. This is one: http://batteryuniversity.com/.
However, with that tiny solar panel, it is unlikely that you can damage NiMH cells no matter how long you charge.
Really that's good to hear! 
I'll try it in the open at first to see what I'm getting.
And then I'll move them into the enclosure I make for them.
Thanks A lot! you really helped me! 
0.2W rating at 5V means the PV cell will give 40mA. Slightly higher (~50mA ) at low voltages.
That's 1/50C (capacity-hour of the battery), should be quite harmless to NiMH chemistry.
Don't forget to add a diode to prevent battery discharge through the panel during the night (a solar panel behaves roughly like a resistor in darkness) .
Or check if it doesn't already has one, cheap small panels normally don't have them.
Yeah I know I'll add the diode anyways.
Thank you for all the responses you really helped me!
@blimpyway what is the max ratio I can put into a NiMH battery without harming it?
blimpyway:
That's 1/50C (capacity-hour of the battery), should be quite harmless to NiMH chemistry.
Thanks again for all the knowledgeable answers. 
From what I understand from battery university site, 1/20C should be a safe trickle charge current for NiMH.
For 4x 2000mAh batteries in series, you might want to use 6V/100mA panel. They-re less than $2 on Aliexpress, but delivery waiting is usually a few weeks.
Also beware that solar resource varies a lot with season and weather.
E.G. at my location (45 deg. latitude, eastern europe) in december-january I can expect a harvest of 1-1.5 full sun-hours daily on average, but can have a couple weeks in a row with much lower than that.
While in june-july, yield can average 4-6 full sun-hours daily.
One "full sun-hour daily" means a panel that provides 1A at full sun, will produce 1Ah in a day.
So a 40mA panel, depending on season, will output between 40mAh and 250mAh in a day.