Understanding FTM CPWM

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Understanding FTM CPWM

352件の閲覧回数
sean_dvorscak
Contributor III

I am looking for a better understanding to something that I am seeing from the PWM output on the FTM in Center Aligned PWM Mode.

From what I read in the reference manual, if the ELSB = 1, and ELSA = 0, then the FTM PWM is set on the channel match during the down count, and cleared on the channel match of the up count.

However, I see on the scope the PWM set on the channel match of the up count, and cleared on the channel match of the down count.

Here is a capture of the scope showing a 80% duty cycle pulse on FTM CH0 (shown in the bottom red Ch 7 on scope).  The pink (Ch 2 on scope) are the INITTRIGs from the FTM when the FTM counter reaches 0 (CNTMIN = 1).  As you can see, the pulse is centered around the MOD value of the FTM:

CNTMIN-working--00000.jpg

 Here is my complete configuration, let me know if I am missing something with my current configuration of FTM3 that is making me misunderstand what I am doing(I know it shows CNTMAX instead of CNTMIN is set, but this is because I was doing other experiments when I took these pictures.  No other configuration settings were changed for the scope picture):

CNTMAX_After_Pulse_Function_1.PNG

CNTMAX_After_Pulse_Function_2.PNG

CNTMAX_After_Pulse_Function_3.PNG

CNTMAX_After_Pulse_Function_4.PNG

 

   

0 件の賞賛
1 返信

320件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hello @sean_dvorscak,

I'm not able to replicate it.

danielmartynek_0-1674641599663.png

Can you share the whole project so that I can test it on my side?

 

Thanks,

BR, Daniel

 

 

0 件の賞賛