1 /* 2 ** ################################################################### 3 ** Processors: MIMX8MM1CVTKZ 4 ** MIMX8MM1DVTLZ 5 ** 6 ** Compilers: GNU C Compiler 7 ** IAR ANSI C/C++ Compiler for ARM 8 ** Keil ARM C/C++ Compiler 9 ** 10 ** Reference manual: MX8MMRM, Rev. 0, 02/2019 11 ** Version: rev. 4.0, 2019-02-18 12 ** Build: b190228 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-2019 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 (2018-03-26) 30 ** Initial version. 31 ** - rev. 2.0 (2018-07-20) 32 ** Rev.A Header EAR 33 ** - rev. 3.0 (2018-10-24) 34 ** Rev.B Header PRC 35 ** - rev. 4.0 (2019-02-18) 36 ** Rev.0 Header RFP 37 ** 38 ** ################################################################### 39 */ 40 41 /*! 42 * @file MIMX8MM1_cm4 43 * @version 4.0 44 * @date 2019-02-18 45 * @brief Device specific configuration file for MIMX8MM1_cm4 (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_MIMX8MM1_cm4_H_ 53 #define _SYSTEM_MIMX8MM1_cm4_H_ /**< Symbol preventing repeated inclusion */ 54 55 #ifdef __cplusplus 56 extern "C" { 57 #endif 58 59 #include <stdint.h> 60 61 62 /* i.MX8MM Definitions */ 63 #ifndef DISABLE_WDOG 64 #define DISABLE_WDOG 1 65 #endif 66 /* Define clock source values */ 67 #define CPU_XTAL_SOSC_CLK_24MHZ 24000000u /* Value of the external System Oscillator Clock(SOSC) frequency in Hz */ 68 #define CLK_PAD_CLK 0u /* The value could be changed according to the actual usage */ 69 #define DEFAULT_SYSTEM_CLOCK 400000000u /* Default System clock value */ 70 71 72 /** 73 * @brief System clock frequency (core clock) 74 * 75 * The system clock frequency supplied to the SysTick timer and the processor 76 * core clock. This variable can be used by the user application to setup the 77 * SysTick timer or configure other parameters. It may also be used by debugger to 78 * query the frequency of the debug timer or configure the trace clock speed 79 * SystemCoreClock is initialized with a correct predefined value. 80 */ 81 extern uint32_t SystemCoreClock; 82 83 /** 84 * @brief Setup the microcontroller system. 85 * 86 * Typically this function configures the oscillator (PLL) that is part of the 87 * microcontroller device. For systems with variable clock speed it also updates 88 * the variable SystemCoreClock. SystemInit is called from startup_device file. 89 */ 90 void SystemInit (void); 91 92 /** 93 * @brief Updates the SystemCoreClock variable. 94 * 95 * It must be called whenever the core clock is changed during program 96 * execution. SystemCoreClockUpdate() evaluates the clock register settings and calculates 97 * the current core clock. 98 */ 99 void SystemCoreClockUpdate (void); 100 101 /** 102 * @brief SystemInit function hook. 103 * 104 * This weak function allows to call specific initialization code during the 105 * SystemInit() execution.This can be used when an application specific code needs 106 * to be called as close to the reset entry as possible (for example the Multicore 107 * Manager MCMGR_EarlyInit() function call). 108 * NOTE: No global r/w variables can be used in this hook function because the 109 * initialization of these variables happens after this function. 110 */ 111 void SystemInitHook (void); 112 113 #ifdef __cplusplus 114 } 115 #endif 116 117 #endif /* _SYSTEM_MIMX8MM1_cm4_H_ */ 118