STM32-F401RE change duty cycle on the fly
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-09-29 03:16 AM
Hi every one; using a STM32-F401RE board , how can i canghe on the fly the period and duty cycle of the two signal got in complementary PWM death time using ARR and CCR register?
Labels:
- Labels:
-
STM32F4 Series
-
TIM
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-09-29 03:18 AM
Starting the timer in this way:
HAL_TIM_PWM_Start(&htim1, TIM_CHANNEL_1);
HAL_TIMEx_PWMN_Start(&htim1, TIM_CHANNEL_1);
and using this call back:
void HAL_TIM_PeriodElapsedCallback (TIM_HandleTypeDef *htim)
doesn't work
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-09-29 06:34 AM
Check if you have enabled the timer interrupt.
My STM32 stuff on github - compact USB device stack and more: https://github.com/gbm-ii/gbmUSBdevice