1 /* 2 ** ################################################################### 3 ** Processors: LPC54606J256BD100 4 ** LPC54606J256ET100 5 ** LPC54606J256ET180 6 ** LPC54606J512BD100 7 ** LPC54606J512BD208 8 ** LPC54606J512ET100 9 ** 10 ** Compilers: GNU C Compiler 11 ** IAR ANSI C/C++ Compiler for ARM 12 ** Keil ARM C/C++ Compiler 13 ** MCUXpresso Compiler 14 ** 15 ** Reference manual: LPC546xx User manual Rev.1.9 5 June 2017 16 ** Version: rev. 1.2, 2017-06-08 17 ** Build: b200304 18 ** 19 ** Abstract: 20 ** Provides a system configuration function and a global variable that 21 ** contains the system frequency. It configures the device and initializes 22 ** the oscillator (PLL) that is part of the microcontroller device. 23 ** 24 ** Copyright 2016 Freescale Semiconductor, Inc. 25 ** Copyright 2016-2020 NXP 26 ** All rights reserved. 27 ** 28 ** SPDX-License-Identifier: BSD-3-Clause 29 ** 30 ** http: www.nxp.com 31 ** mail: support@nxp.com 32 ** 33 ** Revisions: 34 ** - rev. 1.0 (2016-08-12) 35 ** Initial version. 36 ** - rev. 1.1 (2016-11-25) 37 ** Update CANFD and Classic CAN register. 38 ** Add MAC TIMERSTAMP registers. 39 ** - rev. 1.2 (2017-06-08) 40 ** Remove RTC_CTRL_RTC_OSC_BYPASS. 41 ** SYSCON_ARMTRCLKDIV rename to SYSCON_ARMTRACECLKDIV. 42 ** Remove RESET and HALT from SYSCON_AHBCLKDIV. 43 ** 44 ** ################################################################### 45 */ 46 47 /*! 48 * @file LPC54606 49 * @version 1.2 50 * @date 2017-06-08 51 * @brief Device specific configuration file for LPC54606 (header file) 52 * 53 * Provides a system configuration function and a global variable that contains 54 * the system frequency. It configures the device and initializes the oscillator 55 * (PLL) that is part of the microcontroller device. 56 */ 57 58 #ifndef _SYSTEM_LPC54606_H_ 59 #define _SYSTEM_LPC54606_H_ /**< Symbol preventing repeated inclusion */ 60 61 #ifdef __cplusplus 62 extern "C" { 63 #endif 64 65 #include <stdint.h> 66 67 #define DEFAULT_SYSTEM_CLOCK 12000000u /* Default System clock value */ 68 #define CLK_RTC_32K_CLK 32768u /* RTC oscillator 32 kHz output (32k_clk */ 69 #define CLK_FRO_12MHZ 12000000u /* FRO 12 MHz (fro_12m) */ 70 #define CLK_FRO_48MHZ 48000000u /* FRO 48 MHz (fro_48m) */ 71 #define CLK_FRO_96MHZ 96000000u /* FRO 96 MHz (fro_96m) */ 72 #define CLK_CLK_IN 0u /* Default CLK_IN pin clock */ 73 74 75 /** 76 * @brief System clock frequency (core clock) 77 * 78 * The system clock frequency supplied to the SysTick timer and the processor 79 * core clock. This variable can be used by the user application to setup the 80 * SysTick timer or configure other parameters. It may also be used by debugger to 81 * query the frequency of the debug timer or configure the trace clock speed 82 * SystemCoreClock is initialized with a correct predefined value. 83 */ 84 extern uint32_t SystemCoreClock; 85 86 /** 87 * @brief Setup the microcontroller system. 88 * 89 * Typically this function configures the oscillator (PLL) that is part of the 90 * microcontroller device. For systems with variable clock speed it also updates 91 * the variable SystemCoreClock. SystemInit is called from startup_device file. 92 */ 93 void SystemInit (void); 94 95 /** 96 * @brief Updates the SystemCoreClock variable. 97 * 98 * It must be called whenever the core clock is changed during program 99 * execution. SystemCoreClockUpdate() evaluates the clock register settings and calculates 100 * the current core clock. 101 */ 102 void SystemCoreClockUpdate (void); 103 104 /** 105 * @brief SystemInit function hook. 106 * 107 * This weak function allows to call specific initialization code during the 108 * SystemInit() execution.This can be used when an application specific code needs 109 * to be called as close to the reset entry as possible (for example the Multicore 110 * Manager MCMGR_EarlyInit() function call). 111 * NOTE: No global r/w variables can be used in this hook function because the 112 * initialization of these variables happens after this function. 113 */ 114 void SystemInitHook (void); 115 116 #ifdef __cplusplus 117 } 118 #endif 119 120 #endif /* _SYSTEM_LPC54606_H_ */ 121