From 16fbd1c39c634fefce136e69848c81490fc42d50 Mon Sep 17 00:00:00 2001 From: Mirabellensaft Date: Mon, 27 Feb 2023 17:01:02 +0100 Subject: [PATCH] rm button from example --- down-the-stack/apps/src/bin/uarte_print.rs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/down-the-stack/apps/src/bin/uarte_print.rs b/down-the-stack/apps/src/bin/uarte_print.rs index a2aebfc..cf1e6d5 100644 --- a/down-the-stack/apps/src/bin/uarte_print.rs +++ b/down-the-stack/apps/src/bin/uarte_print.rs @@ -4,6 +4,7 @@ use cortex_m::asm; use cortex_m_rt::entry; use core::fmt::Write; + // this imports `down-the-stack/apps/lib.rs` to retrieve our global logger + panicking-behavior use apps as _; @@ -14,16 +15,17 @@ fn main() -> ! { let board = dk_bsc::init().unwrap(); - let button_1 = board.buttons.b_1; let mut uarte = board.uarte; + + + let tx_buffer = "Hello\n"; + uarte.write_str(tx_buffer).unwrap(); // this program does not `exit`; use Ctrl+C to terminate it loop { - if button_1.is_pushed() { - uarte.write_str(tx_buffer).unwrap(); - } + asm::nop(); } }