external clock K22

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

external clock K22

1,025 Views
jacquescharreyr
Contributor I

Hello,

I am using a MK22FN512VLH12 with and external oscillator and it does not run.

Since I had no luck with mbed I tried tried with processor expert and KDS2.0.0 and if I use internal clock it works OK but if I use external crystal no luck :-(

I have used a 8Mhz cristal .as well as the 32kHz for the RTC with the capacitors and resistors specified in the user guide. (FRDMK22UG.pdf)

My programs work on the FRDMK22

Can you help please.

Jacques Charreyron

0 Kudos
Reply
3 Replies

605 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Jacques Charreyron,

    Thank you for your interest in Freescale kinetis product, I would like to provide service for you!

      How did you design your external crystal circuit, please refer to this :

49.jpg

  After your download your external oscillator code to your chip, you should use the oscilloscope to test the external crystal, whether it is oscillating.

  If it is not oscillating, please change anther crystal and try again, maybe your external crystal is broken.

  Wish it helps you!
If you still have question, please contact me!


Have a great day,
Jingjing

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

0 Kudos
Reply

605 Views
jacquescharreyr
Contributor I

Jingjing

Many thanks for your help.

I have followed your recommendations and now we can run on the external crystal PROVIDED we increase the flash memory divisor.

Let me explain a little bit what we did :

     We have developped a test program thanks to the FRDM K22 dev board. It works OK with core @ 12OMHz bus @ 60 MHz and flash @ 24 Mhz (Divisor = 5)

     Then we switched to our production board :  We can only run the test program with core @ 12OMHz bus @ 60 MHz BUT flash at @ 17 Mhz.(Divisor = 7)

     (With the P&E debugger we saw corrupted memory readings)

We are still investigating ou hardware layout (power, decoupling capacitor ...) but does anyone encountered this strange issue before?

Thanks for your help.

Yours,

Jacques

0 Kudos
Reply

605 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Jacques Charreyron,

      Did you use the same test code in your FRDM-K22 and your own board?

      Besides, did you use the same debugger?

    I think, you can configure your board with 24MHZ(the same code with FRDM-K22), then just download the code to your board without the debugger, or use the same debugger with FRDM-k22.

After download the code, then check the code function, whether it is correct.

    We should make sure, it is not caused by debugger.

    Besides this, I suggest you take care of some points:

  1: Reset_b pin, add 4.7K to 10K pullup resistor , and add 0.1uf capacitor between reset_b to ground.

  2: NMI_b pin, add 4.7K to 10K pullup resistor

3: SWD_DIO, add 10K pullup

Wish it helps you!


Have a great day,
Jingjing

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

0 Kudos
Reply