1#[doc = "Register `GTICCR` reader"]
2pub struct R(crate::R<GTICCR_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<GTICCR_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<GTICCR_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<GTICCR_SPEC>) -> Self {
13 R(reader)
14 }
15}
16#[doc = "Register `GTICCR` writer"]
17pub struct W(crate::W<GTICCR_SPEC>);
18impl core::ops::Deref for W {
19 type Target = crate::W<GTICCR_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<GTICCR_SPEC>> for W {
32 #[inline(always)]
33 fn from(writer: crate::W<GTICCR_SPEC>) -> Self {
34 W(writer)
35 }
36}
37#[doc = "Field `ICAFA` reader - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
38pub type ICAFA_R = crate::BitReader<ICAFA_A>;
39#[doc = "Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
40#[derive(Clone, Copy, Debug, PartialEq, Eq)]
41pub enum ICAFA_A {
42 #[doc = "0: Disable forwarding GTCCRA register compare match/input capture to GTCCRA input capture source of other channels"]
43 _0 = 0,
44 #[doc = "1: Enable forwarding GTCCRA register compare match/input capture to GTCCRA input capture source of other channels"]
45 _1 = 1,
46}
47impl From<ICAFA_A> for bool {
48 #[inline(always)]
49 fn from(variant: ICAFA_A) -> Self {
50 variant as u8 != 0
51 }
52}
53impl ICAFA_R {
54 #[doc = "Get enumerated values variant"]
55 #[inline(always)]
56 pub fn variant(&self) -> ICAFA_A {
57 match self.bits {
58 false => ICAFA_A::_0,
59 true => ICAFA_A::_1,
60 }
61 }
62 #[doc = "Checks if the value of the field is `_0`"]
63 #[inline(always)]
64 pub fn is_0(&self) -> bool {
65 *self == ICAFA_A::_0
66 }
67 #[doc = "Checks if the value of the field is `_1`"]
68 #[inline(always)]
69 pub fn is_1(&self) -> bool {
70 *self == ICAFA_A::_1
71 }
72}
73#[doc = "Field `ICAFA` writer - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
74pub type ICAFA_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFA_A, O>;
75impl<'a, const O: u8> ICAFA_W<'a, O> {
76 #[doc = "Disable forwarding GTCCRA register compare match/input capture to GTCCRA input capture source of other channels"]
77 #[inline(always)]
78 pub fn _0(self) -> &'a mut W {
79 self.variant(ICAFA_A::_0)
80 }
81 #[doc = "Enable forwarding GTCCRA register compare match/input capture to GTCCRA input capture source of other channels"]
82 #[inline(always)]
83 pub fn _1(self) -> &'a mut W {
84 self.variant(ICAFA_A::_1)
85 }
86}
87#[doc = "Field `ICAFB` reader - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
88pub type ICAFB_R = crate::BitReader<ICAFB_A>;
89#[doc = "Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
90#[derive(Clone, Copy, Debug, PartialEq, Eq)]
91pub enum ICAFB_A {
92 #[doc = "0: Disable forwarding GTCCRB register compare match/input capture to GTCCRA input capture source of other channels"]
93 _0 = 0,
94 #[doc = "1: Enable forwarding GTCCRB register compare match/input capture to GTCCRA input capture source of other channels"]
95 _1 = 1,
96}
97impl From<ICAFB_A> for bool {
98 #[inline(always)]
99 fn from(variant: ICAFB_A) -> Self {
100 variant as u8 != 0
101 }
102}
103impl ICAFB_R {
104 #[doc = "Get enumerated values variant"]
105 #[inline(always)]
106 pub fn variant(&self) -> ICAFB_A {
107 match self.bits {
108 false => ICAFB_A::_0,
109 true => ICAFB_A::_1,
110 }
111 }
112 #[doc = "Checks if the value of the field is `_0`"]
113 #[inline(always)]
114 pub fn is_0(&self) -> bool {
115 *self == ICAFB_A::_0
116 }
117 #[doc = "Checks if the value of the field is `_1`"]
118 #[inline(always)]
119 pub fn is_1(&self) -> bool {
120 *self == ICAFB_A::_1
121 }
122}
123#[doc = "Field `ICAFB` writer - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
124pub type ICAFB_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFB_A, O>;
125impl<'a, const O: u8> ICAFB_W<'a, O> {
126 #[doc = "Disable forwarding GTCCRB register compare match/input capture to GTCCRA input capture source of other channels"]
127 #[inline(always)]
128 pub fn _0(self) -> &'a mut W {
129 self.variant(ICAFB_A::_0)
130 }
131 #[doc = "Enable forwarding GTCCRB register compare match/input capture to GTCCRA input capture source of other channels"]
132 #[inline(always)]
133 pub fn _1(self) -> &'a mut W {
134 self.variant(ICAFB_A::_1)
135 }
136}
137#[doc = "Field `ICAFC` reader - Forwarding GTCCRC register Compare Match to Other Channel GTCCRA Input Source Capture Enable"]
138pub type ICAFC_R = crate::BitReader<ICAFC_A>;
139#[doc = "Forwarding GTCCRC register Compare Match to Other Channel GTCCRA Input Source Capture Enable\n\nValue on reset: 0"]
140#[derive(Clone, Copy, Debug, PartialEq, Eq)]
141pub enum ICAFC_A {
142 #[doc = "0: Disable forwarding GTCCRC register compare match to GTCCRA input capture source of other channels"]
143 _0 = 0,
144 #[doc = "1: Enable forwarding GTCCRC register compare match to GTCCRA input capture source of other channels"]
145 _1 = 1,
146}
147impl From<ICAFC_A> for bool {
148 #[inline(always)]
149 fn from(variant: ICAFC_A) -> Self {
150 variant as u8 != 0
151 }
152}
153impl ICAFC_R {
154 #[doc = "Get enumerated values variant"]
155 #[inline(always)]
156 pub fn variant(&self) -> ICAFC_A {
157 match self.bits {
158 false => ICAFC_A::_0,
159 true => ICAFC_A::_1,
160 }
161 }
162 #[doc = "Checks if the value of the field is `_0`"]
163 #[inline(always)]
164 pub fn is_0(&self) -> bool {
165 *self == ICAFC_A::_0
166 }
167 #[doc = "Checks if the value of the field is `_1`"]
168 #[inline(always)]
169 pub fn is_1(&self) -> bool {
170 *self == ICAFC_A::_1
171 }
172}
173#[doc = "Field `ICAFC` writer - Forwarding GTCCRC register Compare Match to Other Channel GTCCRA Input Source Capture Enable"]
174pub type ICAFC_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFC_A, O>;
175impl<'a, const O: u8> ICAFC_W<'a, O> {
176 #[doc = "Disable forwarding GTCCRC register compare match to GTCCRA input capture source of other channels"]
177 #[inline(always)]
178 pub fn _0(self) -> &'a mut W {
179 self.variant(ICAFC_A::_0)
180 }
181 #[doc = "Enable forwarding GTCCRC register compare match to GTCCRA input capture source of other channels"]
182 #[inline(always)]
183 pub fn _1(self) -> &'a mut W {
184 self.variant(ICAFC_A::_1)
185 }
186}
187#[doc = "Field `ICAFD` reader - Forwarding GTCCRD register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
188pub type ICAFD_R = crate::BitReader<ICAFD_A>;
189#[doc = "Forwarding GTCCRD register Compare Match to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
190#[derive(Clone, Copy, Debug, PartialEq, Eq)]
191pub enum ICAFD_A {
192 #[doc = "0: Disable forwarding GTCCRD register compare match to GTCCRA input capture source of other channels"]
193 _0 = 0,
194 #[doc = "1: Enable forwarding GTCCRD register compare match to GTCCRA input capture source of other channels"]
195 _1 = 1,
196}
197impl From<ICAFD_A> for bool {
198 #[inline(always)]
199 fn from(variant: ICAFD_A) -> Self {
200 variant as u8 != 0
201 }
202}
203impl ICAFD_R {
204 #[doc = "Get enumerated values variant"]
205 #[inline(always)]
206 pub fn variant(&self) -> ICAFD_A {
207 match self.bits {
208 false => ICAFD_A::_0,
209 true => ICAFD_A::_1,
210 }
211 }
212 #[doc = "Checks if the value of the field is `_0`"]
213 #[inline(always)]
214 pub fn is_0(&self) -> bool {
215 *self == ICAFD_A::_0
216 }
217 #[doc = "Checks if the value of the field is `_1`"]
218 #[inline(always)]
219 pub fn is_1(&self) -> bool {
220 *self == ICAFD_A::_1
221 }
222}
223#[doc = "Field `ICAFD` writer - Forwarding GTCCRD register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
224pub type ICAFD_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFD_A, O>;
225impl<'a, const O: u8> ICAFD_W<'a, O> {
226 #[doc = "Disable forwarding GTCCRD register compare match to GTCCRA input capture source of other channels"]
227 #[inline(always)]
228 pub fn _0(self) -> &'a mut W {
229 self.variant(ICAFD_A::_0)
230 }
231 #[doc = "Enable forwarding GTCCRD register compare match to GTCCRA input capture source of other channels"]
232 #[inline(always)]
233 pub fn _1(self) -> &'a mut W {
234 self.variant(ICAFD_A::_1)
235 }
236}
237#[doc = "Field `ICAFE` reader - Forwarding GTCCRE register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
238pub type ICAFE_R = crate::BitReader<ICAFE_A>;
239#[doc = "Forwarding GTCCRE register Compare Match to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
240#[derive(Clone, Copy, Debug, PartialEq, Eq)]
241pub enum ICAFE_A {
242 #[doc = "0: Disable forwarding GTCCRE register compare match to GTCCRA input capture source of other channels"]
243 _0 = 0,
244 #[doc = "1: Enable forwarding GTCCRE register compare match to GTCCRA input capture source of other channels"]
245 _1 = 1,
246}
247impl From<ICAFE_A> for bool {
248 #[inline(always)]
249 fn from(variant: ICAFE_A) -> Self {
250 variant as u8 != 0
251 }
252}
253impl ICAFE_R {
254 #[doc = "Get enumerated values variant"]
255 #[inline(always)]
256 pub fn variant(&self) -> ICAFE_A {
257 match self.bits {
258 false => ICAFE_A::_0,
259 true => ICAFE_A::_1,
260 }
261 }
262 #[doc = "Checks if the value of the field is `_0`"]
263 #[inline(always)]
264 pub fn is_0(&self) -> bool {
265 *self == ICAFE_A::_0
266 }
267 #[doc = "Checks if the value of the field is `_1`"]
268 #[inline(always)]
269 pub fn is_1(&self) -> bool {
270 *self == ICAFE_A::_1
271 }
272}
273#[doc = "Field `ICAFE` writer - Forwarding GTCCRE register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
274pub type ICAFE_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFE_A, O>;
275impl<'a, const O: u8> ICAFE_W<'a, O> {
276 #[doc = "Disable forwarding GTCCRE register compare match to GTCCRA input capture source of other channels"]
277 #[inline(always)]
278 pub fn _0(self) -> &'a mut W {
279 self.variant(ICAFE_A::_0)
280 }
281 #[doc = "Enable forwarding GTCCRE register compare match to GTCCRA input capture source of other channels"]
282 #[inline(always)]
283 pub fn _1(self) -> &'a mut W {
284 self.variant(ICAFE_A::_1)
285 }
286}
287#[doc = "Field `ICAFF` reader - Forwarding GTCCRF register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
288pub type ICAFF_R = crate::BitReader<ICAFF_A>;
289#[doc = "Forwarding GTCCRF register Compare Match to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
290#[derive(Clone, Copy, Debug, PartialEq, Eq)]
291pub enum ICAFF_A {
292 #[doc = "0: Disable forwarding GTCCRF register compare match to GTCCRA input capture source of other channels"]
293 _0 = 0,
294 #[doc = "1: Enable forwarding GTCCRF register compare match to GTCCRA input capture source of other channels"]
295 _1 = 1,
296}
297impl From<ICAFF_A> for bool {
298 #[inline(always)]
299 fn from(variant: ICAFF_A) -> Self {
300 variant as u8 != 0
301 }
302}
303impl ICAFF_R {
304 #[doc = "Get enumerated values variant"]
305 #[inline(always)]
306 pub fn variant(&self) -> ICAFF_A {
307 match self.bits {
308 false => ICAFF_A::_0,
309 true => ICAFF_A::_1,
310 }
311 }
312 #[doc = "Checks if the value of the field is `_0`"]
313 #[inline(always)]
314 pub fn is_0(&self) -> bool {
315 *self == ICAFF_A::_0
316 }
317 #[doc = "Checks if the value of the field is `_1`"]
318 #[inline(always)]
319 pub fn is_1(&self) -> bool {
320 *self == ICAFF_A::_1
321 }
322}
323#[doc = "Field `ICAFF` writer - Forwarding GTCCRF register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
324pub type ICAFF_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFF_A, O>;
325impl<'a, const O: u8> ICAFF_W<'a, O> {
326 #[doc = "Disable forwarding GTCCRF register compare match to GTCCRA input capture source of other channels"]
327 #[inline(always)]
328 pub fn _0(self) -> &'a mut W {
329 self.variant(ICAFF_A::_0)
330 }
331 #[doc = "Enable forwarding GTCCRF register compare match to GTCCRA input capture source of other channels"]
332 #[inline(always)]
333 pub fn _1(self) -> &'a mut W {
334 self.variant(ICAFF_A::_1)
335 }
336}
337#[doc = "Field `ICAFPO` reader - Forwarding Overflow to Other Channel GTCCRA Input Capture Source Enable"]
338pub type ICAFPO_R = crate::BitReader<ICAFPO_A>;
339#[doc = "Forwarding Overflow to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
340#[derive(Clone, Copy, Debug, PartialEq, Eq)]
341pub enum ICAFPO_A {
342 #[doc = "0: Disable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
343 _0 = 0,
344 #[doc = "1: Enable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
345 _1 = 1,
346}
347impl From<ICAFPO_A> for bool {
348 #[inline(always)]
349 fn from(variant: ICAFPO_A) -> Self {
350 variant as u8 != 0
351 }
352}
353impl ICAFPO_R {
354 #[doc = "Get enumerated values variant"]
355 #[inline(always)]
356 pub fn variant(&self) -> ICAFPO_A {
357 match self.bits {
358 false => ICAFPO_A::_0,
359 true => ICAFPO_A::_1,
360 }
361 }
362 #[doc = "Checks if the value of the field is `_0`"]
363 #[inline(always)]
364 pub fn is_0(&self) -> bool {
365 *self == ICAFPO_A::_0
366 }
367 #[doc = "Checks if the value of the field is `_1`"]
368 #[inline(always)]
369 pub fn is_1(&self) -> bool {
370 *self == ICAFPO_A::_1
371 }
372}
373#[doc = "Field `ICAFPO` writer - Forwarding Overflow to Other Channel GTCCRA Input Capture Source Enable"]
374pub type ICAFPO_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFPO_A, O>;
375impl<'a, const O: u8> ICAFPO_W<'a, O> {
376 #[doc = "Disable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
377 #[inline(always)]
378 pub fn _0(self) -> &'a mut W {
379 self.variant(ICAFPO_A::_0)
380 }
381 #[doc = "Enable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
382 #[inline(always)]
383 pub fn _1(self) -> &'a mut W {
384 self.variant(ICAFPO_A::_1)
385 }
386}
387#[doc = "Field `ICAFPU` reader - Forwarding Underflow to Other Channel GTCCRA Input Capture Source Enable"]
388pub type ICAFPU_R = crate::BitReader<ICAFPU_A>;
389#[doc = "Forwarding Underflow to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
390#[derive(Clone, Copy, Debug, PartialEq, Eq)]
391pub enum ICAFPU_A {
392 #[doc = "0: Disable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
393 _0 = 0,
394 #[doc = "1: Enable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
395 _1 = 1,
396}
397impl From<ICAFPU_A> for bool {
398 #[inline(always)]
399 fn from(variant: ICAFPU_A) -> Self {
400 variant as u8 != 0
401 }
402}
403impl ICAFPU_R {
404 #[doc = "Get enumerated values variant"]
405 #[inline(always)]
406 pub fn variant(&self) -> ICAFPU_A {
407 match self.bits {
408 false => ICAFPU_A::_0,
409 true => ICAFPU_A::_1,
410 }
411 }
412 #[doc = "Checks if the value of the field is `_0`"]
413 #[inline(always)]
414 pub fn is_0(&self) -> bool {
415 *self == ICAFPU_A::_0
416 }
417 #[doc = "Checks if the value of the field is `_1`"]
418 #[inline(always)]
419 pub fn is_1(&self) -> bool {
420 *self == ICAFPU_A::_1
421 }
422}
423#[doc = "Field `ICAFPU` writer - Forwarding Underflow to Other Channel GTCCRA Input Capture Source Enable"]
424pub type ICAFPU_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICAFPU_A, O>;
425impl<'a, const O: u8> ICAFPU_W<'a, O> {
426 #[doc = "Disable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
427 #[inline(always)]
428 pub fn _0(self) -> &'a mut W {
429 self.variant(ICAFPU_A::_0)
430 }
431 #[doc = "Enable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRA input capture source of other channels"]
432 #[inline(always)]
433 pub fn _1(self) -> &'a mut W {
434 self.variant(ICAFPU_A::_1)
435 }
436}
437#[doc = "Field `ICACLK` reader - Forwarding Count Clock to Other Channel GTCCRA Input Capture Source Enable"]
438pub type ICACLK_R = crate::BitReader<ICACLK_A>;
439#[doc = "Forwarding Count Clock to Other Channel GTCCRA Input Capture Source Enable\n\nValue on reset: 0"]
440#[derive(Clone, Copy, Debug, PartialEq, Eq)]
441pub enum ICACLK_A {
442 #[doc = "0: Disable forwarding count clock to GTCCRA input capture source of other channels"]
443 _0 = 0,
444 #[doc = "1: Enable forwarding count clock to GTCCRA input capture source of other channels"]
445 _1 = 1,
446}
447impl From<ICACLK_A> for bool {
448 #[inline(always)]
449 fn from(variant: ICACLK_A) -> Self {
450 variant as u8 != 0
451 }
452}
453impl ICACLK_R {
454 #[doc = "Get enumerated values variant"]
455 #[inline(always)]
456 pub fn variant(&self) -> ICACLK_A {
457 match self.bits {
458 false => ICACLK_A::_0,
459 true => ICACLK_A::_1,
460 }
461 }
462 #[doc = "Checks if the value of the field is `_0`"]
463 #[inline(always)]
464 pub fn is_0(&self) -> bool {
465 *self == ICACLK_A::_0
466 }
467 #[doc = "Checks if the value of the field is `_1`"]
468 #[inline(always)]
469 pub fn is_1(&self) -> bool {
470 *self == ICACLK_A::_1
471 }
472}
473#[doc = "Field `ICACLK` writer - Forwarding Count Clock to Other Channel GTCCRA Input Capture Source Enable"]
474pub type ICACLK_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICACLK_A, O>;
475impl<'a, const O: u8> ICACLK_W<'a, O> {
476 #[doc = "Disable forwarding count clock to GTCCRA input capture source of other channels"]
477 #[inline(always)]
478 pub fn _0(self) -> &'a mut W {
479 self.variant(ICACLK_A::_0)
480 }
481 #[doc = "Enable forwarding count clock to GTCCRA input capture source of other channels"]
482 #[inline(always)]
483 pub fn _1(self) -> &'a mut W {
484 self.variant(ICACLK_A::_1)
485 }
486}
487#[doc = "Field `ICAGRP` reader - GTCCRA Input Capture Group Select"]
488pub type ICAGRP_R = crate::FieldReader<u8, ICAGRP_A>;
489#[doc = "GTCCRA Input Capture Group Select\n\nValue on reset: 0"]
490#[derive(Clone, Copy, Debug, PartialEq, Eq)]
491#[repr(u8)]
492pub enum ICAGRP_A {
493 #[doc = "0: Select group A"]
494 _00 = 0,
495 #[doc = "1: Select group B"]
496 _01 = 1,
497 #[doc = "2: Select group C"]
498 _10 = 2,
499 #[doc = "3: Select group D"]
500 _11 = 3,
501}
502impl From<ICAGRP_A> for u8 {
503 #[inline(always)]
504 fn from(variant: ICAGRP_A) -> Self {
505 variant as _
506 }
507}
508impl ICAGRP_R {
509 #[doc = "Get enumerated values variant"]
510 #[inline(always)]
511 pub fn variant(&self) -> ICAGRP_A {
512 match self.bits {
513 0 => ICAGRP_A::_00,
514 1 => ICAGRP_A::_01,
515 2 => ICAGRP_A::_10,
516 3 => ICAGRP_A::_11,
517 _ => unreachable!(),
518 }
519 }
520 #[doc = "Checks if the value of the field is `_00`"]
521 #[inline(always)]
522 pub fn is_00(&self) -> bool {
523 *self == ICAGRP_A::_00
524 }
525 #[doc = "Checks if the value of the field is `_01`"]
526 #[inline(always)]
527 pub fn is_01(&self) -> bool {
528 *self == ICAGRP_A::_01
529 }
530 #[doc = "Checks if the value of the field is `_10`"]
531 #[inline(always)]
532 pub fn is_10(&self) -> bool {
533 *self == ICAGRP_A::_10
534 }
535 #[doc = "Checks if the value of the field is `_11`"]
536 #[inline(always)]
537 pub fn is_11(&self) -> bool {
538 *self == ICAGRP_A::_11
539 }
540}
541#[doc = "Field `ICAGRP` writer - GTCCRA Input Capture Group Select"]
542pub type ICAGRP_W<'a, const O: u8> =
543 crate::FieldWriterSafe<'a, u32, GTICCR_SPEC, u8, ICAGRP_A, 2, O>;
544impl<'a, const O: u8> ICAGRP_W<'a, O> {
545 #[doc = "Select group A"]
546 #[inline(always)]
547 pub fn _00(self) -> &'a mut W {
548 self.variant(ICAGRP_A::_00)
549 }
550 #[doc = "Select group B"]
551 #[inline(always)]
552 pub fn _01(self) -> &'a mut W {
553 self.variant(ICAGRP_A::_01)
554 }
555 #[doc = "Select group C"]
556 #[inline(always)]
557 pub fn _10(self) -> &'a mut W {
558 self.variant(ICAGRP_A::_10)
559 }
560 #[doc = "Select group D"]
561 #[inline(always)]
562 pub fn _11(self) -> &'a mut W {
563 self.variant(ICAGRP_A::_11)
564 }
565}
566#[doc = "Field `ICBFA` reader - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
567pub type ICBFA_R = crate::BitReader<ICBFA_A>;
568#[doc = "Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
569#[derive(Clone, Copy, Debug, PartialEq, Eq)]
570pub enum ICBFA_A {
571 #[doc = "0: Disable forwarding GTCCRA register compare match/input capture to GTCCRB input capture source of other channels"]
572 _0 = 0,
573 #[doc = "1: Enable forwarding GTCCRA register compare match/input capture to GTCCRB input capture source of other channels"]
574 _1 = 1,
575}
576impl From<ICBFA_A> for bool {
577 #[inline(always)]
578 fn from(variant: ICBFA_A) -> Self {
579 variant as u8 != 0
580 }
581}
582impl ICBFA_R {
583 #[doc = "Get enumerated values variant"]
584 #[inline(always)]
585 pub fn variant(&self) -> ICBFA_A {
586 match self.bits {
587 false => ICBFA_A::_0,
588 true => ICBFA_A::_1,
589 }
590 }
591 #[doc = "Checks if the value of the field is `_0`"]
592 #[inline(always)]
593 pub fn is_0(&self) -> bool {
594 *self == ICBFA_A::_0
595 }
596 #[doc = "Checks if the value of the field is `_1`"]
597 #[inline(always)]
598 pub fn is_1(&self) -> bool {
599 *self == ICBFA_A::_1
600 }
601}
602#[doc = "Field `ICBFA` writer - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
603pub type ICBFA_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFA_A, O>;
604impl<'a, const O: u8> ICBFA_W<'a, O> {
605 #[doc = "Disable forwarding GTCCRA register compare match/input capture to GTCCRB input capture source of other channels"]
606 #[inline(always)]
607 pub fn _0(self) -> &'a mut W {
608 self.variant(ICBFA_A::_0)
609 }
610 #[doc = "Enable forwarding GTCCRA register compare match/input capture to GTCCRB input capture source of other channels"]
611 #[inline(always)]
612 pub fn _1(self) -> &'a mut W {
613 self.variant(ICBFA_A::_1)
614 }
615}
616#[doc = "Field `ICBFB` reader - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
617pub type ICBFB_R = crate::BitReader<ICBFB_A>;
618#[doc = "Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
619#[derive(Clone, Copy, Debug, PartialEq, Eq)]
620pub enum ICBFB_A {
621 #[doc = "0: Disable forwarding GTCCRB register compare match/input capture to GTCCRB input capture source of other channels"]
622 _0 = 0,
623 #[doc = "1: Enable forwarding GTCCRB register compare match/input capture to GTCCRB input capture source of other channels"]
624 _1 = 1,
625}
626impl From<ICBFB_A> for bool {
627 #[inline(always)]
628 fn from(variant: ICBFB_A) -> Self {
629 variant as u8 != 0
630 }
631}
632impl ICBFB_R {
633 #[doc = "Get enumerated values variant"]
634 #[inline(always)]
635 pub fn variant(&self) -> ICBFB_A {
636 match self.bits {
637 false => ICBFB_A::_0,
638 true => ICBFB_A::_1,
639 }
640 }
641 #[doc = "Checks if the value of the field is `_0`"]
642 #[inline(always)]
643 pub fn is_0(&self) -> bool {
644 *self == ICBFB_A::_0
645 }
646 #[doc = "Checks if the value of the field is `_1`"]
647 #[inline(always)]
648 pub fn is_1(&self) -> bool {
649 *self == ICBFB_A::_1
650 }
651}
652#[doc = "Field `ICBFB` writer - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
653pub type ICBFB_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFB_A, O>;
654impl<'a, const O: u8> ICBFB_W<'a, O> {
655 #[doc = "Disable forwarding GTCCRB register compare match/input capture to GTCCRB input capture source of other channels"]
656 #[inline(always)]
657 pub fn _0(self) -> &'a mut W {
658 self.variant(ICBFB_A::_0)
659 }
660 #[doc = "Enable forwarding GTCCRB register compare match/input capture to GTCCRB input capture source of other channels"]
661 #[inline(always)]
662 pub fn _1(self) -> &'a mut W {
663 self.variant(ICBFB_A::_1)
664 }
665}
666#[doc = "Field `ICBFC` reader - Forwarding GTCCRC register Compare Match to Other Channel GTCCRB Input Source Capture Enable"]
667pub type ICBFC_R = crate::BitReader<ICBFC_A>;
668#[doc = "Forwarding GTCCRC register Compare Match to Other Channel GTCCRB Input Source Capture Enable\n\nValue on reset: 0"]
669#[derive(Clone, Copy, Debug, PartialEq, Eq)]
670pub enum ICBFC_A {
671 #[doc = "0: Disable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
672 _0 = 0,
673 #[doc = "1: Enable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
674 _1 = 1,
675}
676impl From<ICBFC_A> for bool {
677 #[inline(always)]
678 fn from(variant: ICBFC_A) -> Self {
679 variant as u8 != 0
680 }
681}
682impl ICBFC_R {
683 #[doc = "Get enumerated values variant"]
684 #[inline(always)]
685 pub fn variant(&self) -> ICBFC_A {
686 match self.bits {
687 false => ICBFC_A::_0,
688 true => ICBFC_A::_1,
689 }
690 }
691 #[doc = "Checks if the value of the field is `_0`"]
692 #[inline(always)]
693 pub fn is_0(&self) -> bool {
694 *self == ICBFC_A::_0
695 }
696 #[doc = "Checks if the value of the field is `_1`"]
697 #[inline(always)]
698 pub fn is_1(&self) -> bool {
699 *self == ICBFC_A::_1
700 }
701}
702#[doc = "Field `ICBFC` writer - Forwarding GTCCRC register Compare Match to Other Channel GTCCRB Input Source Capture Enable"]
703pub type ICBFC_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFC_A, O>;
704impl<'a, const O: u8> ICBFC_W<'a, O> {
705 #[doc = "Disable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
706 #[inline(always)]
707 pub fn _0(self) -> &'a mut W {
708 self.variant(ICBFC_A::_0)
709 }
710 #[doc = "Enable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
711 #[inline(always)]
712 pub fn _1(self) -> &'a mut W {
713 self.variant(ICBFC_A::_1)
714 }
715}
716#[doc = "Field `ICBFD` reader - Forwarding GTCCRD register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
717pub type ICBFD_R = crate::BitReader<ICBFD_A>;
718#[doc = "Forwarding GTCCRD register Compare Match to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
719#[derive(Clone, Copy, Debug, PartialEq, Eq)]
720pub enum ICBFD_A {
721 #[doc = "0: Disable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
722 _0 = 0,
723 #[doc = "1: Enable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
724 _1 = 1,
725}
726impl From<ICBFD_A> for bool {
727 #[inline(always)]
728 fn from(variant: ICBFD_A) -> Self {
729 variant as u8 != 0
730 }
731}
732impl ICBFD_R {
733 #[doc = "Get enumerated values variant"]
734 #[inline(always)]
735 pub fn variant(&self) -> ICBFD_A {
736 match self.bits {
737 false => ICBFD_A::_0,
738 true => ICBFD_A::_1,
739 }
740 }
741 #[doc = "Checks if the value of the field is `_0`"]
742 #[inline(always)]
743 pub fn is_0(&self) -> bool {
744 *self == ICBFD_A::_0
745 }
746 #[doc = "Checks if the value of the field is `_1`"]
747 #[inline(always)]
748 pub fn is_1(&self) -> bool {
749 *self == ICBFD_A::_1
750 }
751}
752#[doc = "Field `ICBFD` writer - Forwarding GTCCRD register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
753pub type ICBFD_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFD_A, O>;
754impl<'a, const O: u8> ICBFD_W<'a, O> {
755 #[doc = "Disable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
756 #[inline(always)]
757 pub fn _0(self) -> &'a mut W {
758 self.variant(ICBFD_A::_0)
759 }
760 #[doc = "Enable forwarding GTCCRD register compare match to GTCCRB input capture source of other channels"]
761 #[inline(always)]
762 pub fn _1(self) -> &'a mut W {
763 self.variant(ICBFD_A::_1)
764 }
765}
766#[doc = "Field `ICBFE` reader - Forwarding GTCCRE register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
767pub type ICBFE_R = crate::BitReader<ICBFE_A>;
768#[doc = "Forwarding GTCCRE register Compare Match to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
769#[derive(Clone, Copy, Debug, PartialEq, Eq)]
770pub enum ICBFE_A {
771 #[doc = "0: Disable forwarding GTCCRE register compare match to GTCCRB input capture source of other channels"]
772 _0 = 0,
773 #[doc = "1: Enable forwarding GTCCRE register compare match to GTCCRB input capture source of other channels"]
774 _1 = 1,
775}
776impl From<ICBFE_A> for bool {
777 #[inline(always)]
778 fn from(variant: ICBFE_A) -> Self {
779 variant as u8 != 0
780 }
781}
782impl ICBFE_R {
783 #[doc = "Get enumerated values variant"]
784 #[inline(always)]
785 pub fn variant(&self) -> ICBFE_A {
786 match self.bits {
787 false => ICBFE_A::_0,
788 true => ICBFE_A::_1,
789 }
790 }
791 #[doc = "Checks if the value of the field is `_0`"]
792 #[inline(always)]
793 pub fn is_0(&self) -> bool {
794 *self == ICBFE_A::_0
795 }
796 #[doc = "Checks if the value of the field is `_1`"]
797 #[inline(always)]
798 pub fn is_1(&self) -> bool {
799 *self == ICBFE_A::_1
800 }
801}
802#[doc = "Field `ICBFE` writer - Forwarding GTCCRE register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
803pub type ICBFE_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFE_A, O>;
804impl<'a, const O: u8> ICBFE_W<'a, O> {
805 #[doc = "Disable forwarding GTCCRE register compare match to GTCCRB input capture source of other channels"]
806 #[inline(always)]
807 pub fn _0(self) -> &'a mut W {
808 self.variant(ICBFE_A::_0)
809 }
810 #[doc = "Enable forwarding GTCCRE register compare match to GTCCRB input capture source of other channels"]
811 #[inline(always)]
812 pub fn _1(self) -> &'a mut W {
813 self.variant(ICBFE_A::_1)
814 }
815}
816#[doc = "Field `ICBFF` reader - Forwarding GTCCRF register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
817pub type ICBFF_R = crate::BitReader<ICBFF_A>;
818#[doc = "Forwarding GTCCRF register Compare Match to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
819#[derive(Clone, Copy, Debug, PartialEq, Eq)]
820pub enum ICBFF_A {
821 #[doc = "0: Disable forwarding GTCCRF register compare match to GTCCRB input capture source of other channels"]
822 _0 = 0,
823 #[doc = "1: Enable forwarding GTCCRF register compare match to GTCCRB input capture source of other channels"]
824 _1 = 1,
825}
826impl From<ICBFF_A> for bool {
827 #[inline(always)]
828 fn from(variant: ICBFF_A) -> Self {
829 variant as u8 != 0
830 }
831}
832impl ICBFF_R {
833 #[doc = "Get enumerated values variant"]
834 #[inline(always)]
835 pub fn variant(&self) -> ICBFF_A {
836 match self.bits {
837 false => ICBFF_A::_0,
838 true => ICBFF_A::_1,
839 }
840 }
841 #[doc = "Checks if the value of the field is `_0`"]
842 #[inline(always)]
843 pub fn is_0(&self) -> bool {
844 *self == ICBFF_A::_0
845 }
846 #[doc = "Checks if the value of the field is `_1`"]
847 #[inline(always)]
848 pub fn is_1(&self) -> bool {
849 *self == ICBFF_A::_1
850 }
851}
852#[doc = "Field `ICBFF` writer - Forwarding GTCCRF register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
853pub type ICBFF_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFF_A, O>;
854impl<'a, const O: u8> ICBFF_W<'a, O> {
855 #[doc = "Disable forwarding GTCCRF register compare match to GTCCRB input capture source of other channels"]
856 #[inline(always)]
857 pub fn _0(self) -> &'a mut W {
858 self.variant(ICBFF_A::_0)
859 }
860 #[doc = "Enable forwarding GTCCRF register compare match to GTCCRB input capture source of other channels"]
861 #[inline(always)]
862 pub fn _1(self) -> &'a mut W {
863 self.variant(ICBFF_A::_1)
864 }
865}
866#[doc = "Field `ICBFPO` reader - Forwarding Overflow to Other Channel GTCCRB Input Capture Source Enable"]
867pub type ICBFPO_R = crate::BitReader<ICBFPO_A>;
868#[doc = "Forwarding Overflow to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
869#[derive(Clone, Copy, Debug, PartialEq, Eq)]
870pub enum ICBFPO_A {
871 #[doc = "0: Disable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
872 _0 = 0,
873 #[doc = "1: Enable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
874 _1 = 1,
875}
876impl From<ICBFPO_A> for bool {
877 #[inline(always)]
878 fn from(variant: ICBFPO_A) -> Self {
879 variant as u8 != 0
880 }
881}
882impl ICBFPO_R {
883 #[doc = "Get enumerated values variant"]
884 #[inline(always)]
885 pub fn variant(&self) -> ICBFPO_A {
886 match self.bits {
887 false => ICBFPO_A::_0,
888 true => ICBFPO_A::_1,
889 }
890 }
891 #[doc = "Checks if the value of the field is `_0`"]
892 #[inline(always)]
893 pub fn is_0(&self) -> bool {
894 *self == ICBFPO_A::_0
895 }
896 #[doc = "Checks if the value of the field is `_1`"]
897 #[inline(always)]
898 pub fn is_1(&self) -> bool {
899 *self == ICBFPO_A::_1
900 }
901}
902#[doc = "Field `ICBFPO` writer - Forwarding Overflow to Other Channel GTCCRB Input Capture Source Enable"]
903pub type ICBFPO_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFPO_A, O>;
904impl<'a, const O: u8> ICBFPO_W<'a, O> {
905 #[doc = "Disable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
906 #[inline(always)]
907 pub fn _0(self) -> &'a mut W {
908 self.variant(ICBFPO_A::_0)
909 }
910 #[doc = "Enable forwarding overflow in saw-waves or the crest in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
911 #[inline(always)]
912 pub fn _1(self) -> &'a mut W {
913 self.variant(ICBFPO_A::_1)
914 }
915}
916#[doc = "Field `ICBFPU` reader - Forwarding Underflow to Other Channel GTCCRB Input Capture Source Enable"]
917pub type ICBFPU_R = crate::BitReader<ICBFPU_A>;
918#[doc = "Forwarding Underflow to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
919#[derive(Clone, Copy, Debug, PartialEq, Eq)]
920pub enum ICBFPU_A {
921 #[doc = "0: Disable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
922 _0 = 0,
923 #[doc = "1: Enable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
924 _1 = 1,
925}
926impl From<ICBFPU_A> for bool {
927 #[inline(always)]
928 fn from(variant: ICBFPU_A) -> Self {
929 variant as u8 != 0
930 }
931}
932impl ICBFPU_R {
933 #[doc = "Get enumerated values variant"]
934 #[inline(always)]
935 pub fn variant(&self) -> ICBFPU_A {
936 match self.bits {
937 false => ICBFPU_A::_0,
938 true => ICBFPU_A::_1,
939 }
940 }
941 #[doc = "Checks if the value of the field is `_0`"]
942 #[inline(always)]
943 pub fn is_0(&self) -> bool {
944 *self == ICBFPU_A::_0
945 }
946 #[doc = "Checks if the value of the field is `_1`"]
947 #[inline(always)]
948 pub fn is_1(&self) -> bool {
949 *self == ICBFPU_A::_1
950 }
951}
952#[doc = "Field `ICBFPU` writer - Forwarding Underflow to Other Channel GTCCRB Input Capture Source Enable"]
953pub type ICBFPU_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBFPU_A, O>;
954impl<'a, const O: u8> ICBFPU_W<'a, O> {
955 #[doc = "Disable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
956 #[inline(always)]
957 pub fn _0(self) -> &'a mut W {
958 self.variant(ICBFPU_A::_0)
959 }
960 #[doc = "Enable forwarding underflow in saw-waves or the trough in triangle-waves or complementary PWM mode to GTCCRB input capture source of other channels"]
961 #[inline(always)]
962 pub fn _1(self) -> &'a mut W {
963 self.variant(ICBFPU_A::_1)
964 }
965}
966#[doc = "Field `ICBCLK` reader - Forwarding Count Clock to Other Channel GTCCRB Input Capture Source Enable"]
967pub type ICBCLK_R = crate::BitReader<ICBCLK_A>;
968#[doc = "Forwarding Count Clock to Other Channel GTCCRB Input Capture Source Enable\n\nValue on reset: 0"]
969#[derive(Clone, Copy, Debug, PartialEq, Eq)]
970pub enum ICBCLK_A {
971 #[doc = "0: Disable forwarding count clock to GTCCRB input capture source of other channels"]
972 _0 = 0,
973 #[doc = "1: Enable forwarding count clock to GTCCRB input capture source of other channels"]
974 _1 = 1,
975}
976impl From<ICBCLK_A> for bool {
977 #[inline(always)]
978 fn from(variant: ICBCLK_A) -> Self {
979 variant as u8 != 0
980 }
981}
982impl ICBCLK_R {
983 #[doc = "Get enumerated values variant"]
984 #[inline(always)]
985 pub fn variant(&self) -> ICBCLK_A {
986 match self.bits {
987 false => ICBCLK_A::_0,
988 true => ICBCLK_A::_1,
989 }
990 }
991 #[doc = "Checks if the value of the field is `_0`"]
992 #[inline(always)]
993 pub fn is_0(&self) -> bool {
994 *self == ICBCLK_A::_0
995 }
996 #[doc = "Checks if the value of the field is `_1`"]
997 #[inline(always)]
998 pub fn is_1(&self) -> bool {
999 *self == ICBCLK_A::_1
1000 }
1001}
1002#[doc = "Field `ICBCLK` writer - Forwarding Count Clock to Other Channel GTCCRB Input Capture Source Enable"]
1003pub type ICBCLK_W<'a, const O: u8> = crate::BitWriter<'a, u32, GTICCR_SPEC, ICBCLK_A, O>;
1004impl<'a, const O: u8> ICBCLK_W<'a, O> {
1005 #[doc = "Disable forwarding count clock to GTCCRB input capture source of other channels"]
1006 #[inline(always)]
1007 pub fn _0(self) -> &'a mut W {
1008 self.variant(ICBCLK_A::_0)
1009 }
1010 #[doc = "Enable forwarding count clock to GTCCRB input capture source of other channels"]
1011 #[inline(always)]
1012 pub fn _1(self) -> &'a mut W {
1013 self.variant(ICBCLK_A::_1)
1014 }
1015}
1016#[doc = "Field `ICBGRP` reader - GTCCRB Input Capture Group Select"]
1017pub type ICBGRP_R = crate::FieldReader<u8, ICBGRP_A>;
1018#[doc = "GTCCRB Input Capture Group Select\n\nValue on reset: 0"]
1019#[derive(Clone, Copy, Debug, PartialEq, Eq)]
1020#[repr(u8)]
1021pub enum ICBGRP_A {
1022 #[doc = "0: Select group A"]
1023 _00 = 0,
1024 #[doc = "1: Select group B"]
1025 _01 = 1,
1026 #[doc = "2: Select group C"]
1027 _10 = 2,
1028 #[doc = "3: Select group D"]
1029 _11 = 3,
1030}
1031impl From<ICBGRP_A> for u8 {
1032 #[inline(always)]
1033 fn from(variant: ICBGRP_A) -> Self {
1034 variant as _
1035 }
1036}
1037impl ICBGRP_R {
1038 #[doc = "Get enumerated values variant"]
1039 #[inline(always)]
1040 pub fn variant(&self) -> ICBGRP_A {
1041 match self.bits {
1042 0 => ICBGRP_A::_00,
1043 1 => ICBGRP_A::_01,
1044 2 => ICBGRP_A::_10,
1045 3 => ICBGRP_A::_11,
1046 _ => unreachable!(),
1047 }
1048 }
1049 #[doc = "Checks if the value of the field is `_00`"]
1050 #[inline(always)]
1051 pub fn is_00(&self) -> bool {
1052 *self == ICBGRP_A::_00
1053 }
1054 #[doc = "Checks if the value of the field is `_01`"]
1055 #[inline(always)]
1056 pub fn is_01(&self) -> bool {
1057 *self == ICBGRP_A::_01
1058 }
1059 #[doc = "Checks if the value of the field is `_10`"]
1060 #[inline(always)]
1061 pub fn is_10(&self) -> bool {
1062 *self == ICBGRP_A::_10
1063 }
1064 #[doc = "Checks if the value of the field is `_11`"]
1065 #[inline(always)]
1066 pub fn is_11(&self) -> bool {
1067 *self == ICBGRP_A::_11
1068 }
1069}
1070#[doc = "Field `ICBGRP` writer - GTCCRB Input Capture Group Select"]
1071pub type ICBGRP_W<'a, const O: u8> =
1072 crate::FieldWriterSafe<'a, u32, GTICCR_SPEC, u8, ICBGRP_A, 2, O>;
1073impl<'a, const O: u8> ICBGRP_W<'a, O> {
1074 #[doc = "Select group A"]
1075 #[inline(always)]
1076 pub fn _00(self) -> &'a mut W {
1077 self.variant(ICBGRP_A::_00)
1078 }
1079 #[doc = "Select group B"]
1080 #[inline(always)]
1081 pub fn _01(self) -> &'a mut W {
1082 self.variant(ICBGRP_A::_01)
1083 }
1084 #[doc = "Select group C"]
1085 #[inline(always)]
1086 pub fn _10(self) -> &'a mut W {
1087 self.variant(ICBGRP_A::_10)
1088 }
1089 #[doc = "Select group D"]
1090 #[inline(always)]
1091 pub fn _11(self) -> &'a mut W {
1092 self.variant(ICBGRP_A::_11)
1093 }
1094}
1095impl R {
1096 #[doc = "Bit 0 - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
1097 #[inline(always)]
1098 pub fn icafa(&self) -> ICAFA_R {
1099 ICAFA_R::new((self.bits & 1) != 0)
1100 }
1101 #[doc = "Bit 1 - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
1102 #[inline(always)]
1103 pub fn icafb(&self) -> ICAFB_R {
1104 ICAFB_R::new(((self.bits >> 1) & 1) != 0)
1105 }
1106 #[doc = "Bit 2 - Forwarding GTCCRC register Compare Match to Other Channel GTCCRA Input Source Capture Enable"]
1107 #[inline(always)]
1108 pub fn icafc(&self) -> ICAFC_R {
1109 ICAFC_R::new(((self.bits >> 2) & 1) != 0)
1110 }
1111 #[doc = "Bit 3 - Forwarding GTCCRD register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
1112 #[inline(always)]
1113 pub fn icafd(&self) -> ICAFD_R {
1114 ICAFD_R::new(((self.bits >> 3) & 1) != 0)
1115 }
1116 #[doc = "Bit 4 - Forwarding GTCCRE register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
1117 #[inline(always)]
1118 pub fn icafe(&self) -> ICAFE_R {
1119 ICAFE_R::new(((self.bits >> 4) & 1) != 0)
1120 }
1121 #[doc = "Bit 5 - Forwarding GTCCRF register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
1122 #[inline(always)]
1123 pub fn icaff(&self) -> ICAFF_R {
1124 ICAFF_R::new(((self.bits >> 5) & 1) != 0)
1125 }
1126 #[doc = "Bit 6 - Forwarding Overflow to Other Channel GTCCRA Input Capture Source Enable"]
1127 #[inline(always)]
1128 pub fn icafpo(&self) -> ICAFPO_R {
1129 ICAFPO_R::new(((self.bits >> 6) & 1) != 0)
1130 }
1131 #[doc = "Bit 7 - Forwarding Underflow to Other Channel GTCCRA Input Capture Source Enable"]
1132 #[inline(always)]
1133 pub fn icafpu(&self) -> ICAFPU_R {
1134 ICAFPU_R::new(((self.bits >> 7) & 1) != 0)
1135 }
1136 #[doc = "Bit 8 - Forwarding Count Clock to Other Channel GTCCRA Input Capture Source Enable"]
1137 #[inline(always)]
1138 pub fn icaclk(&self) -> ICACLK_R {
1139 ICACLK_R::new(((self.bits >> 8) & 1) != 0)
1140 }
1141 #[doc = "Bits 14:15 - GTCCRA Input Capture Group Select"]
1142 #[inline(always)]
1143 pub fn icagrp(&self) -> ICAGRP_R {
1144 ICAGRP_R::new(((self.bits >> 14) & 3) as u8)
1145 }
1146 #[doc = "Bit 16 - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
1147 #[inline(always)]
1148 pub fn icbfa(&self) -> ICBFA_R {
1149 ICBFA_R::new(((self.bits >> 16) & 1) != 0)
1150 }
1151 #[doc = "Bit 17 - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
1152 #[inline(always)]
1153 pub fn icbfb(&self) -> ICBFB_R {
1154 ICBFB_R::new(((self.bits >> 17) & 1) != 0)
1155 }
1156 #[doc = "Bit 18 - Forwarding GTCCRC register Compare Match to Other Channel GTCCRB Input Source Capture Enable"]
1157 #[inline(always)]
1158 pub fn icbfc(&self) -> ICBFC_R {
1159 ICBFC_R::new(((self.bits >> 18) & 1) != 0)
1160 }
1161 #[doc = "Bit 19 - Forwarding GTCCRD register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
1162 #[inline(always)]
1163 pub fn icbfd(&self) -> ICBFD_R {
1164 ICBFD_R::new(((self.bits >> 19) & 1) != 0)
1165 }
1166 #[doc = "Bit 20 - Forwarding GTCCRE register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
1167 #[inline(always)]
1168 pub fn icbfe(&self) -> ICBFE_R {
1169 ICBFE_R::new(((self.bits >> 20) & 1) != 0)
1170 }
1171 #[doc = "Bit 21 - Forwarding GTCCRF register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
1172 #[inline(always)]
1173 pub fn icbff(&self) -> ICBFF_R {
1174 ICBFF_R::new(((self.bits >> 21) & 1) != 0)
1175 }
1176 #[doc = "Bit 22 - Forwarding Overflow to Other Channel GTCCRB Input Capture Source Enable"]
1177 #[inline(always)]
1178 pub fn icbfpo(&self) -> ICBFPO_R {
1179 ICBFPO_R::new(((self.bits >> 22) & 1) != 0)
1180 }
1181 #[doc = "Bit 23 - Forwarding Underflow to Other Channel GTCCRB Input Capture Source Enable"]
1182 #[inline(always)]
1183 pub fn icbfpu(&self) -> ICBFPU_R {
1184 ICBFPU_R::new(((self.bits >> 23) & 1) != 0)
1185 }
1186 #[doc = "Bit 24 - Forwarding Count Clock to Other Channel GTCCRB Input Capture Source Enable"]
1187 #[inline(always)]
1188 pub fn icbclk(&self) -> ICBCLK_R {
1189 ICBCLK_R::new(((self.bits >> 24) & 1) != 0)
1190 }
1191 #[doc = "Bits 30:31 - GTCCRB Input Capture Group Select"]
1192 #[inline(always)]
1193 pub fn icbgrp(&self) -> ICBGRP_R {
1194 ICBGRP_R::new(((self.bits >> 30) & 3) as u8)
1195 }
1196}
1197impl W {
1198 #[doc = "Bit 0 - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
1199 #[inline(always)]
1200 #[must_use]
1201 pub fn icafa(&mut self) -> ICAFA_W<0> {
1202 ICAFA_W::new(self)
1203 }
1204 #[doc = "Bit 1 - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRA Input Capture Source Enable"]
1205 #[inline(always)]
1206 #[must_use]
1207 pub fn icafb(&mut self) -> ICAFB_W<1> {
1208 ICAFB_W::new(self)
1209 }
1210 #[doc = "Bit 2 - Forwarding GTCCRC register Compare Match to Other Channel GTCCRA Input Source Capture Enable"]
1211 #[inline(always)]
1212 #[must_use]
1213 pub fn icafc(&mut self) -> ICAFC_W<2> {
1214 ICAFC_W::new(self)
1215 }
1216 #[doc = "Bit 3 - Forwarding GTCCRD register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
1217 #[inline(always)]
1218 #[must_use]
1219 pub fn icafd(&mut self) -> ICAFD_W<3> {
1220 ICAFD_W::new(self)
1221 }
1222 #[doc = "Bit 4 - Forwarding GTCCRE register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
1223 #[inline(always)]
1224 #[must_use]
1225 pub fn icafe(&mut self) -> ICAFE_W<4> {
1226 ICAFE_W::new(self)
1227 }
1228 #[doc = "Bit 5 - Forwarding GTCCRF register Compare Match to Other Channel GTCCRA Input Capture Source Enable"]
1229 #[inline(always)]
1230 #[must_use]
1231 pub fn icaff(&mut self) -> ICAFF_W<5> {
1232 ICAFF_W::new(self)
1233 }
1234 #[doc = "Bit 6 - Forwarding Overflow to Other Channel GTCCRA Input Capture Source Enable"]
1235 #[inline(always)]
1236 #[must_use]
1237 pub fn icafpo(&mut self) -> ICAFPO_W<6> {
1238 ICAFPO_W::new(self)
1239 }
1240 #[doc = "Bit 7 - Forwarding Underflow to Other Channel GTCCRA Input Capture Source Enable"]
1241 #[inline(always)]
1242 #[must_use]
1243 pub fn icafpu(&mut self) -> ICAFPU_W<7> {
1244 ICAFPU_W::new(self)
1245 }
1246 #[doc = "Bit 8 - Forwarding Count Clock to Other Channel GTCCRA Input Capture Source Enable"]
1247 #[inline(always)]
1248 #[must_use]
1249 pub fn icaclk(&mut self) -> ICACLK_W<8> {
1250 ICACLK_W::new(self)
1251 }
1252 #[doc = "Bits 14:15 - GTCCRA Input Capture Group Select"]
1253 #[inline(always)]
1254 #[must_use]
1255 pub fn icagrp(&mut self) -> ICAGRP_W<14> {
1256 ICAGRP_W::new(self)
1257 }
1258 #[doc = "Bit 16 - Forwarding GTCCRA register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
1259 #[inline(always)]
1260 #[must_use]
1261 pub fn icbfa(&mut self) -> ICBFA_W<16> {
1262 ICBFA_W::new(self)
1263 }
1264 #[doc = "Bit 17 - Forwarding GTCCRB register Compare Match/Input Capture to Other Channel GTCCRB Input Capture Source Enable"]
1265 #[inline(always)]
1266 #[must_use]
1267 pub fn icbfb(&mut self) -> ICBFB_W<17> {
1268 ICBFB_W::new(self)
1269 }
1270 #[doc = "Bit 18 - Forwarding GTCCRC register Compare Match to Other Channel GTCCRB Input Source Capture Enable"]
1271 #[inline(always)]
1272 #[must_use]
1273 pub fn icbfc(&mut self) -> ICBFC_W<18> {
1274 ICBFC_W::new(self)
1275 }
1276 #[doc = "Bit 19 - Forwarding GTCCRD register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
1277 #[inline(always)]
1278 #[must_use]
1279 pub fn icbfd(&mut self) -> ICBFD_W<19> {
1280 ICBFD_W::new(self)
1281 }
1282 #[doc = "Bit 20 - Forwarding GTCCRE register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
1283 #[inline(always)]
1284 #[must_use]
1285 pub fn icbfe(&mut self) -> ICBFE_W<20> {
1286 ICBFE_W::new(self)
1287 }
1288 #[doc = "Bit 21 - Forwarding GTCCRF register Compare Match to Other Channel GTCCRB Input Capture Source Enable"]
1289 #[inline(always)]
1290 #[must_use]
1291 pub fn icbff(&mut self) -> ICBFF_W<21> {
1292 ICBFF_W::new(self)
1293 }
1294 #[doc = "Bit 22 - Forwarding Overflow to Other Channel GTCCRB Input Capture Source Enable"]
1295 #[inline(always)]
1296 #[must_use]
1297 pub fn icbfpo(&mut self) -> ICBFPO_W<22> {
1298 ICBFPO_W::new(self)
1299 }
1300 #[doc = "Bit 23 - Forwarding Underflow to Other Channel GTCCRB Input Capture Source Enable"]
1301 #[inline(always)]
1302 #[must_use]
1303 pub fn icbfpu(&mut self) -> ICBFPU_W<23> {
1304 ICBFPU_W::new(self)
1305 }
1306 #[doc = "Bit 24 - Forwarding Count Clock to Other Channel GTCCRB Input Capture Source Enable"]
1307 #[inline(always)]
1308 #[must_use]
1309 pub fn icbclk(&mut self) -> ICBCLK_W<24> {
1310 ICBCLK_W::new(self)
1311 }
1312 #[doc = "Bits 30:31 - GTCCRB Input Capture Group Select"]
1313 #[inline(always)]
1314 #[must_use]
1315 pub fn icbgrp(&mut self) -> ICBGRP_W<30> {
1316 ICBGRP_W::new(self)
1317 }
1318 #[doc = "Writes raw bits to the register."]
1319 #[inline(always)]
1320 pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
1321 self.0.bits(bits);
1322 self
1323 }
1324}
1325#[doc = "General PWM Timer Inter Channel Cooperation Input Capture Control Register\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 [gticcr](index.html) module"]
1326pub struct GTICCR_SPEC;
1327impl crate::RegisterSpec for GTICCR_SPEC {
1328 type Ux = u32;
1329}
1330#[doc = "`read()` method returns [gticcr::R](R) reader structure"]
1331impl crate::Readable for GTICCR_SPEC {
1332 type Reader = R;
1333}
1334#[doc = "`write(|w| ..)` method takes [gticcr::W](W) writer structure"]
1335impl crate::Writable for GTICCR_SPEC {
1336 type Writer = W;
1337 const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
1338 const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
1339}
1340#[doc = "`reset()` method sets GTICCR to value 0"]
1341impl crate::Resettable for GTICCR_SPEC {
1342 const RESET_VALUE: Self::Ux = 0;
1343}