diff options
| author | Dániel Buga <[email protected]> | 2024-12-16 18:08:19 +0100 |
|---|---|---|
| committer | Dániel Buga <[email protected]> | 2024-12-16 19:22:22 +0100 |
| commit | 3c121e5425e0a1901c459d27e3e5929f86d0a206 (patch) | |
| tree | 39c8c1ff1a5aeaa0c62100880b5d9966866a630f /embassy-time-driver/src | |
| parent | d3f0294fb12e060c4a3ba557ff95766d1c3686e0 (diff) | |
Remove special handling of integrated timer queue
Diffstat (limited to 'embassy-time-driver/src')
| -rw-r--r-- | embassy-time-driver/src/lib.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/embassy-time-driver/src/lib.rs b/embassy-time-driver/src/lib.rs index 57a9f7587..c776fbdf8 100644 --- a/embassy-time-driver/src/lib.rs +++ b/embassy-time-driver/src/lib.rs | |||
| @@ -131,6 +131,7 @@ pub trait Driver: Send + Sync + 'static { | |||
| 131 | 131 | ||
| 132 | extern "Rust" { | 132 | extern "Rust" { |
| 133 | fn _embassy_time_now() -> u64; | 133 | fn _embassy_time_now() -> u64; |
| 134 | fn _embassy_time_schedule_wake(at: u64, waker: &Waker); | ||
| 134 | } | 135 | } |
| 135 | 136 | ||
| 136 | /// See [`Driver::now`] | 137 | /// See [`Driver::now`] |
| @@ -138,6 +139,11 @@ pub fn now() -> u64 { | |||
| 138 | unsafe { _embassy_time_now() } | 139 | unsafe { _embassy_time_now() } |
| 139 | } | 140 | } |
| 140 | 141 | ||
| 142 | /// Schedule the given waker to be woken at `at`. | ||
| 143 | pub fn schedule_wake(at: u64, waker: &Waker) { | ||
| 144 | unsafe { _embassy_time_schedule_wake(at, waker) } | ||
| 145 | } | ||
| 146 | |||
| 141 | /// Set the time Driver implementation. | 147 | /// Set the time Driver implementation. |
| 142 | /// | 148 | /// |
| 143 | /// See the module documentation for an example. | 149 | /// See the module documentation for an example. |
