This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Compiler/TMS320F28035: Modify Solar Explorer

Part Number: TMS320F28035
Other Parts Discussed in Thread: CONTROLSUITE

Tool/software: TI C/C++ Compiler

Hi Guys

I would modify code of MPPT in Solar Explorer devkit. My plan is disable exiting code on B1 and replace with using fuzzy logic. VpvRef_MPPT would be replaced by the result of fuzzy logic computation. NO Error during, i compile that program, but i still have problem in Gui Solar Explorer. I can not start/stop power in panel GUI and display panel GUI (Vpv,Vboost,Ipv,etc) wasn't appropiate value .

void B1(void) // MPPT Execution
//----------------------------------------
{
if(Run_MPPT==1)
{
mppt_pno1.Ipv = IpvRead_EMAVG; //IpvRead;
mppt_pno1.Vpv = VpvRead_EMAVG; //VpvRead;

mppt_pno_MACRO(mppt_pno1);

mppt_incc1.deltaKp = mppt_pno1.delta_Kp;
// MPPT routine
mppt_incc1.Ipv = IpvRead_EMAVG; //IpvRead;
mppt_incc1.Vpv = VpvRead_EMAVG; //VpvRead;

mppt_incc_MACRO(mppt_incc1);

VpvRef_MPPT = mppt_incc1.VmppOut;



if(VpvRef_MPPT<_IQ24(0.0))
{
VpvRef_MPPT=_IQ24(0.0);
}
else if(VpvRef_MPPT>_IQ24(0.9))
{
VpvRef_MPPT=_IQ24(0.9);
}

VpvRef=VpvRef_MPPT;

Run_MPPT=0;
}

//MPPT is a slow task, the following code enables to modulate the rate at which the MPPT is called

if(MPPT_slew==0)
{
if(MPPT_ENABLE==1)
{
Run_MPPT=1;
mppt_incc1.mppt_enable=1;
}
MPPT_slew=0;
}
else
MPPT_slew--;

// Toggle LD2 on the control card if MPPT enabled
if(MPPT_ENABLE==1)
{
if(LedBlinkCnt2==0)
{
GpioDataRegs.GPATOGGLE.bit.GPIO31 = 1; //turn on/off LD2 on the controlCARD
LedBlinkCnt2=1;
}
else
LedBlinkCnt2--;
}
//-----------------
//the next time CpuTimer1 'counter' reaches Period value go to B2
B_Task_Ptr = &B2;
//-----------------
}