diff options
| author | f_punk <[email protected]> | 2021-09-02 12:02:31 +0200 |
|---|---|---|
| committer | f_punk <[email protected]> | 2021-09-02 12:02:31 +0200 |
| commit | 34c66fa78d700fa5ca324dd043dc0861694ea693 (patch) | |
| tree | 44deb75285cbc264f02aef88a2809e33660b6ee0 /embassy-nrf/src/buffered_uarte.rs | |
| parent | 1cef7134d42e581c86102df733f1420d86b20861 (diff) | |
removed type aliases
NotAwaitable as default generic param
added awaitable_timer example
Diffstat (limited to 'embassy-nrf/src/buffered_uarte.rs')
| -rw-r--r-- | embassy-nrf/src/buffered_uarte.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/embassy-nrf/src/buffered_uarte.rs b/embassy-nrf/src/buffered_uarte.rs index 5c9f4270b..90ce49582 100644 --- a/embassy-nrf/src/buffered_uarte.rs +++ b/embassy-nrf/src/buffered_uarte.rs | |||
| @@ -16,7 +16,7 @@ use crate::gpio::{OptionalPin as GpioOptionalPin, Pin as GpioPin}; | |||
| 16 | use crate::pac; | 16 | use crate::pac; |
| 17 | use crate::ppi::{AnyConfigurableChannel, ConfigurableChannel, Event, Ppi, Task}; | 17 | use crate::ppi::{AnyConfigurableChannel, ConfigurableChannel, Event, Ppi, Task}; |
| 18 | use crate::timer::Instance as TimerInstance; | 18 | use crate::timer::Instance as TimerInstance; |
| 19 | use crate::timer::{Frequency, NotAwaitableTimer}; | 19 | use crate::timer::{Frequency, Timer}; |
| 20 | use crate::uarte::{Config, Instance as UarteInstance}; | 20 | use crate::uarte::{Config, Instance as UarteInstance}; |
| 21 | 21 | ||
| 22 | // Re-export SVD variants to allow user to directly set values | 22 | // Re-export SVD variants to allow user to directly set values |
| @@ -43,7 +43,7 @@ impl<'d, U: UarteInstance, T: TimerInstance> State<'d, U, T> { | |||
| 43 | 43 | ||
| 44 | struct StateInner<'d, U: UarteInstance, T: TimerInstance> { | 44 | struct StateInner<'d, U: UarteInstance, T: TimerInstance> { |
| 45 | phantom: PhantomData<&'d mut U>, | 45 | phantom: PhantomData<&'d mut U>, |
| 46 | timer: NotAwaitableTimer<'d, T>, | 46 | timer: Timer<'d, T>, |
| 47 | _ppi_ch1: Ppi<'d, AnyConfigurableChannel>, | 47 | _ppi_ch1: Ppi<'d, AnyConfigurableChannel>, |
| 48 | _ppi_ch2: Ppi<'d, AnyConfigurableChannel>, | 48 | _ppi_ch2: Ppi<'d, AnyConfigurableChannel>, |
| 49 | 49 | ||
| @@ -84,7 +84,7 @@ impl<'d, U: UarteInstance, T: TimerInstance> BufferedUarte<'d, U, T> { | |||
| 84 | 84 | ||
| 85 | let r = U::regs(); | 85 | let r = U::regs(); |
| 86 | 86 | ||
| 87 | let mut timer = NotAwaitableTimer::new(timer); | 87 | let mut timer = Timer::new(timer); |
| 88 | 88 | ||
| 89 | rxd.conf().write(|w| w.input().connect().drive().h0h1()); | 89 | rxd.conf().write(|w| w.input().connect().drive().h0h1()); |
| 90 | r.psel.rxd.write(|w| unsafe { w.bits(rxd.psel_bits()) }); | 90 | r.psel.rxd.write(|w| unsafe { w.bits(rxd.psel_bits()) }); |
