cancel
Showing results for 
Search instead for 
Did you mean: 

Output comparison pulse problem

hao
Associate

On the stm32h750, I want to use 4 channels to implement pwm waves with different phases in the output comparison mode of tim8. Chanel's mode selection switches on match. The stages are 0% 25% 50% 75%. When the phase is zero (sConfigOC.Pulse = 1-1), the waveform does not flip, while other channels flip according to the set phase.

 

This post has been translated from Chinese to comply with the ST Community guidelines.

S__101253122.jpg

3 REPLIES 3
Sarra.S
ST Employee

Hello @hao, welcome to ST community, 

Could you share your TIM8 configuration? 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

My configuration in tim8 is as follows

messageImage_1731749127824.jpg

messageImage_1731749180078.jpgmessageImage_1731749266167.jpg

Sarra.S
ST Employee

Hello @hao

For channel1, the counter starts at 0 and immediately matches the compare value (0) -since it's configured as toggle on match- then the counter starts counting up (to reach 999), there is no further match within the same period, and the output remains in its toggled state

Is that clear? 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.