esp32/sens/
sar_touch_out1.rs1#[doc = "Register `SAR_TOUCH_OUT1` reader"]
2pub type R = crate::R<SAR_TOUCH_OUT1_SPEC>;
3#[doc = "Field `TOUCH_MEAS_OUT1` reader - the counter for touch pad 1"]
4pub type TOUCH_MEAS_OUT1_R = crate::FieldReader<u16>;
5#[doc = "Field `TOUCH_MEAS_OUT0` reader - the counter for touch pad 0"]
6pub type TOUCH_MEAS_OUT0_R = crate::FieldReader<u16>;
7impl R {
8 #[doc = "Bits 0:15 - the counter for touch pad 1"]
9 #[inline(always)]
10 pub fn touch_meas_out1(&self) -> TOUCH_MEAS_OUT1_R {
11 TOUCH_MEAS_OUT1_R::new((self.bits & 0xffff) as u16)
12 }
13 #[doc = "Bits 16:31 - the counter for touch pad 0"]
14 #[inline(always)]
15 pub fn touch_meas_out0(&self) -> TOUCH_MEAS_OUT0_R {
16 TOUCH_MEAS_OUT0_R::new(((self.bits >> 16) & 0xffff) as u16)
17 }
18}
19#[cfg(feature = "impl-register-debug")]
20impl core::fmt::Debug for R {
21 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
22 f.debug_struct("SAR_TOUCH_OUT1")
23 .field("touch_meas_out1", &self.touch_meas_out1())
24 .field("touch_meas_out0", &self.touch_meas_out0())
25 .finish()
26 }
27}
28#[doc = "\n\nYou can [`read`](crate::Reg::read) this register and get [`sar_touch_out1::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
29pub struct SAR_TOUCH_OUT1_SPEC;
30impl crate::RegisterSpec for SAR_TOUCH_OUT1_SPEC {
31 type Ux = u32;
32}
33#[doc = "`read()` method returns [`sar_touch_out1::R`](R) reader structure"]
34impl crate::Readable for SAR_TOUCH_OUT1_SPEC {}
35#[doc = "`reset()` method sets SAR_TOUCH_OUT1 to value 0"]
36impl crate::Resettable for SAR_TOUCH_OUT1_SPEC {
37 const RESET_VALUE: u32 = 0;
38}