LPC1114 changing crystal frequencies

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by JSalisbury on Fri Mar 25 07:07:41 MST 2011
I am wanting to use a 16.384MHz crystal with the LPC1114 expresso boards. As a first step I was wantinging to change blinky to use at 16.384MHz  When I change the the crystal on the board I also set __XTAL in system_LPC11xx.c to 16384000UL The clock set up in system_LPC11xx.h is as shown. When I start the debugging session I keep ending up in the hardfault fault function! What am I doing wrong? I have checked with a scope and the crystal is running at 16.384MHz

#define CLOCK_SETUP           1
#define SYSCLK_SETUP          1
#define SYSOSC_SETUP          1
#define SYSOSCCTRL_Val        0x00000000
#define WDTOSC_SETUP          0
#define WDTOSCCTRL_Val        0x000000A0
#define SYSPLLCLKSEL_Val      0x00000001
#define SYSPLL_SETUP          1
#define SYSPLLCTRL_Val        0x00000022
#define MAINCLKSEL_Val        0x00000003
#define SYSAHBCLKDIV_Val      0x00000001
#define AHBCLKCTRL_Val        0x0001005F
#define SSP0CLKDIV_Val        0x00000001
#define UARTCLKDIV_Val        0x00000001
#define SSP1CLKDIV_Val        0x00000001

blinky16 Debug [C/C++ MCU Application]   
    MCU GDB Debugger (25/03/2011 13:53) (Suspended)   
        Thread [1] (Suspended: Signal 'SIGSTOP' received. Description: Stopped (signal).)   
            3 HardFault_Handler() c:\d656\nxp workspace\blinky16\startup\cr_startup_lpc11.c:284 0x0000036c   
            2 <signal handler called>()  0xfffffff9   
            1 main() c:\d656\nxp workspace\blinky16\src\blinky_main.c:81 0x00000396   
    arm-none-eabi-gdb (25/03/2011 13:53)   
    C:\d656\nxp workspace\blinky16\Debug\blinky.axf (25/03/2011 13:53)