OM13092 CLKOUT/CLKIN

cancel
Showing results for 
Search instead for 
Did you mean: 

OM13092 CLKOUT/CLKIN

237 Views
Contributor II

Hi all,

I have an Eval Board OM13092, and I would like to know how can I have access to CLKOUT function (on which pin of the board, and what code is needed to configure the uP to output the main clock) ? 

I would also like to know how to configure my board to use an external clock ( the code needed to configure CLKIN and and on which pin should I actually put my external clock) ?

Thanks in advance,

Nathan Sowie

Labels (1)
4 Replies

3 Views
Contributor II

Thanks a lot !

Nathan Sowie

0 Kudos

3 Views
NXP TechSupport
NXP TechSupport

Hi Nathan sowie,

   1. CLKOUT pin

   If you want to use the CLKOUT pin, you can enable the according pin as the CLKOUT function.

  From the user manual, you can get that:

pastedImage_1.png

If I select PIO0_26 as the CLKOUT function, you can use this code:

void BOARD_InitPins(void) { /* Function assigned for the Core #0 (ARM Cortex-M4) */
  CLOCK_EnableClock(kCLOCK_Iocon);                           /* Enables the clock for the IOCON block. 0 = Disable; 1 = Enable.: 0x01u */

 

  IOCON->PIO[0][26] = ((IOCON->PIO[0][26] &
    (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))      /* Mask bits to zero which are setting */
      | IOCON_PIO_FUNC(PIO026_FUNC_ALT2)                     /* Selects pin function.: PORT026 (pin M13) is configured as CLKOUT */
      | IOCON_PIO_DIGIMODE(PIO026_DIGIMODE_DIGITAL)          /* Select Analog/Digital mode.: Digital mode. */
    );
}

About the details clock to CLKOUT, you can configure the register CLKOUTSEL and CLKOUTDIV register, like the following picture:

pastedImage_1.png

  1. CLKIN

Take care, this is not the pin, this is the internal clock that comes from external crystal oscillator through dedicated pins.

 pastedImage_2.png

 

Wish it helps you!

 


Have a great day,
Kerry

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

3 Views
Contributor II

Hi Kerry,

Thanks a lot for taking the time to answer me, your indications help a lot.

I have another question related to CLKIN: Is there a way to access the XTALOUT/XTALIN pins on the expansion pins of the Eval Board OM13077 ? if so where can I have access to those dedicated ports ?

Or if I want my uP to run with my own external crystal I would have to take out the 12MHz crystal soldered on my board ?

Thanks, 

Nathan Sowie

0 Kudos

3 Views
NXP TechSupport
NXP TechSupport

Hi nathan sowie,

  If you want to use your own crystal, you need to connect it to the XTALOUT/XTALIN pin, no other pins.

  Wish it helps you!

Have a great day,
Kerry

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------