xmc4700/rtc/
stssr.rs

1#[doc = "Register `STSSR` reader"]
2pub type R = crate::R<STSSR_SPEC>;
3#[doc = "Field `SPSE` reader - Periodic Seconds Service Request Status after Masking"]
4pub type SPSE_R = crate::BitReader;
5#[doc = "Field `SPMI` reader - Periodic Minutes Service Request Status after Masking"]
6pub type SPMI_R = crate::BitReader;
7#[doc = "Field `SPHO` reader - Periodic Hours Service Request Status after Masking"]
8pub type SPHO_R = crate::BitReader;
9#[doc = "Field `SPDA` reader - Periodic Days Service Request Status after Masking"]
10pub type SPDA_R = crate::BitReader;
11#[doc = "Field `SPMO` reader - Periodic Months Service Request Status after Masking"]
12pub type SPMO_R = crate::BitReader;
13#[doc = "Field `SPYE` reader - Periodic Years Service Request Status after Masking"]
14pub type SPYE_R = crate::BitReader;
15#[doc = "Field `SAI` reader - Alarm Service Request Status after Masking"]
16pub type SAI_R = crate::BitReader;
17impl R {
18    #[doc = "Bit 0 - Periodic Seconds Service Request Status after Masking"]
19    #[inline(always)]
20    pub fn spse(&self) -> SPSE_R {
21        SPSE_R::new((self.bits & 1) != 0)
22    }
23    #[doc = "Bit 1 - Periodic Minutes Service Request Status after Masking"]
24    #[inline(always)]
25    pub fn spmi(&self) -> SPMI_R {
26        SPMI_R::new(((self.bits >> 1) & 1) != 0)
27    }
28    #[doc = "Bit 2 - Periodic Hours Service Request Status after Masking"]
29    #[inline(always)]
30    pub fn spho(&self) -> SPHO_R {
31        SPHO_R::new(((self.bits >> 2) & 1) != 0)
32    }
33    #[doc = "Bit 3 - Periodic Days Service Request Status after Masking"]
34    #[inline(always)]
35    pub fn spda(&self) -> SPDA_R {
36        SPDA_R::new(((self.bits >> 3) & 1) != 0)
37    }
38    #[doc = "Bit 5 - Periodic Months Service Request Status after Masking"]
39    #[inline(always)]
40    pub fn spmo(&self) -> SPMO_R {
41        SPMO_R::new(((self.bits >> 5) & 1) != 0)
42    }
43    #[doc = "Bit 6 - Periodic Years Service Request Status after Masking"]
44    #[inline(always)]
45    pub fn spye(&self) -> SPYE_R {
46        SPYE_R::new(((self.bits >> 6) & 1) != 0)
47    }
48    #[doc = "Bit 8 - Alarm Service Request Status after Masking"]
49    #[inline(always)]
50    pub fn sai(&self) -> SAI_R {
51        SAI_R::new(((self.bits >> 8) & 1) != 0)
52    }
53}
54#[doc = "RTC Service Request Status Register\n\nYou can [`read`](crate::Reg::read) this register and get [`stssr::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
55pub struct STSSR_SPEC;
56impl crate::RegisterSpec for STSSR_SPEC {
57    type Ux = u32;
58}
59#[doc = "`read()` method returns [`stssr::R`](R) reader structure"]
60impl crate::Readable for STSSR_SPEC {}
61#[doc = "`reset()` method sets STSSR to value 0"]
62impl crate::Resettable for STSSR_SPEC {
63    const RESET_VALUE: u32 = 0;
64}