I have problem to get a pwm clock.

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

I have problem to get a pwm clock.

961件の閲覧回数
yeongtaehan
Contributor I

Hello.

I'm using KW019032EU board


I want to make a 1Mhz pwm clock by using Processor Expert

This is my code.

int main(void)

/*lint -restore Enable MISRA rule (6.3) checking. */

{

  /* Write your local variable definition here */

  /*** Processor Expert internal initialization. DON'T REMOVE THIS CODE!!! ***/

  PE_low_level_init();

  /*** End of Processor Expert internal initialization.                    ***/

  /* Write your code here */

  /* For example: for(;;) { } */

  TPM_DRV_Init(TPM0_IDX,&tpmTmr1_InitConfig0);

  TPM_DRV_PwmStart(TPM0_IDX,&tpmTmr1_ChnConfig0,4);

  /*** Don't write any code pass this line, or it will be deleted during code generation. ***/

  /*** RTOS startup code. Macro PEX_RTOS_START is defined by the RTOS component. DON'T MODIFY THIS CODE!!! ***/

  #ifdef PEX_RTOS_START

    PEX_RTOS_START();                  /* Startup of the selected RTOS. Macro is defined by the RTOS component. */

  #endif

  /*** End of RTOS startup code.  ***/

  /*** Processor Expert end of main routine. DON'T MODIFY THIS CODE!!! ***/

  for(;;){}

  /*** Processor Expert end of main routine. DON'T WRITE CODE BELOW!!! ***/

} /*** End of main routi

ne. DO NOT MODIFY THIS TEXT!!! ***/

0.6v.jpg

But i have problem. when I get the clock, it always have voltage 0 to 0.6v

How can i  get a 3.3v clock?

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

748件の閲覧回数
yeongtaehan
Contributor I

I found a way.

I changed a pin channel. I got a 3.3v clock. it is working fine.

Thank you

0 件の賞賛
返信

748件の閲覧回数
mario_castaneda
NXP TechSupport
NXP TechSupport

Hi

You have to be sure that clock source for the TPM Module is not cero.

What is your clock initialization for TPM Module? Could you show that picture?

captures3.png

Best Regards

Mario

0 件の賞賛
返信