bl702_pac/sec_eng/
se_ctrl_prot_rd.rs

1#[doc = "Register `se_ctrl_prot_rd` reader"]
2pub struct R(crate::R<SE_CTRL_PROT_RD_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<SE_CTRL_PROT_RD_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<SE_CTRL_PROT_RD_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<SE_CTRL_PROT_RD_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `se_ctrl_prot_rd` writer"]
17pub struct W(crate::W<SE_CTRL_PROT_RD_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<SE_CTRL_PROT_RD_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<SE_CTRL_PROT_RD_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<SE_CTRL_PROT_RD_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `se_sha_prot_en_rd` reader - "]
38pub type SE_SHA_PROT_EN_RD_R = crate::BitReader<bool>;
39#[doc = "Field `se_sha_prot_en_rd` writer - "]
40pub type SE_SHA_PROT_EN_RD_W<'a, const O: u8> =
41    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
42#[doc = "Field `se_sha_id0_en_rd` reader - "]
43pub type SE_SHA_ID0_EN_RD_R = crate::BitReader<bool>;
44#[doc = "Field `se_sha_id0_en_rd` writer - "]
45pub type SE_SHA_ID0_EN_RD_W<'a, const O: u8> =
46    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
47#[doc = "Field `se_sha_id1_en_rd` reader - "]
48pub type SE_SHA_ID1_EN_RD_R = crate::BitReader<bool>;
49#[doc = "Field `se_sha_id1_en_rd` writer - "]
50pub type SE_SHA_ID1_EN_RD_W<'a, const O: u8> =
51    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
52#[doc = "Field `se_aes_prot_en_rd` reader - "]
53pub type SE_AES_PROT_EN_RD_R = crate::BitReader<bool>;
54#[doc = "Field `se_aes_prot_en_rd` writer - "]
55pub type SE_AES_PROT_EN_RD_W<'a, const O: u8> =
56    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
57#[doc = "Field `se_aes_id0_en_rd` reader - "]
58pub type SE_AES_ID0_EN_RD_R = crate::BitReader<bool>;
59#[doc = "Field `se_aes_id0_en_rd` writer - "]
60pub type SE_AES_ID0_EN_RD_W<'a, const O: u8> =
61    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
62#[doc = "Field `se_aes_id1_en_rd` reader - "]
63pub type SE_AES_ID1_EN_RD_R = crate::BitReader<bool>;
64#[doc = "Field `se_aes_id1_en_rd` writer - "]
65pub type SE_AES_ID1_EN_RD_W<'a, const O: u8> =
66    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
67#[doc = "Field `se_trng_prot_en_rd` reader - "]
68pub type SE_TRNG_PROT_EN_RD_R = crate::BitReader<bool>;
69#[doc = "Field `se_trng_prot_en_rd` writer - "]
70pub type SE_TRNG_PROT_EN_RD_W<'a, const O: u8> =
71    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
72#[doc = "Field `se_trng_id0_en_rd` reader - "]
73pub type SE_TRNG_ID0_EN_RD_R = crate::BitReader<bool>;
74#[doc = "Field `se_trng_id0_en_rd` writer - "]
75pub type SE_TRNG_ID0_EN_RD_W<'a, const O: u8> =
76    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
77#[doc = "Field `se_trng_id1_en_rd` reader - "]
78pub type SE_TRNG_ID1_EN_RD_R = crate::BitReader<bool>;
79#[doc = "Field `se_trng_id1_en_rd` writer - "]
80pub type SE_TRNG_ID1_EN_RD_W<'a, const O: u8> =
81    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
82#[doc = "Field `se_pka_prot_en_rd` reader - "]
83pub type SE_PKA_PROT_EN_RD_R = crate::BitReader<bool>;
84#[doc = "Field `se_pka_prot_en_rd` writer - "]
85pub type SE_PKA_PROT_EN_RD_W<'a, const O: u8> =
86    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
87#[doc = "Field `se_pka_id0_en_rd` reader - "]
88pub type SE_PKA_ID0_EN_RD_R = crate::BitReader<bool>;
89#[doc = "Field `se_pka_id0_en_rd` writer - "]
90pub type SE_PKA_ID0_EN_RD_W<'a, const O: u8> =
91    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
92#[doc = "Field `se_pka_id1_en_rd` reader - "]
93pub type SE_PKA_ID1_EN_RD_R = crate::BitReader<bool>;
94#[doc = "Field `se_pka_id1_en_rd` writer - "]
95pub type SE_PKA_ID1_EN_RD_W<'a, const O: u8> =
96    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
97#[doc = "Field `se_cdet_prot_en_rd` reader - "]
98pub type SE_CDET_PROT_EN_RD_R = crate::BitReader<bool>;
99#[doc = "Field `se_cdet_prot_en_rd` writer - "]
100pub type SE_CDET_PROT_EN_RD_W<'a, const O: u8> =
101    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
102#[doc = "Field `se_cdet_id0_en_rd` reader - "]
103pub type SE_CDET_ID0_EN_RD_R = crate::BitReader<bool>;
104#[doc = "Field `se_cdet_id0_en_rd` writer - "]
105pub type SE_CDET_ID0_EN_RD_W<'a, const O: u8> =
106    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
107#[doc = "Field `se_cdet_id1_en_rd` reader - "]
108pub type SE_CDET_ID1_EN_RD_R = crate::BitReader<bool>;
109#[doc = "Field `se_cdet_id1_en_rd` writer - "]
110pub type SE_CDET_ID1_EN_RD_W<'a, const O: u8> =
111    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
112#[doc = "Field `se_gmac_prot_en_rd` reader - "]
113pub type SE_GMAC_PROT_EN_RD_R = crate::BitReader<bool>;
114#[doc = "Field `se_gmac_prot_en_rd` writer - "]
115pub type SE_GMAC_PROT_EN_RD_W<'a, const O: u8> =
116    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
117#[doc = "Field `se_gmac_id0_en_rd` reader - "]
118pub type SE_GMAC_ID0_EN_RD_R = crate::BitReader<bool>;
119#[doc = "Field `se_gmac_id0_en_rd` writer - "]
120pub type SE_GMAC_ID0_EN_RD_W<'a, const O: u8> =
121    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
122#[doc = "Field `se_gmac_id1_en_rd` reader - "]
123pub type SE_GMAC_ID1_EN_RD_R = crate::BitReader<bool>;
124#[doc = "Field `se_gmac_id1_en_rd` writer - "]
125pub type SE_GMAC_ID1_EN_RD_W<'a, const O: u8> =
126    crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
127#[doc = "Field `se_dbg_dis` reader - "]
128pub type SE_DBG_DIS_R = crate::BitReader<bool>;
129#[doc = "Field `se_dbg_dis` writer - "]
130pub type SE_DBG_DIS_W<'a, const O: u8> = crate::BitWriter<'a, u32, SE_CTRL_PROT_RD_SPEC, bool, O>;
131impl R {
132    #[doc = "Bit 0"]
133    #[inline(always)]
134    pub fn se_sha_prot_en_rd(&self) -> SE_SHA_PROT_EN_RD_R {
135        SE_SHA_PROT_EN_RD_R::new((self.bits & 1) != 0)
136    }
137    #[doc = "Bit 1"]
138    #[inline(always)]
139    pub fn se_sha_id0_en_rd(&self) -> SE_SHA_ID0_EN_RD_R {
140        SE_SHA_ID0_EN_RD_R::new(((self.bits >> 1) & 1) != 0)
141    }
142    #[doc = "Bit 2"]
143    #[inline(always)]
144    pub fn se_sha_id1_en_rd(&self) -> SE_SHA_ID1_EN_RD_R {
145        SE_SHA_ID1_EN_RD_R::new(((self.bits >> 2) & 1) != 0)
146    }
147    #[doc = "Bit 4"]
148    #[inline(always)]
149    pub fn se_aes_prot_en_rd(&self) -> SE_AES_PROT_EN_RD_R {
150        SE_AES_PROT_EN_RD_R::new(((self.bits >> 4) & 1) != 0)
151    }
152    #[doc = "Bit 5"]
153    #[inline(always)]
154    pub fn se_aes_id0_en_rd(&self) -> SE_AES_ID0_EN_RD_R {
155        SE_AES_ID0_EN_RD_R::new(((self.bits >> 5) & 1) != 0)
156    }
157    #[doc = "Bit 6"]
158    #[inline(always)]
159    pub fn se_aes_id1_en_rd(&self) -> SE_AES_ID1_EN_RD_R {
160        SE_AES_ID1_EN_RD_R::new(((self.bits >> 6) & 1) != 0)
161    }
162    #[doc = "Bit 8"]
163    #[inline(always)]
164    pub fn se_trng_prot_en_rd(&self) -> SE_TRNG_PROT_EN_RD_R {
165        SE_TRNG_PROT_EN_RD_R::new(((self.bits >> 8) & 1) != 0)
166    }
167    #[doc = "Bit 9"]
168    #[inline(always)]
169    pub fn se_trng_id0_en_rd(&self) -> SE_TRNG_ID0_EN_RD_R {
170        SE_TRNG_ID0_EN_RD_R::new(((self.bits >> 9) & 1) != 0)
171    }
172    #[doc = "Bit 10"]
173    #[inline(always)]
174    pub fn se_trng_id1_en_rd(&self) -> SE_TRNG_ID1_EN_RD_R {
175        SE_TRNG_ID1_EN_RD_R::new(((self.bits >> 10) & 1) != 0)
176    }
177    #[doc = "Bit 12"]
178    #[inline(always)]
179    pub fn se_pka_prot_en_rd(&self) -> SE_PKA_PROT_EN_RD_R {
180        SE_PKA_PROT_EN_RD_R::new(((self.bits >> 12) & 1) != 0)
181    }
182    #[doc = "Bit 13"]
183    #[inline(always)]
184    pub fn se_pka_id0_en_rd(&self) -> SE_PKA_ID0_EN_RD_R {
185        SE_PKA_ID0_EN_RD_R::new(((self.bits >> 13) & 1) != 0)
186    }
187    #[doc = "Bit 14"]
188    #[inline(always)]
189    pub fn se_pka_id1_en_rd(&self) -> SE_PKA_ID1_EN_RD_R {
190        SE_PKA_ID1_EN_RD_R::new(((self.bits >> 14) & 1) != 0)
191    }
192    #[doc = "Bit 16"]
193    #[inline(always)]
194    pub fn se_cdet_prot_en_rd(&self) -> SE_CDET_PROT_EN_RD_R {
195        SE_CDET_PROT_EN_RD_R::new(((self.bits >> 16) & 1) != 0)
196    }
197    #[doc = "Bit 17"]
198    #[inline(always)]
199    pub fn se_cdet_id0_en_rd(&self) -> SE_CDET_ID0_EN_RD_R {
200        SE_CDET_ID0_EN_RD_R::new(((self.bits >> 17) & 1) != 0)
201    }
202    #[doc = "Bit 18"]
203    #[inline(always)]
204    pub fn se_cdet_id1_en_rd(&self) -> SE_CDET_ID1_EN_RD_R {
205        SE_CDET_ID1_EN_RD_R::new(((self.bits >> 18) & 1) != 0)
206    }
207    #[doc = "Bit 20"]
208    #[inline(always)]
209    pub fn se_gmac_prot_en_rd(&self) -> SE_GMAC_PROT_EN_RD_R {
210        SE_GMAC_PROT_EN_RD_R::new(((self.bits >> 20) & 1) != 0)
211    }
212    #[doc = "Bit 21"]
213    #[inline(always)]
214    pub fn se_gmac_id0_en_rd(&self) -> SE_GMAC_ID0_EN_RD_R {
215        SE_GMAC_ID0_EN_RD_R::new(((self.bits >> 21) & 1) != 0)
216    }
217    #[doc = "Bit 22"]
218    #[inline(always)]
219    pub fn se_gmac_id1_en_rd(&self) -> SE_GMAC_ID1_EN_RD_R {
220        SE_GMAC_ID1_EN_RD_R::new(((self.bits >> 22) & 1) != 0)
221    }
222    #[doc = "Bit 31"]
223    #[inline(always)]
224    pub fn se_dbg_dis(&self) -> SE_DBG_DIS_R {
225        SE_DBG_DIS_R::new(((self.bits >> 31) & 1) != 0)
226    }
227}
228impl W {
229    #[doc = "Bit 0"]
230    #[inline(always)]
231    #[must_use]
232    pub fn se_sha_prot_en_rd(&mut self) -> SE_SHA_PROT_EN_RD_W<0> {
233        SE_SHA_PROT_EN_RD_W::new(self)
234    }
235    #[doc = "Bit 1"]
236    #[inline(always)]
237    #[must_use]
238    pub fn se_sha_id0_en_rd(&mut self) -> SE_SHA_ID0_EN_RD_W<1> {
239        SE_SHA_ID0_EN_RD_W::new(self)
240    }
241    #[doc = "Bit 2"]
242    #[inline(always)]
243    #[must_use]
244    pub fn se_sha_id1_en_rd(&mut self) -> SE_SHA_ID1_EN_RD_W<2> {
245        SE_SHA_ID1_EN_RD_W::new(self)
246    }
247    #[doc = "Bit 4"]
248    #[inline(always)]
249    #[must_use]
250    pub fn se_aes_prot_en_rd(&mut self) -> SE_AES_PROT_EN_RD_W<4> {
251        SE_AES_PROT_EN_RD_W::new(self)
252    }
253    #[doc = "Bit 5"]
254    #[inline(always)]
255    #[must_use]
256    pub fn se_aes_id0_en_rd(&mut self) -> SE_AES_ID0_EN_RD_W<5> {
257        SE_AES_ID0_EN_RD_W::new(self)
258    }
259    #[doc = "Bit 6"]
260    #[inline(always)]
261    #[must_use]
262    pub fn se_aes_id1_en_rd(&mut self) -> SE_AES_ID1_EN_RD_W<6> {
263        SE_AES_ID1_EN_RD_W::new(self)
264    }
265    #[doc = "Bit 8"]
266    #[inline(always)]
267    #[must_use]
268    pub fn se_trng_prot_en_rd(&mut self) -> SE_TRNG_PROT_EN_RD_W<8> {
269        SE_TRNG_PROT_EN_RD_W::new(self)
270    }
271    #[doc = "Bit 9"]
272    #[inline(always)]
273    #[must_use]
274    pub fn se_trng_id0_en_rd(&mut self) -> SE_TRNG_ID0_EN_RD_W<9> {
275        SE_TRNG_ID0_EN_RD_W::new(self)
276    }
277    #[doc = "Bit 10"]
278    #[inline(always)]
279    #[must_use]
280    pub fn se_trng_id1_en_rd(&mut self) -> SE_TRNG_ID1_EN_RD_W<10> {
281        SE_TRNG_ID1_EN_RD_W::new(self)
282    }
283    #[doc = "Bit 12"]
284    #[inline(always)]
285    #[must_use]
286    pub fn se_pka_prot_en_rd(&mut self) -> SE_PKA_PROT_EN_RD_W<12> {
287        SE_PKA_PROT_EN_RD_W::new(self)
288    }
289    #[doc = "Bit 13"]
290    #[inline(always)]
291    #[must_use]
292    pub fn se_pka_id0_en_rd(&mut self) -> SE_PKA_ID0_EN_RD_W<13> {
293        SE_PKA_ID0_EN_RD_W::new(self)
294    }
295    #[doc = "Bit 14"]
296    #[inline(always)]
297    #[must_use]
298    pub fn se_pka_id1_en_rd(&mut self) -> SE_PKA_ID1_EN_RD_W<14> {
299        SE_PKA_ID1_EN_RD_W::new(self)
300    }
301    #[doc = "Bit 16"]
302    #[inline(always)]
303    #[must_use]
304    pub fn se_cdet_prot_en_rd(&mut self) -> SE_CDET_PROT_EN_RD_W<16> {
305        SE_CDET_PROT_EN_RD_W::new(self)
306    }
307    #[doc = "Bit 17"]
308    #[inline(always)]
309    #[must_use]
310    pub fn se_cdet_id0_en_rd(&mut self) -> SE_CDET_ID0_EN_RD_W<17> {
311        SE_CDET_ID0_EN_RD_W::new(self)
312    }
313    #[doc = "Bit 18"]
314    #[inline(always)]
315    #[must_use]
316    pub fn se_cdet_id1_en_rd(&mut self) -> SE_CDET_ID1_EN_RD_W<18> {
317        SE_CDET_ID1_EN_RD_W::new(self)
318    }
319    #[doc = "Bit 20"]
320    #[inline(always)]
321    #[must_use]
322    pub fn se_gmac_prot_en_rd(&mut self) -> SE_GMAC_PROT_EN_RD_W<20> {
323        SE_GMAC_PROT_EN_RD_W::new(self)
324    }
325    #[doc = "Bit 21"]
326    #[inline(always)]
327    #[must_use]
328    pub fn se_gmac_id0_en_rd(&mut self) -> SE_GMAC_ID0_EN_RD_W<21> {
329        SE_GMAC_ID0_EN_RD_W::new(self)
330    }
331    #[doc = "Bit 22"]
332    #[inline(always)]
333    #[must_use]
334    pub fn se_gmac_id1_en_rd(&mut self) -> SE_GMAC_ID1_EN_RD_W<22> {
335        SE_GMAC_ID1_EN_RD_W::new(self)
336    }
337    #[doc = "Bit 31"]
338    #[inline(always)]
339    #[must_use]
340    pub fn se_dbg_dis(&mut self) -> SE_DBG_DIS_W<31> {
341        SE_DBG_DIS_W::new(self)
342    }
343    #[doc = "Writes raw bits to the register."]
344    #[inline(always)]
345    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
346        self.0.bits(bits);
347        self
348    }
349}
350#[doc = "se_ctrl_prot_rd.\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 [se_ctrl_prot_rd](index.html) module"]
351pub struct SE_CTRL_PROT_RD_SPEC;
352impl crate::RegisterSpec for SE_CTRL_PROT_RD_SPEC {
353    type Ux = u32;
354}
355#[doc = "`read()` method returns [se_ctrl_prot_rd::R](R) reader structure"]
356impl crate::Readable for SE_CTRL_PROT_RD_SPEC {
357    type Reader = R;
358}
359#[doc = "`write(|w| ..)` method takes [se_ctrl_prot_rd::W](W) writer structure"]
360impl crate::Writable for SE_CTRL_PROT_RD_SPEC {
361    type Writer = W;
362    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
363    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
364}
365#[doc = "`reset()` method sets se_ctrl_prot_rd to value 0"]
366impl crate::Resettable for SE_CTRL_PROT_RD_SPEC {
367    const RESET_VALUE: Self::Ux = 0;
368}