annotate l476rg-hal-test/src/system_stm32l4xx.c @ 4:ca4f5b55b391

working on pwm
author cin
date Wed, 18 Jan 2017 03:27:00 +0300
parents 32a3b1785697
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
1 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
2 ******************************************************************************
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
3 * @file system_stm32l4xx.c
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
4 * @author MCD Application Team
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
5 * @version V1.3.0RC5
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
6 * @date 02-September-2016
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
7 * @brief CMSIS Cortex-M4 Device Peripheral Access Layer System Source File
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
8 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
9 * This file provides two functions and one global variable to be called from
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
10 * user application:
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
11 * - SystemInit(): This function is called at startup just after reset and
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
12 * before branch to main program. This call is made inside
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
13 * the "startup_stm32l4xx.s" file.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
14 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
15 * - SystemCoreClock variable: Contains the core clock (HCLK), it can be used
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
16 * by the user application to setup the SysTick
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
17 * timer or configure other parameters.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
18 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
19 * - SystemCoreClockUpdate(): Updates the variable SystemCoreClock and must
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
20 * be called whenever the core clock is changed
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
21 * during program execution.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
22 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
23 * After each device reset the MSI (4 MHz) is used as system clock source.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
24 * Then SystemInit() function is called, in "startup_stm32l4xx.s" file, to
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
25 * configure the system clock before to branch to main program.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
26 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
27 * This file configures the system clock as follows:
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
28 *=============================================================================
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
29 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
30 * System Clock source | MSI
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
31 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
32 * SYSCLK(Hz) | 4000000
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
33 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
34 * HCLK(Hz) | 4000000
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
35 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
36 * AHB Prescaler | 1
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
37 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
38 * APB1 Prescaler | 1
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
39 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
40 * APB2 Prescaler | 1
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
41 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
42 * PLL_M | 1
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
43 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
44 * PLL_N | 8
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
45 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
46 * PLL_P | 7
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
47 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
48 * PLL_Q | 2
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
49 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
50 * PLL_R | 2
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
51 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
52 * PLLSAI1_P | NA
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
53 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
54 * PLLSAI1_Q | NA
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
55 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
56 * PLLSAI1_R | NA
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
57 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
58 * PLLSAI2_P | NA
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
59 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
60 * PLLSAI2_Q | NA
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
61 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
62 * PLLSAI2_R | NA
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
63 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
64 * Require 48MHz for USB OTG FS, | Disabled
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
65 * SDIO and RNG clock |
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
66 *-----------------------------------------------------------------------------
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
67 *=============================================================================
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
68 ******************************************************************************
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
69 * @attention
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
70 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
71 * <h2><center>&copy; COPYRIGHT(c) 2016 STMicroelectronics</center></h2>
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
72 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
73 * Redistribution and use in source and binary forms, with or without modification,
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
74 * are permitted provided that the following conditions are met:
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
75 * 1. Redistributions of source code must retain the above copyright notice,
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
76 * this list of conditions and the following disclaimer.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
77 * 2. Redistributions in binary form must reproduce the above copyright notice,
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
78 * this list of conditions and the following disclaimer in the documentation
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
79 * and/or other materials provided with the distribution.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
80 * 3. Neither the name of STMicroelectronics nor the names of its contributors
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
81 * may be used to endorse or promote products derived from this software
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
82 * without specific prior written permission.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
83 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
84 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
85 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
86 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
87 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
88 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
89 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
90 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
91 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
92 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
93 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
94 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
95 ******************************************************************************
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
96 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
97
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
98 /** @addtogroup CMSIS
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
99 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
100 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
101
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
102 /** @addtogroup stm32l4xx_system
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
103 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
104 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
105
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
106 /** @addtogroup STM32L4xx_System_Private_Includes
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
107 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
108 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
109
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
110 #include "stm32l4xx.h"
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
111
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
112 #if !defined (HSE_VALUE)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
113 #define HSE_VALUE ((uint32_t)8000000) /*!< Value of the External oscillator in Hz */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
114 #endif /* HSE_VALUE */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
115
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
116 #if !defined (MSI_VALUE)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
117 #define MSI_VALUE ((uint32_t)4000000) /*!< Value of the Internal oscillator in Hz*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
118 #endif /* MSI_VALUE */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
119
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
120 #if !defined (HSI_VALUE)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
121 #define HSI_VALUE ((uint32_t)16000000) /*!< Value of the Internal oscillator in Hz*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
122 #endif /* HSI_VALUE */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
123
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
124 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
125 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
126 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
127
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
128 /** @addtogroup STM32L4xx_System_Private_TypesDefinitions
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
129 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
130 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
131
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
132 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
133 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
134 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
135
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
136 /** @addtogroup STM32L4xx_System_Private_Defines
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
137 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
138 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
139
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
140 /************************* Miscellaneous Configuration ************************/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
141 /*!< Uncomment the following line if you need to relocate your vector Table in
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
142 Internal SRAM. */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
143 /* #define VECT_TAB_SRAM */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
144 #define VECT_TAB_OFFSET 0x00 /*!< Vector Table base offset field.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
145 This value must be a multiple of 0x200. */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
146 /******************************************************************************/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
147 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
148 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
149 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
150
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
151 /** @addtogroup STM32L4xx_System_Private_Macros
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
152 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
153 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
154
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
155 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
156 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
157 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
158
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
159 /** @addtogroup STM32L4xx_System_Private_Variables
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
160 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
161 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
162 /* The SystemCoreClock variable is updated in three ways:
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
163 1) by calling CMSIS function SystemCoreClockUpdate()
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
164 2) by calling HAL API function HAL_RCC_GetHCLKFreq()
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
165 3) each time HAL_RCC_ClockConfig() is called to configure the system clock frequency
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
166 Note: If you use this function to configure the system clock; then there
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
167 is no need to call the 2 first functions listed above, since SystemCoreClock
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
168 variable is updated automatically.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
169 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
170 uint32_t SystemCoreClock = 4000000;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
171
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
172 const uint8_t AHBPrescTable[16] = {0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 6, 7, 8, 9};
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
173 const uint8_t APBPrescTable[8] = {0, 0, 0, 0, 1, 2, 3, 4};
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
174 const uint32_t MSIRangeTable[12] = {100000, 200000, 400000, 800000, 1000000, 2000000, \
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
175 4000000, 8000000, 16000000, 24000000, 32000000, 48000000};
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
176 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
177 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
178 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
179
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
180 /** @addtogroup STM32L4xx_System_Private_FunctionPrototypes
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
181 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
182 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
183
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
184 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
185 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
186 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
187
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
188 /** @addtogroup STM32L4xx_System_Private_Functions
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
189 * @{
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
190 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
191
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
192 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
193 * @brief Setup the microcontroller system.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
194 * @param None
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
195 * @retval None
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
196 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
197
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
198 void SystemInit(void)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
199 {
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
200 /* FPU settings ------------------------------------------------------------*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
201 #if (__FPU_PRESENT == 1) && (__FPU_USED == 1)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
202 SCB->CPACR |= ((3UL << 10*2)|(3UL << 11*2)); /* set CP10 and CP11 Full Access */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
203 #endif
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
204 /* Reset the RCC clock configuration to the default reset state ------------*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
205 /* Set MSION bit */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
206 RCC->CR |= RCC_CR_MSION;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
207
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
208 /* Reset CFGR register */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
209 RCC->CFGR = 0x00000000;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
210
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
211 /* Reset HSEON, CSSON , HSION, and PLLON bits */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
212 RCC->CR &= (uint32_t)0xEAF6FFFF;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
213
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
214 /* Reset PLLCFGR register */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
215 RCC->PLLCFGR = 0x00001000;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
216
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
217 /* Reset HSEBYP bit */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
218 RCC->CR &= (uint32_t)0xFFFBFFFF;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
219
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
220 /* Disable all interrupts */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
221 RCC->CIER = 0x00000000;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
222
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
223 /* Configure the Vector Table location add offset address ------------------*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
224 #ifdef VECT_TAB_SRAM
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
225 SCB->VTOR = SRAM_BASE | VECT_TAB_OFFSET; /* Vector Table Relocation in Internal SRAM */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
226 #else
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
227 SCB->VTOR = FLASH_BASE | VECT_TAB_OFFSET; /* Vector Table Relocation in Internal FLASH */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
228 #endif
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
229 }
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
230
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
231 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
232 * @brief Update SystemCoreClock variable according to Clock Register Values.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
233 * The SystemCoreClock variable contains the core clock (HCLK), it can
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
234 * be used by the user application to setup the SysTick timer or configure
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
235 * other parameters.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
236 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
237 * @note Each time the core clock (HCLK) changes, this function must be called
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
238 * to update SystemCoreClock variable value. Otherwise, any configuration
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
239 * based on this variable will be incorrect.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
240 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
241 * @note - The system frequency computed by this function is not the real
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
242 * frequency in the chip. It is calculated based on the predefined
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
243 * constant and the selected clock source:
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
244 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
245 * - If SYSCLK source is MSI, SystemCoreClock will contain the MSI_VALUE(*)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
246 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
247 * - If SYSCLK source is HSI, SystemCoreClock will contain the HSI_VALUE(**)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
248 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
249 * - If SYSCLK source is HSE, SystemCoreClock will contain the HSE_VALUE(***)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
250 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
251 * - If SYSCLK source is PLL, SystemCoreClock will contain the HSE_VALUE(***)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
252 * or HSI_VALUE(*) or MSI_VALUE(*) multiplied/divided by the PLL factors.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
253 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
254 * (*) MSI_VALUE is a constant defined in stm32l4xx_hal.h file (default value
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
255 * 4 MHz) but the real value may vary depending on the variations
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
256 * in voltage and temperature.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
257 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
258 * (**) HSI_VALUE is a constant defined in stm32l4xx_hal.h file (default value
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
259 * 16 MHz) but the real value may vary depending on the variations
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
260 * in voltage and temperature.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
261 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
262 * (***) HSE_VALUE is a constant defined in stm32l4xx_hal.h file (default value
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
263 * 8 MHz), user has to ensure that HSE_VALUE is same as the real
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
264 * frequency of the crystal used. Otherwise, this function may
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
265 * have wrong result.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
266 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
267 * - The result of this function could be not correct when using fractional
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
268 * value for HSE crystal.
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
269 *
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
270 * @param None
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
271 * @retval None
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
272 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
273 void SystemCoreClockUpdate(void)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
274 {
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
275 uint32_t tmp = 0, msirange = 0, pllvco = 0, pllr = 2, pllsource = 0, pllm = 2;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
276
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
277 /* Get MSI Range frequency--------------------------------------------------*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
278 if((RCC->CR & RCC_CR_MSIRGSEL) == RESET)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
279 { /* MSISRANGE from RCC_CSR applies */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
280 msirange = (RCC->CSR & RCC_CSR_MSISRANGE) >> 8;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
281 }
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
282 else
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
283 { /* MSIRANGE from RCC_CR applies */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
284 msirange = (RCC->CR & RCC_CR_MSIRANGE) >> 4;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
285 }
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
286 /*MSI frequency range in HZ*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
287 msirange = MSIRangeTable[msirange];
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
288
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
289 /* Get SYSCLK source -------------------------------------------------------*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
290 switch (RCC->CFGR & RCC_CFGR_SWS)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
291 {
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
292 case 0x00: /* MSI used as system clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
293 SystemCoreClock = msirange;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
294 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
295
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
296 case 0x04: /* HSI used as system clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
297 SystemCoreClock = HSI_VALUE;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
298 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
299
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
300 case 0x08: /* HSE used as system clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
301 SystemCoreClock = HSE_VALUE;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
302 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
303
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
304 case 0x0C: /* PLL used as system clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
305 /* PLL_VCO = (HSE_VALUE or HSI_VALUE or MSI_VALUE/ PLLM) * PLLN
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
306 SYSCLK = PLL_VCO / PLLR
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
307 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
308 pllsource = (RCC->PLLCFGR & RCC_PLLCFGR_PLLSRC);
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
309 pllm = ((RCC->PLLCFGR & RCC_PLLCFGR_PLLM) >> 4) + 1 ;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
310
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
311 switch (pllsource)
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
312 {
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
313 case 0x02: /* HSI used as PLL clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
314 pllvco = (HSI_VALUE / pllm);
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
315 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
316
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
317 case 0x03: /* HSE used as PLL clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
318 pllvco = (HSE_VALUE / pllm);
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
319 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
320
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
321 default: /* MSI used as PLL clock source */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
322 pllvco = (msirange / pllm);
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
323 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
324 }
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
325 pllvco = pllvco * ((RCC->PLLCFGR & RCC_PLLCFGR_PLLN) >> 8);
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
326 pllr = (((RCC->PLLCFGR & RCC_PLLCFGR_PLLR) >> 25) + 1) * 2;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
327 SystemCoreClock = pllvco/pllr;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
328 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
329
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
330 default:
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
331 SystemCoreClock = msirange;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
332 break;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
333 }
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
334 /* Compute HCLK clock frequency --------------------------------------------*/
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
335 /* Get HCLK prescaler */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
336 tmp = AHBPrescTable[((RCC->CFGR & RCC_CFGR_HPRE) >> 4)];
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
337 /* HCLK clock frequency */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
338 SystemCoreClock >>= tmp;
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
339 }
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
340
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
341
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
342 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
343 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
344 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
345
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
346 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
347 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
348 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
349
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
350 /**
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
351 * @}
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
352 */
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
353
32a3b1785697 a rough draft of Hardware Abstraction Layer for C++
cin
parents:
diff changeset
354 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/