最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

c - STM32F407 TIM PWM mixed offset signals - Stack Overflow

programmeradmin4浏览0评论

I'm working on a project on an STM32F407-DISC and I want to output the attached signal via PWM, I would like to offload as much of this from the processor as possible while keeping the timing of these as consistent as possible. I thought it might be possible to use each of the channels of TIM8 to produce each of the signals, but I'm not sure if it's possible to setup the PWM mode to produce each of these signals. I need it to be 1.024Khz at the moment, with the possibility of going higher later.

I'm working on a project on an STM32F407-DISC and I want to output the attached signal via PWM, I would like to offload as much of this from the processor as possible while keeping the timing of these as consistent as possible. I thought it might be possible to use each of the channels of TIM8 to produce each of the signals, but I'm not sure if it's possible to setup the PWM mode to produce each of these signals. I need it to be 1.024Khz at the moment, with the possibility of going higher later.

Share Improve this question edited Mar 20 at 17:02 3CxEZiVlQ 39.5k11 gold badges84 silver badges93 bronze badges asked Mar 20 at 16:50 Jack M.Jack M. 112 bronze badges 1
  • 1 Hi, Is your question specifically "is it possible to set up TIM8 in PWM mode to generate this waveform?" If so, I think no sorry. PWM mode could generate 4 signals, one on each timer channel, at the same frequency with a single edge each period. The LDAC and CONV signals each have two edges that make this not work. – GandhiGandhi Commented Mar 20 at 17:39
Add a comment  | 

1 Answer 1

Reset to default 0

I would suggest using DMA in memory to memory mode. As destination set your GPIO. Trigger DMA in requiored periods and the waveform required will have to be set in the memory as an array.

发布评论

评论列表(0)

  1. 暂无评论