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
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
#[doc = "Register `CTLL` reader"]
pub type R = crate::R<CTLL_SPEC>;
#[doc = "Register `CTLL` writer"]
pub type W = crate::W<CTLL_SPEC>;
#[doc = "Field `INT_EN` reader - Interrupt Enable Bit"]
pub type INT_EN_R = crate::BitReader;
#[doc = "Field `INT_EN` writer - Interrupt Enable Bit"]
pub type INT_EN_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `DST_TR_WIDTH` reader - Destination Transfer Width"]
pub type DST_TR_WIDTH_R = crate::FieldReader;
#[doc = "Field `DST_TR_WIDTH` writer - Destination Transfer Width"]
pub type DST_TR_WIDTH_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
#[doc = "Field `SRC_TR_WIDTH` reader - Source Transfer Width"]
pub type SRC_TR_WIDTH_R = crate::FieldReader;
#[doc = "Field `SRC_TR_WIDTH` writer - Source Transfer Width"]
pub type SRC_TR_WIDTH_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
#[doc = "Destination Address Increment\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
#[repr(u8)]
pub enum DINC_A {
    #[doc = "0: Increment"]
    VALUE1 = 0,
    #[doc = "1: Decrement"]
    VALUE2 = 1,
    #[doc = "2: No change"]
    VALUE3 = 2,
}
impl From<DINC_A> for u8 {
    #[inline(always)]
    fn from(variant: DINC_A) -> Self {
        variant as _
    }
}
impl crate::FieldSpec for DINC_A {
    type Ux = u8;
}
impl crate::IsEnum for DINC_A {}
#[doc = "Field `DINC` reader - Destination Address Increment"]
pub type DINC_R = crate::FieldReader<DINC_A>;
impl DINC_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub const fn variant(&self) -> Option<DINC_A> {
        match self.bits {
            0 => Some(DINC_A::VALUE1),
            1 => Some(DINC_A::VALUE2),
            2 => Some(DINC_A::VALUE3),
            _ => None,
        }
    }
    #[doc = "Increment"]
    #[inline(always)]
    pub fn is_value1(&self) -> bool {
        *self == DINC_A::VALUE1
    }
    #[doc = "Decrement"]
    #[inline(always)]
    pub fn is_value2(&self) -> bool {
        *self == DINC_A::VALUE2
    }
    #[doc = "No change"]
    #[inline(always)]
    pub fn is_value3(&self) -> bool {
        *self == DINC_A::VALUE3
    }
}
#[doc = "Field `DINC` writer - Destination Address Increment"]
pub type DINC_W<'a, REG> = crate::FieldWriter<'a, REG, 2, DINC_A>;
impl<'a, REG> DINC_W<'a, REG>
where
    REG: crate::Writable + crate::RegisterSpec,
    REG::Ux: From<u8>,
{
    #[doc = "Increment"]
    #[inline(always)]
    pub fn value1(self) -> &'a mut crate::W<REG> {
        self.variant(DINC_A::VALUE1)
    }
    #[doc = "Decrement"]
    #[inline(always)]
    pub fn value2(self) -> &'a mut crate::W<REG> {
        self.variant(DINC_A::VALUE2)
    }
    #[doc = "No change"]
    #[inline(always)]
    pub fn value3(self) -> &'a mut crate::W<REG> {
        self.variant(DINC_A::VALUE3)
    }
}
#[doc = "Source Address Increment\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
#[repr(u8)]
pub enum SINC_A {
    #[doc = "0: Increment"]
    VALUE1 = 0,
    #[doc = "1: Decrement"]
    VALUE2 = 1,
    #[doc = "2: No change"]
    VALUE3 = 2,
}
impl From<SINC_A> for u8 {
    #[inline(always)]
    fn from(variant: SINC_A) -> Self {
        variant as _
    }
}
impl crate::FieldSpec for SINC_A {
    type Ux = u8;
}
impl crate::IsEnum for SINC_A {}
#[doc = "Field `SINC` reader - Source Address Increment"]
pub type SINC_R = crate::FieldReader<SINC_A>;
impl SINC_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub const fn variant(&self) -> Option<SINC_A> {
        match self.bits {
            0 => Some(SINC_A::VALUE1),
            1 => Some(SINC_A::VALUE2),
            2 => Some(SINC_A::VALUE3),
            _ => None,
        }
    }
    #[doc = "Increment"]
    #[inline(always)]
    pub fn is_value1(&self) -> bool {
        *self == SINC_A::VALUE1
    }
    #[doc = "Decrement"]
    #[inline(always)]
    pub fn is_value2(&self) -> bool {
        *self == SINC_A::VALUE2
    }
    #[doc = "No change"]
    #[inline(always)]
    pub fn is_value3(&self) -> bool {
        *self == SINC_A::VALUE3
    }
}
#[doc = "Field `SINC` writer - Source Address Increment"]
pub type SINC_W<'a, REG> = crate::FieldWriter<'a, REG, 2, SINC_A>;
impl<'a, REG> SINC_W<'a, REG>
where
    REG: crate::Writable + crate::RegisterSpec,
    REG::Ux: From<u8>,
{
    #[doc = "Increment"]
    #[inline(always)]
    pub fn value1(self) -> &'a mut crate::W<REG> {
        self.variant(SINC_A::VALUE1)
    }
    #[doc = "Decrement"]
    #[inline(always)]
    pub fn value2(self) -> &'a mut crate::W<REG> {
        self.variant(SINC_A::VALUE2)
    }
    #[doc = "No change"]
    #[inline(always)]
    pub fn value3(self) -> &'a mut crate::W<REG> {
        self.variant(SINC_A::VALUE3)
    }
}
#[doc = "Field `DEST_MSIZE` reader - Destination Burst Transaction Length"]
pub type DEST_MSIZE_R = crate::FieldReader;
#[doc = "Field `DEST_MSIZE` writer - Destination Burst Transaction Length"]
pub type DEST_MSIZE_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
#[doc = "Field `SRC_MSIZE` reader - Source Burst Transaction Length"]
pub type SRC_MSIZE_R = crate::FieldReader;
#[doc = "Field `SRC_MSIZE` writer - Source Burst Transaction Length"]
pub type SRC_MSIZE_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
#[doc = "Source gather enable\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum SRC_GATHER_EN_A {
    #[doc = "0: Gather disabled"]
    VALUE1 = 0,
    #[doc = "1: Gather enabled"]
    VALUE2 = 1,
}
impl From<SRC_GATHER_EN_A> for bool {
    #[inline(always)]
    fn from(variant: SRC_GATHER_EN_A) -> Self {
        variant as u8 != 0
    }
}
#[doc = "Field `SRC_GATHER_EN` reader - Source gather enable"]
pub type SRC_GATHER_EN_R = crate::BitReader<SRC_GATHER_EN_A>;
impl SRC_GATHER_EN_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub const fn variant(&self) -> SRC_GATHER_EN_A {
        match self.bits {
            false => SRC_GATHER_EN_A::VALUE1,
            true => SRC_GATHER_EN_A::VALUE2,
        }
    }
    #[doc = "Gather disabled"]
    #[inline(always)]
    pub fn is_value1(&self) -> bool {
        *self == SRC_GATHER_EN_A::VALUE1
    }
    #[doc = "Gather enabled"]
    #[inline(always)]
    pub fn is_value2(&self) -> bool {
        *self == SRC_GATHER_EN_A::VALUE2
    }
}
#[doc = "Field `SRC_GATHER_EN` writer - Source gather enable"]
pub type SRC_GATHER_EN_W<'a, REG> = crate::BitWriter<'a, REG, SRC_GATHER_EN_A>;
impl<'a, REG> SRC_GATHER_EN_W<'a, REG>
where
    REG: crate::Writable + crate::RegisterSpec,
{
    #[doc = "Gather disabled"]
    #[inline(always)]
    pub fn value1(self) -> &'a mut crate::W<REG> {
        self.variant(SRC_GATHER_EN_A::VALUE1)
    }
    #[doc = "Gather enabled"]
    #[inline(always)]
    pub fn value2(self) -> &'a mut crate::W<REG> {
        self.variant(SRC_GATHER_EN_A::VALUE2)
    }
}
#[doc = "Destination scatter enable\n\nValue on reset: 0"]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum DST_SCATTER_EN_A {
    #[doc = "0: Scatter disabled"]
    VALUE1 = 0,
    #[doc = "1: Scatter enabled"]
    VALUE2 = 1,
}
impl From<DST_SCATTER_EN_A> for bool {
    #[inline(always)]
    fn from(variant: DST_SCATTER_EN_A) -> Self {
        variant as u8 != 0
    }
}
#[doc = "Field `DST_SCATTER_EN` reader - Destination scatter enable"]
pub type DST_SCATTER_EN_R = crate::BitReader<DST_SCATTER_EN_A>;
impl DST_SCATTER_EN_R {
    #[doc = "Get enumerated values variant"]
    #[inline(always)]
    pub const fn variant(&self) -> DST_SCATTER_EN_A {
        match self.bits {
            false => DST_SCATTER_EN_A::VALUE1,
            true => DST_SCATTER_EN_A::VALUE2,
        }
    }
    #[doc = "Scatter disabled"]
    #[inline(always)]
    pub fn is_value1(&self) -> bool {
        *self == DST_SCATTER_EN_A::VALUE1
    }
    #[doc = "Scatter enabled"]
    #[inline(always)]
    pub fn is_value2(&self) -> bool {
        *self == DST_SCATTER_EN_A::VALUE2
    }
}
#[doc = "Field `DST_SCATTER_EN` writer - Destination scatter enable"]
pub type DST_SCATTER_EN_W<'a, REG> = crate::BitWriter<'a, REG, DST_SCATTER_EN_A>;
impl<'a, REG> DST_SCATTER_EN_W<'a, REG>
where
    REG: crate::Writable + crate::RegisterSpec,
{
    #[doc = "Scatter disabled"]
    #[inline(always)]
    pub fn value1(self) -> &'a mut crate::W<REG> {
        self.variant(DST_SCATTER_EN_A::VALUE1)
    }
    #[doc = "Scatter enabled"]
    #[inline(always)]
    pub fn value2(self) -> &'a mut crate::W<REG> {
        self.variant(DST_SCATTER_EN_A::VALUE2)
    }
}
#[doc = "Field `TT_FC` reader - Transfer Type and Flow Control"]
pub type TT_FC_R = crate::FieldReader;
#[doc = "Field `TT_FC` writer - Transfer Type and Flow Control"]
pub type TT_FC_W<'a, REG> = crate::FieldWriter<'a, REG, 3>;
#[doc = "Field `LLP_DST_EN` reader - Linked List Pointer for Destination Enable"]
pub type LLP_DST_EN_R = crate::BitReader;
#[doc = "Field `LLP_DST_EN` writer - Linked List Pointer for Destination Enable"]
pub type LLP_DST_EN_W<'a, REG> = crate::BitWriter<'a, REG>;
#[doc = "Field `LLP_SRC_EN` reader - Linked List Pointer for Source Enable"]
pub type LLP_SRC_EN_R = crate::BitReader;
#[doc = "Field `LLP_SRC_EN` writer - Linked List Pointer for Source Enable"]
pub type LLP_SRC_EN_W<'a, REG> = crate::BitWriter<'a, REG>;
impl R {
    #[doc = "Bit 0 - Interrupt Enable Bit"]
    #[inline(always)]
    pub fn int_en(&self) -> INT_EN_R {
        INT_EN_R::new((self.bits & 1) != 0)
    }
    #[doc = "Bits 1:3 - Destination Transfer Width"]
    #[inline(always)]
    pub fn dst_tr_width(&self) -> DST_TR_WIDTH_R {
        DST_TR_WIDTH_R::new(((self.bits >> 1) & 7) as u8)
    }
    #[doc = "Bits 4:6 - Source Transfer Width"]
    #[inline(always)]
    pub fn src_tr_width(&self) -> SRC_TR_WIDTH_R {
        SRC_TR_WIDTH_R::new(((self.bits >> 4) & 7) as u8)
    }
    #[doc = "Bits 7:8 - Destination Address Increment"]
    #[inline(always)]
    pub fn dinc(&self) -> DINC_R {
        DINC_R::new(((self.bits >> 7) & 3) as u8)
    }
    #[doc = "Bits 9:10 - Source Address Increment"]
    #[inline(always)]
    pub fn sinc(&self) -> SINC_R {
        SINC_R::new(((self.bits >> 9) & 3) as u8)
    }
    #[doc = "Bits 11:13 - Destination Burst Transaction Length"]
    #[inline(always)]
    pub fn dest_msize(&self) -> DEST_MSIZE_R {
        DEST_MSIZE_R::new(((self.bits >> 11) & 7) as u8)
    }
    #[doc = "Bits 14:16 - Source Burst Transaction Length"]
    #[inline(always)]
    pub fn src_msize(&self) -> SRC_MSIZE_R {
        SRC_MSIZE_R::new(((self.bits >> 14) & 7) as u8)
    }
    #[doc = "Bit 17 - Source gather enable"]
    #[inline(always)]
    pub fn src_gather_en(&self) -> SRC_GATHER_EN_R {
        SRC_GATHER_EN_R::new(((self.bits >> 17) & 1) != 0)
    }
    #[doc = "Bit 18 - Destination scatter enable"]
    #[inline(always)]
    pub fn dst_scatter_en(&self) -> DST_SCATTER_EN_R {
        DST_SCATTER_EN_R::new(((self.bits >> 18) & 1) != 0)
    }
    #[doc = "Bits 20:22 - Transfer Type and Flow Control"]
    #[inline(always)]
    pub fn tt_fc(&self) -> TT_FC_R {
        TT_FC_R::new(((self.bits >> 20) & 7) as u8)
    }
    #[doc = "Bit 27 - Linked List Pointer for Destination Enable"]
    #[inline(always)]
    pub fn llp_dst_en(&self) -> LLP_DST_EN_R {
        LLP_DST_EN_R::new(((self.bits >> 27) & 1) != 0)
    }
    #[doc = "Bit 28 - Linked List Pointer for Source Enable"]
    #[inline(always)]
    pub fn llp_src_en(&self) -> LLP_SRC_EN_R {
        LLP_SRC_EN_R::new(((self.bits >> 28) & 1) != 0)
    }
}
impl W {
    #[doc = "Bit 0 - Interrupt Enable Bit"]
    #[inline(always)]
    #[must_use]
    pub fn int_en(&mut self) -> INT_EN_W<CTLL_SPEC> {
        INT_EN_W::new(self, 0)
    }
    #[doc = "Bits 1:3 - Destination Transfer Width"]
    #[inline(always)]
    #[must_use]
    pub fn dst_tr_width(&mut self) -> DST_TR_WIDTH_W<CTLL_SPEC> {
        DST_TR_WIDTH_W::new(self, 1)
    }
    #[doc = "Bits 4:6 - Source Transfer Width"]
    #[inline(always)]
    #[must_use]
    pub fn src_tr_width(&mut self) -> SRC_TR_WIDTH_W<CTLL_SPEC> {
        SRC_TR_WIDTH_W::new(self, 4)
    }
    #[doc = "Bits 7:8 - Destination Address Increment"]
    #[inline(always)]
    #[must_use]
    pub fn dinc(&mut self) -> DINC_W<CTLL_SPEC> {
        DINC_W::new(self, 7)
    }
    #[doc = "Bits 9:10 - Source Address Increment"]
    #[inline(always)]
    #[must_use]
    pub fn sinc(&mut self) -> SINC_W<CTLL_SPEC> {
        SINC_W::new(self, 9)
    }
    #[doc = "Bits 11:13 - Destination Burst Transaction Length"]
    #[inline(always)]
    #[must_use]
    pub fn dest_msize(&mut self) -> DEST_MSIZE_W<CTLL_SPEC> {
        DEST_MSIZE_W::new(self, 11)
    }
    #[doc = "Bits 14:16 - Source Burst Transaction Length"]
    #[inline(always)]
    #[must_use]
    pub fn src_msize(&mut self) -> SRC_MSIZE_W<CTLL_SPEC> {
        SRC_MSIZE_W::new(self, 14)
    }
    #[doc = "Bit 17 - Source gather enable"]
    #[inline(always)]
    #[must_use]
    pub fn src_gather_en(&mut self) -> SRC_GATHER_EN_W<CTLL_SPEC> {
        SRC_GATHER_EN_W::new(self, 17)
    }
    #[doc = "Bit 18 - Destination scatter enable"]
    #[inline(always)]
    #[must_use]
    pub fn dst_scatter_en(&mut self) -> DST_SCATTER_EN_W<CTLL_SPEC> {
        DST_SCATTER_EN_W::new(self, 18)
    }
    #[doc = "Bits 20:22 - Transfer Type and Flow Control"]
    #[inline(always)]
    #[must_use]
    pub fn tt_fc(&mut self) -> TT_FC_W<CTLL_SPEC> {
        TT_FC_W::new(self, 20)
    }
    #[doc = "Bit 27 - Linked List Pointer for Destination Enable"]
    #[inline(always)]
    #[must_use]
    pub fn llp_dst_en(&mut self) -> LLP_DST_EN_W<CTLL_SPEC> {
        LLP_DST_EN_W::new(self, 27)
    }
    #[doc = "Bit 28 - Linked List Pointer for Source Enable"]
    #[inline(always)]
    #[must_use]
    pub fn llp_src_en(&mut self) -> LLP_SRC_EN_W<CTLL_SPEC> {
        LLP_SRC_EN_W::new(self, 28)
    }
}
#[doc = "Control Register Low\n\nYou can [`read`](crate::generic::Reg::read) this register and get [`ctll::R`](R).  You can [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`write_with_zero`](crate::generic::Reg::write_with_zero) this register using [`ctll::W`](W). You can also [`modify`](crate::generic::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
pub struct CTLL_SPEC;
impl crate::RegisterSpec for CTLL_SPEC {
    type Ux = u32;
}
#[doc = "`read()` method returns [`ctll::R`](R) reader structure"]
impl crate::Readable for CTLL_SPEC {}
#[doc = "`write(|w| ..)` method takes [`ctll::W`](W) writer structure"]
impl crate::Writable for CTLL_SPEC {
    type Safety = crate::Unsafe;
    const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
    const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
}
#[doc = "`reset()` method sets CTLL to value 0x0030_4801"]
impl crate::Resettable for CTLL_SPEC {
    const RESET_VALUE: u32 = 0x0030_4801;
}