aboutsummaryrefslogtreecommitdiff
path: root/examples/stm32h755cm4/src/bin/intercore.rs
diff options
context:
space:
mode:
Diffstat (limited to 'examples/stm32h755cm4/src/bin/intercore.rs')
-rw-r--r--examples/stm32h755cm4/src/bin/intercore.rs7
1 files changed, 2 insertions, 5 deletions
diff --git a/examples/stm32h755cm4/src/bin/intercore.rs b/examples/stm32h755cm4/src/bin/intercore.rs
index d38b34365..8f61c3eb2 100644
--- a/examples/stm32h755cm4/src/bin/intercore.rs
+++ b/examples/stm32h755cm4/src/bin/intercore.rs
@@ -31,6 +31,7 @@ mod shared {
31 31
32 /// Set LED state using safe bit operations 32 /// Set LED state using safe bit operations
33 #[inline(never)] 33 #[inline(never)]
34 #[allow(dead_code)]
34 pub fn set_led(&self, is_green: bool, state: bool) { 35 pub fn set_led(&self, is_green: bool, state: bool) {
35 let bit = if is_green { GREEN_LED_BIT } else { YELLOW_LED_BIT }; 36 let bit = if is_green { GREEN_LED_BIT } else { YELLOW_LED_BIT };
36 37
@@ -60,6 +61,7 @@ mod shared {
60 61
61 /// Increment counter safely 62 /// Increment counter safely
62 #[inline(never)] 63 #[inline(never)]
64 #[allow(dead_code)]
63 pub fn increment_counter(&self) -> u32 { 65 pub fn increment_counter(&self) -> u32 {
64 let current = self.counter.load(Ordering::SeqCst); 66 let current = self.counter.load(Ordering::SeqCst);
65 let new_value = current.wrapping_add(1); 67 let new_value = current.wrapping_add(1);
@@ -79,11 +81,6 @@ mod shared {
79 81
80 #[link_section = ".ram_d3"] 82 #[link_section = ".ram_d3"]
81 pub static SHARED_LED_STATE: SharedLedState = SharedLedState::new(); 83 pub static SHARED_LED_STATE: SharedLedState = SharedLedState::new();
82
83 // SRAM4 memory region constants for MPU configuration
84 pub const SRAM4_BASE_ADDRESS: u32 = 0x38000000;
85 pub const SRAM4_SIZE_LOG2: u32 = 15; // 64KB = 2^(15+1)
86 pub const SRAM4_REGION_NUMBER: u8 = 0; // MPU region number to use
87} 84}
88 85
89use core::mem::MaybeUninit; 86use core::mem::MaybeUninit;