aboutsummaryrefslogtreecommitdiff
path: root/embassy-nrf
diff options
context:
space:
mode:
authornerwalt <[email protected]>2024-07-15 13:21:30 -0600
committernerwalt <[email protected]>2024-07-15 13:21:30 -0600
commit8a6cb98e45c45743bc8c8a2b678067d3e1660232 (patch)
tree2cbbb8741539d7b180325f5c78095906ff93ca20 /embassy-nrf
parent4340d74e19bb99e2afdfb97232e8556aca7584b4 (diff)
Adding _nrf91 feature
Combining _nrf9160 and _nrf9120 in many places to reduce cfgs
Diffstat (limited to 'embassy-nrf')
-rw-r--r--embassy-nrf/Cargo.toml17
-rw-r--r--embassy-nrf/src/gpiote.rs1
-rw-r--r--embassy-nrf/src/lib.rs65
-rw-r--r--embassy-nrf/src/nvmc.rs8
-rw-r--r--embassy-nrf/src/pdm.rs8
-rw-r--r--embassy-nrf/src/saadc.rs4
-rw-r--r--embassy-nrf/src/wdt.rs8
7 files changed, 67 insertions, 44 deletions
diff --git a/embassy-nrf/Cargo.toml b/embassy-nrf/Cargo.toml
index fbb5db38a..f47b724ce 100644
--- a/embassy-nrf/Cargo.toml
+++ b/embassy-nrf/Cargo.toml
@@ -97,18 +97,18 @@ nrf5340-app-ns = ["_nrf5340-app", "_ns"]
97## nRF5340 network core 97## nRF5340 network core
98nrf5340-net = ["_nrf5340-net"] 98nrf5340-net = ["_nrf5340-net"]
99## nRF9160 in Secure mode 99## nRF9160 in Secure mode
100nrf9160-s = ["_nrf9160", "_s"] 100nrf9160-s = ["_nrf9160", "_s", "_nrf91"]
101## nRF9160 in Non-Secure mode 101## nRF9160 in Non-Secure mode
102nrf9160-ns = ["_nrf9160", "_ns"] 102nrf9160-ns = ["_nrf9160", "_ns", "_nrf91"]
103## The nRF9120 is the internal part number for the nRF9161 and nRF9151. 103## The nRF9120 is the internal part number for the nRF9161 and nRF9151.
104## nRF9120 in Secure mode 104## nRF9120 in Secure mode
105nrf9120-s = ["_nrf9120", "_s"] 105nrf9120-s = ["_nrf9120", "_s", "_nrf91"]
106nrf9151-s = ["_nrf9120", "_s"] 106nrf9151-s = ["_nrf9120", "_s", "_nrf91"]
107nrf9161-s = ["_nrf9120", "_s"] 107nrf9161-s = ["_nrf9120", "_s", "_nrf91"]
108## nRF9120 in Non-Secure mode 108## nRF9120 in Non-Secure mode
109nrf9120-ns = ["_nrf9120", "_ns"] 109nrf9120-ns = ["_nrf9120", "_ns", "_nrf91"]
110nrf9151-ns = ["_nrf9120", "_ns"] 110nrf9151-ns = ["_nrf9120", "_ns", "_nrf91"]
111nrf9161-ns = ["_nrf9120", "_ns"] 111nrf9161-ns = ["_nrf9120", "_ns", "_nrf91"]
112 112
113# Features starting with `_` are for internal use only. They're not intended 113# Features starting with `_` are for internal use only. They're not intended
114# to be enabled by other crates, and are not covered by semver guarantees. 114# to be enabled by other crates, and are not covered by semver guarantees.
@@ -120,6 +120,7 @@ _nrf9160 = ["nrf9160-pac", "_dppi"]
120_nrf9120 = ["nrf9120-pac", "_dppi"] 120_nrf9120 = ["nrf9120-pac", "_dppi"]
121_nrf52 = ["_ppi"] 121_nrf52 = ["_ppi"]
122_nrf51 = ["_ppi"] 122_nrf51 = ["_ppi"]
123_nrf91 = []
123 124
124_time-driver = ["dep:embassy-time-driver", "embassy-time-driver?/tick-hz-32_768"] 125_time-driver = ["dep:embassy-time-driver", "embassy-time-driver?/tick-hz-32_768"]
125 126
diff --git a/embassy-nrf/src/gpiote.rs b/embassy-nrf/src/gpiote.rs
index 8d15e04d0..9d97c7be9 100644
--- a/embassy-nrf/src/gpiote.rs
+++ b/embassy-nrf/src/gpiote.rs
@@ -166,7 +166,6 @@ unsafe fn handle_gpiote_interrupt() {
166 } 166 }
167} 167}
168 168
169
170#[cfg(not(feature = "_nrf51"))] 169#[cfg(not(feature = "_nrf51"))]
171struct BitIter(u32); 170struct BitIter(u32);
172 171
diff --git a/embassy-nrf/src/lib.rs b/embassy-nrf/src/lib.rs
index 15d2e65b2..75cdb34b6 100644
--- a/embassy-nrf/src/lib.rs
+++ b/embassy-nrf/src/lib.rs
@@ -26,8 +26,32 @@
26 feature = "nrf9160-ns", 26 feature = "nrf9160-ns",
27 feature = "nrf9120-s", 27 feature = "nrf9120-s",
28 feature = "nrf9120-ns", 28 feature = "nrf9120-ns",
29 feature = "nrf9151-s",
30 feature = "nrf9151-ns",
31 feature = "nrf9161-s",
32 feature = "nrf9161-ns",
29)))] 33)))]
30compile_error!("No chip feature activated. You must activate exactly one of the following features: nrf52810, nrf52811, nrf52832, nrf52833, nrf52840"); 34compile_error!("No chip feature activated. You must activate exactly one of the following features:
35 nrf51,
36 nrf52805,
37 nrf52810,
38 nrf52811,
39 nrf52820,
40 nrf52832,
41 nrf52833,
42 nrf52840,
43 nrf5340-app-s,
44 nrf5340-app-ns,
45 nrf5340-net,
46 nrf9160-s,
47 nrf9160-ns,
48 nrf9120-s,
49 nrf9120-ns,
50 nrf9151-s,
51 nrf9151-ns,
52 nrf9161-s,
53 nrf9161-ns,
54 ");
31 55
32#[cfg(all(feature = "reset-pin-as-gpio", not(feature = "_nrf52")))] 56#[cfg(all(feature = "reset-pin-as-gpio", not(feature = "_nrf52")))]
33compile_error!("feature `reset-pin-as-gpio` is only valid for nRF52 series chips."); 57compile_error!("feature `reset-pin-as-gpio` is only valid for nRF52 series chips.");
@@ -49,7 +73,7 @@ pub mod gpio;
49pub mod gpiote; 73pub mod gpiote;
50 74
51// TODO: tested on other chips 75// TODO: tested on other chips
52#[cfg(not(any(feature = "_nrf9160", feature = "_nrf9120", feature = "_nrf5340-app")))] 76#[cfg(not(any(feature = "_nrf91", feature = "_nrf5340-app")))]
53pub mod radio; 77pub mod radio;
54 78
55#[cfg(not(feature = "nrf51"))] 79#[cfg(not(feature = "nrf51"))]
@@ -64,8 +88,7 @@ pub mod nvmc;
64 feature = "nrf52833", 88 feature = "nrf52833",
65 feature = "nrf52840", 89 feature = "nrf52840",
66 feature = "_nrf5340-app", 90 feature = "_nrf5340-app",
67 feature = "_nrf9160", 91 feature = "_nrf91",
68 feature = "_nrf9120"
69))] 92))]
70pub mod pdm; 93pub mod pdm;
71pub mod ppi; 94pub mod ppi;
@@ -76,11 +99,11 @@ pub mod ppi;
76 feature = "_nrf5340-net" 99 feature = "_nrf5340-net"
77)))] 100)))]
78pub mod pwm; 101pub mod pwm;
79#[cfg(not(any(feature = "nrf51", feature = "_nrf9160", feature = "_nrf9120", feature = "_nrf5340-net")))] 102#[cfg(not(any(feature = "nrf51", feature = "_nrf91", feature = "_nrf5340-net")))]
80pub mod qdec; 103pub mod qdec;
81#[cfg(any(feature = "nrf52840", feature = "_nrf5340-app"))] 104#[cfg(any(feature = "nrf52840", feature = "_nrf5340-app"))]
82pub mod qspi; 105pub mod qspi;
83#[cfg(not(any(feature = "_nrf5340-app", feature = "_nrf9160", feature = "_nrf9120")))] 106#[cfg(not(any(feature = "_nrf5340-app", feature = "_nrf91")))]
84pub mod rng; 107pub mod rng;
85#[cfg(not(any(feature = "nrf51", feature = "nrf52820", feature = "_nrf5340-net")))] 108#[cfg(not(any(feature = "nrf51", feature = "nrf52820", feature = "_nrf5340-net")))]
86pub mod saadc; 109pub mod saadc;
@@ -88,7 +111,7 @@ pub mod saadc;
88pub mod spim; 111pub mod spim;
89#[cfg(not(feature = "nrf51"))] 112#[cfg(not(feature = "nrf51"))]
90pub mod spis; 113pub mod spis;
91#[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 114#[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
92pub mod temp; 115pub mod temp;
93pub mod timer; 116pub mod timer;
94#[cfg(not(feature = "nrf51"))] 117#[cfg(not(feature = "nrf51"))]
@@ -200,15 +223,15 @@ pub mod config {
200 /// Internal RC oscillator 223 /// Internal RC oscillator
201 InternalRC, 224 InternalRC,
202 /// Synthesized from the high frequency clock source. 225 /// Synthesized from the high frequency clock source.
203 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 226 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
204 Synthesized, 227 Synthesized,
205 /// External source from xtal. 228 /// External source from xtal.
206 ExternalXtal, 229 ExternalXtal,
207 /// External source from xtal with low swing applied. 230 /// External source from xtal with low swing applied.
208 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 231 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
209 ExternalLowSwing, 232 ExternalLowSwing,
210 /// External source from xtal with full swing applied. 233 /// External source from xtal with full swing applied.
211 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 234 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
212 ExternalFullSwing, 235 ExternalFullSwing,
213 } 236 }
214 237
@@ -226,7 +249,7 @@ pub mod config {
226 } 249 }
227 250
228 /// Settings for enabling the built in DCDC converters. 251 /// Settings for enabling the built in DCDC converters.
229 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 252 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
230 pub struct DcdcConfig { 253 pub struct DcdcConfig {
231 /// Config for the first stage DCDC (VDDH -> VDD), if disabled LDO will be used. 254 /// Config for the first stage DCDC (VDDH -> VDD), if disabled LDO will be used.
232 #[cfg(feature = "nrf52840")] 255 #[cfg(feature = "nrf52840")]
@@ -268,7 +291,7 @@ pub mod config {
268 } 291 }
269 292
270 /// Settings for enabling the built in DCDC converter. 293 /// Settings for enabling the built in DCDC converter.
271 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 294 #[cfg(feature = "_nrf91")]
272 pub struct DcdcConfig { 295 pub struct DcdcConfig {
273 /// Config for the main rail, if disabled LDO will be used. 296 /// Config for the main rail, if disabled LDO will be used.
274 pub regmain: bool, 297 pub regmain: bool,
@@ -302,7 +325,7 @@ pub mod config {
302 // xtals if they know they have them. 325 // xtals if they know they have them.
303 hfclk_source: HfclkSource::Internal, 326 hfclk_source: HfclkSource::Internal,
304 lfclk_source: LfclkSource::InternalRC, 327 lfclk_source: LfclkSource::InternalRC,
305 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 328 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
306 dcdc: DcdcConfig { 329 dcdc: DcdcConfig {
307 #[cfg(feature = "nrf52840")] 330 #[cfg(feature = "nrf52840")]
308 reg0: false, 331 reg0: false,
@@ -316,7 +339,7 @@ pub mod config {
316 regmain: false, 339 regmain: false,
317 regradio: false, 340 regradio: false,
318 }, 341 },
319 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 342 #[cfg(feature = "_nrf91")]
320 dcdc: DcdcConfig { regmain: false }, 343 dcdc: DcdcConfig { regmain: false },
321 #[cfg(feature = "gpiote")] 344 #[cfg(feature = "gpiote")]
322 gpiote_interrupt_priority: crate::interrupt::Priority::P0, 345 gpiote_interrupt_priority: crate::interrupt::Priority::P0,
@@ -333,7 +356,7 @@ pub mod config {
333 } 356 }
334} 357}
335 358
336#[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 359#[cfg(feature = "_nrf91")]
337#[allow(unused)] 360#[allow(unused)]
338mod consts { 361mod consts {
339 pub const UICR_APPROTECT: *mut u32 = 0x00FF8000 as *mut u32; 362 pub const UICR_APPROTECT: *mut u32 = 0x00FF8000 as *mut u32;
@@ -472,7 +495,7 @@ pub fn init(config: config::Config) -> Peripherals {
472 // UICR.APPROTECT = Enabled 495 // UICR.APPROTECT = Enabled
473 let res = uicr_write(consts::UICR_APPROTECT, consts::APPROTECT_ENABLED); 496 let res = uicr_write(consts::UICR_APPROTECT, consts::APPROTECT_ENABLED);
474 needs_reset |= res == WriteResult::Written; 497 needs_reset |= res == WriteResult::Written;
475 #[cfg(any(feature = "_nrf5340-app", feature = "_nrf9160", feature = "_nrf9120"))] 498 #[cfg(any(feature = "_nrf5340-app", feature = "_nrf91"))]
476 { 499 {
477 let res = uicr_write(consts::UICR_SECUREAPPROTECT, consts::APPROTECT_ENABLED); 500 let res = uicr_write(consts::UICR_SECUREAPPROTECT, consts::APPROTECT_ENABLED);
478 needs_reset |= res == WriteResult::Written; 501 needs_reset |= res == WriteResult::Written;
@@ -556,7 +579,7 @@ pub fn init(config: config::Config) -> Peripherals {
556 } 579 }
557 580
558 // Configure LFCLK. 581 // Configure LFCLK.
559 #[cfg(not(any(feature = "nrf51", feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 582 #[cfg(not(any(feature = "nrf51", feature = "_nrf5340", feature = "_nrf91")))]
560 match config.lfclk_source { 583 match config.lfclk_source {
561 config::LfclkSource::InternalRC => r.lfclksrc.write(|w| w.src().rc()), 584 config::LfclkSource::InternalRC => r.lfclksrc.write(|w| w.src().rc()),
562 config::LfclkSource::Synthesized => r.lfclksrc.write(|w| w.src().synth()), 585 config::LfclkSource::Synthesized => r.lfclksrc.write(|w| w.src().synth()),
@@ -576,7 +599,7 @@ pub fn init(config: config::Config) -> Peripherals {
576 w 599 w
577 }), 600 }),
578 } 601 }
579 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 602 #[cfg(feature = "_nrf91")]
580 match config.lfclk_source { 603 match config.lfclk_source {
581 config::LfclkSource::InternalRC => r.lfclksrc.write(|w| w.src().lfrc()), 604 config::LfclkSource::InternalRC => r.lfclksrc.write(|w| w.src().lfrc()),
582 config::LfclkSource::ExternalXtal => r.lfclksrc.write(|w| w.src().lfxo()), 605 config::LfclkSource::ExternalXtal => r.lfclksrc.write(|w| w.src().lfxo()),
@@ -589,7 +612,7 @@ pub fn init(config: config::Config) -> Peripherals {
589 r.tasks_lfclkstart.write(|w| unsafe { w.bits(1) }); 612 r.tasks_lfclkstart.write(|w| unsafe { w.bits(1) });
590 while r.events_lfclkstarted.read().bits() == 0 {} 613 while r.events_lfclkstarted.read().bits() == 0 {}
591 614
592 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf9160", feature = "_nrf9120")))] 615 #[cfg(not(any(feature = "_nrf5340", feature = "_nrf91")))]
593 { 616 {
594 // Setup DCDCs. 617 // Setup DCDCs.
595 let pwr = unsafe { &*pac::POWER::ptr() }; 618 let pwr = unsafe { &*pac::POWER::ptr() };
@@ -601,7 +624,7 @@ pub fn init(config: config::Config) -> Peripherals {
601 pwr.dcdcen.write(|w| w.dcdcen().set_bit()); 624 pwr.dcdcen.write(|w| w.dcdcen().set_bit());
602 } 625 }
603 } 626 }
604 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 627 #[cfg(feature = "_nrf91")]
605 { 628 {
606 // Setup DCDC. 629 // Setup DCDC.
607 let reg = unsafe { &*pac::REGULATORS::ptr() }; 630 let reg = unsafe { &*pac::REGULATORS::ptr() };
@@ -633,7 +656,7 @@ pub fn init(config: config::Config) -> Peripherals {
633 time_driver::init(config.time_interrupt_priority); 656 time_driver::init(config.time_interrupt_priority);
634 657
635 // Disable UARTE (enabled by default for some reason) 658 // Disable UARTE (enabled by default for some reason)
636 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 659 #[cfg(feature = "_nrf91")]
637 unsafe { 660 unsafe {
638 (*pac::UARTE0::ptr()).enable.write(|w| w.enable().disabled()); 661 (*pac::UARTE0::ptr()).enable.write(|w| w.enable().disabled());
639 (*pac::UARTE1::ptr()).enable.write(|w| w.enable().disabled()); 662 (*pac::UARTE1::ptr()).enable.write(|w| w.enable().disabled());
diff --git a/embassy-nrf/src/nvmc.rs b/embassy-nrf/src/nvmc.rs
index df027636c..9b17e7da0 100644
--- a/embassy-nrf/src/nvmc.rs
+++ b/embassy-nrf/src/nvmc.rs
@@ -60,23 +60,23 @@ impl<'d> Nvmc<'d> {
60 while p.ready.read().ready().is_busy() {} 60 while p.ready.read().ready().is_busy() {}
61 } 61 }
62 62
63 #[cfg(not(any(feature = "_nrf9160", feature = "_nrf5340")))] 63 #[cfg(not(any(feature = "_nrf91", feature = "_nrf5340")))]
64 fn wait_ready_write(&mut self) { 64 fn wait_ready_write(&mut self) {
65 self.wait_ready(); 65 self.wait_ready();
66 } 66 }
67 67
68 #[cfg(any(feature = "_nrf9160", feature = "_nrf5340"))] 68 #[cfg(any(feature = "_nrf91", feature = "_nrf5340"))]
69 fn wait_ready_write(&mut self) { 69 fn wait_ready_write(&mut self) {
70 let p = Self::regs(); 70 let p = Self::regs();
71 while p.readynext.read().readynext().is_busy() {} 71 while p.readynext.read().readynext().is_busy() {}
72 } 72 }
73 73
74 #[cfg(not(any(feature = "_nrf9160", feature = "_nrf9120", feature = "_nrf5340")))] 74 #[cfg(not(any(feature = "_nrf91", feature = "_nrf5340")))]
75 fn erase_page(&mut self, page_addr: u32) { 75 fn erase_page(&mut self, page_addr: u32) {
76 Self::regs().erasepage().write(|w| unsafe { w.bits(page_addr) }); 76 Self::regs().erasepage().write(|w| unsafe { w.bits(page_addr) });
77 } 77 }
78 78
79 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120", feature = "_nrf5340"))] 79 #[cfg(any(feature = "_nrf91", feature = "_nrf5340"))]
80 fn erase_page(&mut self, page_addr: u32) { 80 fn erase_page(&mut self, page_addr: u32) {
81 let first_page_word = page_addr as *mut u32; 81 let first_page_word = page_addr as *mut u32;
82 unsafe { 82 unsafe {
diff --git a/embassy-nrf/src/pdm.rs b/embassy-nrf/src/pdm.rs
index c1501e02e..5160fe3c4 100644
--- a/embassy-nrf/src/pdm.rs
+++ b/embassy-nrf/src/pdm.rs
@@ -21,7 +21,7 @@ pub use crate::pac::pdm::pdmclkctrl::FREQ_A as Frequency;
21 feature = "nrf52840", 21 feature = "nrf52840",
22 feature = "nrf52833", 22 feature = "nrf52833",
23 feature = "_nrf5340-app", 23 feature = "_nrf5340-app",
24 feature = "_nrf9160", 24 feature = "_nrf91",
25))] 25))]
26pub use crate::pac::pdm::ratio::RATIO_A as Ratio; 26pub use crate::pac::pdm::ratio::RATIO_A as Ratio;
27use crate::{interrupt, Peripheral}; 27use crate::{interrupt, Peripheral};
@@ -121,7 +121,7 @@ impl<'d, T: Instance> Pdm<'d, T> {
121 feature = "nrf52840", 121 feature = "nrf52840",
122 feature = "nrf52833", 122 feature = "nrf52833",
123 feature = "_nrf5340-app", 123 feature = "_nrf5340-app",
124 feature = "_nrf9160", 124 feature = "_nrf91",
125 ))] 125 ))]
126 r.ratio.write(|w| w.ratio().variant(config.ratio)); 126 r.ratio.write(|w| w.ratio().variant(config.ratio));
127 r.mode.write(|w| { 127 r.mode.write(|w| {
@@ -374,7 +374,7 @@ pub struct Config {
374 feature = "nrf52840", 374 feature = "nrf52840",
375 feature = "nrf52833", 375 feature = "nrf52833",
376 feature = "_nrf5340-app", 376 feature = "_nrf5340-app",
377 feature = "_nrf9160", 377 feature = "_nrf91",
378 ))] 378 ))]
379 pub ratio: Ratio, 379 pub ratio: Ratio,
380 /// Gain left in dB 380 /// Gain left in dB
@@ -393,7 +393,7 @@ impl Default for Config {
393 feature = "nrf52840", 393 feature = "nrf52840",
394 feature = "nrf52833", 394 feature = "nrf52833",
395 feature = "_nrf5340-app", 395 feature = "_nrf5340-app",
396 feature = "_nrf9160", 396 feature = "_nrf91",
397 ))] 397 ))]
398 ratio: Ratio::RATIO80, 398 ratio: Ratio::RATIO80,
399 gain_left: I7F1::ZERO, 399 gain_left: I7F1::ZERO,
diff --git a/embassy-nrf/src/saadc.rs b/embassy-nrf/src/saadc.rs
index e139b15da..3a94cbd8f 100644
--- a/embassy-nrf/src/saadc.rs
+++ b/embassy-nrf/src/saadc.rs
@@ -722,9 +722,9 @@ macro_rules! impl_saadc_input {
722pub struct VddInput; 722pub struct VddInput;
723 723
724impl_peripheral!(VddInput); 724impl_peripheral!(VddInput);
725#[cfg(not(any(feature = "_nrf9160", feature = "_nrf9120")))] 725#[cfg(not(feature = "_nrf91"))]
726impl_saadc_input!(@local, VddInput, VDD); 726impl_saadc_input!(@local, VddInput, VDD);
727#[cfg(not(any(feature = "_nrf9160", feature = "_nrf9120")))] 727#[cfg(not(feature = "_nrf91"))]
728impl_saadc_input!(@local, VddInput, VDDGPIO); 728impl_saadc_input!(@local, VddInput, VDDGPIO);
729 729
730/// A dummy `Input` pin implementation for SAADC peripheral sampling from the 730/// A dummy `Input` pin implementation for SAADC peripheral sampling from the
diff --git a/embassy-nrf/src/wdt.rs b/embassy-nrf/src/wdt.rs
index 5b3e1e930..5a261ce8f 100644
--- a/embassy-nrf/src/wdt.rs
+++ b/embassy-nrf/src/wdt.rs
@@ -30,9 +30,9 @@ impl Config {
30 pub fn try_new(_wdt: &peripherals::WDT) -> Option<Self> { 30 pub fn try_new(_wdt: &peripherals::WDT) -> Option<Self> {
31 let r = unsafe { &*WDT::ptr() }; 31 let r = unsafe { &*WDT::ptr() };
32 32
33 #[cfg(not(any(feature = "_nrf9160", feature = "_nrf9120")))] 33 #[cfg(not(feature = "_nrf91"))]
34 let runstatus = r.runstatus.read().runstatus().bit(); 34 let runstatus = r.runstatus.read().runstatus().bit();
35 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 35 #[cfg(feature = "_nrf91")]
36 let runstatus = r.runstatus.read().runstatuswdt().bit(); 36 let runstatus = r.runstatus.read().runstatuswdt().bit();
37 37
38 if runstatus { 38 if runstatus {
@@ -83,9 +83,9 @@ impl Watchdog {
83 let crv = config.timeout_ticks.max(MIN_TICKS); 83 let crv = config.timeout_ticks.max(MIN_TICKS);
84 let rren = (1u32 << N) - 1; 84 let rren = (1u32 << N) - 1;
85 85
86 #[cfg(not(any(feature = "_nrf9160", feature = "_nrf9120")))] 86 #[cfg(not(feature = "_nrf91"))]
87 let runstatus = r.runstatus.read().runstatus().bit(); 87 let runstatus = r.runstatus.read().runstatus().bit();
88 #[cfg(any(feature = "_nrf9160", feature = "_nrf9120"))] 88 #[cfg(feature = "_nrf91")]
89 let runstatus = r.runstatus.read().runstatuswdt().bit(); 89 let runstatus = r.runstatus.read().runstatuswdt().bit();
90 90
91 if runstatus { 91 if runstatus {