Skip to content

Commit ccff46d

Browse files
authored
Merge pull request #6070 from ithinuel/remove-magic
remove magic calibration value for HSI in ST's targets
2 parents 84f42f6 + d1a0ff9 commit ccff46d

File tree

32 files changed

+32
-32
lines changed

32 files changed

+32
-32
lines changed

targets/TARGET_STM/TARGET_STM32F2/TARGET_NUCLEO_F207ZG/device/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ uint8_t SetSysClock_PLL_HSI(void)
195195

196196
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI;
197197
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
198-
RCC_OscInitStruct.HSICalibrationValue = 16;
198+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
199199
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
200200
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
201201
RCC_OscInitStruct.PLL.PLLM = 16;

targets/TARGET_STM/TARGET_STM32F4/TARGET_MTB_MTS_DRAGONFLY/device/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ uint8_t SetSysClock_PLL_HSI(void)
207207
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
208208
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
209209
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
210-
RCC_OscInitStruct.HSICalibrationValue = 16;
210+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
211211
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
212212
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
213213
//RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_MTS_DRAGONFLY_F411RE/device/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ uint8_t SetSysClock_PLL_HSI(void)
207207
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
208208
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
209209
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
210-
RCC_OscInitStruct.HSICalibrationValue = 16;
210+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
211211
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
212212
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
213213
//RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_MTS_MDOT_F411RE/device/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ uint8_t SetSysClock_PLL_HSI(void)
211211
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
212212
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
213213
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
214-
RCC_OscInitStruct.HSICalibrationValue = 16;
214+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
215215
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
216216
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
217217
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F401xC/TARGET_DISCO_F401VC/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ uint8_t SetSysClock_PLL_HSI(void)
203203
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
204204
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
205205
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
206-
RCC_OscInitStruct.HSICalibrationValue = 16;
206+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
207207
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
208208
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
209209
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F401xE/TARGET_NUCLEO_F401RE/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ uint8_t SetSysClock_PLL_HSI(void)
210210
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
211211
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
212212
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
213-
RCC_OscInitStruct.HSICalibrationValue = 16;
213+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
214214
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
215215
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
216216
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F407xG/TARGET_ARCH_MAX/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ uint8_t SetSysClock_PLL_HSI(void)
204204
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
205205
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
206206
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
207-
RCC_OscInitStruct.HSICalibrationValue = 16;
207+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
208208
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
209209
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
210210
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F407xG/TARGET_DISCO_F407VG/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ uint8_t SetSysClock_PLL_HSI(void)
209209
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
210210
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
211211
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
212-
RCC_OscInitStruct.HSICalibrationValue = 16;
212+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
213213
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
214214
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
215215
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F410xB/TARGET_NUCLEO_F410RB/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ uint8_t SetSysClock_PLL_HSI(void)
209209
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
210210
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
211211
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
212-
RCC_OscInitStruct.HSICalibrationValue = 16;
212+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
213213
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
214214
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
215215
RCC_OscInitStruct.PLL.PLLM = 8;

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F411xE/TARGET_ELMO_F411RE/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ uint8_t SetSysClock_PLL_HSI(void)
213213
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
214214
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
215215
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
216-
RCC_OscInitStruct.HSICalibrationValue = 16;
216+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
217217
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
218218
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
219219
//RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F411xE/TARGET_NUCLEO_F411RE/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ uint8_t SetSysClock_PLL_HSI(void)
212212
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
213213
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
214214
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
215-
RCC_OscInitStruct.HSICalibrationValue = 16;
215+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
216216
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
217217
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
218218
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F411xE/TARGET_SAKURAIO_EVB_01/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ uint8_t SetSysClock_PLL_HSI(void)
212212
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
213213
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
214214
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
215-
RCC_OscInitStruct.HSICalibrationValue = 16;
215+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
216216
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
217217
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
218218
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F412xG/TARGET_MTB_MXCHIP_EMW3166/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ uint8_t SetSysClock_PLL_HSI(void)
230230
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
231231
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
232232
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
233-
RCC_OscInitStruct.HSICalibrationValue = 16;
233+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
234234
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
235235
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
236236
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F412xG/TARGET_NUCLEO_F412ZG/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ uint8_t SetSysClock_PLL_HSI(void)
229229
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
230230
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
231231
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
232-
RCC_OscInitStruct.HSICalibrationValue = 16;
232+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
233233
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
234234
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
235235
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F413xH/TARGET_DISCO_F413ZH/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ uint8_t SetSysClock_PLL_HSI(void)
230230
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
231231
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
232232
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
233-
RCC_OscInitStruct.HSICalibrationValue = 16;
233+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
234234
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
235235
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
236236
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F413xH/TARGET_NUCLEO_F413ZH/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ uint8_t SetSysClock_PLL_HSI(void)
228228
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
229229
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
230230
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
231-
RCC_OscInitStruct.HSICalibrationValue = 16;
231+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
232232
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
233233
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
234234
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F429xI/TARGET_DISCO_F429ZI/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ uint8_t SetSysClock_PLL_HSI(void)
192192
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
193193
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
194194
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
195-
RCC_OscInitStruct.HSICalibrationValue = 16;
195+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
196196
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
197197
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
198198
RCC_OscInitStruct.PLL.PLLM = 8;

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F429xI/TARGET_NUCLEO_F429ZI/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ uint8_t SetSysClock_PLL_HSI(void)
192192
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
193193
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
194194
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
195-
RCC_OscInitStruct.HSICalibrationValue = 16;
195+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
196196
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
197197
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
198198
RCC_OscInitStruct.PLL.PLLM = 8;

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F439xI/TARGET_NUCLEO_F439ZI/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ uint8_t SetSysClock_PLL_HSI(void)
207207
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
208208
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
209209
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
210-
RCC_OscInitStruct.HSICalibrationValue = 16;
210+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
211211
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
212212
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
213213
RCC_OscInitStruct.PLL.PLLM = 8;

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F446xE/TARGET_B96B_F446VE/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ uint8_t SetSysClock_PLL_HSI(void)
224224
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
225225
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
226226
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
227-
RCC_OscInitStruct.HSICalibrationValue = 16;
227+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
228228
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
229229
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
230230
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F446xE/TARGET_NUCLEO_F446RE/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ uint8_t SetSysClock_PLL_HSI(void)
222222
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
223223
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
224224
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
225-
RCC_OscInitStruct.HSICalibrationValue = 16;
225+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
226226
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
227227
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
228228
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F446xE/TARGET_NUCLEO_F446ZE/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ uint8_t SetSysClock_PLL_HSI(void)
235235
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
236236
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
237237
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
238-
RCC_OscInitStruct.HSICalibrationValue = 16;
238+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
239239
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
240240
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
241241
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F469xI/TARGET_DISCO_F469NI/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ uint8_t SetSysClock_PLL_HSI(void)
234234
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
235235
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
236236
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
237-
RCC_OscInitStruct.HSICalibrationValue = 16;
237+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
238238
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
239239
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
240240
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F746xG/TARGET_DISCO_F746NG/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ uint8_t SetSysClock_PLL_HSI(void)
211211
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI;
212212
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
213213
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
214-
RCC_OscInitStruct.HSICalibrationValue = 16;
214+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
215215
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
216216
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
217217
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F746xG/TARGET_NUCLEO_F746ZG/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ uint8_t SetSysClock_PLL_HSI(void)
212212
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI;
213213
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
214214
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
215-
RCC_OscInitStruct.HSICalibrationValue = 16;
215+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
216216
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
217217
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
218218
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F756xG/TARGET_NUCLEO_F756ZG/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ uint8_t SetSysClock_PLL_HSI(void)
211211
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSE;
212212
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
213213
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
214-
RCC_OscInitStruct.HSICalibrationValue = 16;
214+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
215215
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
216216
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
217217
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F767xI/TARGET_NUCLEO_F767ZI/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ uint8_t SetSysClock_PLL_HSI(void)
213213
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI;
214214
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
215215
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
216-
RCC_OscInitStruct.HSICalibrationValue = 16;
216+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
217217
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
218218
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
219219
RCC_OscInitStruct.PLL.PLLM = 8; // VCO input clock = 2 MHz (16 MHz / 8)

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F769xI/TARGET_DISCO_F769NI/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ uint8_t SetSysClock_PLL_HSI(void)
215215
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI;
216216
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
217217
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
218-
RCC_OscInitStruct.HSICalibrationValue = 16;
218+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
219219
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
220220
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSI;
221221
RCC_OscInitStruct.PLL.PLLM = 16; // VCO input clock = 1 MHz (16 MHz / 16)

targets/TARGET_STM/TARGET_STM32L0/TARGET_NUCLEO_L073RZ/device/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ uint8_t SetSysClock_PLL_HSI(void)
209209
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSI48;
210210
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
211211
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
212-
RCC_OscInitStruct.HSICalibrationValue = 16;
212+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
213213
RCC_OscInitStruct.HSI48State = RCC_HSI48_ON; /* For USB and RNG clock */
214214
// PLLCLK = (16 MHz * 4)/2 = 32 MHz
215215
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;

targets/TARGET_STM/TARGET_STM32L0/TARGET_STM32L053x8/TARGET_DISCO_L053C8/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ uint8_t SetSysClock_PLL_HSI(void)
210210
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSI48;
211211
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
212212
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
213-
RCC_OscInitStruct.HSICalibrationValue = 16;
213+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
214214
RCC_OscInitStruct.HSI48State = RCC_HSI48_ON; /* For USB and RNG clock */
215215
// PLLCLK = (16 MHz * 4)/2 = 32 MHz
216216
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;

targets/TARGET_STM/TARGET_STM32L0/TARGET_STM32L053x8/TARGET_NUCLEO_L053R8/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ uint8_t SetSysClock_PLL_HSI(void)
210210
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSI48;
211211
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
212212
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
213-
RCC_OscInitStruct.HSICalibrationValue = 16;
213+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
214214
RCC_OscInitStruct.HSI48State = RCC_HSI48_ON; /* For USB and RNG clock */
215215
// PLLCLK = (16 MHz * 4)/2 = 32 MHz
216216
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;

targets/TARGET_STM/TARGET_STM32L0/TARGET_STM32L0x2xZ/TARGET_MTB_MURATA_ABZ/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ uint8_t SetSysClock_PLL_HSI(void)
115115
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI | RCC_OSCILLATORTYPE_HSI48;
116116
RCC_OscInitStruct.HSEState = RCC_HSE_OFF;
117117
RCC_OscInitStruct.HSIState = RCC_HSI_ON;
118-
RCC_OscInitStruct.HSICalibrationValue = 16;
118+
RCC_OscInitStruct.HSICalibrationValue = RCC_HSICALIBRATION_DEFAULT;
119119
RCC_OscInitStruct.HSI48State = RCC_HSI48_ON; /* For USB and RNG clock */
120120
// PLLCLK = (16 MHz * 4)/2 = 32 MHz
121121
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;

0 commit comments

Comments
 (0)