stm32f1_staging/stm32f107/can1/
fm1r.rs1pub type R = crate::R<FM1Rrs>;
3pub type W = crate::W<FM1Rrs>;
5pub type FBM_R = crate::BitReader;
7pub type FBM_W<'a, REG> = crate::BitWriter<'a, REG>;
9impl R {
10 #[inline(always)]
14 pub fn fbm(&self, n: u8) -> FBM_R {
15 #[allow(clippy::no_effect)] [(); 28][n as usize];
16 FBM_R::new(((self.bits >> n) & 1) != 0)
17 }
18 #[inline(always)]
21 pub fn fbm_iter(&self) -> impl Iterator<Item = FBM_R> + '_ {
22 (0..28).map(move |n| FBM_R::new(((self.bits >> n) & 1) != 0))
23 }
24 #[inline(always)]
26 pub fn fbm0(&self) -> FBM_R {
27 FBM_R::new((self.bits & 1) != 0)
28 }
29 #[inline(always)]
31 pub fn fbm1(&self) -> FBM_R {
32 FBM_R::new(((self.bits >> 1) & 1) != 0)
33 }
34 #[inline(always)]
36 pub fn fbm2(&self) -> FBM_R {
37 FBM_R::new(((self.bits >> 2) & 1) != 0)
38 }
39 #[inline(always)]
41 pub fn fbm3(&self) -> FBM_R {
42 FBM_R::new(((self.bits >> 3) & 1) != 0)
43 }
44 #[inline(always)]
46 pub fn fbm4(&self) -> FBM_R {
47 FBM_R::new(((self.bits >> 4) & 1) != 0)
48 }
49 #[inline(always)]
51 pub fn fbm5(&self) -> FBM_R {
52 FBM_R::new(((self.bits >> 5) & 1) != 0)
53 }
54 #[inline(always)]
56 pub fn fbm6(&self) -> FBM_R {
57 FBM_R::new(((self.bits >> 6) & 1) != 0)
58 }
59 #[inline(always)]
61 pub fn fbm7(&self) -> FBM_R {
62 FBM_R::new(((self.bits >> 7) & 1) != 0)
63 }
64 #[inline(always)]
66 pub fn fbm8(&self) -> FBM_R {
67 FBM_R::new(((self.bits >> 8) & 1) != 0)
68 }
69 #[inline(always)]
71 pub fn fbm9(&self) -> FBM_R {
72 FBM_R::new(((self.bits >> 9) & 1) != 0)
73 }
74 #[inline(always)]
76 pub fn fbm10(&self) -> FBM_R {
77 FBM_R::new(((self.bits >> 10) & 1) != 0)
78 }
79 #[inline(always)]
81 pub fn fbm11(&self) -> FBM_R {
82 FBM_R::new(((self.bits >> 11) & 1) != 0)
83 }
84 #[inline(always)]
86 pub fn fbm12(&self) -> FBM_R {
87 FBM_R::new(((self.bits >> 12) & 1) != 0)
88 }
89 #[inline(always)]
91 pub fn fbm13(&self) -> FBM_R {
92 FBM_R::new(((self.bits >> 13) & 1) != 0)
93 }
94 #[inline(always)]
96 pub fn fbm14(&self) -> FBM_R {
97 FBM_R::new(((self.bits >> 14) & 1) != 0)
98 }
99 #[inline(always)]
101 pub fn fbm15(&self) -> FBM_R {
102 FBM_R::new(((self.bits >> 15) & 1) != 0)
103 }
104 #[inline(always)]
106 pub fn fbm16(&self) -> FBM_R {
107 FBM_R::new(((self.bits >> 16) & 1) != 0)
108 }
109 #[inline(always)]
111 pub fn fbm17(&self) -> FBM_R {
112 FBM_R::new(((self.bits >> 17) & 1) != 0)
113 }
114 #[inline(always)]
116 pub fn fbm18(&self) -> FBM_R {
117 FBM_R::new(((self.bits >> 18) & 1) != 0)
118 }
119 #[inline(always)]
121 pub fn fbm19(&self) -> FBM_R {
122 FBM_R::new(((self.bits >> 19) & 1) != 0)
123 }
124 #[inline(always)]
126 pub fn fbm20(&self) -> FBM_R {
127 FBM_R::new(((self.bits >> 20) & 1) != 0)
128 }
129 #[inline(always)]
131 pub fn fbm21(&self) -> FBM_R {
132 FBM_R::new(((self.bits >> 21) & 1) != 0)
133 }
134 #[inline(always)]
136 pub fn fbm22(&self) -> FBM_R {
137 FBM_R::new(((self.bits >> 22) & 1) != 0)
138 }
139 #[inline(always)]
141 pub fn fbm23(&self) -> FBM_R {
142 FBM_R::new(((self.bits >> 23) & 1) != 0)
143 }
144 #[inline(always)]
146 pub fn fbm24(&self) -> FBM_R {
147 FBM_R::new(((self.bits >> 24) & 1) != 0)
148 }
149 #[inline(always)]
151 pub fn fbm25(&self) -> FBM_R {
152 FBM_R::new(((self.bits >> 25) & 1) != 0)
153 }
154 #[inline(always)]
156 pub fn fbm26(&self) -> FBM_R {
157 FBM_R::new(((self.bits >> 26) & 1) != 0)
158 }
159 #[inline(always)]
161 pub fn fbm27(&self) -> FBM_R {
162 FBM_R::new(((self.bits >> 27) & 1) != 0)
163 }
164}
165impl core::fmt::Debug for R {
166 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
167 f.debug_struct("FM1R")
168 .field("fbm0", &self.fbm0())
169 .field("fbm1", &self.fbm1())
170 .field("fbm2", &self.fbm2())
171 .field("fbm3", &self.fbm3())
172 .field("fbm4", &self.fbm4())
173 .field("fbm5", &self.fbm5())
174 .field("fbm6", &self.fbm6())
175 .field("fbm7", &self.fbm7())
176 .field("fbm8", &self.fbm8())
177 .field("fbm9", &self.fbm9())
178 .field("fbm10", &self.fbm10())
179 .field("fbm11", &self.fbm11())
180 .field("fbm12", &self.fbm12())
181 .field("fbm13", &self.fbm13())
182 .field("fbm14", &self.fbm14())
183 .field("fbm15", &self.fbm15())
184 .field("fbm16", &self.fbm16())
185 .field("fbm17", &self.fbm17())
186 .field("fbm18", &self.fbm18())
187 .field("fbm19", &self.fbm19())
188 .field("fbm20", &self.fbm20())
189 .field("fbm21", &self.fbm21())
190 .field("fbm22", &self.fbm22())
191 .field("fbm23", &self.fbm23())
192 .field("fbm24", &self.fbm24())
193 .field("fbm25", &self.fbm25())
194 .field("fbm26", &self.fbm26())
195 .field("fbm27", &self.fbm27())
196 .finish()
197 }
198}
199impl W {
200 #[inline(always)]
204 pub fn fbm(&mut self, n: u8) -> FBM_W<FM1Rrs> {
205 #[allow(clippy::no_effect)] [(); 28][n as usize];
206 FBM_W::new(self, n)
207 }
208 #[inline(always)]
210 pub fn fbm0(&mut self) -> FBM_W<FM1Rrs> {
211 FBM_W::new(self, 0)
212 }
213 #[inline(always)]
215 pub fn fbm1(&mut self) -> FBM_W<FM1Rrs> {
216 FBM_W::new(self, 1)
217 }
218 #[inline(always)]
220 pub fn fbm2(&mut self) -> FBM_W<FM1Rrs> {
221 FBM_W::new(self, 2)
222 }
223 #[inline(always)]
225 pub fn fbm3(&mut self) -> FBM_W<FM1Rrs> {
226 FBM_W::new(self, 3)
227 }
228 #[inline(always)]
230 pub fn fbm4(&mut self) -> FBM_W<FM1Rrs> {
231 FBM_W::new(self, 4)
232 }
233 #[inline(always)]
235 pub fn fbm5(&mut self) -> FBM_W<FM1Rrs> {
236 FBM_W::new(self, 5)
237 }
238 #[inline(always)]
240 pub fn fbm6(&mut self) -> FBM_W<FM1Rrs> {
241 FBM_W::new(self, 6)
242 }
243 #[inline(always)]
245 pub fn fbm7(&mut self) -> FBM_W<FM1Rrs> {
246 FBM_W::new(self, 7)
247 }
248 #[inline(always)]
250 pub fn fbm8(&mut self) -> FBM_W<FM1Rrs> {
251 FBM_W::new(self, 8)
252 }
253 #[inline(always)]
255 pub fn fbm9(&mut self) -> FBM_W<FM1Rrs> {
256 FBM_W::new(self, 9)
257 }
258 #[inline(always)]
260 pub fn fbm10(&mut self) -> FBM_W<FM1Rrs> {
261 FBM_W::new(self, 10)
262 }
263 #[inline(always)]
265 pub fn fbm11(&mut self) -> FBM_W<FM1Rrs> {
266 FBM_W::new(self, 11)
267 }
268 #[inline(always)]
270 pub fn fbm12(&mut self) -> FBM_W<FM1Rrs> {
271 FBM_W::new(self, 12)
272 }
273 #[inline(always)]
275 pub fn fbm13(&mut self) -> FBM_W<FM1Rrs> {
276 FBM_W::new(self, 13)
277 }
278 #[inline(always)]
280 pub fn fbm14(&mut self) -> FBM_W<FM1Rrs> {
281 FBM_W::new(self, 14)
282 }
283 #[inline(always)]
285 pub fn fbm15(&mut self) -> FBM_W<FM1Rrs> {
286 FBM_W::new(self, 15)
287 }
288 #[inline(always)]
290 pub fn fbm16(&mut self) -> FBM_W<FM1Rrs> {
291 FBM_W::new(self, 16)
292 }
293 #[inline(always)]
295 pub fn fbm17(&mut self) -> FBM_W<FM1Rrs> {
296 FBM_W::new(self, 17)
297 }
298 #[inline(always)]
300 pub fn fbm18(&mut self) -> FBM_W<FM1Rrs> {
301 FBM_W::new(self, 18)
302 }
303 #[inline(always)]
305 pub fn fbm19(&mut self) -> FBM_W<FM1Rrs> {
306 FBM_W::new(self, 19)
307 }
308 #[inline(always)]
310 pub fn fbm20(&mut self) -> FBM_W<FM1Rrs> {
311 FBM_W::new(self, 20)
312 }
313 #[inline(always)]
315 pub fn fbm21(&mut self) -> FBM_W<FM1Rrs> {
316 FBM_W::new(self, 21)
317 }
318 #[inline(always)]
320 pub fn fbm22(&mut self) -> FBM_W<FM1Rrs> {
321 FBM_W::new(self, 22)
322 }
323 #[inline(always)]
325 pub fn fbm23(&mut self) -> FBM_W<FM1Rrs> {
326 FBM_W::new(self, 23)
327 }
328 #[inline(always)]
330 pub fn fbm24(&mut self) -> FBM_W<FM1Rrs> {
331 FBM_W::new(self, 24)
332 }
333 #[inline(always)]
335 pub fn fbm25(&mut self) -> FBM_W<FM1Rrs> {
336 FBM_W::new(self, 25)
337 }
338 #[inline(always)]
340 pub fn fbm26(&mut self) -> FBM_W<FM1Rrs> {
341 FBM_W::new(self, 26)
342 }
343 #[inline(always)]
345 pub fn fbm27(&mut self) -> FBM_W<FM1Rrs> {
346 FBM_W::new(self, 27)
347 }
348}
349pub struct FM1Rrs;
355impl crate::RegisterSpec for FM1Rrs {
356 type Ux = u32;
357}
358impl crate::Readable for FM1Rrs {}
360impl crate::Writable for FM1Rrs {
362 type Safety = crate::Unsafe;
363}
364impl crate::Resettable for FM1Rrs {}