bl702_pac/glb/
tzc_glb_ctrl_3.rs

1#[doc = "Register `tzc_glb_ctrl_3` reader"]
2pub struct R(crate::R<TZC_GLB_CTRL_3_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<TZC_GLB_CTRL_3_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<TZC_GLB_CTRL_3_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<TZC_GLB_CTRL_3_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `tzc_glb_ctrl_3` writer"]
17pub struct W(crate::W<TZC_GLB_CTRL_3_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<TZC_GLB_CTRL_3_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<TZC_GLB_CTRL_3_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<TZC_GLB_CTRL_3_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `tzc_glb_gpio_32_lock` reader - "]
38pub type TZC_GLB_GPIO_32_LOCK_R = crate::BitReader<bool>;
39#[doc = "Field `tzc_glb_gpio_32_lock` writer - "]
40pub type TZC_GLB_GPIO_32_LOCK_W<'a, const O: u8> =
41    crate::BitWriter<'a, u32, TZC_GLB_CTRL_3_SPEC, bool, O>;
42#[doc = "Field `tzc_glb_gpio_33_lock` reader - "]
43pub type TZC_GLB_GPIO_33_LOCK_R = crate::BitReader<bool>;
44#[doc = "Field `tzc_glb_gpio_33_lock` writer - "]
45pub type TZC_GLB_GPIO_33_LOCK_W<'a, const O: u8> =
46    crate::BitWriter<'a, u32, TZC_GLB_CTRL_3_SPEC, bool, O>;
47#[doc = "Field `tzc_glb_gpio_34_lock` reader - "]
48pub type TZC_GLB_GPIO_34_LOCK_R = crate::BitReader<bool>;
49#[doc = "Field `tzc_glb_gpio_34_lock` writer - "]
50pub type TZC_GLB_GPIO_34_LOCK_W<'a, const O: u8> =
51    crate::BitWriter<'a, u32, TZC_GLB_CTRL_3_SPEC, bool, O>;
52#[doc = "Field `tzc_glb_gpio_35_lock` reader - "]
53pub type TZC_GLB_GPIO_35_LOCK_R = crate::BitReader<bool>;
54#[doc = "Field `tzc_glb_gpio_35_lock` writer - "]
55pub type TZC_GLB_GPIO_35_LOCK_W<'a, const O: u8> =
56    crate::BitWriter<'a, u32, TZC_GLB_CTRL_3_SPEC, bool, O>;
57#[doc = "Field `tzc_glb_gpio_36_lock` reader - "]
58pub type TZC_GLB_GPIO_36_LOCK_R = crate::BitReader<bool>;
59#[doc = "Field `tzc_glb_gpio_36_lock` writer - "]
60pub type TZC_GLB_GPIO_36_LOCK_W<'a, const O: u8> =
61    crate::BitWriter<'a, u32, TZC_GLB_CTRL_3_SPEC, bool, O>;
62#[doc = "Field `tzc_glb_gpio_37_lock` reader - "]
63pub type TZC_GLB_GPIO_37_LOCK_R = crate::BitReader<bool>;
64#[doc = "Field `tzc_glb_gpio_37_lock` writer - "]
65pub type TZC_GLB_GPIO_37_LOCK_W<'a, const O: u8> =
66    crate::BitWriter<'a, u32, TZC_GLB_CTRL_3_SPEC, bool, O>;
67impl R {
68    #[doc = "Bit 0"]
69    #[inline(always)]
70    pub fn tzc_glb_gpio_32_lock(&self) -> TZC_GLB_GPIO_32_LOCK_R {
71        TZC_GLB_GPIO_32_LOCK_R::new((self.bits & 1) != 0)
72    }
73    #[doc = "Bit 1"]
74    #[inline(always)]
75    pub fn tzc_glb_gpio_33_lock(&self) -> TZC_GLB_GPIO_33_LOCK_R {
76        TZC_GLB_GPIO_33_LOCK_R::new(((self.bits >> 1) & 1) != 0)
77    }
78    #[doc = "Bit 2"]
79    #[inline(always)]
80    pub fn tzc_glb_gpio_34_lock(&self) -> TZC_GLB_GPIO_34_LOCK_R {
81        TZC_GLB_GPIO_34_LOCK_R::new(((self.bits >> 2) & 1) != 0)
82    }
83    #[doc = "Bit 3"]
84    #[inline(always)]
85    pub fn tzc_glb_gpio_35_lock(&self) -> TZC_GLB_GPIO_35_LOCK_R {
86        TZC_GLB_GPIO_35_LOCK_R::new(((self.bits >> 3) & 1) != 0)
87    }
88    #[doc = "Bit 4"]
89    #[inline(always)]
90    pub fn tzc_glb_gpio_36_lock(&self) -> TZC_GLB_GPIO_36_LOCK_R {
91        TZC_GLB_GPIO_36_LOCK_R::new(((self.bits >> 4) & 1) != 0)
92    }
93    #[doc = "Bit 5"]
94    #[inline(always)]
95    pub fn tzc_glb_gpio_37_lock(&self) -> TZC_GLB_GPIO_37_LOCK_R {
96        TZC_GLB_GPIO_37_LOCK_R::new(((self.bits >> 5) & 1) != 0)
97    }
98}
99impl W {
100    #[doc = "Bit 0"]
101    #[inline(always)]
102    #[must_use]
103    pub fn tzc_glb_gpio_32_lock(&mut self) -> TZC_GLB_GPIO_32_LOCK_W<0> {
104        TZC_GLB_GPIO_32_LOCK_W::new(self)
105    }
106    #[doc = "Bit 1"]
107    #[inline(always)]
108    #[must_use]
109    pub fn tzc_glb_gpio_33_lock(&mut self) -> TZC_GLB_GPIO_33_LOCK_W<1> {
110        TZC_GLB_GPIO_33_LOCK_W::new(self)
111    }
112    #[doc = "Bit 2"]
113    #[inline(always)]
114    #[must_use]
115    pub fn tzc_glb_gpio_34_lock(&mut self) -> TZC_GLB_GPIO_34_LOCK_W<2> {
116        TZC_GLB_GPIO_34_LOCK_W::new(self)
117    }
118    #[doc = "Bit 3"]
119    #[inline(always)]
120    #[must_use]
121    pub fn tzc_glb_gpio_35_lock(&mut self) -> TZC_GLB_GPIO_35_LOCK_W<3> {
122        TZC_GLB_GPIO_35_LOCK_W::new(self)
123    }
124    #[doc = "Bit 4"]
125    #[inline(always)]
126    #[must_use]
127    pub fn tzc_glb_gpio_36_lock(&mut self) -> TZC_GLB_GPIO_36_LOCK_W<4> {
128        TZC_GLB_GPIO_36_LOCK_W::new(self)
129    }
130    #[doc = "Bit 5"]
131    #[inline(always)]
132    #[must_use]
133    pub fn tzc_glb_gpio_37_lock(&mut self) -> TZC_GLB_GPIO_37_LOCK_W<5> {
134        TZC_GLB_GPIO_37_LOCK_W::new(self)
135    }
136    #[doc = "Writes raw bits to the register."]
137    #[inline(always)]
138    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
139        self.0.bits(bits);
140        self
141    }
142}
143#[doc = "tzc_glb_ctrl_3.\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 [tzc_glb_ctrl_3](index.html) module"]
144pub struct TZC_GLB_CTRL_3_SPEC;
145impl crate::RegisterSpec for TZC_GLB_CTRL_3_SPEC {
146    type Ux = u32;
147}
148#[doc = "`read()` method returns [tzc_glb_ctrl_3::R](R) reader structure"]
149impl crate::Readable for TZC_GLB_CTRL_3_SPEC {
150    type Reader = R;
151}
152#[doc = "`write(|w| ..)` method takes [tzc_glb_ctrl_3::W](W) writer structure"]
153impl crate::Writable for TZC_GLB_CTRL_3_SPEC {
154    type Writer = W;
155    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
156    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
157}
158#[doc = "`reset()` method sets tzc_glb_ctrl_3 to value 0"]
159impl crate::Resettable for TZC_GLB_CTRL_3_SPEC {
160    const RESET_VALUE: Self::Ux = 0;
161}