Struct tock_registers::registers::InMemoryRegister [−][src]
#[repr(transparent)]pub struct InMemoryRegister<T: UIntLike, R: RegisterLongName = ()> { /* fields omitted */ }
Expand description
In memory volatile register.
Like ReadWrite
, but can be safely constructed using the
InMemoryRegister::new
method. It will always be initialized to
the passed in, well-defined initial value.
For accessing and manipulating the register contents, the
Readable
, Writeable
and
ReadWriteable
traits are
implemented.
Implementations
Trait Implementations
type T = T
type R = R
fn read_as_enum<E: TryFromValue<Self::T, EnumType = E>>(
&self,
field: Field<Self::T, Self::R>
) -> Option<E>
fn read_as_enum<E: TryFromValue<Self::T, EnumType = E>>(
&self,
field: Field<Self::T, Self::R>
) -> Option<E>
Set the raw register value
Make a local copy of the register
Check if one or more bits in a field are set
Check if any specified parts of a field match
Check if all specified parts of a field match
type T = T
type R = R
Write the value of one or more fields, overwriting the other fields with zero
fn modify_no_read(
&self,
original: LocalRegisterCopy<Self::T, Self::R>,
field: FieldValue<Self::T, Self::R>
)
fn modify_no_read(
&self,
original: LocalRegisterCopy<Self::T, Self::R>,
field: FieldValue<Self::T, Self::R>
)
Write the value of one or more fields, maintaining the value of unchanged fields via a provided original value, rather than a register read. Read more
Auto Trait Implementations
impl<T, R> Send for InMemoryRegister<T, R> where
R: Send,
T: Send,
impl<T, R = ()> !Sync for InMemoryRegister<T, R>
impl<T, R> Unpin for InMemoryRegister<T, R> where
R: Unpin,
T: Unpin,
Blanket Implementations
Mutably borrows from an owned value. Read more
impl<T, R, S> ReadWriteable for S where
T: UIntLike,
R: RegisterLongName,
S: Readable<T = T, R = R> + Writeable<T = T, R = R>,
impl<T, R, S> ReadWriteable for S where
T: UIntLike,
R: RegisterLongName,
S: Readable<T = T, R = R> + Writeable<T = T, R = R>,