cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L Nucleo clock change

marcogrossi89
Associate II
Posted on January 11, 2016 at 12:08

I am trying to configure the clock source in a STM32L Nucleo Board (that mounts the STM32L152RE microcontroller). I use EmBitz as IDE.

I have downloaded the Excel file STM32L1xx Clock configuration tool from ST that generates the system_stm32l1xx.c file to configure the microcontroller.

However the configuration tool does not allow to select the microcontroller I use (STM32L15xxE is not present).

Any idea how to create the configuration file?

4 REPLIES 4
Radosław
Senior II
Posted on January 11, 2016 at 12:15

This configuration is valid for all STM32L1 family.  

marcogrossi89
Associate II
Posted on January 11, 2016 at 14:50

Yes, but when you start the tool (see the image below) you are asked to choose the microcontroller and there is not STM32L15xxE option.

0690X00000604r9QAA.png

________________

Attachments :

tool_config.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006Hzck&d=%2Fa%2F0X0000000bOZ%2FpEqQDkRYCU0FpWhHmSsO4Oq8eSen01EmnXuetlNVNTA&asPdf=false
Radosław
Senior II
Posted on January 11, 2016 at 15:30

Use C optioc. E option is only different flash size. RCC peripheral is the same. Generate file will be valid.

  

marcogrossi89
Associate II
Posted on January 11, 2016 at 18:08

OK. The tool works for low frequencies. However I think there is something wrong.

In fact the default clock configuration is HSI with PLL SysClk 32MHz

*=============================================================================

  *        System Clock source          | PLL(HSI)

  *-----------------------------------------------------------------------------

  *        SYSCLK                       | 32000000 Hz

  *-----------------------------------------------------------------------------

  *        HCLK                         | 32000000 Hz

  *-----------------------------------------------------------------------------

  *        AHB Prescaler                | 1

  *-----------------------------------------------------------------------------

  *        APB1 Prescaler               | 1

  *-----------------------------------------------------------------------------

  *        APB2 Prescaler               | 1

  *-----------------------------------------------------------------------------

  *        HSE Frequency                | 8000000 Hz

  *-----------------------------------------------------------------------------

  *        PLL DIV                      | 3

  *-----------------------------------------------------------------------------

  *        PLL MUL                      | 6

  *-----------------------------------------------------------------------------

  *        VDD                          | 3 V

  *-----------------------------------------------------------------------------

  *        Vcore                        | 1.8 V (Range 1)

  *-----------------------------------------------------------------------------

  *        Flash Latency                | 1 WS

  *-----------------------------------------------------------------------------

  *        Require 48MHz for USB clock  | Disabled

  *-----------------------------------------------------------------------------

However if I set (Expert mode) PLL and HSI with PLLMUL 6 and PLLDIV 3 I get an error (exceeded PLLVCO range).