Other Parts Discussed in Thread: C2000WARE
Hi,
I have an issue with updating duty cycle on EPWM on the run. The update of duty cycle takes around 1us, which is not acceptable, SYSTEM clk is 200MHz, TBPRD is 1000u, PWM freq is 50Khz.
I am using this code to initialize PWM with dead band =>
initEPWMWithoutDB(EPWM11_BASE,2);
setupEPWMActiveHighComplementary(EPWM11_BASE);
After this trying to write to CMP regiter to update the duty cycle =>
EPWM_setCounterCompareValue(base, EPWM_COUNTER_COMPARE_A, Value);
EPWM_setCounterCompareValue(base, EPWM_COUNTER_COMPARE_B, Value);
Please let me know why duty cycle update takes such a long time, is there any way to reduce it?
Regards,
Parvathi