1#[doc = "Register `IDLECONF` reader"]
2pub struct R(crate::R<IDLECONF_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<IDLECONF_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<IDLECONF_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<IDLECONF_SPEC>) -> Self {
13 R(reader)
14 }
15}
16#[doc = "Register `IDLECONF` writer"]
17pub struct W(crate::W<IDLECONF_SPEC>);
18impl core::ops::Deref for W {
19 type Target = crate::W<IDLECONF_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<IDLECONF_SPEC>> for W {
32 #[inline(always)]
33 fn from(writer: crate::W<IDLECONF_SPEC>) -> Self {
34 W(writer)
35 }
36}
37#[doc = "Channel 0 Idle Phase Configuration\n\nValue on reset: 0"]
38#[derive(Clone, Copy, Debug, PartialEq)]
39#[repr(u8)]
40pub enum CH0_A {
41 #[doc = "0: CH0 output is disabled in idle phase"]
42 DISABLE = 0,
43 #[doc = "1: CH0 output is high in idle phase"]
44 HIGH = 1,
45 #[doc = "2: CH0 output is low in idle phase"]
46 LOW = 2,
47 #[doc = "3: CH0 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
48 DAC = 3,
49}
50impl From<CH0_A> for u8 {
51 #[inline(always)]
52 fn from(variant: CH0_A) -> Self {
53 variant as _
54 }
55}
56#[doc = "Field `CH0` reader - Channel 0 Idle Phase Configuration"]
57pub type CH0_R = crate::FieldReader<u8, CH0_A>;
58impl CH0_R {
59 #[doc = "Get enumerated values variant"]
60 #[inline(always)]
61 pub fn variant(&self) -> CH0_A {
62 match self.bits {
63 0 => CH0_A::DISABLE,
64 1 => CH0_A::HIGH,
65 2 => CH0_A::LOW,
66 3 => CH0_A::DAC,
67 _ => unreachable!(),
68 }
69 }
70 #[doc = "Checks if the value of the field is `DISABLE`"]
71 #[inline(always)]
72 pub fn is_disable(&self) -> bool {
73 *self == CH0_A::DISABLE
74 }
75 #[doc = "Checks if the value of the field is `HIGH`"]
76 #[inline(always)]
77 pub fn is_high(&self) -> bool {
78 *self == CH0_A::HIGH
79 }
80 #[doc = "Checks if the value of the field is `LOW`"]
81 #[inline(always)]
82 pub fn is_low(&self) -> bool {
83 *self == CH0_A::LOW
84 }
85 #[doc = "Checks if the value of the field is `DAC`"]
86 #[inline(always)]
87 pub fn is_dac(&self) -> bool {
88 *self == CH0_A::DAC
89 }
90}
91#[doc = "Field `CH0` writer - Channel 0 Idle Phase Configuration"]
92pub type CH0_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH0_A, 2, 0>;
93impl<'a> CH0_W<'a> {
94 #[doc = "CH0 output is disabled in idle phase"]
95 #[inline(always)]
96 pub fn disable(self) -> &'a mut W {
97 self.variant(CH0_A::DISABLE)
98 }
99 #[doc = "CH0 output is high in idle phase"]
100 #[inline(always)]
101 pub fn high(self) -> &'a mut W {
102 self.variant(CH0_A::HIGH)
103 }
104 #[doc = "CH0 output is low in idle phase"]
105 #[inline(always)]
106 pub fn low(self) -> &'a mut W {
107 self.variant(CH0_A::LOW)
108 }
109 #[doc = "CH0 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
110 #[inline(always)]
111 pub fn dac(self) -> &'a mut W {
112 self.variant(CH0_A::DAC)
113 }
114}
115#[doc = "Channel 1 Idle Phase Configuration\n\nValue on reset: 0"]
116#[derive(Clone, Copy, Debug, PartialEq)]
117#[repr(u8)]
118pub enum CH1_A {
119 #[doc = "0: CH1 output is disabled in idle phase"]
120 DISABLE = 0,
121 #[doc = "1: CH1 output is high in idle phase"]
122 HIGH = 1,
123 #[doc = "2: CH1 output is low in idle phase"]
124 LOW = 2,
125 #[doc = "3: CH1 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
126 DAC = 3,
127}
128impl From<CH1_A> for u8 {
129 #[inline(always)]
130 fn from(variant: CH1_A) -> Self {
131 variant as _
132 }
133}
134#[doc = "Field `CH1` reader - Channel 1 Idle Phase Configuration"]
135pub type CH1_R = crate::FieldReader<u8, CH1_A>;
136impl CH1_R {
137 #[doc = "Get enumerated values variant"]
138 #[inline(always)]
139 pub fn variant(&self) -> CH1_A {
140 match self.bits {
141 0 => CH1_A::DISABLE,
142 1 => CH1_A::HIGH,
143 2 => CH1_A::LOW,
144 3 => CH1_A::DAC,
145 _ => unreachable!(),
146 }
147 }
148 #[doc = "Checks if the value of the field is `DISABLE`"]
149 #[inline(always)]
150 pub fn is_disable(&self) -> bool {
151 *self == CH1_A::DISABLE
152 }
153 #[doc = "Checks if the value of the field is `HIGH`"]
154 #[inline(always)]
155 pub fn is_high(&self) -> bool {
156 *self == CH1_A::HIGH
157 }
158 #[doc = "Checks if the value of the field is `LOW`"]
159 #[inline(always)]
160 pub fn is_low(&self) -> bool {
161 *self == CH1_A::LOW
162 }
163 #[doc = "Checks if the value of the field is `DAC`"]
164 #[inline(always)]
165 pub fn is_dac(&self) -> bool {
166 *self == CH1_A::DAC
167 }
168}
169#[doc = "Field `CH1` writer - Channel 1 Idle Phase Configuration"]
170pub type CH1_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH1_A, 2, 2>;
171impl<'a> CH1_W<'a> {
172 #[doc = "CH1 output is disabled in idle phase"]
173 #[inline(always)]
174 pub fn disable(self) -> &'a mut W {
175 self.variant(CH1_A::DISABLE)
176 }
177 #[doc = "CH1 output is high in idle phase"]
178 #[inline(always)]
179 pub fn high(self) -> &'a mut W {
180 self.variant(CH1_A::HIGH)
181 }
182 #[doc = "CH1 output is low in idle phase"]
183 #[inline(always)]
184 pub fn low(self) -> &'a mut W {
185 self.variant(CH1_A::LOW)
186 }
187 #[doc = "CH1 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
188 #[inline(always)]
189 pub fn dac(self) -> &'a mut W {
190 self.variant(CH1_A::DAC)
191 }
192}
193#[doc = "Channel 2 Idle Phase Configuration\n\nValue on reset: 0"]
194#[derive(Clone, Copy, Debug, PartialEq)]
195#[repr(u8)]
196pub enum CH2_A {
197 #[doc = "0: CH2 output is disabled in idle phase"]
198 DISABLE = 0,
199 #[doc = "1: CH2 output is high in idle phase"]
200 HIGH = 1,
201 #[doc = "2: CH2 output is low in idle phase"]
202 LOW = 2,
203 #[doc = "3: CH2 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
204 DAC = 3,
205}
206impl From<CH2_A> for u8 {
207 #[inline(always)]
208 fn from(variant: CH2_A) -> Self {
209 variant as _
210 }
211}
212#[doc = "Field `CH2` reader - Channel 2 Idle Phase Configuration"]
213pub type CH2_R = crate::FieldReader<u8, CH2_A>;
214impl CH2_R {
215 #[doc = "Get enumerated values variant"]
216 #[inline(always)]
217 pub fn variant(&self) -> CH2_A {
218 match self.bits {
219 0 => CH2_A::DISABLE,
220 1 => CH2_A::HIGH,
221 2 => CH2_A::LOW,
222 3 => CH2_A::DAC,
223 _ => unreachable!(),
224 }
225 }
226 #[doc = "Checks if the value of the field is `DISABLE`"]
227 #[inline(always)]
228 pub fn is_disable(&self) -> bool {
229 *self == CH2_A::DISABLE
230 }
231 #[doc = "Checks if the value of the field is `HIGH`"]
232 #[inline(always)]
233 pub fn is_high(&self) -> bool {
234 *self == CH2_A::HIGH
235 }
236 #[doc = "Checks if the value of the field is `LOW`"]
237 #[inline(always)]
238 pub fn is_low(&self) -> bool {
239 *self == CH2_A::LOW
240 }
241 #[doc = "Checks if the value of the field is `DAC`"]
242 #[inline(always)]
243 pub fn is_dac(&self) -> bool {
244 *self == CH2_A::DAC
245 }
246}
247#[doc = "Field `CH2` writer - Channel 2 Idle Phase Configuration"]
248pub type CH2_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH2_A, 2, 4>;
249impl<'a> CH2_W<'a> {
250 #[doc = "CH2 output is disabled in idle phase"]
251 #[inline(always)]
252 pub fn disable(self) -> &'a mut W {
253 self.variant(CH2_A::DISABLE)
254 }
255 #[doc = "CH2 output is high in idle phase"]
256 #[inline(always)]
257 pub fn high(self) -> &'a mut W {
258 self.variant(CH2_A::HIGH)
259 }
260 #[doc = "CH2 output is low in idle phase"]
261 #[inline(always)]
262 pub fn low(self) -> &'a mut W {
263 self.variant(CH2_A::LOW)
264 }
265 #[doc = "CH2 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
266 #[inline(always)]
267 pub fn dac(self) -> &'a mut W {
268 self.variant(CH2_A::DAC)
269 }
270}
271#[doc = "Channel 3 Idle Phase Configuration\n\nValue on reset: 0"]
272#[derive(Clone, Copy, Debug, PartialEq)]
273#[repr(u8)]
274pub enum CH3_A {
275 #[doc = "0: CH3 output is disabled in idle phase"]
276 DISABLE = 0,
277 #[doc = "1: CH3 output is high in idle phase"]
278 HIGH = 1,
279 #[doc = "2: CH3 output is low in idle phase"]
280 LOW = 2,
281 #[doc = "3: CH3 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
282 DAC = 3,
283}
284impl From<CH3_A> for u8 {
285 #[inline(always)]
286 fn from(variant: CH3_A) -> Self {
287 variant as _
288 }
289}
290#[doc = "Field `CH3` reader - Channel 3 Idle Phase Configuration"]
291pub type CH3_R = crate::FieldReader<u8, CH3_A>;
292impl CH3_R {
293 #[doc = "Get enumerated values variant"]
294 #[inline(always)]
295 pub fn variant(&self) -> CH3_A {
296 match self.bits {
297 0 => CH3_A::DISABLE,
298 1 => CH3_A::HIGH,
299 2 => CH3_A::LOW,
300 3 => CH3_A::DAC,
301 _ => unreachable!(),
302 }
303 }
304 #[doc = "Checks if the value of the field is `DISABLE`"]
305 #[inline(always)]
306 pub fn is_disable(&self) -> bool {
307 *self == CH3_A::DISABLE
308 }
309 #[doc = "Checks if the value of the field is `HIGH`"]
310 #[inline(always)]
311 pub fn is_high(&self) -> bool {
312 *self == CH3_A::HIGH
313 }
314 #[doc = "Checks if the value of the field is `LOW`"]
315 #[inline(always)]
316 pub fn is_low(&self) -> bool {
317 *self == CH3_A::LOW
318 }
319 #[doc = "Checks if the value of the field is `DAC`"]
320 #[inline(always)]
321 pub fn is_dac(&self) -> bool {
322 *self == CH3_A::DAC
323 }
324}
325#[doc = "Field `CH3` writer - Channel 3 Idle Phase Configuration"]
326pub type CH3_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH3_A, 2, 6>;
327impl<'a> CH3_W<'a> {
328 #[doc = "CH3 output is disabled in idle phase"]
329 #[inline(always)]
330 pub fn disable(self) -> &'a mut W {
331 self.variant(CH3_A::DISABLE)
332 }
333 #[doc = "CH3 output is high in idle phase"]
334 #[inline(always)]
335 pub fn high(self) -> &'a mut W {
336 self.variant(CH3_A::HIGH)
337 }
338 #[doc = "CH3 output is low in idle phase"]
339 #[inline(always)]
340 pub fn low(self) -> &'a mut W {
341 self.variant(CH3_A::LOW)
342 }
343 #[doc = "CH3 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
344 #[inline(always)]
345 pub fn dac(self) -> &'a mut W {
346 self.variant(CH3_A::DAC)
347 }
348}
349#[doc = "Channel 4 Idle Phase Configuration\n\nValue on reset: 0"]
350#[derive(Clone, Copy, Debug, PartialEq)]
351#[repr(u8)]
352pub enum CH4_A {
353 #[doc = "0: CH4 output is disabled in idle phase"]
354 DISABLE = 0,
355 #[doc = "1: CH4 output is high in idle phase"]
356 HIGH = 1,
357 #[doc = "2: CH4 output is low in idle phase"]
358 LOW = 2,
359 #[doc = "3: CH4 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
360 DAC = 3,
361}
362impl From<CH4_A> for u8 {
363 #[inline(always)]
364 fn from(variant: CH4_A) -> Self {
365 variant as _
366 }
367}
368#[doc = "Field `CH4` reader - Channel 4 Idle Phase Configuration"]
369pub type CH4_R = crate::FieldReader<u8, CH4_A>;
370impl CH4_R {
371 #[doc = "Get enumerated values variant"]
372 #[inline(always)]
373 pub fn variant(&self) -> CH4_A {
374 match self.bits {
375 0 => CH4_A::DISABLE,
376 1 => CH4_A::HIGH,
377 2 => CH4_A::LOW,
378 3 => CH4_A::DAC,
379 _ => unreachable!(),
380 }
381 }
382 #[doc = "Checks if the value of the field is `DISABLE`"]
383 #[inline(always)]
384 pub fn is_disable(&self) -> bool {
385 *self == CH4_A::DISABLE
386 }
387 #[doc = "Checks if the value of the field is `HIGH`"]
388 #[inline(always)]
389 pub fn is_high(&self) -> bool {
390 *self == CH4_A::HIGH
391 }
392 #[doc = "Checks if the value of the field is `LOW`"]
393 #[inline(always)]
394 pub fn is_low(&self) -> bool {
395 *self == CH4_A::LOW
396 }
397 #[doc = "Checks if the value of the field is `DAC`"]
398 #[inline(always)]
399 pub fn is_dac(&self) -> bool {
400 *self == CH4_A::DAC
401 }
402}
403#[doc = "Field `CH4` writer - Channel 4 Idle Phase Configuration"]
404pub type CH4_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH4_A, 2, 8>;
405impl<'a> CH4_W<'a> {
406 #[doc = "CH4 output is disabled in idle phase"]
407 #[inline(always)]
408 pub fn disable(self) -> &'a mut W {
409 self.variant(CH4_A::DISABLE)
410 }
411 #[doc = "CH4 output is high in idle phase"]
412 #[inline(always)]
413 pub fn high(self) -> &'a mut W {
414 self.variant(CH4_A::HIGH)
415 }
416 #[doc = "CH4 output is low in idle phase"]
417 #[inline(always)]
418 pub fn low(self) -> &'a mut W {
419 self.variant(CH4_A::LOW)
420 }
421 #[doc = "CH4 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
422 #[inline(always)]
423 pub fn dac(self) -> &'a mut W {
424 self.variant(CH4_A::DAC)
425 }
426}
427#[doc = "Channel 5 Idle Phase Configuration\n\nValue on reset: 0"]
428#[derive(Clone, Copy, Debug, PartialEq)]
429#[repr(u8)]
430pub enum CH5_A {
431 #[doc = "0: CH5 output is disabled in idle phase"]
432 DISABLE = 0,
433 #[doc = "1: CH5 output is high in idle phase"]
434 HIGH = 1,
435 #[doc = "2: CH5 output is low in idle phase"]
436 LOW = 2,
437 #[doc = "3: CH5 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
438 DAC = 3,
439}
440impl From<CH5_A> for u8 {
441 #[inline(always)]
442 fn from(variant: CH5_A) -> Self {
443 variant as _
444 }
445}
446#[doc = "Field `CH5` reader - Channel 5 Idle Phase Configuration"]
447pub type CH5_R = crate::FieldReader<u8, CH5_A>;
448impl CH5_R {
449 #[doc = "Get enumerated values variant"]
450 #[inline(always)]
451 pub fn variant(&self) -> CH5_A {
452 match self.bits {
453 0 => CH5_A::DISABLE,
454 1 => CH5_A::HIGH,
455 2 => CH5_A::LOW,
456 3 => CH5_A::DAC,
457 _ => unreachable!(),
458 }
459 }
460 #[doc = "Checks if the value of the field is `DISABLE`"]
461 #[inline(always)]
462 pub fn is_disable(&self) -> bool {
463 *self == CH5_A::DISABLE
464 }
465 #[doc = "Checks if the value of the field is `HIGH`"]
466 #[inline(always)]
467 pub fn is_high(&self) -> bool {
468 *self == CH5_A::HIGH
469 }
470 #[doc = "Checks if the value of the field is `LOW`"]
471 #[inline(always)]
472 pub fn is_low(&self) -> bool {
473 *self == CH5_A::LOW
474 }
475 #[doc = "Checks if the value of the field is `DAC`"]
476 #[inline(always)]
477 pub fn is_dac(&self) -> bool {
478 *self == CH5_A::DAC
479 }
480}
481#[doc = "Field `CH5` writer - Channel 5 Idle Phase Configuration"]
482pub type CH5_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH5_A, 2, 10>;
483impl<'a> CH5_W<'a> {
484 #[doc = "CH5 output is disabled in idle phase"]
485 #[inline(always)]
486 pub fn disable(self) -> &'a mut W {
487 self.variant(CH5_A::DISABLE)
488 }
489 #[doc = "CH5 output is high in idle phase"]
490 #[inline(always)]
491 pub fn high(self) -> &'a mut W {
492 self.variant(CH5_A::HIGH)
493 }
494 #[doc = "CH5 output is low in idle phase"]
495 #[inline(always)]
496 pub fn low(self) -> &'a mut W {
497 self.variant(CH5_A::LOW)
498 }
499 #[doc = "CH5 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
500 #[inline(always)]
501 pub fn dac(self) -> &'a mut W {
502 self.variant(CH5_A::DAC)
503 }
504}
505#[doc = "Channel 6 Idle Phase Configuration\n\nValue on reset: 0"]
506#[derive(Clone, Copy, Debug, PartialEq)]
507#[repr(u8)]
508pub enum CH6_A {
509 #[doc = "0: CH6 output is disabled in idle phase"]
510 DISABLE = 0,
511 #[doc = "1: CH6 output is high in idle phase"]
512 HIGH = 1,
513 #[doc = "2: CH6 output is low in idle phase"]
514 LOW = 2,
515 #[doc = "3: CH6 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
516 DAC = 3,
517}
518impl From<CH6_A> for u8 {
519 #[inline(always)]
520 fn from(variant: CH6_A) -> Self {
521 variant as _
522 }
523}
524#[doc = "Field `CH6` reader - Channel 6 Idle Phase Configuration"]
525pub type CH6_R = crate::FieldReader<u8, CH6_A>;
526impl CH6_R {
527 #[doc = "Get enumerated values variant"]
528 #[inline(always)]
529 pub fn variant(&self) -> CH6_A {
530 match self.bits {
531 0 => CH6_A::DISABLE,
532 1 => CH6_A::HIGH,
533 2 => CH6_A::LOW,
534 3 => CH6_A::DAC,
535 _ => unreachable!(),
536 }
537 }
538 #[doc = "Checks if the value of the field is `DISABLE`"]
539 #[inline(always)]
540 pub fn is_disable(&self) -> bool {
541 *self == CH6_A::DISABLE
542 }
543 #[doc = "Checks if the value of the field is `HIGH`"]
544 #[inline(always)]
545 pub fn is_high(&self) -> bool {
546 *self == CH6_A::HIGH
547 }
548 #[doc = "Checks if the value of the field is `LOW`"]
549 #[inline(always)]
550 pub fn is_low(&self) -> bool {
551 *self == CH6_A::LOW
552 }
553 #[doc = "Checks if the value of the field is `DAC`"]
554 #[inline(always)]
555 pub fn is_dac(&self) -> bool {
556 *self == CH6_A::DAC
557 }
558}
559#[doc = "Field `CH6` writer - Channel 6 Idle Phase Configuration"]
560pub type CH6_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH6_A, 2, 12>;
561impl<'a> CH6_W<'a> {
562 #[doc = "CH6 output is disabled in idle phase"]
563 #[inline(always)]
564 pub fn disable(self) -> &'a mut W {
565 self.variant(CH6_A::DISABLE)
566 }
567 #[doc = "CH6 output is high in idle phase"]
568 #[inline(always)]
569 pub fn high(self) -> &'a mut W {
570 self.variant(CH6_A::HIGH)
571 }
572 #[doc = "CH6 output is low in idle phase"]
573 #[inline(always)]
574 pub fn low(self) -> &'a mut W {
575 self.variant(CH6_A::LOW)
576 }
577 #[doc = "CH6 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
578 #[inline(always)]
579 pub fn dac(self) -> &'a mut W {
580 self.variant(CH6_A::DAC)
581 }
582}
583#[doc = "Channel 7 Idle Phase Configuration\n\nValue on reset: 0"]
584#[derive(Clone, Copy, Debug, PartialEq)]
585#[repr(u8)]
586pub enum CH7_A {
587 #[doc = "0: CH7 output is disabled in idle phase"]
588 DISABLE = 0,
589 #[doc = "1: CH7 output is high in idle phase"]
590 HIGH = 1,
591 #[doc = "2: CH7 output is low in idle phase"]
592 LOW = 2,
593 #[doc = "3: CH7 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
594 DAC = 3,
595}
596impl From<CH7_A> for u8 {
597 #[inline(always)]
598 fn from(variant: CH7_A) -> Self {
599 variant as _
600 }
601}
602#[doc = "Field `CH7` reader - Channel 7 Idle Phase Configuration"]
603pub type CH7_R = crate::FieldReader<u8, CH7_A>;
604impl CH7_R {
605 #[doc = "Get enumerated values variant"]
606 #[inline(always)]
607 pub fn variant(&self) -> CH7_A {
608 match self.bits {
609 0 => CH7_A::DISABLE,
610 1 => CH7_A::HIGH,
611 2 => CH7_A::LOW,
612 3 => CH7_A::DAC,
613 _ => unreachable!(),
614 }
615 }
616 #[doc = "Checks if the value of the field is `DISABLE`"]
617 #[inline(always)]
618 pub fn is_disable(&self) -> bool {
619 *self == CH7_A::DISABLE
620 }
621 #[doc = "Checks if the value of the field is `HIGH`"]
622 #[inline(always)]
623 pub fn is_high(&self) -> bool {
624 *self == CH7_A::HIGH
625 }
626 #[doc = "Checks if the value of the field is `LOW`"]
627 #[inline(always)]
628 pub fn is_low(&self) -> bool {
629 *self == CH7_A::LOW
630 }
631 #[doc = "Checks if the value of the field is `DAC`"]
632 #[inline(always)]
633 pub fn is_dac(&self) -> bool {
634 *self == CH7_A::DAC
635 }
636}
637#[doc = "Field `CH7` writer - Channel 7 Idle Phase Configuration"]
638pub type CH7_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH7_A, 2, 14>;
639impl<'a> CH7_W<'a> {
640 #[doc = "CH7 output is disabled in idle phase"]
641 #[inline(always)]
642 pub fn disable(self) -> &'a mut W {
643 self.variant(CH7_A::DISABLE)
644 }
645 #[doc = "CH7 output is high in idle phase"]
646 #[inline(always)]
647 pub fn high(self) -> &'a mut W {
648 self.variant(CH7_A::HIGH)
649 }
650 #[doc = "CH7 output is low in idle phase"]
651 #[inline(always)]
652 pub fn low(self) -> &'a mut W {
653 self.variant(CH7_A::LOW)
654 }
655 #[doc = "CH7 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
656 #[inline(always)]
657 pub fn dac(self) -> &'a mut W {
658 self.variant(CH7_A::DAC)
659 }
660}
661#[doc = "Channel 8 Idle Phase Configuration\n\nValue on reset: 0"]
662#[derive(Clone, Copy, Debug, PartialEq)]
663#[repr(u8)]
664pub enum CH8_A {
665 #[doc = "0: CH8 output is disabled in idle phase"]
666 DISABLE = 0,
667 #[doc = "1: CH8 output is high in idle phase"]
668 HIGH = 1,
669 #[doc = "2: CH8 output is low in idle phase"]
670 LOW = 2,
671 #[doc = "3: CH8 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
672 DAC = 3,
673}
674impl From<CH8_A> for u8 {
675 #[inline(always)]
676 fn from(variant: CH8_A) -> Self {
677 variant as _
678 }
679}
680#[doc = "Field `CH8` reader - Channel 8 Idle Phase Configuration"]
681pub type CH8_R = crate::FieldReader<u8, CH8_A>;
682impl CH8_R {
683 #[doc = "Get enumerated values variant"]
684 #[inline(always)]
685 pub fn variant(&self) -> CH8_A {
686 match self.bits {
687 0 => CH8_A::DISABLE,
688 1 => CH8_A::HIGH,
689 2 => CH8_A::LOW,
690 3 => CH8_A::DAC,
691 _ => unreachable!(),
692 }
693 }
694 #[doc = "Checks if the value of the field is `DISABLE`"]
695 #[inline(always)]
696 pub fn is_disable(&self) -> bool {
697 *self == CH8_A::DISABLE
698 }
699 #[doc = "Checks if the value of the field is `HIGH`"]
700 #[inline(always)]
701 pub fn is_high(&self) -> bool {
702 *self == CH8_A::HIGH
703 }
704 #[doc = "Checks if the value of the field is `LOW`"]
705 #[inline(always)]
706 pub fn is_low(&self) -> bool {
707 *self == CH8_A::LOW
708 }
709 #[doc = "Checks if the value of the field is `DAC`"]
710 #[inline(always)]
711 pub fn is_dac(&self) -> bool {
712 *self == CH8_A::DAC
713 }
714}
715#[doc = "Field `CH8` writer - Channel 8 Idle Phase Configuration"]
716pub type CH8_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH8_A, 2, 16>;
717impl<'a> CH8_W<'a> {
718 #[doc = "CH8 output is disabled in idle phase"]
719 #[inline(always)]
720 pub fn disable(self) -> &'a mut W {
721 self.variant(CH8_A::DISABLE)
722 }
723 #[doc = "CH8 output is high in idle phase"]
724 #[inline(always)]
725 pub fn high(self) -> &'a mut W {
726 self.variant(CH8_A::HIGH)
727 }
728 #[doc = "CH8 output is low in idle phase"]
729 #[inline(always)]
730 pub fn low(self) -> &'a mut W {
731 self.variant(CH8_A::LOW)
732 }
733 #[doc = "CH8 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
734 #[inline(always)]
735 pub fn dac(self) -> &'a mut W {
736 self.variant(CH8_A::DAC)
737 }
738}
739#[doc = "Channel 9 Idle Phase Configuration\n\nValue on reset: 0"]
740#[derive(Clone, Copy, Debug, PartialEq)]
741#[repr(u8)]
742pub enum CH9_A {
743 #[doc = "0: CH9 output is disabled in idle phase"]
744 DISABLE = 0,
745 #[doc = "1: CH9 output is high in idle phase"]
746 HIGH = 1,
747 #[doc = "2: CH9 output is low in idle phase"]
748 LOW = 2,
749 #[doc = "3: CH9 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
750 DAC = 3,
751}
752impl From<CH9_A> for u8 {
753 #[inline(always)]
754 fn from(variant: CH9_A) -> Self {
755 variant as _
756 }
757}
758#[doc = "Field `CH9` reader - Channel 9 Idle Phase Configuration"]
759pub type CH9_R = crate::FieldReader<u8, CH9_A>;
760impl CH9_R {
761 #[doc = "Get enumerated values variant"]
762 #[inline(always)]
763 pub fn variant(&self) -> CH9_A {
764 match self.bits {
765 0 => CH9_A::DISABLE,
766 1 => CH9_A::HIGH,
767 2 => CH9_A::LOW,
768 3 => CH9_A::DAC,
769 _ => unreachable!(),
770 }
771 }
772 #[doc = "Checks if the value of the field is `DISABLE`"]
773 #[inline(always)]
774 pub fn is_disable(&self) -> bool {
775 *self == CH9_A::DISABLE
776 }
777 #[doc = "Checks if the value of the field is `HIGH`"]
778 #[inline(always)]
779 pub fn is_high(&self) -> bool {
780 *self == CH9_A::HIGH
781 }
782 #[doc = "Checks if the value of the field is `LOW`"]
783 #[inline(always)]
784 pub fn is_low(&self) -> bool {
785 *self == CH9_A::LOW
786 }
787 #[doc = "Checks if the value of the field is `DAC`"]
788 #[inline(always)]
789 pub fn is_dac(&self) -> bool {
790 *self == CH9_A::DAC
791 }
792}
793#[doc = "Field `CH9` writer - Channel 9 Idle Phase Configuration"]
794pub type CH9_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH9_A, 2, 18>;
795impl<'a> CH9_W<'a> {
796 #[doc = "CH9 output is disabled in idle phase"]
797 #[inline(always)]
798 pub fn disable(self) -> &'a mut W {
799 self.variant(CH9_A::DISABLE)
800 }
801 #[doc = "CH9 output is high in idle phase"]
802 #[inline(always)]
803 pub fn high(self) -> &'a mut W {
804 self.variant(CH9_A::HIGH)
805 }
806 #[doc = "CH9 output is low in idle phase"]
807 #[inline(always)]
808 pub fn low(self) -> &'a mut W {
809 self.variant(CH9_A::LOW)
810 }
811 #[doc = "CH9 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
812 #[inline(always)]
813 pub fn dac(self) -> &'a mut W {
814 self.variant(CH9_A::DAC)
815 }
816}
817#[doc = "Channel 10 Idle Phase Configuration\n\nValue on reset: 0"]
818#[derive(Clone, Copy, Debug, PartialEq)]
819#[repr(u8)]
820pub enum CH10_A {
821 #[doc = "0: CH10 output is disabled in idle phase"]
822 DISABLE = 0,
823 #[doc = "1: CH10 output is high in idle phase"]
824 HIGH = 1,
825 #[doc = "2: CH10 output is low in idle phase"]
826 LOW = 2,
827 #[doc = "3: CH10 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
828 DAC = 3,
829}
830impl From<CH10_A> for u8 {
831 #[inline(always)]
832 fn from(variant: CH10_A) -> Self {
833 variant as _
834 }
835}
836#[doc = "Field `CH10` reader - Channel 10 Idle Phase Configuration"]
837pub type CH10_R = crate::FieldReader<u8, CH10_A>;
838impl CH10_R {
839 #[doc = "Get enumerated values variant"]
840 #[inline(always)]
841 pub fn variant(&self) -> CH10_A {
842 match self.bits {
843 0 => CH10_A::DISABLE,
844 1 => CH10_A::HIGH,
845 2 => CH10_A::LOW,
846 3 => CH10_A::DAC,
847 _ => unreachable!(),
848 }
849 }
850 #[doc = "Checks if the value of the field is `DISABLE`"]
851 #[inline(always)]
852 pub fn is_disable(&self) -> bool {
853 *self == CH10_A::DISABLE
854 }
855 #[doc = "Checks if the value of the field is `HIGH`"]
856 #[inline(always)]
857 pub fn is_high(&self) -> bool {
858 *self == CH10_A::HIGH
859 }
860 #[doc = "Checks if the value of the field is `LOW`"]
861 #[inline(always)]
862 pub fn is_low(&self) -> bool {
863 *self == CH10_A::LOW
864 }
865 #[doc = "Checks if the value of the field is `DAC`"]
866 #[inline(always)]
867 pub fn is_dac(&self) -> bool {
868 *self == CH10_A::DAC
869 }
870}
871#[doc = "Field `CH10` writer - Channel 10 Idle Phase Configuration"]
872pub type CH10_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH10_A, 2, 20>;
873impl<'a> CH10_W<'a> {
874 #[doc = "CH10 output is disabled in idle phase"]
875 #[inline(always)]
876 pub fn disable(self) -> &'a mut W {
877 self.variant(CH10_A::DISABLE)
878 }
879 #[doc = "CH10 output is high in idle phase"]
880 #[inline(always)]
881 pub fn high(self) -> &'a mut W {
882 self.variant(CH10_A::HIGH)
883 }
884 #[doc = "CH10 output is low in idle phase"]
885 #[inline(always)]
886 pub fn low(self) -> &'a mut W {
887 self.variant(CH10_A::LOW)
888 }
889 #[doc = "CH10 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
890 #[inline(always)]
891 pub fn dac(self) -> &'a mut W {
892 self.variant(CH10_A::DAC)
893 }
894}
895#[doc = "Channel 11 Idle Phase Configuration\n\nValue on reset: 0"]
896#[derive(Clone, Copy, Debug, PartialEq)]
897#[repr(u8)]
898pub enum CH11_A {
899 #[doc = "0: CH11 output is disabled in idle phase"]
900 DISABLE = 0,
901 #[doc = "1: CH11 output is high in idle phase"]
902 HIGH = 1,
903 #[doc = "2: CH11 output is low in idle phase"]
904 LOW = 2,
905 #[doc = "3: CH11 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
906 DAC = 3,
907}
908impl From<CH11_A> for u8 {
909 #[inline(always)]
910 fn from(variant: CH11_A) -> Self {
911 variant as _
912 }
913}
914#[doc = "Field `CH11` reader - Channel 11 Idle Phase Configuration"]
915pub type CH11_R = crate::FieldReader<u8, CH11_A>;
916impl CH11_R {
917 #[doc = "Get enumerated values variant"]
918 #[inline(always)]
919 pub fn variant(&self) -> CH11_A {
920 match self.bits {
921 0 => CH11_A::DISABLE,
922 1 => CH11_A::HIGH,
923 2 => CH11_A::LOW,
924 3 => CH11_A::DAC,
925 _ => unreachable!(),
926 }
927 }
928 #[doc = "Checks if the value of the field is `DISABLE`"]
929 #[inline(always)]
930 pub fn is_disable(&self) -> bool {
931 *self == CH11_A::DISABLE
932 }
933 #[doc = "Checks if the value of the field is `HIGH`"]
934 #[inline(always)]
935 pub fn is_high(&self) -> bool {
936 *self == CH11_A::HIGH
937 }
938 #[doc = "Checks if the value of the field is `LOW`"]
939 #[inline(always)]
940 pub fn is_low(&self) -> bool {
941 *self == CH11_A::LOW
942 }
943 #[doc = "Checks if the value of the field is `DAC`"]
944 #[inline(always)]
945 pub fn is_dac(&self) -> bool {
946 *self == CH11_A::DAC
947 }
948}
949#[doc = "Field `CH11` writer - Channel 11 Idle Phase Configuration"]
950pub type CH11_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH11_A, 2, 22>;
951impl<'a> CH11_W<'a> {
952 #[doc = "CH11 output is disabled in idle phase"]
953 #[inline(always)]
954 pub fn disable(self) -> &'a mut W {
955 self.variant(CH11_A::DISABLE)
956 }
957 #[doc = "CH11 output is high in idle phase"]
958 #[inline(always)]
959 pub fn high(self) -> &'a mut W {
960 self.variant(CH11_A::HIGH)
961 }
962 #[doc = "CH11 output is low in idle phase"]
963 #[inline(always)]
964 pub fn low(self) -> &'a mut W {
965 self.variant(CH11_A::LOW)
966 }
967 #[doc = "CH11 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
968 #[inline(always)]
969 pub fn dac(self) -> &'a mut W {
970 self.variant(CH11_A::DAC)
971 }
972}
973#[doc = "Channel 12 Idle Phase Configuration\n\nValue on reset: 0"]
974#[derive(Clone, Copy, Debug, PartialEq)]
975#[repr(u8)]
976pub enum CH12_A {
977 #[doc = "0: CH12 output is disabled in idle phase"]
978 DISABLE = 0,
979 #[doc = "1: CH12 output is high in idle phase"]
980 HIGH = 1,
981 #[doc = "2: CH12 output is low in idle phase"]
982 LOW = 2,
983 #[doc = "3: CH12 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
984 DAC = 3,
985}
986impl From<CH12_A> for u8 {
987 #[inline(always)]
988 fn from(variant: CH12_A) -> Self {
989 variant as _
990 }
991}
992#[doc = "Field `CH12` reader - Channel 12 Idle Phase Configuration"]
993pub type CH12_R = crate::FieldReader<u8, CH12_A>;
994impl CH12_R {
995 #[doc = "Get enumerated values variant"]
996 #[inline(always)]
997 pub fn variant(&self) -> CH12_A {
998 match self.bits {
999 0 => CH12_A::DISABLE,
1000 1 => CH12_A::HIGH,
1001 2 => CH12_A::LOW,
1002 3 => CH12_A::DAC,
1003 _ => unreachable!(),
1004 }
1005 }
1006 #[doc = "Checks if the value of the field is `DISABLE`"]
1007 #[inline(always)]
1008 pub fn is_disable(&self) -> bool {
1009 *self == CH12_A::DISABLE
1010 }
1011 #[doc = "Checks if the value of the field is `HIGH`"]
1012 #[inline(always)]
1013 pub fn is_high(&self) -> bool {
1014 *self == CH12_A::HIGH
1015 }
1016 #[doc = "Checks if the value of the field is `LOW`"]
1017 #[inline(always)]
1018 pub fn is_low(&self) -> bool {
1019 *self == CH12_A::LOW
1020 }
1021 #[doc = "Checks if the value of the field is `DAC`"]
1022 #[inline(always)]
1023 pub fn is_dac(&self) -> bool {
1024 *self == CH12_A::DAC
1025 }
1026}
1027#[doc = "Field `CH12` writer - Channel 12 Idle Phase Configuration"]
1028pub type CH12_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH12_A, 2, 24>;
1029impl<'a> CH12_W<'a> {
1030 #[doc = "CH12 output is disabled in idle phase"]
1031 #[inline(always)]
1032 pub fn disable(self) -> &'a mut W {
1033 self.variant(CH12_A::DISABLE)
1034 }
1035 #[doc = "CH12 output is high in idle phase"]
1036 #[inline(always)]
1037 pub fn high(self) -> &'a mut W {
1038 self.variant(CH12_A::HIGH)
1039 }
1040 #[doc = "CH12 output is low in idle phase"]
1041 #[inline(always)]
1042 pub fn low(self) -> &'a mut W {
1043 self.variant(CH12_A::LOW)
1044 }
1045 #[doc = "CH12 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1046 #[inline(always)]
1047 pub fn dac(self) -> &'a mut W {
1048 self.variant(CH12_A::DAC)
1049 }
1050}
1051#[doc = "Channel 13 Idle Phase Configuration\n\nValue on reset: 0"]
1052#[derive(Clone, Copy, Debug, PartialEq)]
1053#[repr(u8)]
1054pub enum CH13_A {
1055 #[doc = "0: CH13 output is disabled in idle phase"]
1056 DISABLE = 0,
1057 #[doc = "1: CH13 output is high in idle phase"]
1058 HIGH = 1,
1059 #[doc = "2: CH13 output is low in idle phase"]
1060 LOW = 2,
1061 #[doc = "3: CH13 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1062 DAC = 3,
1063}
1064impl From<CH13_A> for u8 {
1065 #[inline(always)]
1066 fn from(variant: CH13_A) -> Self {
1067 variant as _
1068 }
1069}
1070#[doc = "Field `CH13` reader - Channel 13 Idle Phase Configuration"]
1071pub type CH13_R = crate::FieldReader<u8, CH13_A>;
1072impl CH13_R {
1073 #[doc = "Get enumerated values variant"]
1074 #[inline(always)]
1075 pub fn variant(&self) -> CH13_A {
1076 match self.bits {
1077 0 => CH13_A::DISABLE,
1078 1 => CH13_A::HIGH,
1079 2 => CH13_A::LOW,
1080 3 => CH13_A::DAC,
1081 _ => unreachable!(),
1082 }
1083 }
1084 #[doc = "Checks if the value of the field is `DISABLE`"]
1085 #[inline(always)]
1086 pub fn is_disable(&self) -> bool {
1087 *self == CH13_A::DISABLE
1088 }
1089 #[doc = "Checks if the value of the field is `HIGH`"]
1090 #[inline(always)]
1091 pub fn is_high(&self) -> bool {
1092 *self == CH13_A::HIGH
1093 }
1094 #[doc = "Checks if the value of the field is `LOW`"]
1095 #[inline(always)]
1096 pub fn is_low(&self) -> bool {
1097 *self == CH13_A::LOW
1098 }
1099 #[doc = "Checks if the value of the field is `DAC`"]
1100 #[inline(always)]
1101 pub fn is_dac(&self) -> bool {
1102 *self == CH13_A::DAC
1103 }
1104}
1105#[doc = "Field `CH13` writer - Channel 13 Idle Phase Configuration"]
1106pub type CH13_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH13_A, 2, 26>;
1107impl<'a> CH13_W<'a> {
1108 #[doc = "CH13 output is disabled in idle phase"]
1109 #[inline(always)]
1110 pub fn disable(self) -> &'a mut W {
1111 self.variant(CH13_A::DISABLE)
1112 }
1113 #[doc = "CH13 output is high in idle phase"]
1114 #[inline(always)]
1115 pub fn high(self) -> &'a mut W {
1116 self.variant(CH13_A::HIGH)
1117 }
1118 #[doc = "CH13 output is low in idle phase"]
1119 #[inline(always)]
1120 pub fn low(self) -> &'a mut W {
1121 self.variant(CH13_A::LOW)
1122 }
1123 #[doc = "CH13 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1124 #[inline(always)]
1125 pub fn dac(self) -> &'a mut W {
1126 self.variant(CH13_A::DAC)
1127 }
1128}
1129#[doc = "Channel 14 Idle Phase Configuration\n\nValue on reset: 0"]
1130#[derive(Clone, Copy, Debug, PartialEq)]
1131#[repr(u8)]
1132pub enum CH14_A {
1133 #[doc = "0: CH14 output is disabled in idle phase"]
1134 DISABLE = 0,
1135 #[doc = "1: CH14 output is high in idle phase"]
1136 HIGH = 1,
1137 #[doc = "2: CH14 output is low in idle phase"]
1138 LOW = 2,
1139 #[doc = "3: CH14 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1140 DAC = 3,
1141}
1142impl From<CH14_A> for u8 {
1143 #[inline(always)]
1144 fn from(variant: CH14_A) -> Self {
1145 variant as _
1146 }
1147}
1148#[doc = "Field `CH14` reader - Channel 14 Idle Phase Configuration"]
1149pub type CH14_R = crate::FieldReader<u8, CH14_A>;
1150impl CH14_R {
1151 #[doc = "Get enumerated values variant"]
1152 #[inline(always)]
1153 pub fn variant(&self) -> CH14_A {
1154 match self.bits {
1155 0 => CH14_A::DISABLE,
1156 1 => CH14_A::HIGH,
1157 2 => CH14_A::LOW,
1158 3 => CH14_A::DAC,
1159 _ => unreachable!(),
1160 }
1161 }
1162 #[doc = "Checks if the value of the field is `DISABLE`"]
1163 #[inline(always)]
1164 pub fn is_disable(&self) -> bool {
1165 *self == CH14_A::DISABLE
1166 }
1167 #[doc = "Checks if the value of the field is `HIGH`"]
1168 #[inline(always)]
1169 pub fn is_high(&self) -> bool {
1170 *self == CH14_A::HIGH
1171 }
1172 #[doc = "Checks if the value of the field is `LOW`"]
1173 #[inline(always)]
1174 pub fn is_low(&self) -> bool {
1175 *self == CH14_A::LOW
1176 }
1177 #[doc = "Checks if the value of the field is `DAC`"]
1178 #[inline(always)]
1179 pub fn is_dac(&self) -> bool {
1180 *self == CH14_A::DAC
1181 }
1182}
1183#[doc = "Field `CH14` writer - Channel 14 Idle Phase Configuration"]
1184pub type CH14_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH14_A, 2, 28>;
1185impl<'a> CH14_W<'a> {
1186 #[doc = "CH14 output is disabled in idle phase"]
1187 #[inline(always)]
1188 pub fn disable(self) -> &'a mut W {
1189 self.variant(CH14_A::DISABLE)
1190 }
1191 #[doc = "CH14 output is high in idle phase"]
1192 #[inline(always)]
1193 pub fn high(self) -> &'a mut W {
1194 self.variant(CH14_A::HIGH)
1195 }
1196 #[doc = "CH14 output is low in idle phase"]
1197 #[inline(always)]
1198 pub fn low(self) -> &'a mut W {
1199 self.variant(CH14_A::LOW)
1200 }
1201 #[doc = "CH14 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1202 #[inline(always)]
1203 pub fn dac(self) -> &'a mut W {
1204 self.variant(CH14_A::DAC)
1205 }
1206}
1207#[doc = "Channel 15 Idle Phase Configuration\n\nValue on reset: 0"]
1208#[derive(Clone, Copy, Debug, PartialEq)]
1209#[repr(u8)]
1210pub enum CH15_A {
1211 #[doc = "0: CH15 output is disabled in idle phase"]
1212 DISABLE = 0,
1213 #[doc = "1: CH15 output is high in idle phase"]
1214 HIGH = 1,
1215 #[doc = "2: CH15 output is low in idle phase"]
1216 LOW = 2,
1217 #[doc = "3: CH15 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1218 DAC = 3,
1219}
1220impl From<CH15_A> for u8 {
1221 #[inline(always)]
1222 fn from(variant: CH15_A) -> Self {
1223 variant as _
1224 }
1225}
1226#[doc = "Field `CH15` reader - Channel 15 Idle Phase Configuration"]
1227pub type CH15_R = crate::FieldReader<u8, CH15_A>;
1228impl CH15_R {
1229 #[doc = "Get enumerated values variant"]
1230 #[inline(always)]
1231 pub fn variant(&self) -> CH15_A {
1232 match self.bits {
1233 0 => CH15_A::DISABLE,
1234 1 => CH15_A::HIGH,
1235 2 => CH15_A::LOW,
1236 3 => CH15_A::DAC,
1237 _ => unreachable!(),
1238 }
1239 }
1240 #[doc = "Checks if the value of the field is `DISABLE`"]
1241 #[inline(always)]
1242 pub fn is_disable(&self) -> bool {
1243 *self == CH15_A::DISABLE
1244 }
1245 #[doc = "Checks if the value of the field is `HIGH`"]
1246 #[inline(always)]
1247 pub fn is_high(&self) -> bool {
1248 *self == CH15_A::HIGH
1249 }
1250 #[doc = "Checks if the value of the field is `LOW`"]
1251 #[inline(always)]
1252 pub fn is_low(&self) -> bool {
1253 *self == CH15_A::LOW
1254 }
1255 #[doc = "Checks if the value of the field is `DAC`"]
1256 #[inline(always)]
1257 pub fn is_dac(&self) -> bool {
1258 *self == CH15_A::DAC
1259 }
1260}
1261#[doc = "Field `CH15` writer - Channel 15 Idle Phase Configuration"]
1262pub type CH15_W<'a> = crate::FieldWriterSafe<'a, u32, IDLECONF_SPEC, u8, CH15_A, 2, 30>;
1263impl<'a> CH15_W<'a> {
1264 #[doc = "CH15 output is disabled in idle phase"]
1265 #[inline(always)]
1266 pub fn disable(self) -> &'a mut W {
1267 self.variant(CH15_A::DISABLE)
1268 }
1269 #[doc = "CH15 output is high in idle phase"]
1270 #[inline(always)]
1271 pub fn high(self) -> &'a mut W {
1272 self.variant(CH15_A::HIGH)
1273 }
1274 #[doc = "CH15 output is low in idle phase"]
1275 #[inline(always)]
1276 pub fn low(self) -> &'a mut W {
1277 self.variant(CH15_A::LOW)
1278 }
1279 #[doc = "CH15 output is connected to VDAC output in idle phase. Note that this mode is only available on channels 0, 1, 2, 3, 12, 13, 14, 15"]
1280 #[inline(always)]
1281 pub fn dac(self) -> &'a mut W {
1282 self.variant(CH15_A::DAC)
1283 }
1284}
1285impl R {
1286 #[doc = "Bits 0:1 - Channel 0 Idle Phase Configuration"]
1287 #[inline(always)]
1288 pub fn ch0(&self) -> CH0_R {
1289 CH0_R::new((self.bits & 3) as u8)
1290 }
1291 #[doc = "Bits 2:3 - Channel 1 Idle Phase Configuration"]
1292 #[inline(always)]
1293 pub fn ch1(&self) -> CH1_R {
1294 CH1_R::new(((self.bits >> 2) & 3) as u8)
1295 }
1296 #[doc = "Bits 4:5 - Channel 2 Idle Phase Configuration"]
1297 #[inline(always)]
1298 pub fn ch2(&self) -> CH2_R {
1299 CH2_R::new(((self.bits >> 4) & 3) as u8)
1300 }
1301 #[doc = "Bits 6:7 - Channel 3 Idle Phase Configuration"]
1302 #[inline(always)]
1303 pub fn ch3(&self) -> CH3_R {
1304 CH3_R::new(((self.bits >> 6) & 3) as u8)
1305 }
1306 #[doc = "Bits 8:9 - Channel 4 Idle Phase Configuration"]
1307 #[inline(always)]
1308 pub fn ch4(&self) -> CH4_R {
1309 CH4_R::new(((self.bits >> 8) & 3) as u8)
1310 }
1311 #[doc = "Bits 10:11 - Channel 5 Idle Phase Configuration"]
1312 #[inline(always)]
1313 pub fn ch5(&self) -> CH5_R {
1314 CH5_R::new(((self.bits >> 10) & 3) as u8)
1315 }
1316 #[doc = "Bits 12:13 - Channel 6 Idle Phase Configuration"]
1317 #[inline(always)]
1318 pub fn ch6(&self) -> CH6_R {
1319 CH6_R::new(((self.bits >> 12) & 3) as u8)
1320 }
1321 #[doc = "Bits 14:15 - Channel 7 Idle Phase Configuration"]
1322 #[inline(always)]
1323 pub fn ch7(&self) -> CH7_R {
1324 CH7_R::new(((self.bits >> 14) & 3) as u8)
1325 }
1326 #[doc = "Bits 16:17 - Channel 8 Idle Phase Configuration"]
1327 #[inline(always)]
1328 pub fn ch8(&self) -> CH8_R {
1329 CH8_R::new(((self.bits >> 16) & 3) as u8)
1330 }
1331 #[doc = "Bits 18:19 - Channel 9 Idle Phase Configuration"]
1332 #[inline(always)]
1333 pub fn ch9(&self) -> CH9_R {
1334 CH9_R::new(((self.bits >> 18) & 3) as u8)
1335 }
1336 #[doc = "Bits 20:21 - Channel 10 Idle Phase Configuration"]
1337 #[inline(always)]
1338 pub fn ch10(&self) -> CH10_R {
1339 CH10_R::new(((self.bits >> 20) & 3) as u8)
1340 }
1341 #[doc = "Bits 22:23 - Channel 11 Idle Phase Configuration"]
1342 #[inline(always)]
1343 pub fn ch11(&self) -> CH11_R {
1344 CH11_R::new(((self.bits >> 22) & 3) as u8)
1345 }
1346 #[doc = "Bits 24:25 - Channel 12 Idle Phase Configuration"]
1347 #[inline(always)]
1348 pub fn ch12(&self) -> CH12_R {
1349 CH12_R::new(((self.bits >> 24) & 3) as u8)
1350 }
1351 #[doc = "Bits 26:27 - Channel 13 Idle Phase Configuration"]
1352 #[inline(always)]
1353 pub fn ch13(&self) -> CH13_R {
1354 CH13_R::new(((self.bits >> 26) & 3) as u8)
1355 }
1356 #[doc = "Bits 28:29 - Channel 14 Idle Phase Configuration"]
1357 #[inline(always)]
1358 pub fn ch14(&self) -> CH14_R {
1359 CH14_R::new(((self.bits >> 28) & 3) as u8)
1360 }
1361 #[doc = "Bits 30:31 - Channel 15 Idle Phase Configuration"]
1362 #[inline(always)]
1363 pub fn ch15(&self) -> CH15_R {
1364 CH15_R::new(((self.bits >> 30) & 3) as u8)
1365 }
1366}
1367impl W {
1368 #[doc = "Bits 0:1 - Channel 0 Idle Phase Configuration"]
1369 #[inline(always)]
1370 pub fn ch0(&mut self) -> CH0_W {
1371 CH0_W::new(self)
1372 }
1373 #[doc = "Bits 2:3 - Channel 1 Idle Phase Configuration"]
1374 #[inline(always)]
1375 pub fn ch1(&mut self) -> CH1_W {
1376 CH1_W::new(self)
1377 }
1378 #[doc = "Bits 4:5 - Channel 2 Idle Phase Configuration"]
1379 #[inline(always)]
1380 pub fn ch2(&mut self) -> CH2_W {
1381 CH2_W::new(self)
1382 }
1383 #[doc = "Bits 6:7 - Channel 3 Idle Phase Configuration"]
1384 #[inline(always)]
1385 pub fn ch3(&mut self) -> CH3_W {
1386 CH3_W::new(self)
1387 }
1388 #[doc = "Bits 8:9 - Channel 4 Idle Phase Configuration"]
1389 #[inline(always)]
1390 pub fn ch4(&mut self) -> CH4_W {
1391 CH4_W::new(self)
1392 }
1393 #[doc = "Bits 10:11 - Channel 5 Idle Phase Configuration"]
1394 #[inline(always)]
1395 pub fn ch5(&mut self) -> CH5_W {
1396 CH5_W::new(self)
1397 }
1398 #[doc = "Bits 12:13 - Channel 6 Idle Phase Configuration"]
1399 #[inline(always)]
1400 pub fn ch6(&mut self) -> CH6_W {
1401 CH6_W::new(self)
1402 }
1403 #[doc = "Bits 14:15 - Channel 7 Idle Phase Configuration"]
1404 #[inline(always)]
1405 pub fn ch7(&mut self) -> CH7_W {
1406 CH7_W::new(self)
1407 }
1408 #[doc = "Bits 16:17 - Channel 8 Idle Phase Configuration"]
1409 #[inline(always)]
1410 pub fn ch8(&mut self) -> CH8_W {
1411 CH8_W::new(self)
1412 }
1413 #[doc = "Bits 18:19 - Channel 9 Idle Phase Configuration"]
1414 #[inline(always)]
1415 pub fn ch9(&mut self) -> CH9_W {
1416 CH9_W::new(self)
1417 }
1418 #[doc = "Bits 20:21 - Channel 10 Idle Phase Configuration"]
1419 #[inline(always)]
1420 pub fn ch10(&mut self) -> CH10_W {
1421 CH10_W::new(self)
1422 }
1423 #[doc = "Bits 22:23 - Channel 11 Idle Phase Configuration"]
1424 #[inline(always)]
1425 pub fn ch11(&mut self) -> CH11_W {
1426 CH11_W::new(self)
1427 }
1428 #[doc = "Bits 24:25 - Channel 12 Idle Phase Configuration"]
1429 #[inline(always)]
1430 pub fn ch12(&mut self) -> CH12_W {
1431 CH12_W::new(self)
1432 }
1433 #[doc = "Bits 26:27 - Channel 13 Idle Phase Configuration"]
1434 #[inline(always)]
1435 pub fn ch13(&mut self) -> CH13_W {
1436 CH13_W::new(self)
1437 }
1438 #[doc = "Bits 28:29 - Channel 14 Idle Phase Configuration"]
1439 #[inline(always)]
1440 pub fn ch14(&mut self) -> CH14_W {
1441 CH14_W::new(self)
1442 }
1443 #[doc = "Bits 30:31 - Channel 15 Idle Phase Configuration"]
1444 #[inline(always)]
1445 pub fn ch15(&mut self) -> CH15_W {
1446 CH15_W::new(self)
1447 }
1448 #[doc = "Writes raw bits to the register."]
1449 #[inline(always)]
1450 pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
1451 self.0.bits(bits);
1452 self
1453 }
1454}
1455#[doc = "GPIO Idle Phase Configuration\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 [idleconf](index.html) module"]
1456pub struct IDLECONF_SPEC;
1457impl crate::RegisterSpec for IDLECONF_SPEC {
1458 type Ux = u32;
1459}
1460#[doc = "`read()` method returns [idleconf::R](R) reader structure"]
1461impl crate::Readable for IDLECONF_SPEC {
1462 type Reader = R;
1463}
1464#[doc = "`write(|w| ..)` method takes [idleconf::W](W) writer structure"]
1465impl crate::Writable for IDLECONF_SPEC {
1466 type Writer = W;
1467}
1468#[doc = "`reset()` method sets IDLECONF to value 0"]
1469impl crate::Resettable for IDLECONF_SPEC {
1470 #[inline(always)]
1471 fn reset_value() -> Self::Ux {
1472 0
1473 }
1474}