Trait drone_cortexm::reg::Reg[][src]

pub trait Reg<T>: Token + Sync where
    T: RegTag
{ type Val: Bitfield; type UReg: Reg<Urt>; type SReg: Reg<Srt>; type CReg: Reg<Crt>; pub const ADDRESS: usize; pub const RESET: <Self::Val as Bitfield>::Bits; pub unsafe fn val_from(bits: <Self::Val as Bitfield>::Bits) -> Self::Val; pub fn into_unsync(self) -> Self::UReg
    where
        T: RegOwned
, { ... }
pub fn into_sync(self) -> Self::SReg
    where
        T: RegOwned
, { ... }
pub fn into_copy(self) -> Self::CReg { ... }
pub fn as_sync(&self) -> &Self::SReg
    where
        T: RegAtomic
, { ... }
pub fn default_val(&self) -> Self::Val { ... } }

The base trait for a memory-mapped register token.

Associated Types

type Val: Bitfield[src]

Opaque storage for register values.

This type is only a storage, without methods to read or write the stored bits. It should be used in conjunction with RegHold or register fields.

See also Hold.

type UReg: Reg<Urt>[src]

Corresponding unsynchronized register token.

type SReg: Reg<Srt>[src]

Corresponding synchronized register token.

type CReg: Reg<Crt>[src]

Corresponding copyable register token.

Loading content...

Associated Constants

pub const ADDRESS: usize[src]

The register address in memory.

pub const RESET: <Self::Val as Bitfield>::Bits[src]

The register default value.

Loading content...

Required methods

pub unsafe fn val_from(bits: <Self::Val as Bitfield>::Bits) -> Self::Val[src]

Creates a new instance of Reg::Val from raw bits.

Safety

This function is unsafe because it doesn’t require a token.

Loading content...

Provided methods

pub fn into_unsync(self) -> Self::UReg where
    T: RegOwned
[src]

Converts into unsynchronized register token.

pub fn into_sync(self) -> Self::SReg where
    T: RegOwned
[src]

Converts into synchronized register token.

pub fn into_copy(self) -> Self::CReg[src]

Converts into copyable register token.

pub fn as_sync(&self) -> &Self::SReg where
    T: RegAtomic
[src]

Returns a reference to the synchronized register token.

pub fn default_val(&self) -> Self::Val[src]

Creates a new opaque register value, and initializes it with the reset value.

See also default.

Loading content...

Implementors

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::dwt::cyccnt::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::itm::lar::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::itm::tcr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::itm::tpr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::afsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::aircr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::bfar::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::bfsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::ccr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::cpuid::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::demcr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::dfsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::hfsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::icsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::mmfar::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::mmfsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::scr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::shcsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::shpr1::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::shpr2::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::shpr3::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::ufsr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::scb::vtor::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::stk::calib::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::stk::ctrl::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::stk::load::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::stk::val::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::tpiu::acpr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::tpiu::ffcr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

impl<_T: RegTag> Reg<_T> for drone_cortexm::map::reg::tpiu::sppr::Reg<_T>[src]

type Val = Val

type UReg = Reg<Urt>

type SReg = Reg<Srt>

type CReg = Reg<Crt>

Loading content...