1 /* 2 ** ################################################################### 3 ** Processors: MIMX8MN6CVTIZ 4 ** MIMX8MN6DVTJZ 5 ** 6 ** Compilers: GNU C Compiler 7 ** IAR ANSI C/C++ Compiler for ARM 8 ** Keil ARM C/C++ Compiler 9 ** 10 ** Reference manual: MX8MNRM, Rev.B, 07/2019 11 ** Version: rev. 2.0, 2019-09-23 12 ** Build: b211101 13 ** 14 ** Abstract: 15 ** Provides a system configuration function and a global variable that 16 ** contains the system frequency. It configures the device and initializes 17 ** the oscillator (PLL) that is part of the microcontroller device. 18 ** 19 ** Copyright 2016 Freescale Semiconductor, Inc. 20 ** Copyright 2016-2021 NXP 21 ** All rights reserved. 22 ** 23 ** SPDX-License-Identifier: BSD-3-Clause 24 ** 25 ** http: www.nxp.com 26 ** mail: support@nxp.com 27 ** 28 ** Revisions: 29 ** - rev. 1.0 (2019-04-22) 30 ** Initial version. 31 ** - rev. 2.0 (2019-09-23) 32 ** Rev.B Header RFP 33 ** 34 ** ################################################################### 35 */ 36 37 /*! 38 * @file MIMX8MN6_cm7 39 * @version 1.0 40 * @date 011121 41 * @brief Device specific configuration file for MIMX8MN6_cm7 (header file) 42 * 43 * Provides a system configuration function and a global variable that contains 44 * the system frequency. It configures the device and initializes the oscillator 45 * (PLL) that is part of the microcontroller device. 46 */ 47 #ifndef _SYSTEM_MIMX8MN6_cm7_H_ 48 #define _SYSTEM_MIMX8MN6_cm7_H_ /**< Symbol preventing repeated inclusion */ 49 50 #ifdef __cplusplus 51 extern "C" { 52 #endif 53 54 #include <stdint.h> 55 56 /* i.MX8MN Definitions */ 57 #ifndef DISABLE_WDOG 58 #define DISABLE_WDOG 1 59 #endif 60 /* Define clock source values */ 61 #define CPU_XTAL_SOSC_CLK_24MHZ 24000000u /* Value of the external System Oscillator Clock(SOSC) frequency in Hz */ 62 #define CLK_PAD_CLK 0u /* The value could be changed according to the actual usage */ 63 #define DEFAULT_SYSTEM_CLOCK 600000000u /* Default System clock value */ 64 65 /** 66 * @brief System clock frequency (core clock) 67 * 68 * The system clock frequency supplied to the SysTick timer and the processor 69 * core clock. This variable can be used by the user application to setup the 70 * SysTick timer or configure other parameters. It may also be used by debugger to 71 * query the frequency of the debug timer or configure the trace clock speed 72 * SystemCoreClock is initialized with a correct predefined value. 73 */ 74 extern uint32_t SystemCoreClock; 75 76 /** 77 * @brief Setup the microcontroller system. 78 * 79 * Typically this function configures the oscillator (PLL) that is part of the 80 * microcontroller device. For systems with variable clock speed it also updates 81 * the variable SystemCoreClock. SystemInit is called from startup_device file. 82 */ 83 void SystemInit(void); 84 85 /** 86 * @brief Updates the SystemCoreClock variable. 87 * 88 * It must be called whenever the core clock is changed during program 89 * execution. SystemCoreClockUpdate() evaluates the clock register settings and calculates 90 * the current core clock. 91 */ 92 void SystemCoreClockUpdate(void); 93 94 /** 95 * @brief SystemInit function hook. 96 * 97 * This weak function allows to call specific initialization code during the 98 * SystemInit() execution.This can be used when an application specific code needs 99 * to be called as close to the reset entry as possible (for example the Multicore 100 * Manager MCMGR_EarlyInit() function call). 101 * NOTE: No global r/w variables can be used in this hook function because the 102 * initialization of these variables happens after this function. 103 */ 104 void SystemInitHook(void); 105 106 #ifdef __cplusplus 107 } 108 #endif 109 110 #endif /* _SYSTEM_MIMX8MN6_cm7_H_ */ 111