Can't lock PLL signal

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

Can't lock PLL signal

373 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by deSteini on Thu Jun 05 05:12:11 MST 2014
In my Startup code i also inizialise the Clock Settings. It worked all the time with the same settings perfect, until i got a problem with the Debugger. Now it seems my Code hangs when he wait that the PLL_Clock is locked.

My Code uses the XTAL as PLL, so do i understand it right, that maybe de Crystal is broken? And can i test this? Here are my inizialisation code:

SYS_CLK_CONF = CLK_SEL_XTAL | AUTOBLK;

  /* PLL, 3-phase output control enable, and power down PLL. */
  CGU_PLL_CTRL = P23EN | PLL_PD;
  /* PLL, MSEL=16, 3-phase output control enable, power down PLL. */
  CGU_PLL_CTRL = PLL_XTAL_SEL | (PLL_M_VALUE"<<"MSEL_SHIFT) | P23EN | PLL_PD;
  /* PLL, MSEL=16, 3-phase output control enable, PLL normal operation. */
   CGU_PLL_CTRL = PLL_XTAL_SEL | (PLL_M_VALUE"<<"MSEL_SHIFT) | P23EN;

  /* Check lock bit, if unlocked, PLL_LOCK is always 0 */
  //while ( !(CGU_PLL_STAT & PLL_LOCK) );                                    hangs
  /* Check clock detection register to make sure PLL is present now. */
  //while ( !(CGU_RDET & PLL_PRESENT) );                         hangs also

Somebody has any ideas?

Thx in advance ;)

PS: "<<" only because otherwise it would be a command here
Labels (1)
0 Kudos
1 Reply

313 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by nxp_apps on Thu Jul 03 16:02:18 MST 2014
Hi,

Which device are you using?
Depending on the device you are using, please see if the sample code works for you (under software tab).

http://www.lpcware.com/node/11538/59

Thanks.

nxp_support
0 Kudos