ht32f523x2/gpioa/
dircr.rs1#[doc = "Register `DIRCR` reader"]
2pub type R = crate::R<DircrSpec>;
3#[doc = "Register `DIRCR` writer"]
4pub type W = crate::W<DircrSpec>;
5#[doc = "Field `DIR0` reader - DIR0"]
6pub type Dir0R = crate::BitReader;
7#[doc = "Field `DIR0` writer - DIR0"]
8pub type Dir0W<'a, REG> = crate::BitWriter<'a, REG>;
9#[doc = "Field `DIR1` reader - DIR1"]
10pub type Dir1R = crate::BitReader;
11#[doc = "Field `DIR1` writer - DIR1"]
12pub type Dir1W<'a, REG> = crate::BitWriter<'a, REG>;
13#[doc = "Field `DIR2` reader - DIR2"]
14pub type Dir2R = crate::BitReader;
15#[doc = "Field `DIR2` writer - DIR2"]
16pub type Dir2W<'a, REG> = crate::BitWriter<'a, REG>;
17#[doc = "Field `DIR3` reader - DIR3"]
18pub type Dir3R = crate::BitReader;
19#[doc = "Field `DIR3` writer - DIR3"]
20pub type Dir3W<'a, REG> = crate::BitWriter<'a, REG>;
21#[doc = "Field `DIR4` reader - DIR4"]
22pub type Dir4R = crate::BitReader;
23#[doc = "Field `DIR4` writer - DIR4"]
24pub type Dir4W<'a, REG> = crate::BitWriter<'a, REG>;
25#[doc = "Field `DIR5` reader - DIR5"]
26pub type Dir5R = crate::BitReader;
27#[doc = "Field `DIR5` writer - DIR5"]
28pub type Dir5W<'a, REG> = crate::BitWriter<'a, REG>;
29#[doc = "Field `DIR6` reader - DIR6"]
30pub type Dir6R = crate::BitReader;
31#[doc = "Field `DIR6` writer - DIR6"]
32pub type Dir6W<'a, REG> = crate::BitWriter<'a, REG>;
33#[doc = "Field `DIR7` reader - DIR7"]
34pub type Dir7R = crate::BitReader;
35#[doc = "Field `DIR7` writer - DIR7"]
36pub type Dir7W<'a, REG> = crate::BitWriter<'a, REG>;
37#[doc = "Field `DIR8` reader - DIR8"]
38pub type Dir8R = crate::BitReader;
39#[doc = "Field `DIR8` writer - DIR8"]
40pub type Dir8W<'a, REG> = crate::BitWriter<'a, REG>;
41#[doc = "Field `DIR9` reader - DIR9"]
42pub type Dir9R = crate::BitReader;
43#[doc = "Field `DIR9` writer - DIR9"]
44pub type Dir9W<'a, REG> = crate::BitWriter<'a, REG>;
45#[doc = "Field `DIR10` reader - DIR10"]
46pub type Dir10R = crate::BitReader;
47#[doc = "Field `DIR10` writer - DIR10"]
48pub type Dir10W<'a, REG> = crate::BitWriter<'a, REG>;
49#[doc = "Field `DIR11` reader - DIR11"]
50pub type Dir11R = crate::BitReader;
51#[doc = "Field `DIR11` writer - DIR11"]
52pub type Dir11W<'a, REG> = crate::BitWriter<'a, REG>;
53#[doc = "Field `DIR12` reader - DIR12"]
54pub type Dir12R = crate::BitReader;
55#[doc = "Field `DIR12` writer - DIR12"]
56pub type Dir12W<'a, REG> = crate::BitWriter<'a, REG>;
57#[doc = "Field `DIR13` reader - DIR13"]
58pub type Dir13R = crate::BitReader;
59#[doc = "Field `DIR13` writer - DIR13"]
60pub type Dir13W<'a, REG> = crate::BitWriter<'a, REG>;
61#[doc = "Field `DIR14` reader - DIR14"]
62pub type Dir14R = crate::BitReader;
63#[doc = "Field `DIR14` writer - DIR14"]
64pub type Dir14W<'a, REG> = crate::BitWriter<'a, REG>;
65#[doc = "Field `DIR15` reader - DIR15"]
66pub type Dir15R = crate::BitReader;
67#[doc = "Field `DIR15` writer - DIR15"]
68pub type Dir15W<'a, REG> = crate::BitWriter<'a, REG>;
69impl R {
70 #[doc = "Bit 0 - DIR0"]
71 #[inline(always)]
72 pub fn dir0(&self) -> Dir0R {
73 Dir0R::new((self.bits & 1) != 0)
74 }
75 #[doc = "Bit 1 - DIR1"]
76 #[inline(always)]
77 pub fn dir1(&self) -> Dir1R {
78 Dir1R::new(((self.bits >> 1) & 1) != 0)
79 }
80 #[doc = "Bit 2 - DIR2"]
81 #[inline(always)]
82 pub fn dir2(&self) -> Dir2R {
83 Dir2R::new(((self.bits >> 2) & 1) != 0)
84 }
85 #[doc = "Bit 3 - DIR3"]
86 #[inline(always)]
87 pub fn dir3(&self) -> Dir3R {
88 Dir3R::new(((self.bits >> 3) & 1) != 0)
89 }
90 #[doc = "Bit 4 - DIR4"]
91 #[inline(always)]
92 pub fn dir4(&self) -> Dir4R {
93 Dir4R::new(((self.bits >> 4) & 1) != 0)
94 }
95 #[doc = "Bit 5 - DIR5"]
96 #[inline(always)]
97 pub fn dir5(&self) -> Dir5R {
98 Dir5R::new(((self.bits >> 5) & 1) != 0)
99 }
100 #[doc = "Bit 6 - DIR6"]
101 #[inline(always)]
102 pub fn dir6(&self) -> Dir6R {
103 Dir6R::new(((self.bits >> 6) & 1) != 0)
104 }
105 #[doc = "Bit 7 - DIR7"]
106 #[inline(always)]
107 pub fn dir7(&self) -> Dir7R {
108 Dir7R::new(((self.bits >> 7) & 1) != 0)
109 }
110 #[doc = "Bit 8 - DIR8"]
111 #[inline(always)]
112 pub fn dir8(&self) -> Dir8R {
113 Dir8R::new(((self.bits >> 8) & 1) != 0)
114 }
115 #[doc = "Bit 9 - DIR9"]
116 #[inline(always)]
117 pub fn dir9(&self) -> Dir9R {
118 Dir9R::new(((self.bits >> 9) & 1) != 0)
119 }
120 #[doc = "Bit 10 - DIR10"]
121 #[inline(always)]
122 pub fn dir10(&self) -> Dir10R {
123 Dir10R::new(((self.bits >> 10) & 1) != 0)
124 }
125 #[doc = "Bit 11 - DIR11"]
126 #[inline(always)]
127 pub fn dir11(&self) -> Dir11R {
128 Dir11R::new(((self.bits >> 11) & 1) != 0)
129 }
130 #[doc = "Bit 12 - DIR12"]
131 #[inline(always)]
132 pub fn dir12(&self) -> Dir12R {
133 Dir12R::new(((self.bits >> 12) & 1) != 0)
134 }
135 #[doc = "Bit 13 - DIR13"]
136 #[inline(always)]
137 pub fn dir13(&self) -> Dir13R {
138 Dir13R::new(((self.bits >> 13) & 1) != 0)
139 }
140 #[doc = "Bit 14 - DIR14"]
141 #[inline(always)]
142 pub fn dir14(&self) -> Dir14R {
143 Dir14R::new(((self.bits >> 14) & 1) != 0)
144 }
145 #[doc = "Bit 15 - DIR15"]
146 #[inline(always)]
147 pub fn dir15(&self) -> Dir15R {
148 Dir15R::new(((self.bits >> 15) & 1) != 0)
149 }
150}
151impl W {
152 #[doc = "Bit 0 - DIR0"]
153 #[inline(always)]
154 #[must_use]
155 pub fn dir0(&mut self) -> Dir0W<DircrSpec> {
156 Dir0W::new(self, 0)
157 }
158 #[doc = "Bit 1 - DIR1"]
159 #[inline(always)]
160 #[must_use]
161 pub fn dir1(&mut self) -> Dir1W<DircrSpec> {
162 Dir1W::new(self, 1)
163 }
164 #[doc = "Bit 2 - DIR2"]
165 #[inline(always)]
166 #[must_use]
167 pub fn dir2(&mut self) -> Dir2W<DircrSpec> {
168 Dir2W::new(self, 2)
169 }
170 #[doc = "Bit 3 - DIR3"]
171 #[inline(always)]
172 #[must_use]
173 pub fn dir3(&mut self) -> Dir3W<DircrSpec> {
174 Dir3W::new(self, 3)
175 }
176 #[doc = "Bit 4 - DIR4"]
177 #[inline(always)]
178 #[must_use]
179 pub fn dir4(&mut self) -> Dir4W<DircrSpec> {
180 Dir4W::new(self, 4)
181 }
182 #[doc = "Bit 5 - DIR5"]
183 #[inline(always)]
184 #[must_use]
185 pub fn dir5(&mut self) -> Dir5W<DircrSpec> {
186 Dir5W::new(self, 5)
187 }
188 #[doc = "Bit 6 - DIR6"]
189 #[inline(always)]
190 #[must_use]
191 pub fn dir6(&mut self) -> Dir6W<DircrSpec> {
192 Dir6W::new(self, 6)
193 }
194 #[doc = "Bit 7 - DIR7"]
195 #[inline(always)]
196 #[must_use]
197 pub fn dir7(&mut self) -> Dir7W<DircrSpec> {
198 Dir7W::new(self, 7)
199 }
200 #[doc = "Bit 8 - DIR8"]
201 #[inline(always)]
202 #[must_use]
203 pub fn dir8(&mut self) -> Dir8W<DircrSpec> {
204 Dir8W::new(self, 8)
205 }
206 #[doc = "Bit 9 - DIR9"]
207 #[inline(always)]
208 #[must_use]
209 pub fn dir9(&mut self) -> Dir9W<DircrSpec> {
210 Dir9W::new(self, 9)
211 }
212 #[doc = "Bit 10 - DIR10"]
213 #[inline(always)]
214 #[must_use]
215 pub fn dir10(&mut self) -> Dir10W<DircrSpec> {
216 Dir10W::new(self, 10)
217 }
218 #[doc = "Bit 11 - DIR11"]
219 #[inline(always)]
220 #[must_use]
221 pub fn dir11(&mut self) -> Dir11W<DircrSpec> {
222 Dir11W::new(self, 11)
223 }
224 #[doc = "Bit 12 - DIR12"]
225 #[inline(always)]
226 #[must_use]
227 pub fn dir12(&mut self) -> Dir12W<DircrSpec> {
228 Dir12W::new(self, 12)
229 }
230 #[doc = "Bit 13 - DIR13"]
231 #[inline(always)]
232 #[must_use]
233 pub fn dir13(&mut self) -> Dir13W<DircrSpec> {
234 Dir13W::new(self, 13)
235 }
236 #[doc = "Bit 14 - DIR14"]
237 #[inline(always)]
238 #[must_use]
239 pub fn dir14(&mut self) -> Dir14W<DircrSpec> {
240 Dir14W::new(self, 14)
241 }
242 #[doc = "Bit 15 - DIR15"]
243 #[inline(always)]
244 #[must_use]
245 pub fn dir15(&mut self) -> Dir15W<DircrSpec> {
246 Dir15W::new(self, 15)
247 }
248}
249#[doc = "DIRCR\n\nYou can [`read`](crate::generic::Reg::read) this register and get [`dircr::R`](R). You can [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`write_with_zero`](crate::generic::Reg::write_with_zero) this register using [`dircr::W`](W). You can also [`modify`](crate::generic::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
250pub struct DircrSpec;
251impl crate::RegisterSpec for DircrSpec {
252 type Ux = u32;
253}
254#[doc = "`read()` method returns [`dircr::R`](R) reader structure"]
255impl crate::Readable for DircrSpec {}
256#[doc = "`write(|w| ..)` method takes [`dircr::W`](W) writer structure"]
257impl crate::Writable for DircrSpec {
258 type Safety = crate::Unsafe;
259 const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
260 const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
261}
262#[doc = "`reset()` method sets DIRCR to value 0"]
263impl crate::Resettable for DircrSpec {
264 const RESET_VALUE: u32 = 0;
265}