PEE mode of KL26 doesn't work!

cancel
Showing results for 
Search instead for 
Did you mean: 

PEE mode of KL26 doesn't work!

220 Views
junwang1
Contributor II

clock mode is PEE, 12MHZ crystal. init code is generated under PE, External crystal doesnot work , and program halts at "while((MCG_S & MCG_S_IREFST_MASK) != 0x00U) " //Check that the source of the FLL reference clock is the external reference clock.,  this is why?

0 Kudos
3 Replies

138 Views
mjbcswitzerland
Specialist V

Hi

Try modifying the setting for

MCG_C2 to either have the  MCG_C2_HGO set or fnot (high gain crystal mode or low gain crystal mode).

This depends on the HW design - if the crystal has a parallel resistor and loading capacitors MCG_C2_HGO is needed for it to start but otherwise it should not be used so that it starts.

Regards

Mark

0 Kudos

138 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi junwang,

I am using KDS3.2 with Processor Expert, please refer below setting.

PEE 12MHz KL26.png

If the program still halts, please observe the waveform of XTAL0 and EXTAL0 pins by using oscilloscope.

Make sure the crystal circuit is well soldered.

Best Regards,

Robin

0 Kudos

138 Views
rastislav_pavlanin
NXP Employee
NXP Employee

Hi Jun,

most probably you do not have initilaize OSC module. It is required have it properly initialized to be able to enter PEE mode of MCG.

regards

R.

0 Kudos