#[doc = "Register `PAD_HOLD` reader"]
pub type R = crate::R<PAD_HOLD_SPEC>;
#[doc = "Register `PAD_HOLD` writer"]
pub type W = crate::W<PAD_HOLD_SPEC>;
#[doc = "Field `TOUCH_PAD0` reader - hold rtc pad0"]
pub type TOUCH_PAD0_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD0` writer - hold rtc pad0"]
pub type TOUCH_PAD0_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD1` reader - hold rtc pad-1"]
pub type TOUCH_PAD1_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD1` writer - hold rtc pad-1"]
pub type TOUCH_PAD1_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD2` reader - hold rtc pad-2"]
pub type TOUCH_PAD2_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD2` writer - hold rtc pad-2"]
pub type TOUCH_PAD2_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD3` reader - hold rtc pad-3"]
pub type TOUCH_PAD3_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD3` writer - hold rtc pad-3"]
pub type TOUCH_PAD3_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD4` reader - hold rtc pad-4"]
pub type TOUCH_PAD4_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD4` writer - hold rtc pad-4"]
pub type TOUCH_PAD4_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD5` reader - hold rtc pad-5"]
pub type TOUCH_PAD5_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD5` writer - hold rtc pad-5"]
pub type TOUCH_PAD5_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD6` reader - hold rtc pad-6"]
pub type TOUCH_PAD6_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD6` writer - hold rtc pad-6"]
pub type TOUCH_PAD6_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD7` reader - hold rtc pad-7"]
pub type TOUCH_PAD7_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD7` writer - hold rtc pad-7"]
pub type TOUCH_PAD7_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD8` reader - hold rtc pad-8"]
pub type TOUCH_PAD8_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD8` writer - hold rtc pad-8"]
pub type TOUCH_PAD8_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD9` reader - hold rtc pad-9"]
pub type TOUCH_PAD9_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD9` writer - hold rtc pad-9"]
pub type TOUCH_PAD9_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD10` reader - hold rtc pad-10"]
pub type TOUCH_PAD10_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD10` writer - hold rtc pad-10"]
pub type TOUCH_PAD10_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD11` reader - hold rtc pad-11"]
pub type TOUCH_PAD11_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD11` writer - hold rtc pad-11"]
pub type TOUCH_PAD11_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD12` reader - hold rtc pad-12"]
pub type TOUCH_PAD12_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD12` writer - hold rtc pad-12"]
pub type TOUCH_PAD12_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD13` reader - hold rtc pad-13"]
pub type TOUCH_PAD13_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD13` writer - hold rtc pad-13"]
pub type TOUCH_PAD13_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `TOUCH_PAD14` reader - hold rtc pad-14"]
pub type TOUCH_PAD14_R = crate::BitReader;
#[doc = "Field `TOUCH_PAD14` writer - hold rtc pad-14"]
pub type TOUCH_PAD14_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `X32P` reader - hold rtc pad-15"]
pub type X32P_R = crate::BitReader;
#[doc = "Field `X32P` writer - hold rtc pad-15"]
pub type X32P_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `X32N` reader - hold rtc pad-16"]
pub type X32N_R = crate::BitReader;
#[doc = "Field `X32N` writer - hold rtc pad-16"]
pub type X32N_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `PDAC1` reader - hold rtc pad-17"]
pub type PDAC1_R = crate::BitReader;
#[doc = "Field `PDAC1` writer - hold rtc pad-17"]
pub type PDAC1_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `PDAC2` reader - hold rtc pad-18"]
pub type PDAC2_R = crate::BitReader;
#[doc = "Field `PDAC2` writer - hold rtc pad-18"]
pub type PDAC2_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `PAD19` reader - hold rtc pad-19"]
pub type PAD19_R = crate::BitReader;
#[doc = "Field `PAD19` writer - hold rtc pad-19"]
pub type PAD19_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `PAD20` reader - hold rtc pad-20"]
pub type PAD20_R = crate::BitReader;
#[doc = "Field `PAD20` writer - hold rtc pad-20"]
pub type PAD20_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `PAD21` reader - hold rtc pad-21"]
pub type PAD21_R = crate::BitReader;
#[doc = "Field `PAD21` writer - hold rtc pad-21"]
pub type PAD21_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
#[doc = "Bit 0 - hold rtc pad0"]
#[inline(always)]
pub fn touch_pad0(&self) -> TOUCH_PAD0_R {
TOUCH_PAD0_R::new((self.bits & 1) != 0)
}
#[doc = "Bit 1 - hold rtc pad-1"]
#[inline(always)]
pub fn touch_pad1(&self) -> TOUCH_PAD1_R {
TOUCH_PAD1_R::new(((self.bits >> 1) & 1) != 0)
}
#[doc = "Bit 2 - hold rtc pad-2"]
#[inline(always)]
pub fn touch_pad2(&self) -> TOUCH_PAD2_R {
TOUCH_PAD2_R::new(((self.bits >> 2) & 1) != 0)
}
#[doc = "Bit 3 - hold rtc pad-3"]
#[inline(always)]
pub fn touch_pad3(&self) -> TOUCH_PAD3_R {
TOUCH_PAD3_R::new(((self.bits >> 3) & 1) != 0)
}
#[doc = "Bit 4 - hold rtc pad-4"]
#[inline(always)]
pub fn touch_pad4(&self) -> TOUCH_PAD4_R {
TOUCH_PAD4_R::new(((self.bits >> 4) & 1) != 0)
}
#[doc = "Bit 5 - hold rtc pad-5"]
#[inline(always)]
pub fn touch_pad5(&self) -> TOUCH_PAD5_R {
TOUCH_PAD5_R::new(((self.bits >> 5) & 1) != 0)
}
#[doc = "Bit 6 - hold rtc pad-6"]
#[inline(always)]
pub fn touch_pad6(&self) -> TOUCH_PAD6_R {
TOUCH_PAD6_R::new(((self.bits >> 6) & 1) != 0)
}
#[doc = "Bit 7 - hold rtc pad-7"]
#[inline(always)]
pub fn touch_pad7(&self) -> TOUCH_PAD7_R {
TOUCH_PAD7_R::new(((self.bits >> 7) & 1) != 0)
}
#[doc = "Bit 8 - hold rtc pad-8"]
#[inline(always)]
pub fn touch_pad8(&self) -> TOUCH_PAD8_R {
TOUCH_PAD8_R::new(((self.bits >> 8) & 1) != 0)
}
#[doc = "Bit 9 - hold rtc pad-9"]
#[inline(always)]
pub fn touch_pad9(&self) -> TOUCH_PAD9_R {
TOUCH_PAD9_R::new(((self.bits >> 9) & 1) != 0)
}
#[doc = "Bit 10 - hold rtc pad-10"]
#[inline(always)]
pub fn touch_pad10(&self) -> TOUCH_PAD10_R {
TOUCH_PAD10_R::new(((self.bits >> 10) & 1) != 0)
}
#[doc = "Bit 11 - hold rtc pad-11"]
#[inline(always)]
pub fn touch_pad11(&self) -> TOUCH_PAD11_R {
TOUCH_PAD11_R::new(((self.bits >> 11) & 1) != 0)
}
#[doc = "Bit 12 - hold rtc pad-12"]
#[inline(always)]
pub fn touch_pad12(&self) -> TOUCH_PAD12_R {
TOUCH_PAD12_R::new(((self.bits >> 12) & 1) != 0)
}
#[doc = "Bit 13 - hold rtc pad-13"]
#[inline(always)]
pub fn touch_pad13(&self) -> TOUCH_PAD13_R {
TOUCH_PAD13_R::new(((self.bits >> 13) & 1) != 0)
}
#[doc = "Bit 14 - hold rtc pad-14"]
#[inline(always)]
pub fn touch_pad14(&self) -> TOUCH_PAD14_R {
TOUCH_PAD14_R::new(((self.bits >> 14) & 1) != 0)
}
#[doc = "Bit 15 - hold rtc pad-15"]
#[inline(always)]
pub fn x32p(&self) -> X32P_R {
X32P_R::new(((self.bits >> 15) & 1) != 0)
}
#[doc = "Bit 16 - hold rtc pad-16"]
#[inline(always)]
pub fn x32n(&self) -> X32N_R {
X32N_R::new(((self.bits >> 16) & 1) != 0)
}
#[doc = "Bit 17 - hold rtc pad-17"]
#[inline(always)]
pub fn pdac1(&self) -> PDAC1_R {
PDAC1_R::new(((self.bits >> 17) & 1) != 0)
}
#[doc = "Bit 18 - hold rtc pad-18"]
#[inline(always)]
pub fn pdac2(&self) -> PDAC2_R {
PDAC2_R::new(((self.bits >> 18) & 1) != 0)
}
#[doc = "Bit 19 - hold rtc pad-19"]
#[inline(always)]
pub fn pad19(&self) -> PAD19_R {
PAD19_R::new(((self.bits >> 19) & 1) != 0)
}
#[doc = "Bit 20 - hold rtc pad-20"]
#[inline(always)]
pub fn pad20(&self) -> PAD20_R {
PAD20_R::new(((self.bits >> 20) & 1) != 0)
}
#[doc = "Bit 21 - hold rtc pad-21"]
#[inline(always)]
pub fn pad21(&self) -> PAD21_R {
PAD21_R::new(((self.bits >> 21) & 1) != 0)
}
}
#[cfg(feature = "impl-register-debug")]
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("PAD_HOLD")
.field("touch_pad0", &self.touch_pad0())
.field("touch_pad1", &self.touch_pad1())
.field("touch_pad2", &self.touch_pad2())
.field("touch_pad3", &self.touch_pad3())
.field("touch_pad4", &self.touch_pad4())
.field("touch_pad5", &self.touch_pad5())
.field("touch_pad6", &self.touch_pad6())
.field("touch_pad7", &self.touch_pad7())
.field("touch_pad8", &self.touch_pad8())
.field("touch_pad9", &self.touch_pad9())
.field("touch_pad10", &self.touch_pad10())
.field("touch_pad11", &self.touch_pad11())
.field("touch_pad12", &self.touch_pad12())
.field("touch_pad13", &self.touch_pad13())
.field("touch_pad14", &self.touch_pad14())
.field("x32p", &self.x32p())
.field("x32n", &self.x32n())
.field("pdac1", &self.pdac1())
.field("pdac2", &self.pdac2())
.field("pad19", &self.pad19())
.field("pad20", &self.pad20())
.field("pad21", &self.pad21())
.finish()
}
}
impl W {
#[doc = "Bit 0 - hold rtc pad0"]
#[inline(always)]
pub fn touch_pad0(&mut self) -> TOUCH_PAD0_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD0_W::new(self, 0)
}
#[doc = "Bit 1 - hold rtc pad-1"]
#[inline(always)]
pub fn touch_pad1(&mut self) -> TOUCH_PAD1_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD1_W::new(self, 1)
}
#[doc = "Bit 2 - hold rtc pad-2"]
#[inline(always)]
pub fn touch_pad2(&mut self) -> TOUCH_PAD2_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD2_W::new(self, 2)
}
#[doc = "Bit 3 - hold rtc pad-3"]
#[inline(always)]
pub fn touch_pad3(&mut self) -> TOUCH_PAD3_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD3_W::new(self, 3)
}
#[doc = "Bit 4 - hold rtc pad-4"]
#[inline(always)]
pub fn touch_pad4(&mut self) -> TOUCH_PAD4_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD4_W::new(self, 4)
}
#[doc = "Bit 5 - hold rtc pad-5"]
#[inline(always)]
pub fn touch_pad5(&mut self) -> TOUCH_PAD5_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD5_W::new(self, 5)
}
#[doc = "Bit 6 - hold rtc pad-6"]
#[inline(always)]
pub fn touch_pad6(&mut self) -> TOUCH_PAD6_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD6_W::new(self, 6)
}
#[doc = "Bit 7 - hold rtc pad-7"]
#[inline(always)]
pub fn touch_pad7(&mut self) -> TOUCH_PAD7_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD7_W::new(self, 7)
}
#[doc = "Bit 8 - hold rtc pad-8"]
#[inline(always)]
pub fn touch_pad8(&mut self) -> TOUCH_PAD8_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD8_W::new(self, 8)
}
#[doc = "Bit 9 - hold rtc pad-9"]
#[inline(always)]
pub fn touch_pad9(&mut self) -> TOUCH_PAD9_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD9_W::new(self, 9)
}
#[doc = "Bit 10 - hold rtc pad-10"]
#[inline(always)]
pub fn touch_pad10(&mut self) -> TOUCH_PAD10_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD10_W::new(self, 10)
}
#[doc = "Bit 11 - hold rtc pad-11"]
#[inline(always)]
pub fn touch_pad11(&mut self) -> TOUCH_PAD11_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD11_W::new(self, 11)
}
#[doc = "Bit 12 - hold rtc pad-12"]
#[inline(always)]
pub fn touch_pad12(&mut self) -> TOUCH_PAD12_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD12_W::new(self, 12)
}
#[doc = "Bit 13 - hold rtc pad-13"]
#[inline(always)]
pub fn touch_pad13(&mut self) -> TOUCH_PAD13_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD13_W::new(self, 13)
}
#[doc = "Bit 14 - hold rtc pad-14"]
#[inline(always)]
pub fn touch_pad14(&mut self) -> TOUCH_PAD14_W<'_, PAD_HOLD_SPEC> {
TOUCH_PAD14_W::new(self, 14)
}
#[doc = "Bit 15 - hold rtc pad-15"]
#[inline(always)]
pub fn x32p(&mut self) -> X32P_W<'_, PAD_HOLD_SPEC> {
X32P_W::new(self, 15)
}
#[doc = "Bit 16 - hold rtc pad-16"]
#[inline(always)]
pub fn x32n(&mut self) -> X32N_W<'_, PAD_HOLD_SPEC> {
X32N_W::new(self, 16)
}
#[doc = "Bit 17 - hold rtc pad-17"]
#[inline(always)]
pub fn pdac1(&mut self) -> PDAC1_W<'_, PAD_HOLD_SPEC> {
PDAC1_W::new(self, 17)
}
#[doc = "Bit 18 - hold rtc pad-18"]
#[inline(always)]
pub fn pdac2(&mut self) -> PDAC2_W<'_, PAD_HOLD_SPEC> {
PDAC2_W::new(self, 18)
}
#[doc = "Bit 19 - hold rtc pad-19"]
#[inline(always)]
pub fn pad19(&mut self) -> PAD19_W<'_, PAD_HOLD_SPEC> {
PAD19_W::new(self, 19)
}
#[doc = "Bit 20 - hold rtc pad-20"]
#[inline(always)]
pub fn pad20(&mut self) -> PAD20_W<'_, PAD_HOLD_SPEC> {
PAD20_W::new(self, 20)
}
#[doc = "Bit 21 - hold rtc pad-21"]
#[inline(always)]
pub fn pad21(&mut self) -> PAD21_W<'_, PAD_HOLD_SPEC> {
PAD21_W::new(self, 21)
}
}
#[doc = "rtc pad hold configure\n\nYou can [`read`](crate::Reg::read) this register and get [`pad_hold::R`](R). You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`pad_hold::W`](W). You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
pub struct PAD_HOLD_SPEC;
impl crate::RegisterSpec for PAD_HOLD_SPEC {
type Ux = u32;
}
#[doc = "`read()` method returns [`pad_hold::R`](R) reader structure"]
impl crate::Readable for PAD_HOLD_SPEC {}
#[doc = "`write(|w| ..)` method takes [`pad_hold::W`](W) writer structure"]
impl crate::Writable for PAD_HOLD_SPEC {
type Safety = crate::Unsafe;
}
#[doc = "`reset()` method sets PAD_HOLD to value 0"]
impl crate::Resettable for PAD_HOLD_SPEC {}