ra4m3/pscu/
psarb.rs

1#[doc = "Register `PSARB` reader"]
2pub struct R(crate::R<PSARB_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<PSARB_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<PSARB_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<PSARB_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `PSARB` writer"]
17pub struct W(crate::W<PSARB_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<PSARB_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<PSARB_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<PSARB_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `PSARB1` reader - CAN1 and the MSTPCRB.MSTPB1 bit security attribution"]
38pub type PSARB1_R = crate::BitReader<PSARB1_A>;
39#[doc = "CAN1 and the MSTPCRB.MSTPB1 bit security attribution\n\nValue on reset: 1"]
40#[derive(Clone, Copy, Debug, PartialEq, Eq)]
41pub enum PSARB1_A {
42    #[doc = "0: Secure"]
43    _0 = 0,
44    #[doc = "1: Non-secure"]
45    _1 = 1,
46}
47impl From<PSARB1_A> for bool {
48    #[inline(always)]
49    fn from(variant: PSARB1_A) -> Self {
50        variant as u8 != 0
51    }
52}
53impl PSARB1_R {
54    #[doc = "Get enumerated values variant"]
55    #[inline(always)]
56    pub fn variant(&self) -> PSARB1_A {
57        match self.bits {
58            false => PSARB1_A::_0,
59            true => PSARB1_A::_1,
60        }
61    }
62    #[doc = "Checks if the value of the field is `_0`"]
63    #[inline(always)]
64    pub fn is_0(&self) -> bool {
65        *self == PSARB1_A::_0
66    }
67    #[doc = "Checks if the value of the field is `_1`"]
68    #[inline(always)]
69    pub fn is_1(&self) -> bool {
70        *self == PSARB1_A::_1
71    }
72}
73#[doc = "Field `PSARB1` writer - CAN1 and the MSTPCRB.MSTPB1 bit security attribution"]
74pub type PSARB1_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB1_A, O>;
75impl<'a, const O: u8> PSARB1_W<'a, O> {
76    #[doc = "Secure"]
77    #[inline(always)]
78    pub fn _0(self) -> &'a mut W {
79        self.variant(PSARB1_A::_0)
80    }
81    #[doc = "Non-secure"]
82    #[inline(always)]
83    pub fn _1(self) -> &'a mut W {
84        self.variant(PSARB1_A::_1)
85    }
86}
87#[doc = "Field `PSARB2` reader - CAN0 and the MSTPCRB.MSTPB2 bit security attribution"]
88pub type PSARB2_R = crate::BitReader<PSARB2_A>;
89#[doc = "CAN0 and the MSTPCRB.MSTPB2 bit security attribution\n\nValue on reset: 1"]
90#[derive(Clone, Copy, Debug, PartialEq, Eq)]
91pub enum PSARB2_A {
92    #[doc = "0: Secure"]
93    _0 = 0,
94    #[doc = "1: Non-secure"]
95    _1 = 1,
96}
97impl From<PSARB2_A> for bool {
98    #[inline(always)]
99    fn from(variant: PSARB2_A) -> Self {
100        variant as u8 != 0
101    }
102}
103impl PSARB2_R {
104    #[doc = "Get enumerated values variant"]
105    #[inline(always)]
106    pub fn variant(&self) -> PSARB2_A {
107        match self.bits {
108            false => PSARB2_A::_0,
109            true => PSARB2_A::_1,
110        }
111    }
112    #[doc = "Checks if the value of the field is `_0`"]
113    #[inline(always)]
114    pub fn is_0(&self) -> bool {
115        *self == PSARB2_A::_0
116    }
117    #[doc = "Checks if the value of the field is `_1`"]
118    #[inline(always)]
119    pub fn is_1(&self) -> bool {
120        *self == PSARB2_A::_1
121    }
122}
123#[doc = "Field `PSARB2` writer - CAN0 and the MSTPCRB.MSTPB2 bit security attribution"]
124pub type PSARB2_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB2_A, O>;
125impl<'a, const O: u8> PSARB2_W<'a, O> {
126    #[doc = "Secure"]
127    #[inline(always)]
128    pub fn _0(self) -> &'a mut W {
129        self.variant(PSARB2_A::_0)
130    }
131    #[doc = "Non-secure"]
132    #[inline(always)]
133    pub fn _1(self) -> &'a mut W {
134        self.variant(PSARB2_A::_1)
135    }
136}
137#[doc = "Field `PSARB6` reader - QSPI and the MSTPCRB.MSTPB6 bit security attribution"]
138pub type PSARB6_R = crate::BitReader<bool>;
139#[doc = "Field `PSARB8` reader - IIC1 and the MSTPCRB.MSTPB8 bit security attribution"]
140pub type PSARB8_R = crate::BitReader<PSARB8_A>;
141#[doc = "IIC1 and the MSTPCRB.MSTPB8 bit security attribution\n\nValue on reset: 1"]
142#[derive(Clone, Copy, Debug, PartialEq, Eq)]
143pub enum PSARB8_A {
144    #[doc = "0: Secure"]
145    _0 = 0,
146    #[doc = "1: Non-secure"]
147    _1 = 1,
148}
149impl From<PSARB8_A> for bool {
150    #[inline(always)]
151    fn from(variant: PSARB8_A) -> Self {
152        variant as u8 != 0
153    }
154}
155impl PSARB8_R {
156    #[doc = "Get enumerated values variant"]
157    #[inline(always)]
158    pub fn variant(&self) -> PSARB8_A {
159        match self.bits {
160            false => PSARB8_A::_0,
161            true => PSARB8_A::_1,
162        }
163    }
164    #[doc = "Checks if the value of the field is `_0`"]
165    #[inline(always)]
166    pub fn is_0(&self) -> bool {
167        *self == PSARB8_A::_0
168    }
169    #[doc = "Checks if the value of the field is `_1`"]
170    #[inline(always)]
171    pub fn is_1(&self) -> bool {
172        *self == PSARB8_A::_1
173    }
174}
175#[doc = "Field `PSARB8` writer - IIC1 and the MSTPCRB.MSTPB8 bit security attribution"]
176pub type PSARB8_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB8_A, O>;
177impl<'a, const O: u8> PSARB8_W<'a, O> {
178    #[doc = "Secure"]
179    #[inline(always)]
180    pub fn _0(self) -> &'a mut W {
181        self.variant(PSARB8_A::_0)
182    }
183    #[doc = "Non-secure"]
184    #[inline(always)]
185    pub fn _1(self) -> &'a mut W {
186        self.variant(PSARB8_A::_1)
187    }
188}
189#[doc = "Field `PSARB9` reader - IIC0 and the MSTPCRB.MSTPB9 bit security attribution"]
190pub type PSARB9_R = crate::BitReader<PSARB9_A>;
191#[doc = "IIC0 and the MSTPCRB.MSTPB9 bit security attribution\n\nValue on reset: 1"]
192#[derive(Clone, Copy, Debug, PartialEq, Eq)]
193pub enum PSARB9_A {
194    #[doc = "0: Secure"]
195    _0 = 0,
196    #[doc = "1: Non-secure"]
197    _1 = 1,
198}
199impl From<PSARB9_A> for bool {
200    #[inline(always)]
201    fn from(variant: PSARB9_A) -> Self {
202        variant as u8 != 0
203    }
204}
205impl PSARB9_R {
206    #[doc = "Get enumerated values variant"]
207    #[inline(always)]
208    pub fn variant(&self) -> PSARB9_A {
209        match self.bits {
210            false => PSARB9_A::_0,
211            true => PSARB9_A::_1,
212        }
213    }
214    #[doc = "Checks if the value of the field is `_0`"]
215    #[inline(always)]
216    pub fn is_0(&self) -> bool {
217        *self == PSARB9_A::_0
218    }
219    #[doc = "Checks if the value of the field is `_1`"]
220    #[inline(always)]
221    pub fn is_1(&self) -> bool {
222        *self == PSARB9_A::_1
223    }
224}
225#[doc = "Field `PSARB9` writer - IIC0 and the MSTPCRB.MSTPB9 bit security attribution"]
226pub type PSARB9_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB9_A, O>;
227impl<'a, const O: u8> PSARB9_W<'a, O> {
228    #[doc = "Secure"]
229    #[inline(always)]
230    pub fn _0(self) -> &'a mut W {
231        self.variant(PSARB9_A::_0)
232    }
233    #[doc = "Non-secure"]
234    #[inline(always)]
235    pub fn _1(self) -> &'a mut W {
236        self.variant(PSARB9_A::_1)
237    }
238}
239#[doc = "Field `PSARB11` reader - USBFS and the MSTPCRB.MSTPB11 bit security attribution"]
240pub type PSARB11_R = crate::BitReader<PSARB11_A>;
241#[doc = "USBFS and the MSTPCRB.MSTPB11 bit security attribution\n\nValue on reset: 1"]
242#[derive(Clone, Copy, Debug, PartialEq, Eq)]
243pub enum PSARB11_A {
244    #[doc = "0: Secure"]
245    _0 = 0,
246    #[doc = "1: Non-secure"]
247    _1 = 1,
248}
249impl From<PSARB11_A> for bool {
250    #[inline(always)]
251    fn from(variant: PSARB11_A) -> Self {
252        variant as u8 != 0
253    }
254}
255impl PSARB11_R {
256    #[doc = "Get enumerated values variant"]
257    #[inline(always)]
258    pub fn variant(&self) -> PSARB11_A {
259        match self.bits {
260            false => PSARB11_A::_0,
261            true => PSARB11_A::_1,
262        }
263    }
264    #[doc = "Checks if the value of the field is `_0`"]
265    #[inline(always)]
266    pub fn is_0(&self) -> bool {
267        *self == PSARB11_A::_0
268    }
269    #[doc = "Checks if the value of the field is `_1`"]
270    #[inline(always)]
271    pub fn is_1(&self) -> bool {
272        *self == PSARB11_A::_1
273    }
274}
275#[doc = "Field `PSARB11` writer - USBFS and the MSTPCRB.MSTPB11 bit security attribution"]
276pub type PSARB11_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB11_A, O>;
277impl<'a, const O: u8> PSARB11_W<'a, O> {
278    #[doc = "Secure"]
279    #[inline(always)]
280    pub fn _0(self) -> &'a mut W {
281        self.variant(PSARB11_A::_0)
282    }
283    #[doc = "Non-secure"]
284    #[inline(always)]
285    pub fn _1(self) -> &'a mut W {
286        self.variant(PSARB11_A::_1)
287    }
288}
289#[doc = "Field `PSARB19` reader - SPI0 and the MSTPCRB.MSTPB19 bit security attribution"]
290pub type PSARB19_R = crate::BitReader<PSARB19_A>;
291#[doc = "SPI0 and the MSTPCRB.MSTPB19 bit security attribution\n\nValue on reset: 1"]
292#[derive(Clone, Copy, Debug, PartialEq, Eq)]
293pub enum PSARB19_A {
294    #[doc = "0: Secure"]
295    _0 = 0,
296    #[doc = "1: Non-secure"]
297    _1 = 1,
298}
299impl From<PSARB19_A> for bool {
300    #[inline(always)]
301    fn from(variant: PSARB19_A) -> Self {
302        variant as u8 != 0
303    }
304}
305impl PSARB19_R {
306    #[doc = "Get enumerated values variant"]
307    #[inline(always)]
308    pub fn variant(&self) -> PSARB19_A {
309        match self.bits {
310            false => PSARB19_A::_0,
311            true => PSARB19_A::_1,
312        }
313    }
314    #[doc = "Checks if the value of the field is `_0`"]
315    #[inline(always)]
316    pub fn is_0(&self) -> bool {
317        *self == PSARB19_A::_0
318    }
319    #[doc = "Checks if the value of the field is `_1`"]
320    #[inline(always)]
321    pub fn is_1(&self) -> bool {
322        *self == PSARB19_A::_1
323    }
324}
325#[doc = "Field `PSARB19` writer - SPI0 and the MSTPCRB.MSTPB19 bit security attribution"]
326pub type PSARB19_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB19_A, O>;
327impl<'a, const O: u8> PSARB19_W<'a, O> {
328    #[doc = "Secure"]
329    #[inline(always)]
330    pub fn _0(self) -> &'a mut W {
331        self.variant(PSARB19_A::_0)
332    }
333    #[doc = "Non-secure"]
334    #[inline(always)]
335    pub fn _1(self) -> &'a mut W {
336        self.variant(PSARB19_A::_1)
337    }
338}
339#[doc = "Field `PSARB22` reader - SCI9 and the MSTPCRB.MSTPB22 bit security attribution"]
340pub type PSARB22_R = crate::BitReader<PSARB22_A>;
341#[doc = "SCI9 and the MSTPCRB.MSTPB22 bit security attribution\n\nValue on reset: 1"]
342#[derive(Clone, Copy, Debug, PartialEq, Eq)]
343pub enum PSARB22_A {
344    #[doc = "0: Secure"]
345    _0 = 0,
346    #[doc = "1: Non-secure"]
347    _1 = 1,
348}
349impl From<PSARB22_A> for bool {
350    #[inline(always)]
351    fn from(variant: PSARB22_A) -> Self {
352        variant as u8 != 0
353    }
354}
355impl PSARB22_R {
356    #[doc = "Get enumerated values variant"]
357    #[inline(always)]
358    pub fn variant(&self) -> PSARB22_A {
359        match self.bits {
360            false => PSARB22_A::_0,
361            true => PSARB22_A::_1,
362        }
363    }
364    #[doc = "Checks if the value of the field is `_0`"]
365    #[inline(always)]
366    pub fn is_0(&self) -> bool {
367        *self == PSARB22_A::_0
368    }
369    #[doc = "Checks if the value of the field is `_1`"]
370    #[inline(always)]
371    pub fn is_1(&self) -> bool {
372        *self == PSARB22_A::_1
373    }
374}
375#[doc = "Field `PSARB22` writer - SCI9 and the MSTPCRB.MSTPB22 bit security attribution"]
376pub type PSARB22_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB22_A, O>;
377impl<'a, const O: u8> PSARB22_W<'a, O> {
378    #[doc = "Secure"]
379    #[inline(always)]
380    pub fn _0(self) -> &'a mut W {
381        self.variant(PSARB22_A::_0)
382    }
383    #[doc = "Non-secure"]
384    #[inline(always)]
385    pub fn _1(self) -> &'a mut W {
386        self.variant(PSARB22_A::_1)
387    }
388}
389#[doc = "Field `PSARB27` reader - SCI4 and the MSTPCRB.MSTPB27 bit security attribution"]
390pub type PSARB27_R = crate::BitReader<PSARB27_A>;
391#[doc = "SCI4 and the MSTPCRB.MSTPB27 bit security attribution\n\nValue on reset: 1"]
392#[derive(Clone, Copy, Debug, PartialEq, Eq)]
393pub enum PSARB27_A {
394    #[doc = "0: Secure"]
395    _0 = 0,
396    #[doc = "1: Non-secure"]
397    _1 = 1,
398}
399impl From<PSARB27_A> for bool {
400    #[inline(always)]
401    fn from(variant: PSARB27_A) -> Self {
402        variant as u8 != 0
403    }
404}
405impl PSARB27_R {
406    #[doc = "Get enumerated values variant"]
407    #[inline(always)]
408    pub fn variant(&self) -> PSARB27_A {
409        match self.bits {
410            false => PSARB27_A::_0,
411            true => PSARB27_A::_1,
412        }
413    }
414    #[doc = "Checks if the value of the field is `_0`"]
415    #[inline(always)]
416    pub fn is_0(&self) -> bool {
417        *self == PSARB27_A::_0
418    }
419    #[doc = "Checks if the value of the field is `_1`"]
420    #[inline(always)]
421    pub fn is_1(&self) -> bool {
422        *self == PSARB27_A::_1
423    }
424}
425#[doc = "Field `PSARB27` writer - SCI4 and the MSTPCRB.MSTPB27 bit security attribution"]
426pub type PSARB27_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB27_A, O>;
427impl<'a, const O: u8> PSARB27_W<'a, O> {
428    #[doc = "Secure"]
429    #[inline(always)]
430    pub fn _0(self) -> &'a mut W {
431        self.variant(PSARB27_A::_0)
432    }
433    #[doc = "Non-secure"]
434    #[inline(always)]
435    pub fn _1(self) -> &'a mut W {
436        self.variant(PSARB27_A::_1)
437    }
438}
439#[doc = "Field `PSARB28` reader - SCI3 and the MSTPCRB.MSTPB28 bit security attribution"]
440pub type PSARB28_R = crate::BitReader<PSARB28_A>;
441#[doc = "SCI3 and the MSTPCRB.MSTPB28 bit security attribution\n\nValue on reset: 1"]
442#[derive(Clone, Copy, Debug, PartialEq, Eq)]
443pub enum PSARB28_A {
444    #[doc = "0: Secure"]
445    _0 = 0,
446    #[doc = "1: Non-secure"]
447    _1 = 1,
448}
449impl From<PSARB28_A> for bool {
450    #[inline(always)]
451    fn from(variant: PSARB28_A) -> Self {
452        variant as u8 != 0
453    }
454}
455impl PSARB28_R {
456    #[doc = "Get enumerated values variant"]
457    #[inline(always)]
458    pub fn variant(&self) -> PSARB28_A {
459        match self.bits {
460            false => PSARB28_A::_0,
461            true => PSARB28_A::_1,
462        }
463    }
464    #[doc = "Checks if the value of the field is `_0`"]
465    #[inline(always)]
466    pub fn is_0(&self) -> bool {
467        *self == PSARB28_A::_0
468    }
469    #[doc = "Checks if the value of the field is `_1`"]
470    #[inline(always)]
471    pub fn is_1(&self) -> bool {
472        *self == PSARB28_A::_1
473    }
474}
475#[doc = "Field `PSARB28` writer - SCI3 and the MSTPCRB.MSTPB28 bit security attribution"]
476pub type PSARB28_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB28_A, O>;
477impl<'a, const O: u8> PSARB28_W<'a, O> {
478    #[doc = "Secure"]
479    #[inline(always)]
480    pub fn _0(self) -> &'a mut W {
481        self.variant(PSARB28_A::_0)
482    }
483    #[doc = "Non-secure"]
484    #[inline(always)]
485    pub fn _1(self) -> &'a mut W {
486        self.variant(PSARB28_A::_1)
487    }
488}
489#[doc = "Field `PSARB29` reader - SCI2 and the MSTPCRB.MSTPB29 bit security attribution"]
490pub type PSARB29_R = crate::BitReader<PSARB29_A>;
491#[doc = "SCI2 and the MSTPCRB.MSTPB29 bit security attribution\n\nValue on reset: 1"]
492#[derive(Clone, Copy, Debug, PartialEq, Eq)]
493pub enum PSARB29_A {
494    #[doc = "0: Secure"]
495    _0 = 0,
496    #[doc = "1: Non-secure"]
497    _1 = 1,
498}
499impl From<PSARB29_A> for bool {
500    #[inline(always)]
501    fn from(variant: PSARB29_A) -> Self {
502        variant as u8 != 0
503    }
504}
505impl PSARB29_R {
506    #[doc = "Get enumerated values variant"]
507    #[inline(always)]
508    pub fn variant(&self) -> PSARB29_A {
509        match self.bits {
510            false => PSARB29_A::_0,
511            true => PSARB29_A::_1,
512        }
513    }
514    #[doc = "Checks if the value of the field is `_0`"]
515    #[inline(always)]
516    pub fn is_0(&self) -> bool {
517        *self == PSARB29_A::_0
518    }
519    #[doc = "Checks if the value of the field is `_1`"]
520    #[inline(always)]
521    pub fn is_1(&self) -> bool {
522        *self == PSARB29_A::_1
523    }
524}
525#[doc = "Field `PSARB29` writer - SCI2 and the MSTPCRB.MSTPB29 bit security attribution"]
526pub type PSARB29_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB29_A, O>;
527impl<'a, const O: u8> PSARB29_W<'a, O> {
528    #[doc = "Secure"]
529    #[inline(always)]
530    pub fn _0(self) -> &'a mut W {
531        self.variant(PSARB29_A::_0)
532    }
533    #[doc = "Non-secure"]
534    #[inline(always)]
535    pub fn _1(self) -> &'a mut W {
536        self.variant(PSARB29_A::_1)
537    }
538}
539#[doc = "Field `PSARB30` reader - SCI1 and the MSTPCRB.MSTPB30 bit security attribution"]
540pub type PSARB30_R = crate::BitReader<PSARB30_A>;
541#[doc = "SCI1 and the MSTPCRB.MSTPB30 bit security attribution\n\nValue on reset: 1"]
542#[derive(Clone, Copy, Debug, PartialEq, Eq)]
543pub enum PSARB30_A {
544    #[doc = "0: Secure"]
545    _0 = 0,
546    #[doc = "1: Non-secure"]
547    _1 = 1,
548}
549impl From<PSARB30_A> for bool {
550    #[inline(always)]
551    fn from(variant: PSARB30_A) -> Self {
552        variant as u8 != 0
553    }
554}
555impl PSARB30_R {
556    #[doc = "Get enumerated values variant"]
557    #[inline(always)]
558    pub fn variant(&self) -> PSARB30_A {
559        match self.bits {
560            false => PSARB30_A::_0,
561            true => PSARB30_A::_1,
562        }
563    }
564    #[doc = "Checks if the value of the field is `_0`"]
565    #[inline(always)]
566    pub fn is_0(&self) -> bool {
567        *self == PSARB30_A::_0
568    }
569    #[doc = "Checks if the value of the field is `_1`"]
570    #[inline(always)]
571    pub fn is_1(&self) -> bool {
572        *self == PSARB30_A::_1
573    }
574}
575#[doc = "Field `PSARB30` writer - SCI1 and the MSTPCRB.MSTPB30 bit security attribution"]
576pub type PSARB30_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB30_A, O>;
577impl<'a, const O: u8> PSARB30_W<'a, O> {
578    #[doc = "Secure"]
579    #[inline(always)]
580    pub fn _0(self) -> &'a mut W {
581        self.variant(PSARB30_A::_0)
582    }
583    #[doc = "Non-secure"]
584    #[inline(always)]
585    pub fn _1(self) -> &'a mut W {
586        self.variant(PSARB30_A::_1)
587    }
588}
589#[doc = "Field `PSARB31` reader - SCI0 and the MSTPCRB.MSTPB31 bit security attribution"]
590pub type PSARB31_R = crate::BitReader<PSARB31_A>;
591#[doc = "SCI0 and the MSTPCRB.MSTPB31 bit security attribution\n\nValue on reset: 1"]
592#[derive(Clone, Copy, Debug, PartialEq, Eq)]
593pub enum PSARB31_A {
594    #[doc = "0: Secure"]
595    _0 = 0,
596    #[doc = "1: Non-secure"]
597    _1 = 1,
598}
599impl From<PSARB31_A> for bool {
600    #[inline(always)]
601    fn from(variant: PSARB31_A) -> Self {
602        variant as u8 != 0
603    }
604}
605impl PSARB31_R {
606    #[doc = "Get enumerated values variant"]
607    #[inline(always)]
608    pub fn variant(&self) -> PSARB31_A {
609        match self.bits {
610            false => PSARB31_A::_0,
611            true => PSARB31_A::_1,
612        }
613    }
614    #[doc = "Checks if the value of the field is `_0`"]
615    #[inline(always)]
616    pub fn is_0(&self) -> bool {
617        *self == PSARB31_A::_0
618    }
619    #[doc = "Checks if the value of the field is `_1`"]
620    #[inline(always)]
621    pub fn is_1(&self) -> bool {
622        *self == PSARB31_A::_1
623    }
624}
625#[doc = "Field `PSARB31` writer - SCI0 and the MSTPCRB.MSTPB31 bit security attribution"]
626pub type PSARB31_W<'a, const O: u8> = crate::BitWriter<'a, u32, PSARB_SPEC, PSARB31_A, O>;
627impl<'a, const O: u8> PSARB31_W<'a, O> {
628    #[doc = "Secure"]
629    #[inline(always)]
630    pub fn _0(self) -> &'a mut W {
631        self.variant(PSARB31_A::_0)
632    }
633    #[doc = "Non-secure"]
634    #[inline(always)]
635    pub fn _1(self) -> &'a mut W {
636        self.variant(PSARB31_A::_1)
637    }
638}
639impl R {
640    #[doc = "Bit 1 - CAN1 and the MSTPCRB.MSTPB1 bit security attribution"]
641    #[inline(always)]
642    pub fn psarb1(&self) -> PSARB1_R {
643        PSARB1_R::new(((self.bits >> 1) & 1) != 0)
644    }
645    #[doc = "Bit 2 - CAN0 and the MSTPCRB.MSTPB2 bit security attribution"]
646    #[inline(always)]
647    pub fn psarb2(&self) -> PSARB2_R {
648        PSARB2_R::new(((self.bits >> 2) & 1) != 0)
649    }
650    #[doc = "Bit 6 - QSPI and the MSTPCRB.MSTPB6 bit security attribution"]
651    #[inline(always)]
652    pub fn psarb6(&self) -> PSARB6_R {
653        PSARB6_R::new(((self.bits >> 6) & 1) != 0)
654    }
655    #[doc = "Bit 8 - IIC1 and the MSTPCRB.MSTPB8 bit security attribution"]
656    #[inline(always)]
657    pub fn psarb8(&self) -> PSARB8_R {
658        PSARB8_R::new(((self.bits >> 8) & 1) != 0)
659    }
660    #[doc = "Bit 9 - IIC0 and the MSTPCRB.MSTPB9 bit security attribution"]
661    #[inline(always)]
662    pub fn psarb9(&self) -> PSARB9_R {
663        PSARB9_R::new(((self.bits >> 9) & 1) != 0)
664    }
665    #[doc = "Bit 11 - USBFS and the MSTPCRB.MSTPB11 bit security attribution"]
666    #[inline(always)]
667    pub fn psarb11(&self) -> PSARB11_R {
668        PSARB11_R::new(((self.bits >> 11) & 1) != 0)
669    }
670    #[doc = "Bit 19 - SPI0 and the MSTPCRB.MSTPB19 bit security attribution"]
671    #[inline(always)]
672    pub fn psarb19(&self) -> PSARB19_R {
673        PSARB19_R::new(((self.bits >> 19) & 1) != 0)
674    }
675    #[doc = "Bit 22 - SCI9 and the MSTPCRB.MSTPB22 bit security attribution"]
676    #[inline(always)]
677    pub fn psarb22(&self) -> PSARB22_R {
678        PSARB22_R::new(((self.bits >> 22) & 1) != 0)
679    }
680    #[doc = "Bit 27 - SCI4 and the MSTPCRB.MSTPB27 bit security attribution"]
681    #[inline(always)]
682    pub fn psarb27(&self) -> PSARB27_R {
683        PSARB27_R::new(((self.bits >> 27) & 1) != 0)
684    }
685    #[doc = "Bit 28 - SCI3 and the MSTPCRB.MSTPB28 bit security attribution"]
686    #[inline(always)]
687    pub fn psarb28(&self) -> PSARB28_R {
688        PSARB28_R::new(((self.bits >> 28) & 1) != 0)
689    }
690    #[doc = "Bit 29 - SCI2 and the MSTPCRB.MSTPB29 bit security attribution"]
691    #[inline(always)]
692    pub fn psarb29(&self) -> PSARB29_R {
693        PSARB29_R::new(((self.bits >> 29) & 1) != 0)
694    }
695    #[doc = "Bit 30 - SCI1 and the MSTPCRB.MSTPB30 bit security attribution"]
696    #[inline(always)]
697    pub fn psarb30(&self) -> PSARB30_R {
698        PSARB30_R::new(((self.bits >> 30) & 1) != 0)
699    }
700    #[doc = "Bit 31 - SCI0 and the MSTPCRB.MSTPB31 bit security attribution"]
701    #[inline(always)]
702    pub fn psarb31(&self) -> PSARB31_R {
703        PSARB31_R::new(((self.bits >> 31) & 1) != 0)
704    }
705}
706impl W {
707    #[doc = "Bit 1 - CAN1 and the MSTPCRB.MSTPB1 bit security attribution"]
708    #[inline(always)]
709    #[must_use]
710    pub fn psarb1(&mut self) -> PSARB1_W<1> {
711        PSARB1_W::new(self)
712    }
713    #[doc = "Bit 2 - CAN0 and the MSTPCRB.MSTPB2 bit security attribution"]
714    #[inline(always)]
715    #[must_use]
716    pub fn psarb2(&mut self) -> PSARB2_W<2> {
717        PSARB2_W::new(self)
718    }
719    #[doc = "Bit 8 - IIC1 and the MSTPCRB.MSTPB8 bit security attribution"]
720    #[inline(always)]
721    #[must_use]
722    pub fn psarb8(&mut self) -> PSARB8_W<8> {
723        PSARB8_W::new(self)
724    }
725    #[doc = "Bit 9 - IIC0 and the MSTPCRB.MSTPB9 bit security attribution"]
726    #[inline(always)]
727    #[must_use]
728    pub fn psarb9(&mut self) -> PSARB9_W<9> {
729        PSARB9_W::new(self)
730    }
731    #[doc = "Bit 11 - USBFS and the MSTPCRB.MSTPB11 bit security attribution"]
732    #[inline(always)]
733    #[must_use]
734    pub fn psarb11(&mut self) -> PSARB11_W<11> {
735        PSARB11_W::new(self)
736    }
737    #[doc = "Bit 19 - SPI0 and the MSTPCRB.MSTPB19 bit security attribution"]
738    #[inline(always)]
739    #[must_use]
740    pub fn psarb19(&mut self) -> PSARB19_W<19> {
741        PSARB19_W::new(self)
742    }
743    #[doc = "Bit 22 - SCI9 and the MSTPCRB.MSTPB22 bit security attribution"]
744    #[inline(always)]
745    #[must_use]
746    pub fn psarb22(&mut self) -> PSARB22_W<22> {
747        PSARB22_W::new(self)
748    }
749    #[doc = "Bit 27 - SCI4 and the MSTPCRB.MSTPB27 bit security attribution"]
750    #[inline(always)]
751    #[must_use]
752    pub fn psarb27(&mut self) -> PSARB27_W<27> {
753        PSARB27_W::new(self)
754    }
755    #[doc = "Bit 28 - SCI3 and the MSTPCRB.MSTPB28 bit security attribution"]
756    #[inline(always)]
757    #[must_use]
758    pub fn psarb28(&mut self) -> PSARB28_W<28> {
759        PSARB28_W::new(self)
760    }
761    #[doc = "Bit 29 - SCI2 and the MSTPCRB.MSTPB29 bit security attribution"]
762    #[inline(always)]
763    #[must_use]
764    pub fn psarb29(&mut self) -> PSARB29_W<29> {
765        PSARB29_W::new(self)
766    }
767    #[doc = "Bit 30 - SCI1 and the MSTPCRB.MSTPB30 bit security attribution"]
768    #[inline(always)]
769    #[must_use]
770    pub fn psarb30(&mut self) -> PSARB30_W<30> {
771        PSARB30_W::new(self)
772    }
773    #[doc = "Bit 31 - SCI0 and the MSTPCRB.MSTPB31 bit security attribution"]
774    #[inline(always)]
775    #[must_use]
776    pub fn psarb31(&mut self) -> PSARB31_W<31> {
777        PSARB31_W::new(self)
778    }
779    #[doc = "Writes raw bits to the register."]
780    #[inline(always)]
781    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
782        self.0.bits(bits);
783        self
784    }
785}
786#[doc = "Peripheral Security Attribution Register B\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 [psarb](index.html) module"]
787pub struct PSARB_SPEC;
788impl crate::RegisterSpec for PSARB_SPEC {
789    type Ux = u32;
790}
791#[doc = "`read()` method returns [psarb::R](R) reader structure"]
792impl crate::Readable for PSARB_SPEC {
793    type Reader = R;
794}
795#[doc = "`write(|w| ..)` method takes [psarb::W](W) writer structure"]
796impl crate::Writable for PSARB_SPEC {
797    type Writer = W;
798    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
799    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
800}
801#[doc = "`reset()` method sets PSARB to value 0xffff_ffff"]
802impl crate::Resettable for PSARB_SPEC {
803    const RESET_VALUE: Self::Ux = 0xffff_ffff;
804}