[−][src]Struct samd_dma::TransferDescriptor
The raw descriptor memory structure used by the DMA system to configure a block transfer.
Methods
impl TransferDescriptor
[src]
pub fn new() -> TransferDescriptor
[src]
Create a new empty descriptor.
pub fn get_src_addr(&self) -> *const ()
[src]
Get the type-erased source address.
pub fn get_dst_addr(&self) -> *const ()
[src]
Get the type-erased destination address.
pub fn get_next_desc_addr(&self) -> *mut TransferDescriptor
[src]
Get address for the next linked descriptor.
pub fn set_src_addr(&mut self, addr: *const ())
[src]
Set the source address of the descriptor. This is a type erased pointer.
pub fn set_dst_addr(&mut self, addr: *const ())
[src]
Set the destination address of the descriptor. This is a type erased pointer.
pub fn set_valid(&mut self)
[src]
Mark the descriptor as valid.
pub fn set_invalid(&mut self)
[src]
Mark the descriptor as invalid.
pub fn is_valid(&self) -> bool
[src]
Return the value of the valid bit.
pub fn set_block_count(&mut self, block_count: u16)
[src]
Set the block count for the descriptor.
pub fn get_block_transfer_count(&self) -> u16
[src]
Get the configured block transfer count.
pub fn get_step_size(&self) -> StepSize
[src]
Get the step size of the descriptor.
pub fn set_step_size(&mut self, step_size: StepSize)
[src]
Set the step size for the descriptor.
pub fn get_step_selection(&self) -> bool
[src]
Get which address is incremented with the descriptor's step size, if enabled.
Returns true
if the source address is incremented, false
if the destination address is incremented.
pub fn set_step_selection(&mut self, step_sel: bool)
[src]
Set which address is incremented with the descriptor's step size, if enabled.
true
will increment the source address by the step size, false
will increment the destination address by
the step size.
pub fn get_dest_addr_increment(&self) -> bool
[src]
Get whether the destination address is incremented after each beat transfer.
If get_step_selection()
is true
, the address will be incremented by 1. Otherwise, the address will be
incremented by the step size.
pub fn set_dest_addr_increment(&mut self, increment: bool)
[src]
Set whether the destination address is incremented after each beat transfer.
pub fn get_src_addr_increment(&self) -> bool
[src]
Get whether the source address is incremented after each beat transfer.
If get_step_selection()
is false
, the address will be incremented by 1. Otherwise, the address will be
incremented by the step size.
pub fn set_src_addr_increment(&mut self, increment: bool)
[src]
Set whether the source address is incremented after each beat transfer.
pub fn get_block_action(&self) -> BlockAction
[src]
Get the action taken after this block transfer completes.
pub fn set_block_action(&mut self, block_action: BlockAction)
[src]
Set the action taken after this block transfer completes.
pub fn get_event_output(&self) -> EventOutput
[src]
Get the trigger that causes the transfer to output an event.
pub fn set_event_output(&mut self, event_output: EventOutput)
[src]
Set the trigger that causes the transfer to output an event.
pub fn link_descriptor(&mut self, next: *mut TransferDescriptor)
[src]
Link a transfer descriptor to execute AFTER this descriptor.
pub fn unlink_descriptor(&mut self) -> *mut TransferDescriptor
[src]
Unlink the next transfer descriptor, returning its address (which maybe null).
Trait Implementations
impl Debug for TransferDescriptor
[src]
impl Default for TransferDescriptor
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,