MPC5675K FlexPWM Help

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

MPC5675K FlexPWM Help

1,770件の閲覧回数
seandonohue
Contributor II

Hi, I am having difficulty seeing an output from the FlexPWM module. I am trying to set up a simple 1Hz PWM with a 50% duty cycle on FlexPWM0_B1. My MOTC clock source is the 16MHz IROsc divided down by 4 to get a 4MHz clock. In the FlexPWM, the IPBus clock is selected as source and the clock is divided down by 128 for a 31.25KHz PWM clock. INIT is -(31250/2), VAL0 is 0, VAL1 is 31250/2, VAL4 is -(31250/4) and VAL5 is 31250/4. Can someone tell me what is missing from my configuration?

Original Attachment has been moved to: PWM_ADC_Tests.zip

ラベル(1)
0 件の賞賛
返信
1 返信

1,506件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

The root cause is the Fault protection. In fact any of 4 FAULT pins can “disable” single PWM output of the submodule. The mapping is done by DISMAP register. You may see chapter “ Fault protection” within device reference manual.

So for example if there is a fault (logic one if FLVL bit is set or logic 0 if FLVL bit cleared) on FAULT0 pin and corresponding DISA0 bit is set the PWMA output of the submodule will be disabled. Similarly for other FAULTx / DISAx pairs.

Each submodule have its DISMAP register so for each PWMX/PWMA/PWMB pin the fault protection may be enabled for certain FAULT pin.

Try to clear the DISMAP register, then you will see the output signal.

Note: internal logic level may prevent PWM output to run, so you should check the FLVLx bits in such case (only if DISx is set, but no external pin is selected for FAULT circuitry, PCR[IBE] cleared).

Best Ragards,

Petr

0 件の賞賛
返信