pub type R = crate::R<IENrs>;
pub type W = crate::W<IENrs>;
pub type DoneR = crate::FieldReader;
pub type DoneW<'a, REG> = crate::FieldWriter<'a, REG, 8>;
pub type ErrorR = crate::BitReader;
pub type ErrorW<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[inline(always)]
pub fn done(&self) -> DoneR {
DoneR::new((self.bits & 0xff) as u8)
}
#[inline(always)]
pub fn error(&self) -> ErrorR {
ErrorR::new(((self.bits >> 31) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("IEN")
.field("done", &self.done())
.field("error", &self.error())
.finish()
}
}
impl W {
#[inline(always)]
pub fn done(&mut self) -> DoneW<'_, IENrs> {
DoneW::new(self, 0)
}
#[inline(always)]
pub fn error(&mut self) -> ErrorW<'_, IENrs> {
ErrorW::new(self, 31)
}
}
pub struct IENrs;
impl crate::RegisterSpec for IENrs {
type Ux = u32;
}
impl crate::Readable for IENrs {}
impl crate::Writable for IENrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for IENrs {}