Hi
Now l meet a question,l want to set PWM mode as center align,neither use Official library (SDK)function or use set register way,can not set PWM mode as center align.
use register set PWM mode l have publish.why I set PWM model is center align,but result is not I set ?
Use SDK function configure PWM center align process follow:
In main fuction code ,l change PTB14 IO level while set PWM,
OSIF_TimeDelay(2000);
PTB-> PSOR |= 1<<14;
FTM_DRV_DeinitPwm(INST_FLEXTIMER_PWM1);
FTM_DRV_InitPwm(INST_FLEXTIMER_PWM1, &flexTimer_pwm1_PwmConfig);
OSIF_TimeDelay(2000);
PTB-> PCOR |= 1<<14;
FTM_DRV_DeinitPwm(INST_FLEXTIMER_PWM1);
FTM_DRV_InitPwm(INST_FLEXTIMER_PWM1, &flexTimer_pwm1_PwmConfig1);
the result as below picture
l have upload the project that set pwm mode on use SDK function in the attachment.
Solved! Go to Solution.