1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
#[doc = "Register `IFCR` reader"]
pub struct R(crate::R<IFCR_SPEC>);
impl core::ops::Deref for R {
    type Target = crate::R<IFCR_SPEC>;
    #[inline(always)]
    fn deref(&self) -> &Self::Target {
        &self.0
    }
}
impl From<crate::R<IFCR_SPEC>> for R {
    #[inline(always)]
    fn from(reader: crate::R<IFCR_SPEC>) -> Self {
        R(reader)
    }
}
#[doc = "Clear channel 1 global interrupt flag\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum CGIF1_A {
    #[doc = "1: Clears the GIF, TEIF, HTIF, TCIF flags in the ISR register"]
    Clear = 1,
}
impl From<CGIF1_A> for bool {
    #[inline(always)]
    fn from(variant: CGIF1_A) -> Self {
        variant as u8 != 0
    }
}
#[doc = "Field `CGIF1` reader - Clear channel 1 global interrupt flag"]
pub type CGIF1_R = crate::BitReader<CGIF1_A>;
impl CGIF1_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub fn variant(&self) -> Option<CGIF1_A> {
        match self.bits {
            true => Some(CGIF1_A::Clear),
            _ => None,
        }
    }
    #[doc = "Checks if the value of the field is `Clear`"]
    #[inline(always)]
    pub fn is_clear(&self) -> bool {
        *self == CGIF1_A::Clear
    }
}
#[doc = "Clear channel 1 transfer complete flag\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum CTCIF1_A {
    #[doc = "1: Clears the TCIF flag in the ISR register"]
    Clear = 1,
}
impl From<CTCIF1_A> for bool {
    #[inline(always)]
    fn from(variant: CTCIF1_A) -> Self {
        variant as u8 != 0
    }
}
#[doc = "Field `CTCIF1` reader - Clear channel 1 transfer complete flag"]
pub type CTCIF1_R = crate::BitReader<CTCIF1_A>;
impl CTCIF1_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub fn variant(&self) -> Option<CTCIF1_A> {
        match self.bits {
            true => Some(CTCIF1_A::Clear),
            _ => None,
        }
    }
    #[doc = "Checks if the value of the field is `Clear`"]
    #[inline(always)]
    pub fn is_clear(&self) -> bool {
        *self == CTCIF1_A::Clear
    }
}
#[doc = "Clear channel 1 half transfer flag\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum CHTIF1_A {
    #[doc = "1: Clears the HTIF flag in the ISR register"]
    Clear = 1,
}
impl From<CHTIF1_A> for bool {
    #[inline(always)]
    fn from(variant: CHTIF1_A) -> Self {
        variant as u8 != 0
    }
}
#[doc = "Field `CHTIF1` reader - Clear channel 1 half transfer flag"]
pub type CHTIF1_R = crate::BitReader<CHTIF1_A>;
impl CHTIF1_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub fn variant(&self) -> Option<CHTIF1_A> {
        match self.bits {
            true => Some(CHTIF1_A::Clear),
            _ => None,
        }
    }
    #[doc = "Checks if the value of the field is `Clear`"]
    #[inline(always)]
    pub fn is_clear(&self) -> bool {
        *self == CHTIF1_A::Clear
    }
}
#[doc = "Clear channel 1 transfer error flag\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum CTEIF1_A {
    #[doc = "1: Clears the TEIF flag in the ISR register"]
    Clear = 1,
}
impl From<CTEIF1_A> for bool {
    #[inline(always)]
    fn from(variant: CTEIF1_A) -> Self {
        variant as u8 != 0
    }
}
#[doc = "Field `CTEIF1` reader - Clear channel 1 transfer error flag"]
pub type CTEIF1_R = crate::BitReader<CTEIF1_A>;
impl CTEIF1_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub fn variant(&self) -> Option<CTEIF1_A> {
        match self.bits {
            true => Some(CTEIF1_A::Clear),
            _ => None,
        }
    }
    #[doc = "Checks if the value of the field is `Clear`"]
    #[inline(always)]
    pub fn is_clear(&self) -> bool {
        *self == CTEIF1_A::Clear
    }
}
#[doc = "Clear channel 2 global interrupt flag"]
pub use CGIF1_A as CGIF2_A;
#[doc = "Clear channel 3 global interrupt flag"]
pub use CGIF1_A as CGIF3_A;
#[doc = "Clear channel 4 global interrupt flag"]
pub use CGIF1_A as CGIF4_A;
#[doc = "Clear channel 5 global interrupt flag"]
pub use CGIF1_A as CGIF5_A;
#[doc = "Clear channel 6 global interrupt flag"]
pub use CGIF1_A as CGIF6_A;
#[doc = "Clear channel 7 global interrupt flag"]
pub use CGIF1_A as CGIF7_A;
#[doc = "Field `CGIF2` reader - Clear channel 2 global interrupt flag"]
pub use CGIF1_R as CGIF2_R;
#[doc = "Field `CGIF3` reader - Clear channel 3 global interrupt flag"]
pub use CGIF1_R as CGIF3_R;
#[doc = "Field `CGIF4` reader - Clear channel 4 global interrupt flag"]
pub use CGIF1_R as CGIF4_R;
#[doc = "Field `CGIF5` reader - Clear channel 5 global interrupt flag"]
pub use CGIF1_R as CGIF5_R;
#[doc = "Field `CGIF6` reader - Clear channel 6 global interrupt flag"]
pub use CGIF1_R as CGIF6_R;
#[doc = "Field `CGIF7` reader - Clear channel 7 global interrupt flag"]
pub use CGIF1_R as CGIF7_R;
#[doc = "Clear channel 2 half transfer flag"]
pub use CHTIF1_A as CHTIF2_A;
#[doc = "Clear channel 3 half transfer flag"]
pub use CHTIF1_A as CHTIF3_A;
#[doc = "Clear channel 4 half transfer flag"]
pub use CHTIF1_A as CHTIF4_A;
#[doc = "Clear channel 5 half transfer flag"]
pub use CHTIF1_A as CHTIF5_A;
#[doc = "Clear channel 6 half transfer flag"]
pub use CHTIF1_A as CHTIF6_A;
#[doc = "Clear channel 7 half transfer flag"]
pub use CHTIF1_A as CHTIF7_A;
#[doc = "Field `CHTIF2` reader - Clear channel 2 half transfer flag"]
pub use CHTIF1_R as CHTIF2_R;
#[doc = "Field `CHTIF3` reader - Clear channel 3 half transfer flag"]
pub use CHTIF1_R as CHTIF3_R;
#[doc = "Field `CHTIF4` reader - Clear channel 4 half transfer flag"]
pub use CHTIF1_R as CHTIF4_R;
#[doc = "Field `CHTIF5` reader - Clear channel 5 half transfer flag"]
pub use CHTIF1_R as CHTIF5_R;
#[doc = "Field `CHTIF6` reader - Clear channel 6 half transfer flag"]
pub use CHTIF1_R as CHTIF6_R;
#[doc = "Field `CHTIF7` reader - Clear channel 7 half transfer flag"]
pub use CHTIF1_R as CHTIF7_R;
#[doc = "Clear channel 2 transfer complete flag"]
pub use CTCIF1_A as CTCIF2_A;
#[doc = "Clear channel 3 transfer complete flag"]
pub use CTCIF1_A as CTCIF3_A;
#[doc = "Clear channel 4 transfer complete flag"]
pub use CTCIF1_A as CTCIF4_A;
#[doc = "Clear channel 5 transfer complete flag"]
pub use CTCIF1_A as CTCIF5_A;
#[doc = "Clear channel 6 transfer complete flag"]
pub use CTCIF1_A as CTCIF6_A;
#[doc = "Clear channel 7 transfer complete flag"]
pub use CTCIF1_A as CTCIF7_A;
#[doc = "Field `CTCIF2` reader - Clear channel 2 transfer complete flag"]
pub use CTCIF1_R as CTCIF2_R;
#[doc = "Field `CTCIF3` reader - Clear channel 3 transfer complete flag"]
pub use CTCIF1_R as CTCIF3_R;
#[doc = "Field `CTCIF4` reader - Clear channel 4 transfer complete flag"]
pub use CTCIF1_R as CTCIF4_R;
#[doc = "Field `CTCIF5` reader - Clear channel 5 transfer complete flag"]
pub use CTCIF1_R as CTCIF5_R;
#[doc = "Field `CTCIF6` reader - Clear channel 6 transfer complete flag"]
pub use CTCIF1_R as CTCIF6_R;
#[doc = "Field `CTCIF7` reader - Clear channel 7 transfer complete flag"]
pub use CTCIF1_R as CTCIF7_R;
#[doc = "Clear channel 2 transfer error flag"]
pub use CTEIF1_A as CTEIF2_A;
#[doc = "Clear channel 3 transfer error flag"]
pub use CTEIF1_A as CTEIF3_A;
#[doc = "Clear channel 4 transfer error flag"]
pub use CTEIF1_A as CTEIF4_A;
#[doc = "Clear channel 5 transfer error flag"]
pub use CTEIF1_A as CTEIF5_A;
#[doc = "Clear channel 6 transfer error flag"]
pub use CTEIF1_A as CTEIF6_A;
#[doc = "Clear channel 7 transfer error flag"]
pub use CTEIF1_A as CTEIF7_A;
#[doc = "Field `CTEIF2` reader - Clear channel 2 transfer error flag"]
pub use CTEIF1_R as CTEIF2_R;
#[doc = "Field `CTEIF3` reader - Clear channel 3 transfer error flag"]
pub use CTEIF1_R as CTEIF3_R;
#[doc = "Field `CTEIF4` reader - Clear channel 4 transfer error flag"]
pub use CTEIF1_R as CTEIF4_R;
#[doc = "Field `CTEIF5` reader - Clear channel 5 transfer error flag"]
pub use CTEIF1_R as CTEIF5_R;
#[doc = "Field `CTEIF6` reader - Clear channel 6 transfer error flag"]
pub use CTEIF1_R as CTEIF6_R;
#[doc = "Field `CTEIF7` reader - Clear channel 7 transfer error flag"]
pub use CTEIF1_R as CTEIF7_R;
impl R {
    #[doc = "Bit 0 - Clear channel 1 global interrupt flag"]
    #[inline(always)]
    pub fn cgif1(&self) -> CGIF1_R {
        CGIF1_R::new((self.bits & 1) != 0)
    }
    #[doc = "Bit 1 - Clear channel 1 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif1(&self) -> CTCIF1_R {
        CTCIF1_R::new(((self.bits >> 1) & 1) != 0)
    }
    #[doc = "Bit 2 - Clear channel 1 half transfer flag"]
    #[inline(always)]
    pub fn chtif1(&self) -> CHTIF1_R {
        CHTIF1_R::new(((self.bits >> 2) & 1) != 0)
    }
    #[doc = "Bit 3 - Clear channel 1 transfer error flag"]
    #[inline(always)]
    pub fn cteif1(&self) -> CTEIF1_R {
        CTEIF1_R::new(((self.bits >> 3) & 1) != 0)
    }
    #[doc = "Bit 4 - Clear channel 2 global interrupt flag"]
    #[inline(always)]
    pub fn cgif2(&self) -> CGIF2_R {
        CGIF2_R::new(((self.bits >> 4) & 1) != 0)
    }
    #[doc = "Bit 5 - Clear channel 2 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif2(&self) -> CTCIF2_R {
        CTCIF2_R::new(((self.bits >> 5) & 1) != 0)
    }
    #[doc = "Bit 6 - Clear channel 2 half transfer flag"]
    #[inline(always)]
    pub fn chtif2(&self) -> CHTIF2_R {
        CHTIF2_R::new(((self.bits >> 6) & 1) != 0)
    }
    #[doc = "Bit 7 - Clear channel 2 transfer error flag"]
    #[inline(always)]
    pub fn cteif2(&self) -> CTEIF2_R {
        CTEIF2_R::new(((self.bits >> 7) & 1) != 0)
    }
    #[doc = "Bit 8 - Clear channel 3 global interrupt flag"]
    #[inline(always)]
    pub fn cgif3(&self) -> CGIF3_R {
        CGIF3_R::new(((self.bits >> 8) & 1) != 0)
    }
    #[doc = "Bit 9 - Clear channel 3 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif3(&self) -> CTCIF3_R {
        CTCIF3_R::new(((self.bits >> 9) & 1) != 0)
    }
    #[doc = "Bit 10 - Clear channel 3 half transfer flag"]
    #[inline(always)]
    pub fn chtif3(&self) -> CHTIF3_R {
        CHTIF3_R::new(((self.bits >> 10) & 1) != 0)
    }
    #[doc = "Bit 11 - Clear channel 3 transfer error flag"]
    #[inline(always)]
    pub fn cteif3(&self) -> CTEIF3_R {
        CTEIF3_R::new(((self.bits >> 11) & 1) != 0)
    }
    #[doc = "Bit 12 - Clear channel 4 global interrupt flag"]
    #[inline(always)]
    pub fn cgif4(&self) -> CGIF4_R {
        CGIF4_R::new(((self.bits >> 12) & 1) != 0)
    }
    #[doc = "Bit 13 - Clear channel 4 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif4(&self) -> CTCIF4_R {
        CTCIF4_R::new(((self.bits >> 13) & 1) != 0)
    }
    #[doc = "Bit 14 - Clear channel 4 half transfer flag"]
    #[inline(always)]
    pub fn chtif4(&self) -> CHTIF4_R {
        CHTIF4_R::new(((self.bits >> 14) & 1) != 0)
    }
    #[doc = "Bit 15 - Clear channel 4 transfer error flag"]
    #[inline(always)]
    pub fn cteif4(&self) -> CTEIF4_R {
        CTEIF4_R::new(((self.bits >> 15) & 1) != 0)
    }
    #[doc = "Bit 16 - Clear channel 5 global interrupt flag"]
    #[inline(always)]
    pub fn cgif5(&self) -> CGIF5_R {
        CGIF5_R::new(((self.bits >> 16) & 1) != 0)
    }
    #[doc = "Bit 17 - Clear channel 5 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif5(&self) -> CTCIF5_R {
        CTCIF5_R::new(((self.bits >> 17) & 1) != 0)
    }
    #[doc = "Bit 18 - Clear channel 5 half transfer flag"]
    #[inline(always)]
    pub fn chtif5(&self) -> CHTIF5_R {
        CHTIF5_R::new(((self.bits >> 18) & 1) != 0)
    }
    #[doc = "Bit 19 - Clear channel 5 transfer error flag"]
    #[inline(always)]
    pub fn cteif5(&self) -> CTEIF5_R {
        CTEIF5_R::new(((self.bits >> 19) & 1) != 0)
    }
    #[doc = "Bit 20 - Clear channel 6 global interrupt flag"]
    #[inline(always)]
    pub fn cgif6(&self) -> CGIF6_R {
        CGIF6_R::new(((self.bits >> 20) & 1) != 0)
    }
    #[doc = "Bit 21 - Clear channel 6 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif6(&self) -> CTCIF6_R {
        CTCIF6_R::new(((self.bits >> 21) & 1) != 0)
    }
    #[doc = "Bit 22 - Clear channel 6 half transfer flag"]
    #[inline(always)]
    pub fn chtif6(&self) -> CHTIF6_R {
        CHTIF6_R::new(((self.bits >> 22) & 1) != 0)
    }
    #[doc = "Bit 23 - Clear channel 6 transfer error flag"]
    #[inline(always)]
    pub fn cteif6(&self) -> CTEIF6_R {
        CTEIF6_R::new(((self.bits >> 23) & 1) != 0)
    }
    #[doc = "Bit 24 - Clear channel 7 global interrupt flag"]
    #[inline(always)]
    pub fn cgif7(&self) -> CGIF7_R {
        CGIF7_R::new(((self.bits >> 24) & 1) != 0)
    }
    #[doc = "Bit 25 - Clear channel 7 transfer complete flag"]
    #[inline(always)]
    pub fn ctcif7(&self) -> CTCIF7_R {
        CTCIF7_R::new(((self.bits >> 25) & 1) != 0)
    }
    #[doc = "Bit 26 - Clear channel 7 half transfer flag"]
    #[inline(always)]
    pub fn chtif7(&self) -> CHTIF7_R {
        CHTIF7_R::new(((self.bits >> 26) & 1) != 0)
    }
    #[doc = "Bit 27 - Clear channel 7 transfer error flag"]
    #[inline(always)]
    pub fn cteif7(&self) -> CTEIF7_R {
        CTEIF7_R::new(((self.bits >> 27) & 1) != 0)
    }
}
#[doc = "high interrupt status register\n\nThis register you can [`read`](crate::generic::Reg::read). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [ifcr](index.html) module"]
pub struct IFCR_SPEC;
impl crate::RegisterSpec for IFCR_SPEC {
    type Ux = u32;
}
#[doc = "`read()` method returns [ifcr::R](R) reader structure"]
impl crate::Readable for IFCR_SPEC {
    type Reader = R;
}
#[doc = "`reset()` method sets IFCR to value 0"]
impl crate::Resettable for IFCR_SPEC {
    #[inline(always)]
    fn reset_value() -> Self::Ux {
        0
    }
}