How to change periode using timer DMA PWM?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-06-24 5:16 AM
I watched a tutorial using this code:
pwmData[0] = 10;
pwmData[1] = 20;
pwmData[2] = 30;
pwmData[3] = 40;
pwmData[4] = 50;
pwmData[5] = 60;
pwmData[6] = 70;
pwmData[7] = 80;
pwmData[8] = 90;
pwmData[9] = 100;
HAL_TIM_PWM_Start_DMA(&htim1, TIM_CHANNEL_1, (uint32_t *)pwmData, 10);
With it you can change the duty cycle of many signals, I would like to know a way to put also successive periods in an array, in order to change, not only the duty cycle but the periode as well. The problem with this code is that ARR doesn't change? Is there a proper way to realize what I would like?
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-06-24 8:08 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-06-24 5:43 AM
HAL_TIM_PWM_Start_DMA = PWM control for constant frequency pwm ~`duty change.
If yoou need other setup configure DMA for your reg...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-06-24 5:45 AM
I saw that there is special function, i will look into to know how it works using TIM with DMA Burst Transfer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-06-24 8:08 AM
