AdamWelchUK / PWM85

An ATTiny version of Julian Iletts PWM5 Solar Charge Controller
GNU General Public License v3.0
47 stars 15 forks source link

[Question] How do you handle the maximum power point of the solar panel? #8

Open Rudgas opened 4 years ago

Rudgas commented 4 years ago

Hi,

you make great videos, so thanks for making them! :-)

I have a question about this PWM controller. As I understand it, you measure the voltage at the battery, and if it is below maximum charge, the solar panel is connected directly to the battery. If the voltage starts to rise, you use PWM to "lower" the voltage as not to overcharge the battery until it presumably turns off.

Now, when the battery is, at let's say 9V, the solar panel will operate far from it's desired maximum power point. So I was wondering, why not measure the voltage at the solar panel, and adjust the PWM so the panel as kept at it's preferred voltage near maximum power? In a very simple implementation this could be 75% Voc and reasonably close. Seems to me a good approximation to mppt before actually using mppt.

Also I'm thinking about a supercapacitor as load, so discharged starts and 0V which is very far from the maximum power point.

Cheers!

AdamWelchUK commented 4 years ago

Hi and thanks for the question (and kind comments). You are right of cause that a low battery voltage causes the panel to be further away from it's maximum power point, however this is the case for all PWM solar charge controllers. If you look at the voltage of the solar panel on an oscilloscope you will see when it is connected to the battery, the panel voltage is only slightly above the battery voltage, when the panel is disconnected, it will sit at it's open circuit voltage - the transition between is very fast - there is no stored energy in a solar panel which slows that process. So if you increase the disconnected time to increase the average voltage of the panel (in the aim of keeping it closer to is MPP) all you are doing is reducing the time connected to allow current to flow from the panel into the battery. A DC2DC converter holds that energy in a magnetic field using the inductor but that's a much more difficult build.

Rudgas commented 4 years ago

Would a simple capacitor be suitable? A DC2DC converter is used because we don't want overvoltage on our lead acid batteries right? For my application I've reevaluated my DC microgrid and come to the conclusion of using a few step-down converters with USB plugs. (HW-298, which are quite interesting as they take ~6-32V and output a max. of 24W across several Quick Charge protocols from ~3-12V). Now since HW298 fulfills the role of the buck-converter, I'm wondering if a capacitor on the output of the polar panel would work like this:

Panel -> Cap -> Mosfet(controlled) -> HW298

The solar panel will constantly charge the capacitor and at the point we reach our target voltage(Vmp), the mosfet is switched on, providing power to the load. Ideally in such a high frequency the load doesn't just go on/off every few seconds, possibly using some king of PID algorithm to make it a bit smoother.

Currently when there is low light, the HW298 will pull the panel (50Wp 36 cells) down to about ~5V and keep it's output at ~4.6V which trickle charges the powerbank. So using the above mentioned "buffer" capacitor to keep the panel at a higher voltage I wonder if I can get a bit more power out or if my HW298 will just deplete its input capacitor in an attempt to charge the power bank at maximum power that it will turn on/off a few times per second,

Rudgas commented 4 years ago

Ok, some progress on this. The HW298 does not have any input current limitation and will always pull as much as possible/the output will draw. My powerbank has an input current limitation and will only draw as much current as is possible while keeping the input Voltage above ~4.6V.

Now what will happen on more or less cloudy days is, the HW298/powerbank will increase it's current draw and pull the panel down to ~5V while the HW298 is still providing around 4.6V as output. The powerbank reduces its current draw and will keep the HW298 "alive". The panel will now be very far away from it's mpp and even if the clouds lift a bit, it will not get out of the "5V sink" (now I understand that's a problem that lead acid batteries will never have). If there is a spot of bright sun, power draw from the load will be overcome and the voltage will shoot up to about ~20V. So for a lot of time the panel will sit at 5V, far from it's mpp and trapped at low power output even though it could provide a lot more.

I've now hooked up an arduino with a voltage divider for voltage sensing and a mosfet to control power flow. The code is extremely simple, if the panel voltage falls below 16V, decrease PWM duty cycle until panel voltage > 16V and then increase it.

This is so far successful in that it prevents the panel to stay trapped at a low voltage. But it's not really smooth. Devices drawing more than the panel can supply, the panel V will plummet, the HW298 turns off, the arduino will cut power, panel V rises, HW298 turns on and drops the panel V again. And this will repeat. (Sadly for the powerbank as well as I guess it will have no time to adjust to the lower supply current as the output of the HW298 will jump up and down).

However it works marvelous with a simple resistor as load >.<

slybunda commented 1 year ago

use a 15000uf cap on the solar panel, that should help it out.