pub struct StaticRegister<T>where
T: RegisterValue,{
spec: &'static StaticRegisterSpec<T>,
}Expand description
A static register is a register inited by hardware. The value won’t change in it’s lifetime. All functions implemented on this one is thread safe.
Fields§
§spec: &'static StaticRegisterSpec<T>Implementations§
Source§impl<T> StaticRegister<T>where
T: RegisterValue,
impl<T> StaticRegister<T>where
T: RegisterValue,
Sourcepub fn new(spec: &'static StaticRegisterSpec<T>) -> StaticRegister<T>
pub fn new(spec: &'static StaticRegisterSpec<T>) -> StaticRegister<T>
Create an new static register from spec.
Trait Implementations§
Source§impl<T> Clone for StaticRegister<T>where
T: RegisterValue + Clone,
impl<T> Clone for StaticRegister<T>where
T: RegisterValue + Clone,
Source§fn clone(&self) -> StaticRegister<T>
fn clone(&self) -> StaticRegister<T>
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<T> RegisterInterface for StaticRegister<T>where
T: RegisterValue,
impl<T> RegisterInterface for StaticRegister<T>where
T: RegisterValue,
Auto Trait Implementations§
impl<T> Freeze for StaticRegister<T>
impl<T> RefUnwindSafe for StaticRegister<T>where
T: RefUnwindSafe,
impl<T> Send for StaticRegister<T>
impl<T> Sync for StaticRegister<T>
impl<T> Unpin for StaticRegister<T>
impl<T> UnwindSafe for StaticRegister<T>where
T: RefUnwindSafe,
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
Mutably borrows from an owned value. Read more