Skip to main content
GAnde.1
Associate
August 24, 2020
Question

Timer PWM Dithering for each CCRx register?

The STM32G4 series offers dithering to enhance the PWM ratio. My question is, if dithering can be used on ALL the compare channels of the same timer?

Specifically, we generate a center-aligned PWM with two output compare channels 180° shifted. CCR1 and CCR2 are changed simultaneously to change both duty cycle. Can dithering be applied to both registers?

This topic has been closed for replies.

1 reply

waclawek.jan
Super User
August 24, 2020

> The STM32G4 series offers dithering to enhance the PWM ratio.

That's no 'G4-specific feature, it's just software regularly changing the duty cycle.

Okay so hardware dithering is a new feature in G4 timers.

> Can dithering be applied to both registers?

As dithering is nothing more than changing duty cycle, so... why not?

According to RM, yes; you can't avoid it working on all CCRx registers.

JW