Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions targets/TARGET_STM/sleep.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,10 @@ __WEAK void ForceOscOutofDeepSleep(void)
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_MSI;
RCC_OscInitStruct.MSIState = RCC_MSI_ON;
RCC_OscInitStruct.MSICalibrationValue = RCC_MSICALIBRATION_DEFAULT;
#if defined RCC_MSIRANGE_11
RCC_OscInitStruct.MSIClockRange = RCC_MSIRANGE_11; // Highest freq, 48MHz range
#if defined (TARGET_STM32U5)
RCC_OscInitStruct.MSIClockRange = RCC_MSIRANGE_0; // Highest freq for U5, 48MHz range
#elif defined (RCC_MSIRANGE_11)
RCC_OscInitStruct.MSIClockRange = RCC_MSIRANGE_11; // Highest freq for L4/L5, 48MHz range
#else
RCC_OscInitStruct.MSIClockRange = RCC_MSIRANGE_6; // 4MHz range
#endif
Expand Down