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.

TMS320F280049: PWM configuration in VIENNA PFC code

Part Number: TMS320F280049
Other Parts Discussed in Thread: C2000WARE

Dear C2000 expert,

In vienna pfc code, the path is C:\ti\c2000\C2000Ware_DigitalPower_SDK_2_00_01_00\solutions\tidm_1000\f28004x, I fould that the slave PWM has a phase shift value with 2, can you please help me know why? I have highlighted the question code as show below.

void VIENNA_HAL_setupPWM(uint32_t base1, uint32_t base2, uint32_t base3,
uint16_t pwm_period_ticks)
{
VIENNA_HAL_configurePWMUpDwnCnt(base1, pwm_period_ticks);
VIENNA_HAL_configurePWMUpDwnCnt(base2, pwm_period_ticks);
VIENNA_HAL_configurePWMUpDwnCnt(base3, pwm_period_ticks);

//
// configure PWM 1 as master and Phase 2, 3 as slaves and
// let it pass the sync in pulse from PWM1
//
EPWM_disablePhaseShiftLoad(base1);
EPWM_setSyncOutPulseMode(base1, EPWM_SYNC_OUT_PULSE_ON_COUNTER_ZERO);

EPWM_enablePhaseShiftLoad(base2);
EPWM_setSyncOutPulseMode(base2, EPWM_SYNC_OUT_PULSE_ON_SOFTWARE);

EPWM_setPhaseShift(base2, 2);
EPWM_setCountModeAfterSync(base2, EPWM_COUNT_MODE_UP_AFTER_SYNC);

EPWM_enablePhaseShiftLoad(base3);

EPWM_setSyncOutPulseMode(base3, EPWM_SYNC_OUT_PULSE_ON_SOFTWARE);

EPWM_setPhaseShift(base3, 2);
EPWM_setCountModeAfterSync(base3, EPWM_COUNT_MODE_UP_AFTER_SYNC);

}