aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDario Nieuwenhuis <[email protected]>2023-04-03 13:32:34 +0000
committerGitHub <[email protected]>2023-04-03 13:32:34 +0000
commitfd5c7acafc810dea732f28b49847baba7b1c2aae (patch)
tree61061eddf49e880241450942944773833ea37095 /src
parente6e5685f7c75c3f5f5475e64101de90e6999b79c (diff)
parent608eb9b1fde5c2d6c5e8f4f5732379de22c2e6c1 (diff)
Merge pull request #61 from kbleeke/noop-mutex-for-events
event queue mutexs can be noop because we are already !Sync in other …
Diffstat (limited to 'src')
-rw-r--r--src/events.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/events.rs b/src/events.rs
index b9c8cca6b..87f6c01a3 100644
--- a/src/events.rs
+++ b/src/events.rs
@@ -3,7 +3,7 @@
3 3
4use core::num; 4use core::num;
5 5
6use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex; 6use embassy_sync::blocking_mutex::raw::NoopRawMutex;
7use embassy_sync::pubsub::{PubSubChannel, Publisher, Subscriber}; 7use embassy_sync::pubsub::{PubSubChannel, Publisher, Subscriber};
8 8
9#[derive(Debug, Clone, Copy, PartialEq, Eq, num_enum::FromPrimitive)] 9#[derive(Debug, Clone, Copy, PartialEq, Eq, num_enum::FromPrimitive)]
@@ -284,9 +284,9 @@ pub enum Event {
284 LAST = 190, 284 LAST = 190,
285} 285}
286 286
287pub type EventQueue = PubSubChannel<CriticalSectionRawMutex, EventStatus, 2, 1, 1>; 287pub type EventQueue = PubSubChannel<NoopRawMutex, EventStatus, 2, 1, 1>;
288pub type EventPublisher<'a> = Publisher<'a, CriticalSectionRawMutex, EventStatus, 2, 1, 1>; 288pub type EventPublisher<'a> = Publisher<'a, NoopRawMutex, EventStatus, 2, 1, 1>;
289pub type EventSubscriber<'a> = Subscriber<'a, CriticalSectionRawMutex, EventStatus, 2, 1, 1>; 289pub type EventSubscriber<'a> = Subscriber<'a, NoopRawMutex, EventStatus, 2, 1, 1>;
290 290
291#[derive(Clone, Copy)] 291#[derive(Clone, Copy)]
292#[cfg_attr(feature = "defmt", derive(defmt::Format))] 292#[cfg_attr(feature = "defmt", derive(defmt::Format))]