Associate II
October 18, 2023
Solved
Generate a specific PWM signal
- October 18, 2023
- 7 replies
- 10157 views
Hi ST community,
For a project I would like to generate two interdependent PWM signals (Sa and Sw in the attached figure) with the STM32G0. The constraints/tasks are as follows:
- tSw,off = constant for ~100ns
- tSw,on = in a time range from ~100ns to 20us and is limited cycle by cycle by an active break (peak control application).
- tSa,off = set every 300us in a time range from ~100ns to 30us.
- tSa,on = is set every 300us in a time range from ~100ns to 5us.
The times for tSa,off and tSa,on are thus adjusted every 300us. The time tSw,on is limited cycle by cycle by the active break.
Following limitations I had to mention:
- I'm allowed to interrupt the software all 300us for a few us (so polling could be difficult).
- Focus on the STM32G0 microcontroller series.
- The on time tSw,on is limited cycle by cycle with an comparator.
I will not present my previous approaches now, in order not to influence your ideas.
I look forward to your feedback.
Br, Stefan
