pub type R = crate::R<DMACMFCRrs>;
pub type W = crate::W<DMACMFCRrs>;
pub type MFC_R = crate::FieldReader<u16>;
pub type MFC_W<'a, REG> = crate::FieldWriter<'a, REG, 11, u16>;
pub type MFCO_R = crate::BitReader;
pub type MFCO_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn mfc(&self) -> MFC_R {
MFC_R::new((self.bits & 0x07ff) as u16)
}
#[inline(always)]
pub fn mfco(&self) -> MFCO_R {
MFCO_R::new(((self.bits >> 15) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("DMACMFCR")
.field("mfco", &self.mfco())
.field("mfc", &self.mfc())
.finish()
}
}
impl W {
#[inline(always)]
pub fn mfc(&mut self) -> MFC_W<DMACMFCRrs> {
MFC_W::new(self, 0)
}
#[inline(always)]
pub fn mfco(&mut self) -> MFCO_W<DMACMFCRrs> {
MFCO_W::new(self, 15)
}
}
pub struct DMACMFCRrs;
impl crate::RegisterSpec for DMACMFCRrs {
type Ux = u32;
}
impl crate::Readable for DMACMFCRrs {}
impl crate::Writable for DMACMFCRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for DMACMFCRrs {}