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.

C2000 F28335 ePWM Module



Hi Everyone,

I am working on DC-DC converter for my college project. I am using C2000 F28335 for controlling my DC-DC converter. I have problem in generating the duty cycle from the ePWM module.

The output of the converter is sensed and that is given to ADCA0 of the F28335 DSC and compensator is implemented to generate the proper duty cycle for the MOSFET. But duty cycle is generated for only initial value of the ADC. The duty cycle value is not updating if i change the ADC value. What could be the problem?...

I am using MATLAB/Simulink Embedded Coder to generate the code for my controller..

  • Hi Nityanand,
    Looks like the PWM duty cycle (compare registers) are not getting updated.
    Make sure that the code (reading ADC result, compensator, updating PWM Duty cycle) is interrupt service routine (ISR) and ensure that ISR is initiated every time there is a new ADC result available.
    -Bharathi.

  • Hi Nityanand,

    As SB has correctly mentioned, using {ADC_ISR and updating duty in this ISR} would definitely solve your issue. There was a similar query a way back and was solved in similar fashion.

    Regards,
    Gautam