2017-05-25 04:10 AM
I use SW4STM32.
I noticed that when I generate a project with SW4STM32, the speed of my STM32F401VBT6 is twice faster. For example, HAL_Delay(1000) actually awaits 500ms. USART1 transmits data on the speed 230400, although 115200 is specified in cofiguration.But if I generate a project using CubeMX it's all ok.
I transfered all the source code from the project generated by CubeMX into the project generatd by SW4STM32, but the problem remained.#cube-mx #clocks2017-05-25 07:44 AM
Check that HSE_VALUE definition reflects the clock source crystal in use, and the PLL settings. The baud rate settings get computed by backing out the current RCC/PLL settings, and doing maths base on the assumed clocks source. Failures of the type described occur when the value the software is using differs from reality.