Monday, October 24, 2016

MPPT Circuit using PIC16F88 with 3 Level Charging

MPPT Circuit using PIC16F88 with 3 Level Charging


An MPPT as we all know refers to maximum power point tracking which is typically associated with solar panels for optimizing their outputs with maximum efficiency. In this post we learn how to make a PIC16F88 microcontroller based MPPT circuit with a 3-stage charging.

This data was donated by: Mr. hisham bahaa-aldeen (hisham2630@gmail.com)



The optimized output from MPPT circuits is primarily used for charging batteries with maximum efficiency from the available sunshine.

New hobbyists normally find the concept to difficult and get confused with the many parameters associated with MPPT, such as the maximum power point, "knee" of the I/V graph etc.

Actually theres nothing so complex about this concept, because a solar panel is nothing but just a form of power supply.

Optimizing this power supply becomes necessary because typically solar panels lack current, but posses excess voltage, this abnormal specs of a solar panel tends to get incompatible with standard loads such as 6V, 12V batteries which carry higher AH rating and lower voltage rating compared to the panel specs, and furthermore the ever-varying sunshine makes the device extremely inconsistent with its V and I parameters.

And thats why we require an intermediate device such as an MPPT which can "understand" these variations and churn out the most desirable output from a connected solar panel.

You might have already studied this simple IC 555 based MPPT circuit which is exclusively researched and designed by me and provides an excellent example of a working MPPT circuit.

The basic idea behind all MPPTs is to drop or trim down the excess voltage from the panel according to the load specs making sure that the deducted amount of voltage is converted into an equivalent amount of current, thus balancing the I x V magnitude across the input and the output always up to the mark...we cannot expect anything more than this from this useful gadget, do we?

The above automatic tracking and appropriately converting the parameters efficiently is implemented using a PWM tracker stage and a buck converter stage, or sometimes a buck-boost converter stage, although a solitary buck converter gives better results and is simpler to implement.

In this post we study an MPPT circuit which is quite similar to the IC 555 design, the only difference being the use of a microcontroller PIC16F88 and an enhanced 3-level charging circuit.


MPPT Circuit using PIC16F88 with 3-Level Charging



The basic function of the various stages can be understood with the help of the following description:

1) The panel output is tracked by extracting a couple of information from it through the associated potential divider networks.

2) One opamp from IC2 is configured as a voltage follower and it tracks the instantaneous voltage output from the panel through a potential divider at its pin3, and feeds the info to the relevant sensing pin of the PIC.

3) The second opamp from IC2 becomes responsible for tracking and monitoring the varying current from the panel and feeds the same to another sensing input of the PIC.

4) These two inputs are processed internally by the MCU for developing a correspondingly tailored PWM for the buck converter stage associated with its pin#9.

5) The PWM out from the PIC is buffered by Q2, Q3 for triggering the switching P-mosfet safely. The associated diode protects the mosfet gate from overvolatges.

6) The mosfet switches in accordance with the switching PWMs and modulates the buck converter stage formed by the inductor L1 and D2.

7) The above procedures produce the most appropriate output from the buck converter which is lower in voltage as per the battery, but rich in current.

8) The output from the buck is constantly tweaked and appropriately adjusted by the IC with reference to the sent info from the two opamps associated with the solar panel.

9) In addition to the above MPPT regulation, the PIC is also programmed to monitor the battery charging through 3 discrete levels, which are normally specified as the bulk mode, absorption mode, an the float mode.

10) The MCU "keeps an eye" on the rising battery voltage and adjusts the buck current accordingly maintaining the correct Ampere levels during the 3 levels of charging procedure. This is done in conjunction with the MPPT control, thats like handling two situations at a time for delivering the most favorable results for the battery.

11) The PIC itself is supplied with a precision regulated voltage at its Vdd pinout through the IC TL499, any other suitable voltage regulator could be replaced here for rendering the same.

12) A thermistor can be also seen in the design this may be optional but can be effectively configured for monitoring the battery temperature and feeding the info to the PIC, which effortlessly processes this third information for tailoring the buck output making sure that the battery temperature never rises above unsafe levels.

13) The LED indicators associated with the PIC indicate the various charging states for the battery which allows the user to get an up-to-date information regarding the charging condition of the battery throughout the day.

14) The proposed MPPT Circuit using PIC16F88 with 3-Level Charging supports 12V battery charging as well as 24V battery charging without any change in the circuit, except the values shown in parenthesis and VR3 setting which needs to be adjusted to allow the output to be 14.4V at the onset for a 12V battery and 29V for a 24V battery.

The next article gives the access to the entire source code for the above discussed MPPT circuit using PIC16F88

Available link for download