bl702_pac/ef_ctrl/
ef_if_0_manual.rs

1#[doc = "Register `ef_if_0_manual` reader"]
2pub struct R(crate::R<EF_IF_0_MANUAL_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<EF_IF_0_MANUAL_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<EF_IF_0_MANUAL_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<EF_IF_0_MANUAL_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `ef_if_0_manual` writer"]
17pub struct W(crate::W<EF_IF_0_MANUAL_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<EF_IF_0_MANUAL_SPEC>;
20    #[inline(always)]
21    fn deref(&self) -> &Self::Target {
22        &self.0
23    }
24}
25impl core::ops::DerefMut for W {
26    #[inline(always)]
27    fn deref_mut(&mut self) -> &mut Self::Target {
28        &mut self.0
29    }
30}
31impl From<crate::W<EF_IF_0_MANUAL_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<EF_IF_0_MANUAL_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `ef_if_a` reader - "]
38pub type EF_IF_A_R = crate::FieldReader<u16, u16>;
39#[doc = "Field `ef_if_a` writer - "]
40pub type EF_IF_A_W<'a, const O: u8> =
41    crate::FieldWriter<'a, u32, EF_IF_0_MANUAL_SPEC, u16, u16, 10, O>;
42#[doc = "Field `ef_if_pd` reader - "]
43pub type EF_IF_PD_R = crate::BitReader<bool>;
44#[doc = "Field `ef_if_pd` writer - "]
45pub type EF_IF_PD_W<'a, const O: u8> = crate::BitWriter<'a, u32, EF_IF_0_MANUAL_SPEC, bool, O>;
46#[doc = "Field `ef_if_ps` reader - "]
47pub type EF_IF_PS_R = crate::BitReader<bool>;
48#[doc = "Field `ef_if_ps` writer - "]
49pub type EF_IF_PS_W<'a, const O: u8> = crate::BitWriter<'a, u32, EF_IF_0_MANUAL_SPEC, bool, O>;
50#[doc = "Field `ef_if_strobe` reader - "]
51pub type EF_IF_STROBE_R = crate::BitReader<bool>;
52#[doc = "Field `ef_if_strobe` writer - "]
53pub type EF_IF_STROBE_W<'a, const O: u8> = crate::BitWriter<'a, u32, EF_IF_0_MANUAL_SPEC, bool, O>;
54#[doc = "Field `ef_if_pgenb` reader - "]
55pub type EF_IF_PGENB_R = crate::BitReader<bool>;
56#[doc = "Field `ef_if_pgenb` writer - "]
57pub type EF_IF_PGENB_W<'a, const O: u8> = crate::BitWriter<'a, u32, EF_IF_0_MANUAL_SPEC, bool, O>;
58#[doc = "Field `ef_if_load` reader - "]
59pub type EF_IF_LOAD_R = crate::BitReader<bool>;
60#[doc = "Field `ef_if_load` writer - "]
61pub type EF_IF_LOAD_W<'a, const O: u8> = crate::BitWriter<'a, u32, EF_IF_0_MANUAL_SPEC, bool, O>;
62#[doc = "Field `ef_if_csb` reader - "]
63pub type EF_IF_CSB_R = crate::BitReader<bool>;
64#[doc = "Field `ef_if_csb` writer - "]
65pub type EF_IF_CSB_W<'a, const O: u8> = crate::BitWriter<'a, u32, EF_IF_0_MANUAL_SPEC, bool, O>;
66#[doc = "Field `ef_if_0_q` reader - "]
67pub type EF_IF_0_Q_R = crate::FieldReader<u8, u8>;
68#[doc = "Field `ef_if_0_q` writer - "]
69pub type EF_IF_0_Q_W<'a, const O: u8> =
70    crate::FieldWriter<'a, u32, EF_IF_0_MANUAL_SPEC, u8, u8, 8, O>;
71#[doc = "Field `ef_if_prot_code_manual` reader - "]
72pub type EF_IF_PROT_CODE_MANUAL_R = crate::FieldReader<u8, u8>;
73#[doc = "Field `ef_if_prot_code_manual` writer - "]
74pub type EF_IF_PROT_CODE_MANUAL_W<'a, const O: u8> =
75    crate::FieldWriter<'a, u32, EF_IF_0_MANUAL_SPEC, u8, u8, 8, O>;
76impl R {
77    #[doc = "Bits 0:9"]
78    #[inline(always)]
79    pub fn ef_if_a(&self) -> EF_IF_A_R {
80        EF_IF_A_R::new((self.bits & 0x03ff) as u16)
81    }
82    #[doc = "Bit 10"]
83    #[inline(always)]
84    pub fn ef_if_pd(&self) -> EF_IF_PD_R {
85        EF_IF_PD_R::new(((self.bits >> 10) & 1) != 0)
86    }
87    #[doc = "Bit 11"]
88    #[inline(always)]
89    pub fn ef_if_ps(&self) -> EF_IF_PS_R {
90        EF_IF_PS_R::new(((self.bits >> 11) & 1) != 0)
91    }
92    #[doc = "Bit 12"]
93    #[inline(always)]
94    pub fn ef_if_strobe(&self) -> EF_IF_STROBE_R {
95        EF_IF_STROBE_R::new(((self.bits >> 12) & 1) != 0)
96    }
97    #[doc = "Bit 13"]
98    #[inline(always)]
99    pub fn ef_if_pgenb(&self) -> EF_IF_PGENB_R {
100        EF_IF_PGENB_R::new(((self.bits >> 13) & 1) != 0)
101    }
102    #[doc = "Bit 14"]
103    #[inline(always)]
104    pub fn ef_if_load(&self) -> EF_IF_LOAD_R {
105        EF_IF_LOAD_R::new(((self.bits >> 14) & 1) != 0)
106    }
107    #[doc = "Bit 15"]
108    #[inline(always)]
109    pub fn ef_if_csb(&self) -> EF_IF_CSB_R {
110        EF_IF_CSB_R::new(((self.bits >> 15) & 1) != 0)
111    }
112    #[doc = "Bits 16:23"]
113    #[inline(always)]
114    pub fn ef_if_0_q(&self) -> EF_IF_0_Q_R {
115        EF_IF_0_Q_R::new(((self.bits >> 16) & 0xff) as u8)
116    }
117    #[doc = "Bits 24:31"]
118    #[inline(always)]
119    pub fn ef_if_prot_code_manual(&self) -> EF_IF_PROT_CODE_MANUAL_R {
120        EF_IF_PROT_CODE_MANUAL_R::new(((self.bits >> 24) & 0xff) as u8)
121    }
122}
123impl W {
124    #[doc = "Bits 0:9"]
125    #[inline(always)]
126    #[must_use]
127    pub fn ef_if_a(&mut self) -> EF_IF_A_W<0> {
128        EF_IF_A_W::new(self)
129    }
130    #[doc = "Bit 10"]
131    #[inline(always)]
132    #[must_use]
133    pub fn ef_if_pd(&mut self) -> EF_IF_PD_W<10> {
134        EF_IF_PD_W::new(self)
135    }
136    #[doc = "Bit 11"]
137    #[inline(always)]
138    #[must_use]
139    pub fn ef_if_ps(&mut self) -> EF_IF_PS_W<11> {
140        EF_IF_PS_W::new(self)
141    }
142    #[doc = "Bit 12"]
143    #[inline(always)]
144    #[must_use]
145    pub fn ef_if_strobe(&mut self) -> EF_IF_STROBE_W<12> {
146        EF_IF_STROBE_W::new(self)
147    }
148    #[doc = "Bit 13"]
149    #[inline(always)]
150    #[must_use]
151    pub fn ef_if_pgenb(&mut self) -> EF_IF_PGENB_W<13> {
152        EF_IF_PGENB_W::new(self)
153    }
154    #[doc = "Bit 14"]
155    #[inline(always)]
156    #[must_use]
157    pub fn ef_if_load(&mut self) -> EF_IF_LOAD_W<14> {
158        EF_IF_LOAD_W::new(self)
159    }
160    #[doc = "Bit 15"]
161    #[inline(always)]
162    #[must_use]
163    pub fn ef_if_csb(&mut self) -> EF_IF_CSB_W<15> {
164        EF_IF_CSB_W::new(self)
165    }
166    #[doc = "Bits 16:23"]
167    #[inline(always)]
168    #[must_use]
169    pub fn ef_if_0_q(&mut self) -> EF_IF_0_Q_W<16> {
170        EF_IF_0_Q_W::new(self)
171    }
172    #[doc = "Bits 24:31"]
173    #[inline(always)]
174    #[must_use]
175    pub fn ef_if_prot_code_manual(&mut self) -> EF_IF_PROT_CODE_MANUAL_W<24> {
176        EF_IF_PROT_CODE_MANUAL_W::new(self)
177    }
178    #[doc = "Writes raw bits to the register."]
179    #[inline(always)]
180    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
181        self.0.bits(bits);
182        self
183    }
184}
185#[doc = "ef_if_0_manual.\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [ef_if_0_manual](index.html) module"]
186pub struct EF_IF_0_MANUAL_SPEC;
187impl crate::RegisterSpec for EF_IF_0_MANUAL_SPEC {
188    type Ux = u32;
189}
190#[doc = "`read()` method returns [ef_if_0_manual::R](R) reader structure"]
191impl crate::Readable for EF_IF_0_MANUAL_SPEC {
192    type Reader = R;
193}
194#[doc = "`write(|w| ..)` method takes [ef_if_0_manual::W](W) writer structure"]
195impl crate::Writable for EF_IF_0_MANUAL_SPEC {
196    type Writer = W;
197    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
198    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
199}
200#[doc = "`reset()` method sets ef_if_0_manual to value 0"]
201impl crate::Resettable for EF_IF_0_MANUAL_SPEC {
202    const RESET_VALUE: Self::Ux = 0;
203}