efm32pg1b200_pac/i2c0/
rxdoublep.rs

1#[doc = "Register `RXDOUBLEP` reader"]
2pub struct R(crate::R<RXDOUBLEP_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<RXDOUBLEP_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<RXDOUBLEP_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<RXDOUBLEP_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Field `RXDATAP0` reader - RX Data 0 Peek"]
17pub type RXDATAP0_R = crate::FieldReader<u8, u8>;
18#[doc = "Field `RXDATAP1` reader - RX Data 1 Peek"]
19pub type RXDATAP1_R = crate::FieldReader<u8, u8>;
20impl R {
21    #[doc = "Bits 0:7 - RX Data 0 Peek"]
22    #[inline(always)]
23    pub fn rxdatap0(&self) -> RXDATAP0_R {
24        RXDATAP0_R::new((self.bits & 0xff) as u8)
25    }
26    #[doc = "Bits 8:15 - RX Data 1 Peek"]
27    #[inline(always)]
28    pub fn rxdatap1(&self) -> RXDATAP1_R {
29        RXDATAP1_R::new(((self.bits >> 8) & 0xff) as u8)
30    }
31}
32#[doc = "Receive Buffer Double Data Peek Register\n\nThis register you can [`read`](crate::generic::Reg::read). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [rxdoublep](index.html) module"]
33pub struct RXDOUBLEP_SPEC;
34impl crate::RegisterSpec for RXDOUBLEP_SPEC {
35    type Ux = u32;
36}
37#[doc = "`read()` method returns [rxdoublep::R](R) reader structure"]
38impl crate::Readable for RXDOUBLEP_SPEC {
39    type Reader = R;
40}
41#[doc = "`reset()` method sets RXDOUBLEP to value 0"]
42impl crate::Resettable for RXDOUBLEP_SPEC {
43    #[inline(always)]
44    fn reset_value() -> Self::Ux {
45        0
46    }
47}