1#[doc = "Register `ADGRSR` reader"]
2pub struct R(crate::R<ADGRSR_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<ADGRSR_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<ADGRSR_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<ADGRSR_SPEC>) -> Self {
13 R(reader)
14 }
15}
16#[doc = "Field `ACTGR0` reader - Scan Group n Status"]
17pub type ACTGR0_R = crate::BitReader<ACTGR0_A>;
18#[doc = "Scan Group n Status\n\nValue on reset: 0"]
19#[derive(Clone, Copy, Debug, PartialEq, Eq)]
20pub enum ACTGR0_A {
21 #[doc = "0: Scan group n is idle"]
22 _0 = 0,
23 #[doc = "1: Scan group n is in the scanning operation"]
24 _1 = 1,
25}
26impl From<ACTGR0_A> for bool {
27 #[inline(always)]
28 fn from(variant: ACTGR0_A) -> Self {
29 variant as u8 != 0
30 }
31}
32impl ACTGR0_R {
33 #[doc = "Get enumerated values variant"]
34 #[inline(always)]
35 pub fn variant(&self) -> ACTGR0_A {
36 match self.bits {
37 false => ACTGR0_A::_0,
38 true => ACTGR0_A::_1,
39 }
40 }
41 #[doc = "Checks if the value of the field is `_0`"]
42 #[inline(always)]
43 pub fn is_0(&self) -> bool {
44 *self == ACTGR0_A::_0
45 }
46 #[doc = "Checks if the value of the field is `_1`"]
47 #[inline(always)]
48 pub fn is_1(&self) -> bool {
49 *self == ACTGR0_A::_1
50 }
51}
52#[doc = "Field `ACTGR1` reader - Scan Group n Status"]
53pub type ACTGR1_R = crate::BitReader<ACTGR1_A>;
54#[doc = "Scan Group n Status\n\nValue on reset: 0"]
55#[derive(Clone, Copy, Debug, PartialEq, Eq)]
56pub enum ACTGR1_A {
57 #[doc = "0: Scan group n is idle"]
58 _0 = 0,
59 #[doc = "1: Scan group n is in the scanning operation"]
60 _1 = 1,
61}
62impl From<ACTGR1_A> for bool {
63 #[inline(always)]
64 fn from(variant: ACTGR1_A) -> Self {
65 variant as u8 != 0
66 }
67}
68impl ACTGR1_R {
69 #[doc = "Get enumerated values variant"]
70 #[inline(always)]
71 pub fn variant(&self) -> ACTGR1_A {
72 match self.bits {
73 false => ACTGR1_A::_0,
74 true => ACTGR1_A::_1,
75 }
76 }
77 #[doc = "Checks if the value of the field is `_0`"]
78 #[inline(always)]
79 pub fn is_0(&self) -> bool {
80 *self == ACTGR1_A::_0
81 }
82 #[doc = "Checks if the value of the field is `_1`"]
83 #[inline(always)]
84 pub fn is_1(&self) -> bool {
85 *self == ACTGR1_A::_1
86 }
87}
88#[doc = "Field `ACTGR2` reader - Scan Group n Status"]
89pub type ACTGR2_R = crate::BitReader<ACTGR2_A>;
90#[doc = "Scan Group n Status\n\nValue on reset: 0"]
91#[derive(Clone, Copy, Debug, PartialEq, Eq)]
92pub enum ACTGR2_A {
93 #[doc = "0: Scan group n is idle"]
94 _0 = 0,
95 #[doc = "1: Scan group n is in the scanning operation"]
96 _1 = 1,
97}
98impl From<ACTGR2_A> for bool {
99 #[inline(always)]
100 fn from(variant: ACTGR2_A) -> Self {
101 variant as u8 != 0
102 }
103}
104impl ACTGR2_R {
105 #[doc = "Get enumerated values variant"]
106 #[inline(always)]
107 pub fn variant(&self) -> ACTGR2_A {
108 match self.bits {
109 false => ACTGR2_A::_0,
110 true => ACTGR2_A::_1,
111 }
112 }
113 #[doc = "Checks if the value of the field is `_0`"]
114 #[inline(always)]
115 pub fn is_0(&self) -> bool {
116 *self == ACTGR2_A::_0
117 }
118 #[doc = "Checks if the value of the field is `_1`"]
119 #[inline(always)]
120 pub fn is_1(&self) -> bool {
121 *self == ACTGR2_A::_1
122 }
123}
124#[doc = "Field `ACTGR3` reader - Scan Group n Status"]
125pub type ACTGR3_R = crate::BitReader<ACTGR3_A>;
126#[doc = "Scan Group n Status\n\nValue on reset: 0"]
127#[derive(Clone, Copy, Debug, PartialEq, Eq)]
128pub enum ACTGR3_A {
129 #[doc = "0: Scan group n is idle"]
130 _0 = 0,
131 #[doc = "1: Scan group n is in the scanning operation"]
132 _1 = 1,
133}
134impl From<ACTGR3_A> for bool {
135 #[inline(always)]
136 fn from(variant: ACTGR3_A) -> Self {
137 variant as u8 != 0
138 }
139}
140impl ACTGR3_R {
141 #[doc = "Get enumerated values variant"]
142 #[inline(always)]
143 pub fn variant(&self) -> ACTGR3_A {
144 match self.bits {
145 false => ACTGR3_A::_0,
146 true => ACTGR3_A::_1,
147 }
148 }
149 #[doc = "Checks if the value of the field is `_0`"]
150 #[inline(always)]
151 pub fn is_0(&self) -> bool {
152 *self == ACTGR3_A::_0
153 }
154 #[doc = "Checks if the value of the field is `_1`"]
155 #[inline(always)]
156 pub fn is_1(&self) -> bool {
157 *self == ACTGR3_A::_1
158 }
159}
160#[doc = "Field `ACTGR4` reader - Scan Group n Status"]
161pub type ACTGR4_R = crate::BitReader<ACTGR4_A>;
162#[doc = "Scan Group n Status\n\nValue on reset: 0"]
163#[derive(Clone, Copy, Debug, PartialEq, Eq)]
164pub enum ACTGR4_A {
165 #[doc = "0: Scan group n is idle"]
166 _0 = 0,
167 #[doc = "1: Scan group n is in the scanning operation"]
168 _1 = 1,
169}
170impl From<ACTGR4_A> for bool {
171 #[inline(always)]
172 fn from(variant: ACTGR4_A) -> Self {
173 variant as u8 != 0
174 }
175}
176impl ACTGR4_R {
177 #[doc = "Get enumerated values variant"]
178 #[inline(always)]
179 pub fn variant(&self) -> ACTGR4_A {
180 match self.bits {
181 false => ACTGR4_A::_0,
182 true => ACTGR4_A::_1,
183 }
184 }
185 #[doc = "Checks if the value of the field is `_0`"]
186 #[inline(always)]
187 pub fn is_0(&self) -> bool {
188 *self == ACTGR4_A::_0
189 }
190 #[doc = "Checks if the value of the field is `_1`"]
191 #[inline(always)]
192 pub fn is_1(&self) -> bool {
193 *self == ACTGR4_A::_1
194 }
195}
196#[doc = "Field `ACTGR5` reader - Scan Group n Status"]
197pub type ACTGR5_R = crate::BitReader<ACTGR5_A>;
198#[doc = "Scan Group n Status\n\nValue on reset: 0"]
199#[derive(Clone, Copy, Debug, PartialEq, Eq)]
200pub enum ACTGR5_A {
201 #[doc = "0: Scan group n is idle"]
202 _0 = 0,
203 #[doc = "1: Scan group n is in the scanning operation"]
204 _1 = 1,
205}
206impl From<ACTGR5_A> for bool {
207 #[inline(always)]
208 fn from(variant: ACTGR5_A) -> Self {
209 variant as u8 != 0
210 }
211}
212impl ACTGR5_R {
213 #[doc = "Get enumerated values variant"]
214 #[inline(always)]
215 pub fn variant(&self) -> ACTGR5_A {
216 match self.bits {
217 false => ACTGR5_A::_0,
218 true => ACTGR5_A::_1,
219 }
220 }
221 #[doc = "Checks if the value of the field is `_0`"]
222 #[inline(always)]
223 pub fn is_0(&self) -> bool {
224 *self == ACTGR5_A::_0
225 }
226 #[doc = "Checks if the value of the field is `_1`"]
227 #[inline(always)]
228 pub fn is_1(&self) -> bool {
229 *self == ACTGR5_A::_1
230 }
231}
232#[doc = "Field `ACTGR6` reader - Scan Group n Status"]
233pub type ACTGR6_R = crate::BitReader<ACTGR6_A>;
234#[doc = "Scan Group n Status\n\nValue on reset: 0"]
235#[derive(Clone, Copy, Debug, PartialEq, Eq)]
236pub enum ACTGR6_A {
237 #[doc = "0: Scan group n is idle"]
238 _0 = 0,
239 #[doc = "1: Scan group n is in the scanning operation"]
240 _1 = 1,
241}
242impl From<ACTGR6_A> for bool {
243 #[inline(always)]
244 fn from(variant: ACTGR6_A) -> Self {
245 variant as u8 != 0
246 }
247}
248impl ACTGR6_R {
249 #[doc = "Get enumerated values variant"]
250 #[inline(always)]
251 pub fn variant(&self) -> ACTGR6_A {
252 match self.bits {
253 false => ACTGR6_A::_0,
254 true => ACTGR6_A::_1,
255 }
256 }
257 #[doc = "Checks if the value of the field is `_0`"]
258 #[inline(always)]
259 pub fn is_0(&self) -> bool {
260 *self == ACTGR6_A::_0
261 }
262 #[doc = "Checks if the value of the field is `_1`"]
263 #[inline(always)]
264 pub fn is_1(&self) -> bool {
265 *self == ACTGR6_A::_1
266 }
267}
268#[doc = "Field `ACTGR7` reader - Scan Group n Status"]
269pub type ACTGR7_R = crate::BitReader<ACTGR7_A>;
270#[doc = "Scan Group n Status\n\nValue on reset: 0"]
271#[derive(Clone, Copy, Debug, PartialEq, Eq)]
272pub enum ACTGR7_A {
273 #[doc = "0: Scan group n is idle"]
274 _0 = 0,
275 #[doc = "1: Scan group n is in the scanning operation"]
276 _1 = 1,
277}
278impl From<ACTGR7_A> for bool {
279 #[inline(always)]
280 fn from(variant: ACTGR7_A) -> Self {
281 variant as u8 != 0
282 }
283}
284impl ACTGR7_R {
285 #[doc = "Get enumerated values variant"]
286 #[inline(always)]
287 pub fn variant(&self) -> ACTGR7_A {
288 match self.bits {
289 false => ACTGR7_A::_0,
290 true => ACTGR7_A::_1,
291 }
292 }
293 #[doc = "Checks if the value of the field is `_0`"]
294 #[inline(always)]
295 pub fn is_0(&self) -> bool {
296 *self == ACTGR7_A::_0
297 }
298 #[doc = "Checks if the value of the field is `_1`"]
299 #[inline(always)]
300 pub fn is_1(&self) -> bool {
301 *self == ACTGR7_A::_1
302 }
303}
304#[doc = "Field `ACTGR8` reader - Scan Group n Status"]
305pub type ACTGR8_R = crate::BitReader<ACTGR8_A>;
306#[doc = "Scan Group n Status\n\nValue on reset: 0"]
307#[derive(Clone, Copy, Debug, PartialEq, Eq)]
308pub enum ACTGR8_A {
309 #[doc = "0: Scan group n is idle"]
310 _0 = 0,
311 #[doc = "1: Scan group n is in the scanning operation"]
312 _1 = 1,
313}
314impl From<ACTGR8_A> for bool {
315 #[inline(always)]
316 fn from(variant: ACTGR8_A) -> Self {
317 variant as u8 != 0
318 }
319}
320impl ACTGR8_R {
321 #[doc = "Get enumerated values variant"]
322 #[inline(always)]
323 pub fn variant(&self) -> ACTGR8_A {
324 match self.bits {
325 false => ACTGR8_A::_0,
326 true => ACTGR8_A::_1,
327 }
328 }
329 #[doc = "Checks if the value of the field is `_0`"]
330 #[inline(always)]
331 pub fn is_0(&self) -> bool {
332 *self == ACTGR8_A::_0
333 }
334 #[doc = "Checks if the value of the field is `_1`"]
335 #[inline(always)]
336 pub fn is_1(&self) -> bool {
337 *self == ACTGR8_A::_1
338 }
339}
340impl R {
341 #[doc = "Bit 0 - Scan Group n Status"]
342 #[inline(always)]
343 pub fn actgr0(&self) -> ACTGR0_R {
344 ACTGR0_R::new((self.bits & 1) != 0)
345 }
346 #[doc = "Bit 1 - Scan Group n Status"]
347 #[inline(always)]
348 pub fn actgr1(&self) -> ACTGR1_R {
349 ACTGR1_R::new(((self.bits >> 1) & 1) != 0)
350 }
351 #[doc = "Bit 2 - Scan Group n Status"]
352 #[inline(always)]
353 pub fn actgr2(&self) -> ACTGR2_R {
354 ACTGR2_R::new(((self.bits >> 2) & 1) != 0)
355 }
356 #[doc = "Bit 3 - Scan Group n Status"]
357 #[inline(always)]
358 pub fn actgr3(&self) -> ACTGR3_R {
359 ACTGR3_R::new(((self.bits >> 3) & 1) != 0)
360 }
361 #[doc = "Bit 4 - Scan Group n Status"]
362 #[inline(always)]
363 pub fn actgr4(&self) -> ACTGR4_R {
364 ACTGR4_R::new(((self.bits >> 4) & 1) != 0)
365 }
366 #[doc = "Bit 5 - Scan Group n Status"]
367 #[inline(always)]
368 pub fn actgr5(&self) -> ACTGR5_R {
369 ACTGR5_R::new(((self.bits >> 5) & 1) != 0)
370 }
371 #[doc = "Bit 6 - Scan Group n Status"]
372 #[inline(always)]
373 pub fn actgr6(&self) -> ACTGR6_R {
374 ACTGR6_R::new(((self.bits >> 6) & 1) != 0)
375 }
376 #[doc = "Bit 7 - Scan Group n Status"]
377 #[inline(always)]
378 pub fn actgr7(&self) -> ACTGR7_R {
379 ACTGR7_R::new(((self.bits >> 7) & 1) != 0)
380 }
381 #[doc = "Bit 8 - Scan Group n Status"]
382 #[inline(always)]
383 pub fn actgr8(&self) -> ACTGR8_R {
384 ACTGR8_R::new(((self.bits >> 8) & 1) != 0)
385 }
386}
387#[doc = "Scan Group Status Register\n\nThis register you can [`read`](crate::generic::Reg::read). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [adgrsr](index.html) module"]
388pub struct ADGRSR_SPEC;
389impl crate::RegisterSpec for ADGRSR_SPEC {
390 type Ux = u32;
391}
392#[doc = "`read()` method returns [adgrsr::R](R) reader structure"]
393impl crate::Readable for ADGRSR_SPEC {
394 type Reader = R;
395}
396#[doc = "`reset()` method sets ADGRSR to value 0"]
397impl crate::Resettable for ADGRSR_SPEC {
398 const RESET_VALUE: Self::Ux = 0;
399}