Skip to main content

Csw

Struct Csw 

Source
pub struct Csw(/* private fields */);
Expand description

Control/Status Word register data

Implementations§

Source§

impl Csw

Source

pub const SIZE_8BIT: u32 = 0b000

Source

pub const SIZE_16BIT: u32 = 0b001

Source

pub const SIZE_32BIT: u32 = 0b010

Source

pub const SIZE_64BIT: u32 = 0b011

Source

pub const SIZE_128BIT: u32 = 0b100

Source

pub const SIZE_256BIT: u32 = 0b101

Source

pub const ADDRINC_OFF: u32 = 0b00

Source

pub const ADDRINC_SINGLE: u32 = 0b01

Source

pub const ADDRINC_PACKED: u32 = 0b10

Source

pub const PROT_MASTER_DEBUG: u32

Source

pub const PROT_BIT_1: u32

Source

pub fn value(&self) -> u32

Get raw register value

Source

pub fn size(&self) -> u32

Get size field

Source

pub fn addrinc(&self) -> u32

Get address increment field

Source

pub fn device_en(&self) -> bool

Get device enable flag

Source

pub fn tr_in_prog(&self) -> bool

Get transfer in progress flag

Source

pub fn mode(&self) -> u32

Get mode field

Source

pub fn type_bits(&self) -> u32

Get type field

Source

pub fn mte(&self) -> bool

Get MTE flag

Source

pub fn spiden(&self) -> bool

Get SPIDEN flag

Source

pub fn prot(&self) -> u32

Get protection field

Source

pub fn dbg_sw_enable(&self) -> bool

Get debug software enable flag

Source

pub fn set_reserved_high(&mut self)

Source

pub fn set_size(&mut self, size: u32)

Set size field

Source

pub fn set_addrinc(&mut self, addrinc: u32)

Set address increment field

Source

pub fn set_device_en(&mut self, enable: bool)

Set device enable flag

Source

pub fn set_mode(&mut self, mode: u32)

Set mode field

Source

pub fn set_type(&mut self, type_bits: u32)

Set type field

Source

pub fn set_mte(&mut self, enable: bool)

Set MTE flag

Source

pub fn set_spiden(&mut self, enable: bool)

Set SPIDEN flag

Source

pub fn set_prot(&mut self, prot: u32)

Set protection field

Source

pub fn set_dbg_sw_enable(&mut self, enable: bool)

Set debug software enable flag

Source

pub fn transfer_config(&self) -> String

Get transfer configuration description

Source

pub fn status_flags(&self) -> String

Get status flags description

Source

pub fn security_state(&self) -> String

Get security state description

Trait Implementations§

Source§

impl Clone for Csw

Source§

fn clone(&self) -> Csw

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Csw

Source§

impl Debug for Csw

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Csw

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Display for Csw

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Csw

Source§

impl From<Csw> for u32

Source§

fn from(value: Csw) -> u32

Converts to this type from the input type.
Source§

impl From<u32> for Csw

Source§

fn from(value: u32) -> Self

Converts to this type from the input type.
Source§

impl PartialEq for Csw

Source§

fn eq(&self, other: &Csw) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Csw

Auto Trait Implementations§

§

impl Freeze for Csw

§

impl RefUnwindSafe for Csw

§

impl Send for Csw

§

impl Sync for Csw

§

impl Unpin for Csw

§

impl UnsafeUnpin for Csw

§

impl UnwindSafe for Csw

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.