TMS320F28374D: Control for both Duty Cycle and Phase shift

Part Number: TMS320F28374D

Tool/software:

Hi Team, 

I received this inquiry from a customer, asking for a mode that would provide precise control of both duty cycle and phase shift: 

"

I am using F2837xD MCU for my project to generate PWM signals. I plan to get the data from ADC and use it to control the duty cycle of PWM. Also, there are two PWM channels that their phase difference should be controlled precisely. In other words, I need both high-resolution duty cycle control and phase shift control. I was reading “TMS320x280x, 2801x, 2804x High Resolution Pulse Width Modulator (HRPWM)” app note SPRU924F and it says:

 

Edge Mode: — The MEP can be programmed to provide precise position control on the rising edge (RE), falling edge (FE) or both edges (BE) at the same time. FE and RE are used for power topologies requiring duty cycle control, while BE is used for topologies requiring phase shifting, e.g., phase shifted full bridge.

Control Mode: — The MEP is programmed to be controlled either from the CMPAHR register (duty cycle control) or the TBPHSHR register (phase control). RE or FE control mode should be used with CMPAHR register. BE control mode should be used with TBPHSHR register.

Apparently none of these configure modes for HRPWM can provide precise control for both duty cycle and phase shift. Can you confirm this or correct me by suggesting a configure mode that I can use for both duty cycle control and phase shift control at the same time?"

Can you help with this? 

-RT

  • Hi RT,

    This is correct, the MEP which controls the high resolution edge of the HRPWM module cannot be controlled by both duty and phase control. In instances where HR control, you can implement modes to switch control of the MEP between duty and phase. For instance, we have implemented this in our TIDM-2013 design which you can reference.

    Alternately, you can keep the HRPWM in duty control mode and calculate the phase shift manually to make use of HR. We don’t have example code that demonstrates this but it is possible

    Regards,

    Peter