Fixes broken NS build

This commit is contained in:
nerwalt 2025-08-08 11:03:36 -06:00
parent adc0fc0a97
commit 1d08cde6e4
2 changed files with 9 additions and 2 deletions

View File

@ -205,6 +205,9 @@ pub const EASY_DMA_SIZE: usize = (1 << 16) - 1;
embassy_hal_internal::peripherals! {
// WDT
#[cfg(feature = "_ns")]
WDT,
#[cfg(feature = "_s")]
WDT0,
#[cfg(feature = "_s")]
WDT1,
@ -290,6 +293,9 @@ impl_pin!(P2_08, 2, 8);
impl_pin!(P2_09, 2, 9);
impl_pin!(P2_10, 2, 10);
#[cfg(feature = "_ns")]
impl_wdt!(WDT, WDT31, WDT31, 0);
#[cfg(feature = "_s")]
impl_wdt!(WDT0, WDT31, WDT31, 0);
#[cfg(feature = "_s")]
impl_wdt!(WDT1, WDT30, WDT30, 1);

View File

@ -21,8 +21,9 @@ async fn main(_spawner: Spawner) {
// in the WDT interrupt. The core resets 2 ticks after firing the interrupt.
config.action_during_debug_halt = HaltConfig::PAUSE;
// The nrf54l15 has two watchdogs. Only WDT0 is available in non-secure (ns) mode, as WDT1 is
// reserved for the secure (s) environment. In secure mode, both WDT0 and WDT1 are available.
// The nrf54l15 has two watchdogs. Only one (WDT) is available in non-secure (ns) mode, as the
// other is reserved for the secure (s) environment. In secure mode, both are available as WDT0
// and WDT1.
info!("Watchdog launched with {} s timeout", TIMEOUT_S);
let (_wdt, [mut handle]) = match Watchdog::try_new(p.WDT1, config) {
Ok(x) => x,