ra6e1/sysc/
sckdivcr.rs

1#[doc = "Register `SCKDIVCR` reader"]
2pub struct R(crate::R<SCKDIVCR_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<SCKDIVCR_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<SCKDIVCR_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<SCKDIVCR_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `SCKDIVCR` writer"]
17pub struct W(crate::W<SCKDIVCR_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<SCKDIVCR_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<SCKDIVCR_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<SCKDIVCR_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `PCKD` reader - Peripheral Module Clock D (PCLKD) Select"]
38pub type PCKD_R = crate::FieldReader<u8, PCKD_A>;
39#[doc = "Peripheral Module Clock D (PCLKD) Select\n\nValue on reset: 2"]
40#[derive(Clone, Copy, Debug, PartialEq, Eq)]
41#[repr(u8)]
42pub enum PCKD_A {
43    #[doc = "0: x 1/1"]
44    _000 = 0,
45    #[doc = "1: x 1/2"]
46    _001 = 1,
47    #[doc = "2: x 1/4"]
48    _010 = 2,
49    #[doc = "3: x 1/8"]
50    _011 = 3,
51    #[doc = "4: x 1/16"]
52    _100 = 4,
53    #[doc = "5: x 1/32"]
54    _101 = 5,
55    #[doc = "6: x 1/64"]
56    _110 = 6,
57}
58impl From<PCKD_A> for u8 {
59    #[inline(always)]
60    fn from(variant: PCKD_A) -> Self {
61        variant as _
62    }
63}
64impl PCKD_R {
65    #[doc = "Get enumerated values variant"]
66    #[inline(always)]
67    pub fn variant(&self) -> PCKD_A {
68        match self.bits {
69            0 => PCKD_A::_000,
70            1 => PCKD_A::_001,
71            2 => PCKD_A::_010,
72            3 => PCKD_A::_011,
73            4 => PCKD_A::_100,
74            5 => PCKD_A::_101,
75            6 => PCKD_A::_110,
76            _ => unreachable!(),
77        }
78    }
79    #[doc = "Checks if the value of the field is `_000`"]
80    #[inline(always)]
81    pub fn is_000(&self) -> bool {
82        *self == PCKD_A::_000
83    }
84    #[doc = "Checks if the value of the field is `_001`"]
85    #[inline(always)]
86    pub fn is_001(&self) -> bool {
87        *self == PCKD_A::_001
88    }
89    #[doc = "Checks if the value of the field is `_010`"]
90    #[inline(always)]
91    pub fn is_010(&self) -> bool {
92        *self == PCKD_A::_010
93    }
94    #[doc = "Checks if the value of the field is `_011`"]
95    #[inline(always)]
96    pub fn is_011(&self) -> bool {
97        *self == PCKD_A::_011
98    }
99    #[doc = "Checks if the value of the field is `_100`"]
100    #[inline(always)]
101    pub fn is_100(&self) -> bool {
102        *self == PCKD_A::_100
103    }
104    #[doc = "Checks if the value of the field is `_101`"]
105    #[inline(always)]
106    pub fn is_101(&self) -> bool {
107        *self == PCKD_A::_101
108    }
109    #[doc = "Checks if the value of the field is `_110`"]
110    #[inline(always)]
111    pub fn is_110(&self) -> bool {
112        *self == PCKD_A::_110
113    }
114}
115#[doc = "Field `PCKD` writer - Peripheral Module Clock D (PCLKD) Select"]
116pub type PCKD_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, PCKD_A, 3, O>;
117impl<'a, const O: u8> PCKD_W<'a, O> {
118    #[doc = "x 1/1"]
119    #[inline(always)]
120    pub fn _000(self) -> &'a mut W {
121        self.variant(PCKD_A::_000)
122    }
123    #[doc = "x 1/2"]
124    #[inline(always)]
125    pub fn _001(self) -> &'a mut W {
126        self.variant(PCKD_A::_001)
127    }
128    #[doc = "x 1/4"]
129    #[inline(always)]
130    pub fn _010(self) -> &'a mut W {
131        self.variant(PCKD_A::_010)
132    }
133    #[doc = "x 1/8"]
134    #[inline(always)]
135    pub fn _011(self) -> &'a mut W {
136        self.variant(PCKD_A::_011)
137    }
138    #[doc = "x 1/16"]
139    #[inline(always)]
140    pub fn _100(self) -> &'a mut W {
141        self.variant(PCKD_A::_100)
142    }
143    #[doc = "x 1/32"]
144    #[inline(always)]
145    pub fn _101(self) -> &'a mut W {
146        self.variant(PCKD_A::_101)
147    }
148    #[doc = "x 1/64"]
149    #[inline(always)]
150    pub fn _110(self) -> &'a mut W {
151        self.variant(PCKD_A::_110)
152    }
153}
154#[doc = "Field `PCKC` reader - Peripheral Module Clock C (PCLKC) Select"]
155pub type PCKC_R = crate::FieldReader<u8, PCKC_A>;
156#[doc = "Peripheral Module Clock C (PCLKC) Select\n\nValue on reset: 2"]
157#[derive(Clone, Copy, Debug, PartialEq, Eq)]
158#[repr(u8)]
159pub enum PCKC_A {
160    #[doc = "0: x 1/1"]
161    _000 = 0,
162    #[doc = "1: x 1/2"]
163    _001 = 1,
164    #[doc = "2: x 1/4"]
165    _010 = 2,
166    #[doc = "3: x 1/8"]
167    _011 = 3,
168    #[doc = "4: x 1/16"]
169    _100 = 4,
170    #[doc = "5: x 1/32"]
171    _101 = 5,
172    #[doc = "6: x 1/64"]
173    _110 = 6,
174}
175impl From<PCKC_A> for u8 {
176    #[inline(always)]
177    fn from(variant: PCKC_A) -> Self {
178        variant as _
179    }
180}
181impl PCKC_R {
182    #[doc = "Get enumerated values variant"]
183    #[inline(always)]
184    pub fn variant(&self) -> PCKC_A {
185        match self.bits {
186            0 => PCKC_A::_000,
187            1 => PCKC_A::_001,
188            2 => PCKC_A::_010,
189            3 => PCKC_A::_011,
190            4 => PCKC_A::_100,
191            5 => PCKC_A::_101,
192            6 => PCKC_A::_110,
193            _ => unreachable!(),
194        }
195    }
196    #[doc = "Checks if the value of the field is `_000`"]
197    #[inline(always)]
198    pub fn is_000(&self) -> bool {
199        *self == PCKC_A::_000
200    }
201    #[doc = "Checks if the value of the field is `_001`"]
202    #[inline(always)]
203    pub fn is_001(&self) -> bool {
204        *self == PCKC_A::_001
205    }
206    #[doc = "Checks if the value of the field is `_010`"]
207    #[inline(always)]
208    pub fn is_010(&self) -> bool {
209        *self == PCKC_A::_010
210    }
211    #[doc = "Checks if the value of the field is `_011`"]
212    #[inline(always)]
213    pub fn is_011(&self) -> bool {
214        *self == PCKC_A::_011
215    }
216    #[doc = "Checks if the value of the field is `_100`"]
217    #[inline(always)]
218    pub fn is_100(&self) -> bool {
219        *self == PCKC_A::_100
220    }
221    #[doc = "Checks if the value of the field is `_101`"]
222    #[inline(always)]
223    pub fn is_101(&self) -> bool {
224        *self == PCKC_A::_101
225    }
226    #[doc = "Checks if the value of the field is `_110`"]
227    #[inline(always)]
228    pub fn is_110(&self) -> bool {
229        *self == PCKC_A::_110
230    }
231}
232#[doc = "Field `PCKC` writer - Peripheral Module Clock C (PCLKC) Select"]
233pub type PCKC_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, PCKC_A, 3, O>;
234impl<'a, const O: u8> PCKC_W<'a, O> {
235    #[doc = "x 1/1"]
236    #[inline(always)]
237    pub fn _000(self) -> &'a mut W {
238        self.variant(PCKC_A::_000)
239    }
240    #[doc = "x 1/2"]
241    #[inline(always)]
242    pub fn _001(self) -> &'a mut W {
243        self.variant(PCKC_A::_001)
244    }
245    #[doc = "x 1/4"]
246    #[inline(always)]
247    pub fn _010(self) -> &'a mut W {
248        self.variant(PCKC_A::_010)
249    }
250    #[doc = "x 1/8"]
251    #[inline(always)]
252    pub fn _011(self) -> &'a mut W {
253        self.variant(PCKC_A::_011)
254    }
255    #[doc = "x 1/16"]
256    #[inline(always)]
257    pub fn _100(self) -> &'a mut W {
258        self.variant(PCKC_A::_100)
259    }
260    #[doc = "x 1/32"]
261    #[inline(always)]
262    pub fn _101(self) -> &'a mut W {
263        self.variant(PCKC_A::_101)
264    }
265    #[doc = "x 1/64"]
266    #[inline(always)]
267    pub fn _110(self) -> &'a mut W {
268        self.variant(PCKC_A::_110)
269    }
270}
271#[doc = "Field `PCKB` reader - Peripheral Module Clock B (PCLKB) Select"]
272pub type PCKB_R = crate::FieldReader<u8, PCKB_A>;
273#[doc = "Peripheral Module Clock B (PCLKB) Select\n\nValue on reset: 2"]
274#[derive(Clone, Copy, Debug, PartialEq, Eq)]
275#[repr(u8)]
276pub enum PCKB_A {
277    #[doc = "0: x 1/1"]
278    _000 = 0,
279    #[doc = "1: x 1/2"]
280    _001 = 1,
281    #[doc = "2: x 1/4"]
282    _010 = 2,
283    #[doc = "3: x 1/8"]
284    _011 = 3,
285    #[doc = "4: x 1/16"]
286    _100 = 4,
287    #[doc = "5: x 1/32"]
288    _101 = 5,
289    #[doc = "6: x 1/64"]
290    _110 = 6,
291}
292impl From<PCKB_A> for u8 {
293    #[inline(always)]
294    fn from(variant: PCKB_A) -> Self {
295        variant as _
296    }
297}
298impl PCKB_R {
299    #[doc = "Get enumerated values variant"]
300    #[inline(always)]
301    pub fn variant(&self) -> PCKB_A {
302        match self.bits {
303            0 => PCKB_A::_000,
304            1 => PCKB_A::_001,
305            2 => PCKB_A::_010,
306            3 => PCKB_A::_011,
307            4 => PCKB_A::_100,
308            5 => PCKB_A::_101,
309            6 => PCKB_A::_110,
310            _ => unreachable!(),
311        }
312    }
313    #[doc = "Checks if the value of the field is `_000`"]
314    #[inline(always)]
315    pub fn is_000(&self) -> bool {
316        *self == PCKB_A::_000
317    }
318    #[doc = "Checks if the value of the field is `_001`"]
319    #[inline(always)]
320    pub fn is_001(&self) -> bool {
321        *self == PCKB_A::_001
322    }
323    #[doc = "Checks if the value of the field is `_010`"]
324    #[inline(always)]
325    pub fn is_010(&self) -> bool {
326        *self == PCKB_A::_010
327    }
328    #[doc = "Checks if the value of the field is `_011`"]
329    #[inline(always)]
330    pub fn is_011(&self) -> bool {
331        *self == PCKB_A::_011
332    }
333    #[doc = "Checks if the value of the field is `_100`"]
334    #[inline(always)]
335    pub fn is_100(&self) -> bool {
336        *self == PCKB_A::_100
337    }
338    #[doc = "Checks if the value of the field is `_101`"]
339    #[inline(always)]
340    pub fn is_101(&self) -> bool {
341        *self == PCKB_A::_101
342    }
343    #[doc = "Checks if the value of the field is `_110`"]
344    #[inline(always)]
345    pub fn is_110(&self) -> bool {
346        *self == PCKB_A::_110
347    }
348}
349#[doc = "Field `PCKB` writer - Peripheral Module Clock B (PCLKB) Select"]
350pub type PCKB_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, PCKB_A, 3, O>;
351impl<'a, const O: u8> PCKB_W<'a, O> {
352    #[doc = "x 1/1"]
353    #[inline(always)]
354    pub fn _000(self) -> &'a mut W {
355        self.variant(PCKB_A::_000)
356    }
357    #[doc = "x 1/2"]
358    #[inline(always)]
359    pub fn _001(self) -> &'a mut W {
360        self.variant(PCKB_A::_001)
361    }
362    #[doc = "x 1/4"]
363    #[inline(always)]
364    pub fn _010(self) -> &'a mut W {
365        self.variant(PCKB_A::_010)
366    }
367    #[doc = "x 1/8"]
368    #[inline(always)]
369    pub fn _011(self) -> &'a mut W {
370        self.variant(PCKB_A::_011)
371    }
372    #[doc = "x 1/16"]
373    #[inline(always)]
374    pub fn _100(self) -> &'a mut W {
375        self.variant(PCKB_A::_100)
376    }
377    #[doc = "x 1/32"]
378    #[inline(always)]
379    pub fn _101(self) -> &'a mut W {
380        self.variant(PCKB_A::_101)
381    }
382    #[doc = "x 1/64"]
383    #[inline(always)]
384    pub fn _110(self) -> &'a mut W {
385        self.variant(PCKB_A::_110)
386    }
387}
388#[doc = "Field `PCKA` reader - Peripheral Module Clock A (PCLKA) Select"]
389pub type PCKA_R = crate::FieldReader<u8, PCKA_A>;
390#[doc = "Peripheral Module Clock A (PCLKA) Select\n\nValue on reset: 2"]
391#[derive(Clone, Copy, Debug, PartialEq, Eq)]
392#[repr(u8)]
393pub enum PCKA_A {
394    #[doc = "0: x 1/1"]
395    _000 = 0,
396    #[doc = "1: x 1/2"]
397    _001 = 1,
398    #[doc = "2: x 1/4"]
399    _010 = 2,
400    #[doc = "3: x 1/8"]
401    _011 = 3,
402    #[doc = "4: x 1/16"]
403    _100 = 4,
404    #[doc = "5: x 1/32"]
405    _101 = 5,
406    #[doc = "6: x 1/64"]
407    _110 = 6,
408}
409impl From<PCKA_A> for u8 {
410    #[inline(always)]
411    fn from(variant: PCKA_A) -> Self {
412        variant as _
413    }
414}
415impl PCKA_R {
416    #[doc = "Get enumerated values variant"]
417    #[inline(always)]
418    pub fn variant(&self) -> PCKA_A {
419        match self.bits {
420            0 => PCKA_A::_000,
421            1 => PCKA_A::_001,
422            2 => PCKA_A::_010,
423            3 => PCKA_A::_011,
424            4 => PCKA_A::_100,
425            5 => PCKA_A::_101,
426            6 => PCKA_A::_110,
427            _ => unreachable!(),
428        }
429    }
430    #[doc = "Checks if the value of the field is `_000`"]
431    #[inline(always)]
432    pub fn is_000(&self) -> bool {
433        *self == PCKA_A::_000
434    }
435    #[doc = "Checks if the value of the field is `_001`"]
436    #[inline(always)]
437    pub fn is_001(&self) -> bool {
438        *self == PCKA_A::_001
439    }
440    #[doc = "Checks if the value of the field is `_010`"]
441    #[inline(always)]
442    pub fn is_010(&self) -> bool {
443        *self == PCKA_A::_010
444    }
445    #[doc = "Checks if the value of the field is `_011`"]
446    #[inline(always)]
447    pub fn is_011(&self) -> bool {
448        *self == PCKA_A::_011
449    }
450    #[doc = "Checks if the value of the field is `_100`"]
451    #[inline(always)]
452    pub fn is_100(&self) -> bool {
453        *self == PCKA_A::_100
454    }
455    #[doc = "Checks if the value of the field is `_101`"]
456    #[inline(always)]
457    pub fn is_101(&self) -> bool {
458        *self == PCKA_A::_101
459    }
460    #[doc = "Checks if the value of the field is `_110`"]
461    #[inline(always)]
462    pub fn is_110(&self) -> bool {
463        *self == PCKA_A::_110
464    }
465}
466#[doc = "Field `PCKA` writer - Peripheral Module Clock A (PCLKA) Select"]
467pub type PCKA_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, PCKA_A, 3, O>;
468impl<'a, const O: u8> PCKA_W<'a, O> {
469    #[doc = "x 1/1"]
470    #[inline(always)]
471    pub fn _000(self) -> &'a mut W {
472        self.variant(PCKA_A::_000)
473    }
474    #[doc = "x 1/2"]
475    #[inline(always)]
476    pub fn _001(self) -> &'a mut W {
477        self.variant(PCKA_A::_001)
478    }
479    #[doc = "x 1/4"]
480    #[inline(always)]
481    pub fn _010(self) -> &'a mut W {
482        self.variant(PCKA_A::_010)
483    }
484    #[doc = "x 1/8"]
485    #[inline(always)]
486    pub fn _011(self) -> &'a mut W {
487        self.variant(PCKA_A::_011)
488    }
489    #[doc = "x 1/16"]
490    #[inline(always)]
491    pub fn _100(self) -> &'a mut W {
492        self.variant(PCKA_A::_100)
493    }
494    #[doc = "x 1/32"]
495    #[inline(always)]
496    pub fn _101(self) -> &'a mut W {
497        self.variant(PCKA_A::_101)
498    }
499    #[doc = "x 1/64"]
500    #[inline(always)]
501    pub fn _110(self) -> &'a mut W {
502        self.variant(PCKA_A::_110)
503    }
504}
505#[doc = "Field `RSV` reader - Reserved. Set these bits to the same value as PCKB\\[2:0\\]."]
506pub type RSV_R = crate::FieldReader<u8, RSV_A>;
507#[doc = "Reserved. Set these bits to the same value as PCKB\\[2:0\\].\n\nValue on reset: 2"]
508#[derive(Clone, Copy, Debug, PartialEq, Eq)]
509#[repr(u8)]
510pub enum RSV_A {
511    #[doc = "0: x 1/1"]
512    _000 = 0,
513    #[doc = "1: x 1/2"]
514    _001 = 1,
515    #[doc = "2: x 1/4"]
516    _010 = 2,
517    #[doc = "3: x 1/8"]
518    _011 = 3,
519    #[doc = "4: x 1/16"]
520    _100 = 4,
521    #[doc = "5: x 1/32"]
522    _101 = 5,
523    #[doc = "6: x 1/64"]
524    _110 = 6,
525}
526impl From<RSV_A> for u8 {
527    #[inline(always)]
528    fn from(variant: RSV_A) -> Self {
529        variant as _
530    }
531}
532impl RSV_R {
533    #[doc = "Get enumerated values variant"]
534    #[inline(always)]
535    pub fn variant(&self) -> RSV_A {
536        match self.bits {
537            0 => RSV_A::_000,
538            1 => RSV_A::_001,
539            2 => RSV_A::_010,
540            3 => RSV_A::_011,
541            4 => RSV_A::_100,
542            5 => RSV_A::_101,
543            6 => RSV_A::_110,
544            _ => unreachable!(),
545        }
546    }
547    #[doc = "Checks if the value of the field is `_000`"]
548    #[inline(always)]
549    pub fn is_000(&self) -> bool {
550        *self == RSV_A::_000
551    }
552    #[doc = "Checks if the value of the field is `_001`"]
553    #[inline(always)]
554    pub fn is_001(&self) -> bool {
555        *self == RSV_A::_001
556    }
557    #[doc = "Checks if the value of the field is `_010`"]
558    #[inline(always)]
559    pub fn is_010(&self) -> bool {
560        *self == RSV_A::_010
561    }
562    #[doc = "Checks if the value of the field is `_011`"]
563    #[inline(always)]
564    pub fn is_011(&self) -> bool {
565        *self == RSV_A::_011
566    }
567    #[doc = "Checks if the value of the field is `_100`"]
568    #[inline(always)]
569    pub fn is_100(&self) -> bool {
570        *self == RSV_A::_100
571    }
572    #[doc = "Checks if the value of the field is `_101`"]
573    #[inline(always)]
574    pub fn is_101(&self) -> bool {
575        *self == RSV_A::_101
576    }
577    #[doc = "Checks if the value of the field is `_110`"]
578    #[inline(always)]
579    pub fn is_110(&self) -> bool {
580        *self == RSV_A::_110
581    }
582}
583#[doc = "Field `RSV` writer - Reserved. Set these bits to the same value as PCKB\\[2:0\\]."]
584pub type RSV_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, RSV_A, 3, O>;
585impl<'a, const O: u8> RSV_W<'a, O> {
586    #[doc = "x 1/1"]
587    #[inline(always)]
588    pub fn _000(self) -> &'a mut W {
589        self.variant(RSV_A::_000)
590    }
591    #[doc = "x 1/2"]
592    #[inline(always)]
593    pub fn _001(self) -> &'a mut W {
594        self.variant(RSV_A::_001)
595    }
596    #[doc = "x 1/4"]
597    #[inline(always)]
598    pub fn _010(self) -> &'a mut W {
599        self.variant(RSV_A::_010)
600    }
601    #[doc = "x 1/8"]
602    #[inline(always)]
603    pub fn _011(self) -> &'a mut W {
604        self.variant(RSV_A::_011)
605    }
606    #[doc = "x 1/16"]
607    #[inline(always)]
608    pub fn _100(self) -> &'a mut W {
609        self.variant(RSV_A::_100)
610    }
611    #[doc = "x 1/32"]
612    #[inline(always)]
613    pub fn _101(self) -> &'a mut W {
614        self.variant(RSV_A::_101)
615    }
616    #[doc = "x 1/64"]
617    #[inline(always)]
618    pub fn _110(self) -> &'a mut W {
619        self.variant(RSV_A::_110)
620    }
621}
622#[doc = "Field `ICK` reader - System Clock (ICLK) Select"]
623pub type ICK_R = crate::FieldReader<u8, ICK_A>;
624#[doc = "System Clock (ICLK) Select\n\nValue on reset: 2"]
625#[derive(Clone, Copy, Debug, PartialEq, Eq)]
626#[repr(u8)]
627pub enum ICK_A {
628    #[doc = "0: x 1/1"]
629    _000 = 0,
630    #[doc = "1: x 1/2"]
631    _001 = 1,
632    #[doc = "2: x 1/4"]
633    _010 = 2,
634    #[doc = "3: x 1/8"]
635    _011 = 3,
636    #[doc = "4: x 1/16"]
637    _100 = 4,
638    #[doc = "5: x 1/32"]
639    _101 = 5,
640    #[doc = "6: x 1/64"]
641    _110 = 6,
642}
643impl From<ICK_A> for u8 {
644    #[inline(always)]
645    fn from(variant: ICK_A) -> Self {
646        variant as _
647    }
648}
649impl ICK_R {
650    #[doc = "Get enumerated values variant"]
651    #[inline(always)]
652    pub fn variant(&self) -> ICK_A {
653        match self.bits {
654            0 => ICK_A::_000,
655            1 => ICK_A::_001,
656            2 => ICK_A::_010,
657            3 => ICK_A::_011,
658            4 => ICK_A::_100,
659            5 => ICK_A::_101,
660            6 => ICK_A::_110,
661            _ => unreachable!(),
662        }
663    }
664    #[doc = "Checks if the value of the field is `_000`"]
665    #[inline(always)]
666    pub fn is_000(&self) -> bool {
667        *self == ICK_A::_000
668    }
669    #[doc = "Checks if the value of the field is `_001`"]
670    #[inline(always)]
671    pub fn is_001(&self) -> bool {
672        *self == ICK_A::_001
673    }
674    #[doc = "Checks if the value of the field is `_010`"]
675    #[inline(always)]
676    pub fn is_010(&self) -> bool {
677        *self == ICK_A::_010
678    }
679    #[doc = "Checks if the value of the field is `_011`"]
680    #[inline(always)]
681    pub fn is_011(&self) -> bool {
682        *self == ICK_A::_011
683    }
684    #[doc = "Checks if the value of the field is `_100`"]
685    #[inline(always)]
686    pub fn is_100(&self) -> bool {
687        *self == ICK_A::_100
688    }
689    #[doc = "Checks if the value of the field is `_101`"]
690    #[inline(always)]
691    pub fn is_101(&self) -> bool {
692        *self == ICK_A::_101
693    }
694    #[doc = "Checks if the value of the field is `_110`"]
695    #[inline(always)]
696    pub fn is_110(&self) -> bool {
697        *self == ICK_A::_110
698    }
699}
700#[doc = "Field `ICK` writer - System Clock (ICLK) Select"]
701pub type ICK_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, ICK_A, 3, O>;
702impl<'a, const O: u8> ICK_W<'a, O> {
703    #[doc = "x 1/1"]
704    #[inline(always)]
705    pub fn _000(self) -> &'a mut W {
706        self.variant(ICK_A::_000)
707    }
708    #[doc = "x 1/2"]
709    #[inline(always)]
710    pub fn _001(self) -> &'a mut W {
711        self.variant(ICK_A::_001)
712    }
713    #[doc = "x 1/4"]
714    #[inline(always)]
715    pub fn _010(self) -> &'a mut W {
716        self.variant(ICK_A::_010)
717    }
718    #[doc = "x 1/8"]
719    #[inline(always)]
720    pub fn _011(self) -> &'a mut W {
721        self.variant(ICK_A::_011)
722    }
723    #[doc = "x 1/16"]
724    #[inline(always)]
725    pub fn _100(self) -> &'a mut W {
726        self.variant(ICK_A::_100)
727    }
728    #[doc = "x 1/32"]
729    #[inline(always)]
730    pub fn _101(self) -> &'a mut W {
731        self.variant(ICK_A::_101)
732    }
733    #[doc = "x 1/64"]
734    #[inline(always)]
735    pub fn _110(self) -> &'a mut W {
736        self.variant(ICK_A::_110)
737    }
738}
739#[doc = "Field `FCK` reader - FlashIF Clock (FCLK) Select"]
740pub type FCK_R = crate::FieldReader<u8, FCK_A>;
741#[doc = "FlashIF Clock (FCLK) Select\n\nValue on reset: 2"]
742#[derive(Clone, Copy, Debug, PartialEq, Eq)]
743#[repr(u8)]
744pub enum FCK_A {
745    #[doc = "0: x 1/1"]
746    _000 = 0,
747    #[doc = "1: x 1/2"]
748    _001 = 1,
749    #[doc = "2: x 1/4"]
750    _010 = 2,
751    #[doc = "3: x 1/8"]
752    _011 = 3,
753    #[doc = "4: x 1/16"]
754    _100 = 4,
755    #[doc = "5: x 1/32"]
756    _101 = 5,
757    #[doc = "6: x 1/64"]
758    _110 = 6,
759}
760impl From<FCK_A> for u8 {
761    #[inline(always)]
762    fn from(variant: FCK_A) -> Self {
763        variant as _
764    }
765}
766impl FCK_R {
767    #[doc = "Get enumerated values variant"]
768    #[inline(always)]
769    pub fn variant(&self) -> FCK_A {
770        match self.bits {
771            0 => FCK_A::_000,
772            1 => FCK_A::_001,
773            2 => FCK_A::_010,
774            3 => FCK_A::_011,
775            4 => FCK_A::_100,
776            5 => FCK_A::_101,
777            6 => FCK_A::_110,
778            _ => unreachable!(),
779        }
780    }
781    #[doc = "Checks if the value of the field is `_000`"]
782    #[inline(always)]
783    pub fn is_000(&self) -> bool {
784        *self == FCK_A::_000
785    }
786    #[doc = "Checks if the value of the field is `_001`"]
787    #[inline(always)]
788    pub fn is_001(&self) -> bool {
789        *self == FCK_A::_001
790    }
791    #[doc = "Checks if the value of the field is `_010`"]
792    #[inline(always)]
793    pub fn is_010(&self) -> bool {
794        *self == FCK_A::_010
795    }
796    #[doc = "Checks if the value of the field is `_011`"]
797    #[inline(always)]
798    pub fn is_011(&self) -> bool {
799        *self == FCK_A::_011
800    }
801    #[doc = "Checks if the value of the field is `_100`"]
802    #[inline(always)]
803    pub fn is_100(&self) -> bool {
804        *self == FCK_A::_100
805    }
806    #[doc = "Checks if the value of the field is `_101`"]
807    #[inline(always)]
808    pub fn is_101(&self) -> bool {
809        *self == FCK_A::_101
810    }
811    #[doc = "Checks if the value of the field is `_110`"]
812    #[inline(always)]
813    pub fn is_110(&self) -> bool {
814        *self == FCK_A::_110
815    }
816}
817#[doc = "Field `FCK` writer - FlashIF Clock (FCLK) Select"]
818pub type FCK_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SCKDIVCR_SPEC, u8, FCK_A, 3, O>;
819impl<'a, const O: u8> FCK_W<'a, O> {
820    #[doc = "x 1/1"]
821    #[inline(always)]
822    pub fn _000(self) -> &'a mut W {
823        self.variant(FCK_A::_000)
824    }
825    #[doc = "x 1/2"]
826    #[inline(always)]
827    pub fn _001(self) -> &'a mut W {
828        self.variant(FCK_A::_001)
829    }
830    #[doc = "x 1/4"]
831    #[inline(always)]
832    pub fn _010(self) -> &'a mut W {
833        self.variant(FCK_A::_010)
834    }
835    #[doc = "x 1/8"]
836    #[inline(always)]
837    pub fn _011(self) -> &'a mut W {
838        self.variant(FCK_A::_011)
839    }
840    #[doc = "x 1/16"]
841    #[inline(always)]
842    pub fn _100(self) -> &'a mut W {
843        self.variant(FCK_A::_100)
844    }
845    #[doc = "x 1/32"]
846    #[inline(always)]
847    pub fn _101(self) -> &'a mut W {
848        self.variant(FCK_A::_101)
849    }
850    #[doc = "x 1/64"]
851    #[inline(always)]
852    pub fn _110(self) -> &'a mut W {
853        self.variant(FCK_A::_110)
854    }
855}
856impl R {
857    #[doc = "Bits 0:2 - Peripheral Module Clock D (PCLKD) Select"]
858    #[inline(always)]
859    pub fn pckd(&self) -> PCKD_R {
860        PCKD_R::new((self.bits & 7) as u8)
861    }
862    #[doc = "Bits 4:6 - Peripheral Module Clock C (PCLKC) Select"]
863    #[inline(always)]
864    pub fn pckc(&self) -> PCKC_R {
865        PCKC_R::new(((self.bits >> 4) & 7) as u8)
866    }
867    #[doc = "Bits 8:10 - Peripheral Module Clock B (PCLKB) Select"]
868    #[inline(always)]
869    pub fn pckb(&self) -> PCKB_R {
870        PCKB_R::new(((self.bits >> 8) & 7) as u8)
871    }
872    #[doc = "Bits 12:14 - Peripheral Module Clock A (PCLKA) Select"]
873    #[inline(always)]
874    pub fn pcka(&self) -> PCKA_R {
875        PCKA_R::new(((self.bits >> 12) & 7) as u8)
876    }
877    #[doc = "Bits 16:18 - Reserved. Set these bits to the same value as PCKB\\[2:0\\]."]
878    #[inline(always)]
879    pub fn rsv(&self) -> RSV_R {
880        RSV_R::new(((self.bits >> 16) & 7) as u8)
881    }
882    #[doc = "Bits 24:26 - System Clock (ICLK) Select"]
883    #[inline(always)]
884    pub fn ick(&self) -> ICK_R {
885        ICK_R::new(((self.bits >> 24) & 7) as u8)
886    }
887    #[doc = "Bits 28:30 - FlashIF Clock (FCLK) Select"]
888    #[inline(always)]
889    pub fn fck(&self) -> FCK_R {
890        FCK_R::new(((self.bits >> 28) & 7) as u8)
891    }
892}
893impl W {
894    #[doc = "Bits 0:2 - Peripheral Module Clock D (PCLKD) Select"]
895    #[inline(always)]
896    #[must_use]
897    pub fn pckd(&mut self) -> PCKD_W<0> {
898        PCKD_W::new(self)
899    }
900    #[doc = "Bits 4:6 - Peripheral Module Clock C (PCLKC) Select"]
901    #[inline(always)]
902    #[must_use]
903    pub fn pckc(&mut self) -> PCKC_W<4> {
904        PCKC_W::new(self)
905    }
906    #[doc = "Bits 8:10 - Peripheral Module Clock B (PCLKB) Select"]
907    #[inline(always)]
908    #[must_use]
909    pub fn pckb(&mut self) -> PCKB_W<8> {
910        PCKB_W::new(self)
911    }
912    #[doc = "Bits 12:14 - Peripheral Module Clock A (PCLKA) Select"]
913    #[inline(always)]
914    #[must_use]
915    pub fn pcka(&mut self) -> PCKA_W<12> {
916        PCKA_W::new(self)
917    }
918    #[doc = "Bits 16:18 - Reserved. Set these bits to the same value as PCKB\\[2:0\\]."]
919    #[inline(always)]
920    #[must_use]
921    pub fn rsv(&mut self) -> RSV_W<16> {
922        RSV_W::new(self)
923    }
924    #[doc = "Bits 24:26 - System Clock (ICLK) Select"]
925    #[inline(always)]
926    #[must_use]
927    pub fn ick(&mut self) -> ICK_W<24> {
928        ICK_W::new(self)
929    }
930    #[doc = "Bits 28:30 - FlashIF Clock (FCLK) Select"]
931    #[inline(always)]
932    #[must_use]
933    pub fn fck(&mut self) -> FCK_W<28> {
934        FCK_W::new(self)
935    }
936    #[doc = "Writes raw bits to the register."]
937    #[inline(always)]
938    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
939        self.0.bits(bits);
940        self
941    }
942}
943#[doc = "System Clock Division 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 [sckdivcr](index.html) module"]
944pub struct SCKDIVCR_SPEC;
945impl crate::RegisterSpec for SCKDIVCR_SPEC {
946    type Ux = u32;
947}
948#[doc = "`read()` method returns [sckdivcr::R](R) reader structure"]
949impl crate::Readable for SCKDIVCR_SPEC {
950    type Reader = R;
951}
952#[doc = "`write(|w| ..)` method takes [sckdivcr::W](W) writer structure"]
953impl crate::Writable for SCKDIVCR_SPEC {
954    type Writer = W;
955    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
956    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
957}
958#[doc = "`reset()` method sets SCKDIVCR to value 0x2202_2222"]
959impl crate::Resettable for SCKDIVCR_SPEC {
960    const RESET_VALUE: Self::Ux = 0x2202_2222;
961}