stm32f7xx-hal
stm32f7xx-hal copied to clipboard
Release build does not flashing led
Very strange things occur on release build:
when sysclk is greater that pclk1, for example:
let clocks = rcc.cfgr.sysclk(96.MHz()).pclk1(48.MHz()).freeze();
led does not flashing, but debug build is fine.
I tested this combination:
let clocks = rcc.cfgr.sysclk(16.MHz()).pclk1(16.MHz()).freeze();
let clocks = rcc.cfgr.sysclk(32.MHz()).pclk1(32.MHz()).freeze();
let clocks = rcc.cfgr.sysclk(48.MHz()).pclk1(48.MHz()).freeze();
It's work fine, at both debug and release builds.
But, What occurs when i follow CubeMX suggestion(frequency), I don't understand.
I little modify example from this crate - PA5 for NUCLEO- F767ZI by default not connected from factory - https://github.com/chessnokov/pfm/blob/master/bin/pfm.rs