atsam4ls8b_pac/pm/
config.rs

1#[doc = "Register `CONFIG` reader"]
2pub struct R(crate::R<CONFIG_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<CONFIG_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<CONFIG_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<CONFIG_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Field `PBA` reader - APBA Implemented"]
17pub type PBA_R = crate::BitReader<bool>;
18#[doc = "Field `PBB` reader - APBB Implemented"]
19pub type PBB_R = crate::BitReader<bool>;
20#[doc = "Field `PBC` reader - APBC Implemented"]
21pub type PBC_R = crate::BitReader<bool>;
22#[doc = "Field `PBD` reader - APBD Implemented"]
23pub type PBD_R = crate::BitReader<bool>;
24#[doc = "Field `HSBPEVC` reader - HSB PEVC Clock Implemented"]
25pub type HSBPEVC_R = crate::BitReader<bool>;
26impl R {
27    #[doc = "Bit 0 - APBA Implemented"]
28    #[inline(always)]
29    pub fn pba(&self) -> PBA_R {
30        PBA_R::new((self.bits & 1) != 0)
31    }
32    #[doc = "Bit 1 - APBB Implemented"]
33    #[inline(always)]
34    pub fn pbb(&self) -> PBB_R {
35        PBB_R::new(((self.bits >> 1) & 1) != 0)
36    }
37    #[doc = "Bit 2 - APBC Implemented"]
38    #[inline(always)]
39    pub fn pbc(&self) -> PBC_R {
40        PBC_R::new(((self.bits >> 2) & 1) != 0)
41    }
42    #[doc = "Bit 3 - APBD Implemented"]
43    #[inline(always)]
44    pub fn pbd(&self) -> PBD_R {
45        PBD_R::new(((self.bits >> 3) & 1) != 0)
46    }
47    #[doc = "Bit 7 - HSB PEVC Clock Implemented"]
48    #[inline(always)]
49    pub fn hsbpevc(&self) -> HSBPEVC_R {
50        HSBPEVC_R::new(((self.bits >> 7) & 1) != 0)
51    }
52}
53#[doc = "Configuration 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 [config](index.html) module"]
54pub struct CONFIG_SPEC;
55impl crate::RegisterSpec for CONFIG_SPEC {
56    type Ux = u32;
57}
58#[doc = "`read()` method returns [config::R](R) reader structure"]
59impl crate::Readable for CONFIG_SPEC {
60    type Reader = R;
61}
62#[doc = "`reset()` method sets CONFIG to value 0x0f"]
63impl crate::Resettable for CONFIG_SPEC {
64    const RESET_VALUE: Self::Ux = 0x0f;
65}