aboutsummaryrefslogtreecommitdiff
path: root/examples/stm32f4/src/bin/flash_async.rs
diff options
context:
space:
mode:
authorDario Nieuwenhuis <[email protected]>2023-12-17 22:09:14 +0100
committerDario Nieuwenhuis <[email protected]>2023-12-18 00:53:18 +0100
commit80c9d04bbd83367340a4f3a1e991df825a0b6029 (patch)
treed79b74b0ca17dd943dfcb3b809e895918f4ae629 /examples/stm32f4/src/bin/flash_async.rs
parenta2d4bab2f8a4a9b994bc0289938a9f725950715f (diff)
stm32: add some docs.
Diffstat (limited to 'examples/stm32f4/src/bin/flash_async.rs')
-rw-r--r--examples/stm32f4/src/bin/flash_async.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/stm32f4/src/bin/flash_async.rs b/examples/stm32f4/src/bin/flash_async.rs
index f0a65a725..1624d842e 100644
--- a/examples/stm32f4/src/bin/flash_async.rs
+++ b/examples/stm32f4/src/bin/flash_async.rs
@@ -48,7 +48,7 @@ async fn test_flash<'a>(f: &mut Flash<'a>, offset: u32, size: u32) {
48 48
49 info!("Reading..."); 49 info!("Reading...");
50 let mut buf = [0u8; 32]; 50 let mut buf = [0u8; 32];
51 unwrap!(f.read(offset, &mut buf)); 51 unwrap!(f.blocking_read(offset, &mut buf));
52 info!("Read: {=[u8]:x}", buf); 52 info!("Read: {=[u8]:x}", buf);
53 53
54 info!("Erasing..."); 54 info!("Erasing...");
@@ -56,7 +56,7 @@ async fn test_flash<'a>(f: &mut Flash<'a>, offset: u32, size: u32) {
56 56
57 info!("Reading..."); 57 info!("Reading...");
58 let mut buf = [0u8; 32]; 58 let mut buf = [0u8; 32];
59 unwrap!(f.read(offset, &mut buf)); 59 unwrap!(f.blocking_read(offset, &mut buf));
60 info!("Read after erase: {=[u8]:x}", buf); 60 info!("Read after erase: {=[u8]:x}", buf);
61 61
62 info!("Writing..."); 62 info!("Writing...");
@@ -73,7 +73,7 @@ async fn test_flash<'a>(f: &mut Flash<'a>, offset: u32, size: u32) {
73 73
74 info!("Reading..."); 74 info!("Reading...");
75 let mut buf = [0u8; 32]; 75 let mut buf = [0u8; 32];
76 unwrap!(f.read(offset, &mut buf)); 76 unwrap!(f.blocking_read(offset, &mut buf));
77 info!("Read: {=[u8]:x}", buf); 77 info!("Read: {=[u8]:x}", buf);
78 assert_eq!( 78 assert_eq!(
79 &buf[..], 79 &buf[..],