Skip to content

Commit 8c4000b

Browse files
committed
Fix more errors
1 parent f80df21 commit 8c4000b

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

examples/adc.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ fn main() -> ! {
4545

4646
// This is a workaround, so that the debugger will not disconnect imidiatly on asm::wfi();
4747
// https://github.com/probe-rs/probe-rs/issues/350#issuecomment-740550519
48-
dp.DBGMCU.cr.modify(|_, w| {
48+
dp.DBGMCU.cr().modify(|_, w| {
4949
w.dbg_sleep().set_bit();
5050
w.dbg_standby().set_bit();
5151
w.dbg_stop().set_bit()

examples/i2c_scanner.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,14 @@ fn main() -> ! {
5252
for addr in 0x00_u8..0x80 {
5353
// Write the empty array and check the slave response.
5454
if VALID_ADDR_RANGE.contains(&addr) && i2c.write(addr, &[]).is_ok() {
55-
hprint!("{:02x}", addr).unwrap();
55+
hprint!("{:02x}", addr);
5656
} else {
57-
hprint!("..").unwrap();
57+
hprint!("..");
5858
}
5959
if addr % 0x10 == 0x0F {
60-
hprintln!().unwrap();
60+
hprintln!();
6161
} else {
62-
hprint!(" ").unwrap();
62+
hprint!(" ");
6363
}
6464
}
6565

examples/serial_dma.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,12 @@ fn main() -> ! {
2020
// This is a workaround, so that the debugger will not disconnect
2121
// imidiatly on asm::wfi();
2222
// https://github.com/probe-rs/probe-rs/issues/350#issuecomment-740550519
23-
dp.DBGMCU.cr.modify(|_, w| {
23+
dp.DBGMCU.cr().modify(|_, w| {
2424
w.dbg_sleep().set_bit();
2525
w.dbg_standby().set_bit();
2626
w.dbg_stop().set_bit()
2727
});
28-
dp.RCC.ahbenr.modify(|_, w| w.dma1en().enabled());
28+
dp.RCC.ahbenr().modify(|_, w| w.dma1en().enabled());
2929

3030
let mut rcc = dp.RCC.constrain();
3131
let clocks = rcc.cfgr.freeze(&mut flash.acr);

0 commit comments

Comments
 (0)