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.

TMS320F280025: TBPRD and CMPA updated simultaneously in different EPWM modules?

Part Number: TMS320F280025


Hi Experts,

I am asking for my customer here. Urgent case for customer.

Customer are using LLC control by Variable frequency control from 40K to 400K. And when updates the CMPA and TBPRD by using EPWM1_INT (generate the when TBCTR  = Zero) to simultaneous Writes to TBPRD and CMPx Registers Between ePWM Modules. We know the EPWMXLINK and global load function as mentioned F28002x'TRM. 

The customer keep want to use software interrupts to implement the simultaneous Writes, but an error occurred as shown in the figure below. Actually EPWM1 and EPWM2 are writed the same CMPA and TBPRD, but the below figure shows EPWM1A is not normal. This is urgent case, customer need solve this issue to RTM F280025.

(CH1:EPWM1A; CH2:EPWM2A; CH3:EPWM1 ISR; CH4: ADC ISR)

Customer use the ADC ISR to calculate the EPWM1.CMPA/EPWM2.CMPA, the below code enable the EPWM interrupt enable bit in the ADC ISR, and then updates the TBPRD and CMPA/CMPB value in EPWM1_Int.

1.we check the EPwm1Regs.CMPA.bit.CMPA > EPwm2Regs.CMPA.bit.CMPA, no found.

2.we check the utemp > utemp1, no found. and also check the same TBPRD for all epwm module when simultaneous updates.

3.we check the EPWM init code Vs TI's example, no found error.

4.we also have enabled the TBPHS and SYNC from different module, ADC ISR execution time is 2.180us and EPWM1 ISR execution time is 3.06 us.

Please help to check and deep dive the project. Thanks.

1234.zip