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.

help about Tms320f28335 (ADC and EPWM) programing with ccs3.3v for MPPT algorithm.

Dear brothers,

I'm using TMS320F335 WITH CCS 3.3.My topic is about mppt with fuzzy logic controller. the input of ADC are the voltage and current from the PV source while the output of DSP (epwm) is  the duty ratio.

I guess i have problem with the setting of ADC and ePWM.  

for ADC i'm using the  SAME sampling time of the system inside time pane of the ADC.the sampling time value is 1/150k is used inside time pane of ADC.

 while the ePWM setting is as follows.

timer period is 3000 because i used up-down mode.so 150Mkh/2*25Khz=3000

other setting of epwm is repectively

do nothing

do nothing

set

clear.

the system is just two sensors and dc-dc boost converter with resistive load. 25khz switching frequency and 1/150khz is the sampling time.

the problem i face is that  when i implement the algorithm inside the dsp, i get higher dsp output (duty ratio) value than normal value so the results are affected. 80% instead of 50%.

please if some one can help me . i agree to send him the module to check the setting of blocks. 

thanks brothers.

  • Your PWM is 25kHz. So I am not sure why you are sampling at 150kHz? This means you are calculating PWM duty ratio 6 times in every PWM cycle. You can update the PWM duty register only once unless you use immediate update mode. I would suggest that you use the sampling freq same as PWM freq.

    To validate your controller output (the calculated duty value) first you need to check that the converted ADC values are good. Then calculate the appropriate controller coefficients based on control loop stability analysis (will require the power stage small signal model) before using it in the control loop.

    Shamim

  • Thanks Shamim for the reply,

    Regarding sampling frequency is 6 times bigger than switching frequency. SAME setting i also use it in simulation part. so, i use the same sampling frequency for the hardware circuit. I think the sampling frequency value is for the whole system not only PWM(not sure).

    for calculating appropriate coefficient i didn't understand the meaning of control loop stability.

    thank you so much