pub struct LinkedListTransfer<'a, const ITEM_COUNT: usize> { /* private fields */ }
Expand description
Linked-list DMA transfer.
Implementations§
Source§impl<'a, const ITEM_COUNT: usize> LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> LinkedListTransfer<'a, ITEM_COUNT>
Sourcepub unsafe fn new_linked_list<const N: usize>(
channel: Peri<'a, impl Channel>,
table: Table<ITEM_COUNT>,
options: TransferOptions,
) -> Self
pub unsafe fn new_linked_list<const N: usize>( channel: Peri<'a, impl Channel>, table: Table<ITEM_COUNT>, options: TransferOptions, ) -> Self
Create a new linked-list transfer.
Sourcepub fn request_pause(&mut self)
pub fn request_pause(&mut self)
Request the transfer to pause, keeping the existing configuration for this channel.
To resume the transfer, call request_resume
again.
This doesn’t immediately stop the transfer, you have to wait until is_running
returns false.
Sourcepub fn request_resume(&mut self)
pub fn request_resume(&mut self)
Request the transfer to resume after having been paused.
Sourcepub fn request_reset(&mut self)
pub fn request_reset(&mut self)
Request the DMA to reset.
The configuration for this channel will not be preserved. If you need to restart the transfer
at a later point with the same configuration, see request_pause
instead.
Sourcepub fn is_running(&mut self) -> bool
pub fn is_running(&mut self) -> bool
Return whether this transfer is still running.
If this returns false
, it can be because either the transfer finished, or
it was requested to stop early with request_pause
.
Sourcepub fn get_remaining_transfers(&self) -> u16
pub fn get_remaining_transfers(&self) -> u16
Gets the total remaining transfers for the channel Note: this will be zero for transfers that completed without cancellation.
Sourcepub fn blocking_wait(self)
pub fn blocking_wait(self)
Blocking wait until the transfer finishes.
Trait Implementations§
Source§impl<'a, const ITEM_COUNT: usize> Drop for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> Drop for LinkedListTransfer<'a, ITEM_COUNT>
Source§impl<'a, const ITEM_COUNT: usize> Future for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> Future for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> Unpin for LinkedListTransfer<'a, ITEM_COUNT>
Auto Trait Implementations§
impl<'a, const ITEM_COUNT: usize> Freeze for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> RefUnwindSafe for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> Send for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> Sync for LinkedListTransfer<'a, ITEM_COUNT>
impl<'a, const ITEM_COUNT: usize> !UnwindSafe for LinkedListTransfer<'a, ITEM_COUNT>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn map<U, F>(self, f: F) -> Map<Self, F>
fn map<U, F>(self, f: F) -> Map<Self, F>
Source§fn map_into<U>(self) -> MapInto<Self, U>
fn map_into<U>(self) -> MapInto<Self, U>
Source§fn then<Fut, F>(self, f: F) -> Then<Self, Fut, F>
fn then<Fut, F>(self, f: F) -> Then<Self, Fut, F>
f
. Read moreSource§fn left_future<B>(self) -> Either<Self, B>
fn left_future<B>(self) -> Either<Self, B>
Source§fn right_future<A>(self) -> Either<A, Self>
fn right_future<A>(self) -> Either<A, Self>
Source§fn into_stream(self) -> IntoStream<Self>where
Self: Sized,
fn into_stream(self) -> IntoStream<Self>where
Self: Sized,
Source§fn flatten(self) -> Flatten<Self>
fn flatten(self) -> Flatten<Self>
Source§fn flatten_stream(self) -> FlattenStream<Self>
fn flatten_stream(self) -> FlattenStream<Self>
Source§fn fuse(self) -> Fuse<Self>where
Self: Sized,
fn fuse(self) -> Fuse<Self>where
Self: Sized,
poll
will never again be called once it has
completed. This method can be used to turn any Future
into a
FusedFuture
. Read moreSource§fn inspect<F>(self, f: F) -> Inspect<Self, F>
fn inspect<F>(self, f: F) -> Inspect<Self, F>
Source§fn unit_error(self) -> UnitError<Self>where
Self: Sized,
fn unit_error(self) -> UnitError<Self>where
Self: Sized,
Future<Output = T>
into a
TryFuture<Ok = T, Error = ()
>.Source§fn never_error(self) -> NeverError<Self>where
Self: Sized,
fn never_error(self) -> NeverError<Self>where
Self: Sized,
Future<Output = T>
into a
TryFuture<Ok = T, Error = Never
>.