mirror of
https://github.com/embassy-rs/embassy.git
synced 2025-10-02 14:44:32 +00:00
Fixed missing nrf52840 in Event
This commit is contained in:
parent
4294bc5e4b
commit
35febae570
@ -97,6 +97,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_framestart.read().events_framestart().bit_is_set() {
|
if radio.events_framestart.read().events_framestart().bit_is_set() {
|
||||||
@ -106,6 +107,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_edend.read().events_edend().bit_is_set() {
|
if radio.events_edend.read().events_edend().bit_is_set() {
|
||||||
@ -115,20 +117,36 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_edstopped.read().events_edstopped().bit_is_set() {
|
if radio.events_edstopped.read().events_edstopped().bit_is_set() {
|
||||||
value |= Self::ED_STOPPED;
|
value |= Self::ED_STOPPED;
|
||||||
}
|
}
|
||||||
#[cfg(any(feature = "nrf52820", feature = "nrf52833", feature = "_nrf5340-net"))]
|
#[cfg(any(
|
||||||
|
feature = "nrf52820",
|
||||||
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
|
feature = "_nrf5340-net"
|
||||||
|
))]
|
||||||
if radio.events_ccaidle.read().events_ccaidle().bit_is_set() {
|
if radio.events_ccaidle.read().events_ccaidle().bit_is_set() {
|
||||||
value |= Self::CCA_IDLE;
|
value |= Self::CCA_IDLE;
|
||||||
}
|
}
|
||||||
#[cfg(any(feature = "nrf52820", feature = "nrf52833", feature = "_nrf5340-net"))]
|
#[cfg(any(
|
||||||
|
feature = "nrf52820",
|
||||||
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
|
feature = "_nrf5340-net"
|
||||||
|
))]
|
||||||
if radio.events_ccabusy.read().events_ccabusy().bit_is_set() {
|
if radio.events_ccabusy.read().events_ccabusy().bit_is_set() {
|
||||||
value |= Self::CCA_BUSY;
|
value |= Self::CCA_BUSY;
|
||||||
}
|
}
|
||||||
#[cfg(any(feature = "nrf52820", feature = "nrf52833", feature = "_nrf5340-net"))]
|
#[cfg(any(
|
||||||
|
feature = "nrf52820",
|
||||||
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
|
feature = "_nrf5340-net"
|
||||||
|
))]
|
||||||
if radio.events_ccastopped.read().events_ccastopped().bit_is_set() {
|
if radio.events_ccastopped.read().events_ccastopped().bit_is_set() {
|
||||||
value |= Self::CCA_STOPPED;
|
value |= Self::CCA_STOPPED;
|
||||||
}
|
}
|
||||||
@ -136,6 +154,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_rateboost.read().events_rateboost().bit_is_set() {
|
if radio.events_rateboost.read().events_rateboost().bit_is_set() {
|
||||||
@ -146,6 +165,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_txready.read().events_txready().bit_is_set() {
|
if radio.events_txready.read().events_txready().bit_is_set() {
|
||||||
@ -156,6 +176,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_rxready.read().events_rxready().bit_is_set() {
|
if radio.events_rxready.read().events_rxready().bit_is_set() {
|
||||||
@ -165,6 +186,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_mhrmatch.read().events_mhrmatch().bit_is_set() {
|
if radio.events_mhrmatch.read().events_mhrmatch().bit_is_set() {
|
||||||
@ -179,6 +201,7 @@ impl Event {
|
|||||||
feature = "nrf52811",
|
feature = "nrf52811",
|
||||||
feature = "nrf52820",
|
feature = "nrf52820",
|
||||||
feature = "nrf52833",
|
feature = "nrf52833",
|
||||||
|
feature = "nrf52840",
|
||||||
feature = "_nrf5340-net"
|
feature = "_nrf5340-net"
|
||||||
))]
|
))]
|
||||||
if radio.events_phyend.read().events_phyend().bit_is_set() {
|
if radio.events_phyend.read().events_phyend().bit_is_set() {
|
||||||
|
@ -164,7 +164,7 @@ impl<'d, T: Instance> Radio<'d, T> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Changes the Start of Frame Delimiter
|
/// Changes the Start of Frame Delimiter (SFD)
|
||||||
pub fn set_sfd(&mut self, sfd: u8) {
|
pub fn set_sfd(&mut self, sfd: u8) {
|
||||||
let r = T::regs();
|
let r = T::regs();
|
||||||
r.sfd.write(|w| unsafe { w.sfd().bits(sfd) });
|
r.sfd.write(|w| unsafe { w.sfd().bits(sfd) });
|
||||||
|
Loading…
x
Reference in New Issue
Block a user