cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H7 PWM ASYMMETRIC MODE

Toxicobull
Associate II

Hi, 

I would use PWM Asymmetric mode to create phase shift between two PWM signals on stm32h7. i didn't find application note for this mode for stm32cubemx, could anyone explain it for me please ? 

duty cycle must be the same for the two signals.

Thank 

4 REPLIES 4

The asymmetric mode is described in AN4013 and in more detail in Asymmetric PWM mode subchapter of TIM chapter in RM. Basically, you set up one of the asymmetric modes in TIMx_CCMRx.OCxM (note that for historical reasons it's not a continuous bitfield), and then adjust the two times corresponding to the two edges in both CCRx and its adjacent CCR(x+1)/CCR(x-1), depending on whether x is even or odd.

JW

Toxicobull
Associate II

Thank you for your answer,

I setted up the timer it output the two signal, now am trying to shift them with dead time value (0,255) , but it's not sufficient I want to shift between 0 PI ?

TDK
Guru

Don't use dead time, use PWM Mode 2 as JW suggested. This, along with potentially flipping polarity, will give you full control of the duty cycle and delay between signals.

If you feel a post has answered your question, please click "Accept as Solution".
Toxicobull
Associate II

Thank you guys 🙂