SparkFun Forums 

Where electronics enthusiasts find answers.

General project discussion / help
Did you make a robotic coffee pot which implements HTCPCP and decafs unauthorized users? Show it off here!
By ipish
#177297
Hi guys, I am quite new in electronic projects and my basics are quite limited. I've been reading a lot regarding this topic (refer to the tittle) and I am currently working out to buy the suitable solar panel and battery for my project. The price is expensive, so I need to ensure I made the right choices.

1. My project
We assume the battery need to power the RPi for about 15 hours (assume 5pm – 8am without sunlight in Malaysia) without having the solar panel charging the battery. This means, it will rely on the battery solely for 15 hours. the power consumption is ~5.25 W or ~1200mA (with wifi dongle,camera,and IR sensor connected at GPIO)

In brief, a proper Power Supply to the RPi must be rated at 5V regulated, 2A and that the power consumption would be around 5.25 W.

How to proceed in calculating suitable Solar Panel, regulator and Battery?

2. Running RPi from Solar Power (and battery) Example

From viewtopic.php?f=63&t=13901
“…I used a 50 watt solar panel, a 20 Ah Lithium battery, and a charge controller that was made for that particular battery. I also used a USB car charger to convert the 12 volts from the battery down to 5 volts… this setup is working perfectly. I've had several cloudy days with no issues. The Pi keeps on running! I also see the controller charging the battery (and running the Pi) when there is fairly low light, so I think the 50 watt panel was the way to go…”

But this might be an overkill?

3. Some choices

Solar Panel
http://www.lelong.com.my/20-watt-solar- ... -Std-P.htm
This one gives 12V 20W

Battery
http://solarpower-mart.com/solar_battery
12AH, 12V
By Valen
#177315
From viewtopic.php?f=63&t=13901
The requested topic does not exist. Please provide the full link to it.

Your stated voltages and currents don't match the power values that you state. So please check your values or explain how you derived them.
By ipish
#177357
@Valen Apologize for the error, the actual link is below

http://www.raspberrypi.org/forums/viewt ... 63&t=13901

@jreminton It's not the "right choice" per say. I am required to use Raspberry Pi for this project. The RPi is already bought and the basic project (it's a mailbox notification system) is finished. Now I want to run it on Battery + Solar Panel (using a 24 hours operation first for testing before possibly going further)

Any help on the question (1) and (2)? Thanks.
By waltr
#177358
1- Consider a few cloudy/rainy days. This increases the time the battery is needed.
1a- Be careful on Battery capacity specs. Many batteries can not be fully discharged therefore you must adjust the capacity values in your calculations. Dividing by two is safer.
1b- Be careful on what battery you use. Not all Lithium batteries are the same. the Deep Cycle Lead-acid battery you linked to is a good choice if its capacity is large enough.
1c- You do need to consider the Voltage regulator efficiency as this is additional discharge for the battery. A switching PS tends to be more efficient.

2- Again be careful with Solar Panel specs, most are rated for Maximum direct sun at 90°. When the sun is rising/setting the solar panel output is greatly decreased and the Voltage may be too low to run the R-Pi and charge the battery. This means that your 8am to 5pm Sun time is much less. Half the spec to ensure you obtain enough power for the solar panel.
By ipish
#177383
Thanks for the kind advice. I will take notes on each of those specific issues when I'm about to buy the battery.

However, my main aim remain unanswered. I need to understand the calculation necessary to find out the minimum capacity of the equipment (Solar Panel, charger and battery). Would you be kind to give some explanation on that? For simplicity, lets assume a single 24 hours operation. You can use the values I provide below and some dummy values for charger efficiency and other variables if needed.
- power to the RPi should be at 5V regulated, 2A
- power consumption is ~5.25 W.
- runs on battery solely for 15 hours
- runs on battery with Solar Panel charging for 9 hours
By waltr
#177396
You just need to ensure that in the following equations the left side is greater than the right side:

Power generated >= power consumed
For sunlight
Solar panel power(Watts) * time (hours) >= {[R-Pi power (Watts) + efficiency losses (Watts)] * time (hours)} + used battery capacity (WHr)
For night
Battery capacity (WHr) >= [R-Pi power (Watts) + efficiency losses(Watts)] * time (hours)
By ipish
#177418
Mee_n_Mac wrote:
ipish wrote: - power to the RPi should be at 5V regulated, 2A
- power consumption is ~5.25 W.
Which is it, 5V @ 2A (10W) or 5.25W ?
Hi, the RPi (with devices attached) draws around 1.2A but there are not many adapters with 1.2A (the ones I have is 1A or 2A). So, I assume that using 1A is probably not enough and using that 2A adapter will give sufficient current. Do I understand this wrongly? Please advice, thanks.
By ipish
#177419
waltr wrote:You just need to ensure that in the following equations the left side is greater than the right side:

Power generated >= power consumed
For sunlight
Solar panel power(Watts) * time (hours) >= {[R-Pi power (Watts) + efficiency losses (Watts)] * time (hours)} + used battery capacity (WHr)
For night
Battery capacity (WHr) >= [R-Pi power (Watts) + efficiency losses(Watts)] * time (hours)

Hey man, this is just what I need! Thanks!
By ipish
#177422
I came out with this after further reading. Can you guys check if my understanding is correct?

1. Determine the energy consumed in a 24 hour period.

RPi usage (load) = 5.25W * 24 Hour = 126 watt-hours

2. Add in the Fudge Factor for energy consumed (50% losses)

Lets multiply the total 24 hour load energy by 1.5 to account for several factors such as the system efficiencies, including wiring and interconnection losses as well as the efficiency of the battery charging and discharging cycle, and allowing extra capacity for the system to recharge the batteries after they have been drained.

New load = 126*1.5 = 189 watt-hours

3. Determine Solar Insolation in Hours (disregard 9 hours of sunlight stated earlier)

Most solar map data are given in terms of energy per surface area per day (kWh/m2/day) which can be read directly as "Sun Hour Day” (hours of a day with sunlight). Kuala Lumpur receives in average around 6.0 kWh/m2/day.

4. Determine the size of the Solar Panel

The size of the solar panel array is determined by having the adjusted daily load divided by the Sun Hour Day. So for Kuala Lumpur;

189 /6.0 = 31.5 watts

5. Determine Battery size

All batteries will last substantially longer if they are shallow cycled (discharged only by about 20% of their capacity) whereas deep discharge means that a battery is discharged by as much as 80% of its capacity. Let’s assume we want the battery for the system discharged by 80% of its capacity. The battery daily load (the daily energy taken from the battery) should be more or the same as the energy consumed in the 24 hours period. Add an additional fudge factor for battery of about 50% to account for the efficiency of the battery discharge, the battery's capacity is available after use, and the loss in efficiency due to temperature. We have;

189*1.5 = 283.5 watt hours

This is the battery capacity, which is usually given in ampere-hours so it must be divided by the nominal voltage; 283.5 / 12 = 23.625 Amp Hours
By waltr
#177426
I would use 50% of rated battery cap instead of 80%.
6.0 kWh/m2/day.
189 /6.0 = 31.5 watts
Are you mixing Watts with kiloWatts?
Hours with days?
I don't follow this part.
By ipish
#177445
@waltr I'm trying to reduce the minimum battery capacity required. I need to show a demo for it. The deep cycle charging is deliberately chosen for now, despite its disadvantage on battery life.

Regarding the Sun Hour Day, it's a new concept to me. You may wanna read more here. There is no mixing between watts and kilowatts as far as i understand. The Sun Hour Day is given in kWh/m2/day but calculating the Solar Panel amperage needs it to be in that unit.

Have a look on these links (the info needed is on step 4 and 5)
http://solardirect.com/pv/systems/gts/g ... power.html

Afterwards, can you tell me if I do this correctly? I'd appreciate that. totally a newb here
By Mee_n_Mac
#177446
ipish wrote: Can you guys check if my understanding is correct?
OK, let's take it point by point.
ipish wrote:1. Determine the energy consumed in a 24 hour period.

RPi usage (load) = 5.25W * 24 Hour = 126 watt-hours

2. Add in the Fudge Factor for energy consumed (50% losses)

Lets multiply the total 24 hour load energy by 1.5 to account for several factors such as the system efficiencies, including wiring and interconnection losses as well as the efficiency of the battery charging and discharging cycle, and allowing extra capacity for the system to recharge the batteries after they have been drained.

New load = 126*1.5 = 189 watt-hours
So that's really 189 W-hr/day. I might argue w/the fudge factor. You need something to account for added RPi "accessories" and to transform the battery voltage into the RPi's input voltage (5V). Don't double count the battery related stuff, just try to get a good average but conservative number for the energy used in a day.
ipish wrote:3. Determine Solar Insolation in Hours (disregard 9 hours of sunlight stated earlier)

Most solar map data are given in terms of energy per surface area per day (kWh/m2/day) which can be read directly as "Sun Hour Day” (hours of a day with sunlight). Kuala Lumpur receives in average around 6.0 kWh/m2/day.
OK so at the end of an average day, a 1m^2 panel would have 6 kW-hr fall on it. Actual panel output would be less as no panel is 100% efficient.
ipish wrote:4. Determine the size of the Solar Panel

The size of the solar panel array is determined by having the adjusted daily load divided by the Sun Hour Day. So for Kuala Lumpur;

189 /6.0 = 31.5 watts
No and yes. At first it appears that you've mixed units. 6 kW-hr is 6000 W-hr and that's for a 1 m square panel at a mythical 100% efficiency. So it's really;

189 W-hr/day / 6000 W-hr/m^2/day

... which gives an answer in m^2, not W, assuming 100% efficiency. That's 0.0315 m^2.

So what's a reasonable efficiency ? I'll SWAG 12% for a panel you can afford.

So you need a panel that's 0.0315/0.12 = 0.26 m^2 or ~ 50cm by 50 cm.

Alternately you can look at the peak power rating of a panel. This is supposed to be the power output when under an "illumination" (irradiance) of 1000 W/m^2, what you might get at high noon at the equator. If you get 6000 W-hr/day then multiply the power rating in W by 6 (=6000 W-hr/day/1000 W/m^2) to get the panel output in W-hr/day. Conversely divide the energy needed by 6 to get the panel power rating. (perhaps this is how you got it ?)

A 100 W panel, whatever it's size, will output 100 W if it's illumination is 1000 W/m^2. If it got that for 6 hrs (= 6000 W-hr) then it would output 100 W during those 6 hrs for an energy total of 600 W-hr.

Since you only need 189 W-hr/day, you need 189/6 = 31.5 W panel. (this is the yes part of no and yes)

I'm unsure if the Sun Hour Day includes a factor for the Sun not being perpendicular to the surface over the whole day. I think it does.
http://pveducation.org/pvcdrom/properti ... -radiation

But wait there's more. The panels output voltage won't match the battery voltage. There will be a loss in converting one to the other and so the panel needs to output more power to account for that loss or you won't be refilling your battery. A good efficiency number to use would be 85%, so divide the size or power rating by 0.85.
ipish wrote:5. Determine Battery size
Now redo using the above and don't forget to include extra capacity for days w/o any Sun. After all you can't charge it up to more than 100%. Multiple very sunny days can't make up for 2 days of pouring rain (ie : no sunlight). I also think your 50% efficiency is really conservative. A real number might be 95% for the charging cycle and 95% during the discharge cycle (= 0.95 * 0.95 = 0.9).
By Mee_n_Mac
#177448
But wait there's more. The panels output voltage won't match the battery voltage. There will be a loss in converting one to the other and so the panel needs to output more power to account for that loss or you won't be refilling your battery. A good efficiency number to use would be 85%, so divide the size or power rating by 0.85.
Now that I think about it, the panel must be larger than the above. It must account for all power losses and uses in the system. So it must also sized to include the battery losses. Using my 95%/95% from above and keeping the 189 W-hr/day means the panel needs to supply 189 W-hr/day used /(.95*.95*.85) = 246 W-hr/day. So that's a 41 W panel.