cancel
Showing results for 
Search instead for 
Did you mean: 

There is a bug in stm32l1xx_hal_conf.h. The MSI_VALUE value is wrong.

MSipo
Senior II

DeviceId = STM32L151RETx

FirmwarePackage = STM32Cube FW_L1 V1.10.2

Bug in: stm32l1xx_hal_conf.h

On row 110. The MSI_VALUE is defined as 16000000. It should be defined as 2097152 Hz

/**
  * @brief Internal Multiple Speed oscillator (MSI) default value.
  *        This value is the default MSI range value after Reset.
  */
#if !defined  (MSI_VALUE)
  #define MSI_VALUE    ((uint32_t)16000000) /*!< Value of the Internal oscillator in Hz*/
#endif /* MSI_VALUE */

2 REPLIES 2
Imen.D
ST Employee

Hello @Community member​ ,

I found different define in the latest firmware package that you may want to check out:

/**
  * @brief Internal Multiple Speed oscillator (MSI) default value.
  *        This value is the default MSI range value after Reset.
  */
#if !defined  (MSI_VALUE)
#define MSI_VALUE    (2097000U) /*!< Value of the Internal oscillator in Hz*/
#endif /* MSI_VALUE */
 

Please make sure to use the latest release of STM32CubeL1 V1.10.2, then keep me infomed about your update.

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
Imen.D
ST Employee

Hi @Community member​ ,

After check, it seems the error is in the template stm32l1xx_hal_conf.h when using CubeMX tool, which is not aligned with the HAL package.

 #if !defined (MSI_VALUE)
 #define MSI_VALUE  ((uint32_t)16000000) /*!< Value of the Internal oscillator in Hz*/
#endif /* MSI_VALUE */
 

I have passed your feedback along to our CubeMX team for fix.

Thank you for bringing this issue to our attention.

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen