Struct aw_soc::spi::GlobalControl
source · #[repr(transparent)]pub struct GlobalControl(_);Expand description
Global control for current peripheral.
Implementations§
source§impl GlobalControl
impl GlobalControl
sourcepub const fn software_reset(self) -> Self
pub const fn software_reset(self) -> Self
Perform software reset to the SPI controller.
sourcepub const fn is_software_reset_finished(self) -> bool
pub const fn is_software_reset_finished(self) -> bool
Check if software reset request has finished.
sourcepub const fn set_transmit_pause_enable(self, val: bool) -> Self
pub const fn set_transmit_pause_enable(self, val: bool) -> Self
Set transmit pause enable flag.
In master mode, if this flag is enabled, transmitting data will be stopped when receive FIFO is full.
sourcepub const fn transmit_pause_enabled(self) -> bool
pub const fn transmit_pause_enabled(self) -> bool
Check if transmit pause has enabled.
sourcepub const fn set_master_mode(self) -> Self
pub const fn set_master_mode(self) -> Self
Set this peripheral to operate on master mode.
sourcepub const fn set_slave_mode(self) -> Self
pub const fn set_slave_mode(self) -> Self
Set this peripheral to operate on slave mode.
sourcepub const fn is_master_mode(self) -> bool
pub const fn is_master_mode(self) -> bool
Check if this peripheral operates on master mode.
sourcepub const fn is_slave_mode(self) -> bool
pub const fn is_slave_mode(self) -> bool
Check if this peripheral operates on slave mode.
sourcepub const fn set_enabled(self, val: bool) -> Self
pub const fn set_enabled(self, val: bool) -> Self
Enable or disable this peripheral.
sourcepub const fn is_enabled(self) -> bool
pub const fn is_enabled(self) -> bool
Check if this peripheral is enabled.
Trait Implementations§
source§impl Clone for GlobalControl
impl Clone for GlobalControl
source§fn clone(&self) -> GlobalControl
fn clone(&self) -> GlobalControl
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for GlobalControl
impl Debug for GlobalControl
source§impl Default for GlobalControl
impl Default for GlobalControl
source§fn default() -> GlobalControl
fn default() -> GlobalControl
Returns the “default value” for a type. Read more
source§impl PartialEq<GlobalControl> for GlobalControl
impl PartialEq<GlobalControl> for GlobalControl
source§fn eq(&self, other: &GlobalControl) -> bool
fn eq(&self, other: &GlobalControl) -> bool
This method tests for
self and other values to be equal, and is used
by ==.