I am working on a project where i have to charge a battery from a PV panel source. I have a boost cascaded by a buck converter for my system. The boost converter for P&O MPPT and the buck for the 3 stage battery charging algorithm. So now I am looking to implement the control. So on a theoretical base I understood that load determines the power drawn with the use of the battery charger and that as the load varies on an MPPT the operating point will move away from true maximum power point. With that said, does it mean that the P&O MPPT algorithm can just be implemented independently and will move from true MPPT on its as when connected to a battery charger ? as in will the charging limits set by the battery charger "tell" the MPPT circuit to move further away from true MPPT or is there a combined algorithm for this ? Is there a source code for this that you guys can refer me to?