PSoC 5LP and AN76496

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi All,

   

I am a part of an organization that is trying to implement a Solar Microinverter. While surfing the net for already implemented similar solutions, we came across the wonderfully written Application Note AN76496. That particular AN had everything that we needed to get us started. It even had the PCB files and the firmware too. It was the best we could hope for.

   

But the problem arose when we needed to do some minor modifications to the firmware to suit our needs. For instance, the proposed design is for 60 Hz while we require a 50 Hz design. In order to make this modification it is essential to know every last bit of the code. Though the algorithm of each block is provided in the AN, I don't find it enough to understand the whole firmware. By whole firmware I mean each and every single line. I contacted the authors of the AN to gather all the available documents related to the firmware. Unfortunately, they don't have any additional documents other than the AN.

   

I need some help in understanding the firmware in such a depth that I will be able to do any modifications depending on our needs. If any of you could help me with this it would be of a big help.

   

Thanks in advance.

0 Likes
2 Replies
AnkitaS_51
Employee
Employee
100 likes received 50 likes received 25 likes received

This design is meant to work for 50Hz or 60Hz as mentioned at page#18 of this application under the topic "Line Lock Detection".

   

If you can ask specific questions to the implementation of code,it will be possible for us to answer.

0 Likes
Anonymous
Not applicable

Hi ANKS,

   

The issue is, I haven't understood the code in depth. For instance I know what each section of the code is supposed to do but I cannot understand what each line of the code does.

   

The first section that I tried to understand was mppt portion. I opened the mppt.c page and had a look at it for days. I know that in the switch case different states are being monitored such as a Self-Test, Wait and so on as shown in Page#20 of AN. But I can't understand what is happening inside each switch case.

   

If I start from the beginning of the .c file, then please could you tell me what the below mentioned macros are for?

   

#define MPPT_AVG_POWER_SIG                (analog_Pslr_z3 >> 16)
#define MPPT_AVG_CURRENT_SIG            (analog_Islr_z2 >> 16)
#define MPPT_AVG_VOLTAGE_SIG            (analog_Vslr_z2 >> 16)
#define MPPT_CURRENT_SIG                analog_Islr
#define MPPT_VOLTAGE_SIG                analog_Vslr

   

​And also how and why these scales are calculated? I did read the comments associated with it but I can't completely understand what is it for.

   

#define    MPPT_UV_SCALING                    62259

   

#define    MPPT_BACKOFF_SCALING            62913

0 Likes