Content originally posted in LPCWare by bazli on Thu May 26 04:57:07 MST 2016
Hi,
we narrowed it down.. on boards that it fails, it's failing when we run CGU code to get it to 180MHz.. It seems to get to 96MHz reliably. Is it something that might be able to fix in code?
uint32_t CGU_Init(void){
CGU_EntityConnect(CGU_CLKSRC_IRC, CGU_BASE_M3);
CGU_SetXTALOSC(12000000); //enable the external crystal = 12MHz
CGU_EnableEntity(CGU_CLKSRC_XTAL_OSC, ENABLE);
CGU_EntityConnect(CGU_CLKSRC_XTAL_OSC, CGU_CLKSRC_PLL1);
CGU_SetPLL1(8); // Set System Core Clock = 8 * 12MHz = 96MHz
CGU_EnableEntity(CGU_CLKSRC_PLL1, ENABLE);
CGU_EntityConnect(CGU_CLKSRC_PLL1, CGU_BASE_M3);
// CGU_SetPLL1(15); // Set System Core Clock = 15 * 12MHz = 180MHz <==== failing if we call this function..
CGU_UpdateClock();
return 0;
}