pub type R = crate::R<ATCR2rs>;
pub type W = crate::W<ATCR2rs>;
pub type ATOSEL1_R = crate::FieldReader;
pub type ATOSEL1_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL2_R = crate::FieldReader;
pub type ATOSEL2_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL3_R = crate::FieldReader;
pub type ATOSEL3_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL4_R = crate::FieldReader;
pub type ATOSEL4_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL5_R = crate::FieldReader;
pub type ATOSEL5_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL6_R = crate::FieldReader;
pub type ATOSEL6_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL7_R = crate::FieldReader;
pub type ATOSEL7_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
pub type ATOSEL8_R = crate::FieldReader;
pub type ATOSEL8_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
impl R {
#[inline(always)]
pub fn atosel1(&self) -> ATOSEL1_R {
ATOSEL1_R::new(((self.bits >> 8) & 7) as u8)
}
#[inline(always)]
pub fn atosel2(&self) -> ATOSEL2_R {
ATOSEL2_R::new(((self.bits >> 11) & 7) as u8)
}
#[inline(always)]
pub fn atosel3(&self) -> ATOSEL3_R {
ATOSEL3_R::new(((self.bits >> 14) & 7) as u8)
}
#[inline(always)]
pub fn atosel4(&self) -> ATOSEL4_R {
ATOSEL4_R::new(((self.bits >> 17) & 7) as u8)
}
#[inline(always)]
pub fn atosel5(&self) -> ATOSEL5_R {
ATOSEL5_R::new(((self.bits >> 20) & 7) as u8)
}
#[inline(always)]
pub fn atosel6(&self) -> ATOSEL6_R {
ATOSEL6_R::new(((self.bits >> 23) & 7) as u8)
}
#[inline(always)]
pub fn atosel7(&self) -> ATOSEL7_R {
ATOSEL7_R::new(((self.bits >> 26) & 7) as u8)
}
#[inline(always)]
pub fn atosel8(&self) -> ATOSEL8_R {
ATOSEL8_R::new(((self.bits >> 29) & 7) as u8)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("ATCR2")
.field("atosel1", &self.atosel1())
.field("atosel2", &self.atosel2())
.field("atosel3", &self.atosel3())
.field("atosel4", &self.atosel4())
.field("atosel5", &self.atosel5())
.field("atosel6", &self.atosel6())
.field("atosel7", &self.atosel7())
.field("atosel8", &self.atosel8())
.finish()
}
}
impl W {
#[inline(always)]
pub fn atosel1(&mut self) -> ATOSEL1_W<ATCR2rs> {
ATOSEL1_W::new(self, 8)
}
#[inline(always)]
pub fn atosel2(&mut self) -> ATOSEL2_W<ATCR2rs> {
ATOSEL2_W::new(self, 11)
}
#[inline(always)]
pub fn atosel3(&mut self) -> ATOSEL3_W<ATCR2rs> {
ATOSEL3_W::new(self, 14)
}
#[inline(always)]
pub fn atosel4(&mut self) -> ATOSEL4_W<ATCR2rs> {
ATOSEL4_W::new(self, 17)
}
#[inline(always)]
pub fn atosel5(&mut self) -> ATOSEL5_W<ATCR2rs> {
ATOSEL5_W::new(self, 20)
}
#[inline(always)]
pub fn atosel6(&mut self) -> ATOSEL6_W<ATCR2rs> {
ATOSEL6_W::new(self, 23)
}
#[inline(always)]
pub fn atosel7(&mut self) -> ATOSEL7_W<ATCR2rs> {
ATOSEL7_W::new(self, 26)
}
#[inline(always)]
pub fn atosel8(&mut self) -> ATOSEL8_W<ATCR2rs> {
ATOSEL8_W::new(self, 29)
}
}
pub struct ATCR2rs;
impl crate::RegisterSpec for ATCR2rs {
type Ux = u32;
}
impl crate::Readable for ATCR2rs {}
impl crate::Writable for ATCR2rs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for ATCR2rs {}