Use Dbgmcu::enable_all() in stm32f4 examples

This commit is contained in:
Timo Kröger
2021-07-23 17:49:53 +02:00
parent 5ac91933ff
commit 57eecd4292
6 changed files with 10 additions and 39 deletions

View File

@ -9,8 +9,8 @@
#[path = "../example_common.rs"]
mod example_common;
use cortex_m_rt::entry;
use embassy_stm32::dbgmcu::Dbgmcu;
use embassy_stm32::gpio::{Input, Level, Output, Pull, Speed};
use embassy_stm32::pac;
use embedded_hal::digital::v2::{InputPin, OutputPin};
use example_common::*;
@ -19,11 +19,7 @@ fn main() -> ! {
info!("Hello World!");
unsafe {
pac::DBGMCU.cr().modify(|w| {
w.set_dbg_sleep(true);
w.set_dbg_standby(true);
w.set_dbg_stop(true);
});
Dbgmcu::enable_all();
}
let p = embassy_stm32::init(Default::default());