Timer registers to be updated simultaneously
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-08-10 1:17 AM
Hi,
I am using STM32G474 with TIM1, TIM8 and TIM20 and working with STM32CubeIDE.
I want to updatethe ARR, CCR1, CCR2 and CCR3 regs at the same time. I taught that with the preload register it can be done but it doesn't work for me.
So how can I do to set the ARR, CCR1, CCR2 and CCR3 shadow registers and to make them be updated in a, lets say, overflow event of the CNT register?
Thanks!
- Labels:
-
STM32G4 Series
-
TIM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-08-10 5:51 AM
In output compare mode, enable the OCxPE preload bits. You'll need to write all values before an update occurs.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-08-11 1:00 AM
Hi, thanks for your answer.
I am working in PWM mode 1. I must work in output compare mode? I think it will work in a different way..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2020-08-11 1:12 AM
PWM is one of the output compare modes. Read the timer chapter in RM.
JW
