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