efm32jg12b_pac/efm32jg12b500/timer0/
dtfc.rs

1#[doc = "Register `DTFC` reader"]
2pub struct R(crate::R<DTFC_SPEC>);
3impl core::ops::Deref for R {
4    type Target = crate::R<DTFC_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl From<crate::R<DTFC_SPEC>> for R {
11    #[inline(always)]
12    fn from(reader: crate::R<DTFC_SPEC>) -> Self {
13        R(reader)
14    }
15}
16#[doc = "Register `DTFC` writer"]
17pub struct W(crate::W<DTFC_SPEC>);
18impl core::ops::Deref for W {
19    type Target = crate::W<DTFC_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<DTFC_SPEC>> for W {
32    #[inline(always)]
33    fn from(writer: crate::W<DTFC_SPEC>) -> Self {
34        W(writer)
35    }
36}
37#[doc = "Field `DTPRS0FSEL` reader - DTI PRS Fault Source 0 Select"]
38pub type DTPRS0FSEL_R = crate::FieldReader<u8, DTPRS0FSEL_A>;
39#[doc = "DTI PRS Fault Source 0 Select\n\nValue on reset: 0"]
40#[derive(Clone, Copy, Debug, PartialEq, Eq)]
41#[repr(u8)]
42pub enum DTPRS0FSEL_A {
43    #[doc = "0: PRS Channel 0 selected as fault source 0"]
44    PRSCH0 = 0,
45    #[doc = "1: PRS Channel 1 selected as fault source 1"]
46    PRSCH1 = 1,
47    #[doc = "2: PRS Channel 2 selected as fault source 2"]
48    PRSCH2 = 2,
49    #[doc = "3: PRS Channel 3 selected as fault source 3"]
50    PRSCH3 = 3,
51    #[doc = "4: PRS Channel 4 selected as fault source 4"]
52    PRSCH4 = 4,
53    #[doc = "5: PRS Channel 5 selected as fault source 5"]
54    PRSCH5 = 5,
55    #[doc = "6: PRS Channel 6 selected as fault source 6"]
56    PRSCH6 = 6,
57    #[doc = "7: PRS Channel 7 selected as fault source 7"]
58    PRSCH7 = 7,
59    #[doc = "8: PRS Channel 8 selected as fault source 8"]
60    PRSCH8 = 8,
61    #[doc = "9: PRS Channel 9 selected as fault source 9"]
62    PRSCH9 = 9,
63    #[doc = "10: PRS Channel 10 selected as fault source 10"]
64    PRSCH10 = 10,
65    #[doc = "11: PRS Channel 11 selected as fault source 11"]
66    PRSCH11 = 11,
67}
68impl From<DTPRS0FSEL_A> for u8 {
69    #[inline(always)]
70    fn from(variant: DTPRS0FSEL_A) -> Self {
71        variant as _
72    }
73}
74impl DTPRS0FSEL_R {
75    #[doc = "Get enumerated values variant"]
76    #[inline(always)]
77    pub fn variant(&self) -> Option<DTPRS0FSEL_A> {
78        match self.bits {
79            0 => Some(DTPRS0FSEL_A::PRSCH0),
80            1 => Some(DTPRS0FSEL_A::PRSCH1),
81            2 => Some(DTPRS0FSEL_A::PRSCH2),
82            3 => Some(DTPRS0FSEL_A::PRSCH3),
83            4 => Some(DTPRS0FSEL_A::PRSCH4),
84            5 => Some(DTPRS0FSEL_A::PRSCH5),
85            6 => Some(DTPRS0FSEL_A::PRSCH6),
86            7 => Some(DTPRS0FSEL_A::PRSCH7),
87            8 => Some(DTPRS0FSEL_A::PRSCH8),
88            9 => Some(DTPRS0FSEL_A::PRSCH9),
89            10 => Some(DTPRS0FSEL_A::PRSCH10),
90            11 => Some(DTPRS0FSEL_A::PRSCH11),
91            _ => None,
92        }
93    }
94    #[doc = "Checks if the value of the field is `PRSCH0`"]
95    #[inline(always)]
96    pub fn is_prsch0(&self) -> bool {
97        *self == DTPRS0FSEL_A::PRSCH0
98    }
99    #[doc = "Checks if the value of the field is `PRSCH1`"]
100    #[inline(always)]
101    pub fn is_prsch1(&self) -> bool {
102        *self == DTPRS0FSEL_A::PRSCH1
103    }
104    #[doc = "Checks if the value of the field is `PRSCH2`"]
105    #[inline(always)]
106    pub fn is_prsch2(&self) -> bool {
107        *self == DTPRS0FSEL_A::PRSCH2
108    }
109    #[doc = "Checks if the value of the field is `PRSCH3`"]
110    #[inline(always)]
111    pub fn is_prsch3(&self) -> bool {
112        *self == DTPRS0FSEL_A::PRSCH3
113    }
114    #[doc = "Checks if the value of the field is `PRSCH4`"]
115    #[inline(always)]
116    pub fn is_prsch4(&self) -> bool {
117        *self == DTPRS0FSEL_A::PRSCH4
118    }
119    #[doc = "Checks if the value of the field is `PRSCH5`"]
120    #[inline(always)]
121    pub fn is_prsch5(&self) -> bool {
122        *self == DTPRS0FSEL_A::PRSCH5
123    }
124    #[doc = "Checks if the value of the field is `PRSCH6`"]
125    #[inline(always)]
126    pub fn is_prsch6(&self) -> bool {
127        *self == DTPRS0FSEL_A::PRSCH6
128    }
129    #[doc = "Checks if the value of the field is `PRSCH7`"]
130    #[inline(always)]
131    pub fn is_prsch7(&self) -> bool {
132        *self == DTPRS0FSEL_A::PRSCH7
133    }
134    #[doc = "Checks if the value of the field is `PRSCH8`"]
135    #[inline(always)]
136    pub fn is_prsch8(&self) -> bool {
137        *self == DTPRS0FSEL_A::PRSCH8
138    }
139    #[doc = "Checks if the value of the field is `PRSCH9`"]
140    #[inline(always)]
141    pub fn is_prsch9(&self) -> bool {
142        *self == DTPRS0FSEL_A::PRSCH9
143    }
144    #[doc = "Checks if the value of the field is `PRSCH10`"]
145    #[inline(always)]
146    pub fn is_prsch10(&self) -> bool {
147        *self == DTPRS0FSEL_A::PRSCH10
148    }
149    #[doc = "Checks if the value of the field is `PRSCH11`"]
150    #[inline(always)]
151    pub fn is_prsch11(&self) -> bool {
152        *self == DTPRS0FSEL_A::PRSCH11
153    }
154}
155#[doc = "Field `DTPRS0FSEL` writer - DTI PRS Fault Source 0 Select"]
156pub type DTPRS0FSEL_W<'a, const O: u8> =
157    crate::FieldWriter<'a, u32, DTFC_SPEC, u8, DTPRS0FSEL_A, 4, O>;
158impl<'a, const O: u8> DTPRS0FSEL_W<'a, O> {
159    #[doc = "PRS Channel 0 selected as fault source 0"]
160    #[inline(always)]
161    pub fn prsch0(self) -> &'a mut W {
162        self.variant(DTPRS0FSEL_A::PRSCH0)
163    }
164    #[doc = "PRS Channel 1 selected as fault source 1"]
165    #[inline(always)]
166    pub fn prsch1(self) -> &'a mut W {
167        self.variant(DTPRS0FSEL_A::PRSCH1)
168    }
169    #[doc = "PRS Channel 2 selected as fault source 2"]
170    #[inline(always)]
171    pub fn prsch2(self) -> &'a mut W {
172        self.variant(DTPRS0FSEL_A::PRSCH2)
173    }
174    #[doc = "PRS Channel 3 selected as fault source 3"]
175    #[inline(always)]
176    pub fn prsch3(self) -> &'a mut W {
177        self.variant(DTPRS0FSEL_A::PRSCH3)
178    }
179    #[doc = "PRS Channel 4 selected as fault source 4"]
180    #[inline(always)]
181    pub fn prsch4(self) -> &'a mut W {
182        self.variant(DTPRS0FSEL_A::PRSCH4)
183    }
184    #[doc = "PRS Channel 5 selected as fault source 5"]
185    #[inline(always)]
186    pub fn prsch5(self) -> &'a mut W {
187        self.variant(DTPRS0FSEL_A::PRSCH5)
188    }
189    #[doc = "PRS Channel 6 selected as fault source 6"]
190    #[inline(always)]
191    pub fn prsch6(self) -> &'a mut W {
192        self.variant(DTPRS0FSEL_A::PRSCH6)
193    }
194    #[doc = "PRS Channel 7 selected as fault source 7"]
195    #[inline(always)]
196    pub fn prsch7(self) -> &'a mut W {
197        self.variant(DTPRS0FSEL_A::PRSCH7)
198    }
199    #[doc = "PRS Channel 8 selected as fault source 8"]
200    #[inline(always)]
201    pub fn prsch8(self) -> &'a mut W {
202        self.variant(DTPRS0FSEL_A::PRSCH8)
203    }
204    #[doc = "PRS Channel 9 selected as fault source 9"]
205    #[inline(always)]
206    pub fn prsch9(self) -> &'a mut W {
207        self.variant(DTPRS0FSEL_A::PRSCH9)
208    }
209    #[doc = "PRS Channel 10 selected as fault source 10"]
210    #[inline(always)]
211    pub fn prsch10(self) -> &'a mut W {
212        self.variant(DTPRS0FSEL_A::PRSCH10)
213    }
214    #[doc = "PRS Channel 11 selected as fault source 11"]
215    #[inline(always)]
216    pub fn prsch11(self) -> &'a mut W {
217        self.variant(DTPRS0FSEL_A::PRSCH11)
218    }
219}
220#[doc = "Field `DTPRS1FSEL` reader - DTI PRS Fault Source 1 Select"]
221pub type DTPRS1FSEL_R = crate::FieldReader<u8, DTPRS1FSEL_A>;
222#[doc = "DTI PRS Fault Source 1 Select\n\nValue on reset: 0"]
223#[derive(Clone, Copy, Debug, PartialEq, Eq)]
224#[repr(u8)]
225pub enum DTPRS1FSEL_A {
226    #[doc = "0: PRS Channel 0 selected as fault source 1"]
227    PRSCH0 = 0,
228    #[doc = "1: PRS Channel 1 selected as fault source 1"]
229    PRSCH1 = 1,
230    #[doc = "2: PRS Channel 2 selected as fault source 1"]
231    PRSCH2 = 2,
232    #[doc = "3: PRS Channel 3 selected as fault source 1"]
233    PRSCH3 = 3,
234    #[doc = "4: PRS Channel 4 selected as fault source 1"]
235    PRSCH4 = 4,
236    #[doc = "5: PRS Channel 5 selected as fault source 1"]
237    PRSCH5 = 5,
238    #[doc = "6: PRS Channel 6 selected as fault source 1"]
239    PRSCH6 = 6,
240    #[doc = "7: PRS Channel 7 selected as fault source 1"]
241    PRSCH7 = 7,
242    #[doc = "8: PRS Channel 8 selected as fault source 1"]
243    PRSCH8 = 8,
244    #[doc = "9: PRS Channel 9 selected as fault source 1"]
245    PRSCH9 = 9,
246    #[doc = "10: PRS Channel 10 selected as fault source 1"]
247    PRSCH10 = 10,
248    #[doc = "11: PRS Channel 11 selected as fault source 1"]
249    PRSCH11 = 11,
250}
251impl From<DTPRS1FSEL_A> for u8 {
252    #[inline(always)]
253    fn from(variant: DTPRS1FSEL_A) -> Self {
254        variant as _
255    }
256}
257impl DTPRS1FSEL_R {
258    #[doc = "Get enumerated values variant"]
259    #[inline(always)]
260    pub fn variant(&self) -> Option<DTPRS1FSEL_A> {
261        match self.bits {
262            0 => Some(DTPRS1FSEL_A::PRSCH0),
263            1 => Some(DTPRS1FSEL_A::PRSCH1),
264            2 => Some(DTPRS1FSEL_A::PRSCH2),
265            3 => Some(DTPRS1FSEL_A::PRSCH3),
266            4 => Some(DTPRS1FSEL_A::PRSCH4),
267            5 => Some(DTPRS1FSEL_A::PRSCH5),
268            6 => Some(DTPRS1FSEL_A::PRSCH6),
269            7 => Some(DTPRS1FSEL_A::PRSCH7),
270            8 => Some(DTPRS1FSEL_A::PRSCH8),
271            9 => Some(DTPRS1FSEL_A::PRSCH9),
272            10 => Some(DTPRS1FSEL_A::PRSCH10),
273            11 => Some(DTPRS1FSEL_A::PRSCH11),
274            _ => None,
275        }
276    }
277    #[doc = "Checks if the value of the field is `PRSCH0`"]
278    #[inline(always)]
279    pub fn is_prsch0(&self) -> bool {
280        *self == DTPRS1FSEL_A::PRSCH0
281    }
282    #[doc = "Checks if the value of the field is `PRSCH1`"]
283    #[inline(always)]
284    pub fn is_prsch1(&self) -> bool {
285        *self == DTPRS1FSEL_A::PRSCH1
286    }
287    #[doc = "Checks if the value of the field is `PRSCH2`"]
288    #[inline(always)]
289    pub fn is_prsch2(&self) -> bool {
290        *self == DTPRS1FSEL_A::PRSCH2
291    }
292    #[doc = "Checks if the value of the field is `PRSCH3`"]
293    #[inline(always)]
294    pub fn is_prsch3(&self) -> bool {
295        *self == DTPRS1FSEL_A::PRSCH3
296    }
297    #[doc = "Checks if the value of the field is `PRSCH4`"]
298    #[inline(always)]
299    pub fn is_prsch4(&self) -> bool {
300        *self == DTPRS1FSEL_A::PRSCH4
301    }
302    #[doc = "Checks if the value of the field is `PRSCH5`"]
303    #[inline(always)]
304    pub fn is_prsch5(&self) -> bool {
305        *self == DTPRS1FSEL_A::PRSCH5
306    }
307    #[doc = "Checks if the value of the field is `PRSCH6`"]
308    #[inline(always)]
309    pub fn is_prsch6(&self) -> bool {
310        *self == DTPRS1FSEL_A::PRSCH6
311    }
312    #[doc = "Checks if the value of the field is `PRSCH7`"]
313    #[inline(always)]
314    pub fn is_prsch7(&self) -> bool {
315        *self == DTPRS1FSEL_A::PRSCH7
316    }
317    #[doc = "Checks if the value of the field is `PRSCH8`"]
318    #[inline(always)]
319    pub fn is_prsch8(&self) -> bool {
320        *self == DTPRS1FSEL_A::PRSCH8
321    }
322    #[doc = "Checks if the value of the field is `PRSCH9`"]
323    #[inline(always)]
324    pub fn is_prsch9(&self) -> bool {
325        *self == DTPRS1FSEL_A::PRSCH9
326    }
327    #[doc = "Checks if the value of the field is `PRSCH10`"]
328    #[inline(always)]
329    pub fn is_prsch10(&self) -> bool {
330        *self == DTPRS1FSEL_A::PRSCH10
331    }
332    #[doc = "Checks if the value of the field is `PRSCH11`"]
333    #[inline(always)]
334    pub fn is_prsch11(&self) -> bool {
335        *self == DTPRS1FSEL_A::PRSCH11
336    }
337}
338#[doc = "Field `DTPRS1FSEL` writer - DTI PRS Fault Source 1 Select"]
339pub type DTPRS1FSEL_W<'a, const O: u8> =
340    crate::FieldWriter<'a, u32, DTFC_SPEC, u8, DTPRS1FSEL_A, 4, O>;
341impl<'a, const O: u8> DTPRS1FSEL_W<'a, O> {
342    #[doc = "PRS Channel 0 selected as fault source 1"]
343    #[inline(always)]
344    pub fn prsch0(self) -> &'a mut W {
345        self.variant(DTPRS1FSEL_A::PRSCH0)
346    }
347    #[doc = "PRS Channel 1 selected as fault source 1"]
348    #[inline(always)]
349    pub fn prsch1(self) -> &'a mut W {
350        self.variant(DTPRS1FSEL_A::PRSCH1)
351    }
352    #[doc = "PRS Channel 2 selected as fault source 1"]
353    #[inline(always)]
354    pub fn prsch2(self) -> &'a mut W {
355        self.variant(DTPRS1FSEL_A::PRSCH2)
356    }
357    #[doc = "PRS Channel 3 selected as fault source 1"]
358    #[inline(always)]
359    pub fn prsch3(self) -> &'a mut W {
360        self.variant(DTPRS1FSEL_A::PRSCH3)
361    }
362    #[doc = "PRS Channel 4 selected as fault source 1"]
363    #[inline(always)]
364    pub fn prsch4(self) -> &'a mut W {
365        self.variant(DTPRS1FSEL_A::PRSCH4)
366    }
367    #[doc = "PRS Channel 5 selected as fault source 1"]
368    #[inline(always)]
369    pub fn prsch5(self) -> &'a mut W {
370        self.variant(DTPRS1FSEL_A::PRSCH5)
371    }
372    #[doc = "PRS Channel 6 selected as fault source 1"]
373    #[inline(always)]
374    pub fn prsch6(self) -> &'a mut W {
375        self.variant(DTPRS1FSEL_A::PRSCH6)
376    }
377    #[doc = "PRS Channel 7 selected as fault source 1"]
378    #[inline(always)]
379    pub fn prsch7(self) -> &'a mut W {
380        self.variant(DTPRS1FSEL_A::PRSCH7)
381    }
382    #[doc = "PRS Channel 8 selected as fault source 1"]
383    #[inline(always)]
384    pub fn prsch8(self) -> &'a mut W {
385        self.variant(DTPRS1FSEL_A::PRSCH8)
386    }
387    #[doc = "PRS Channel 9 selected as fault source 1"]
388    #[inline(always)]
389    pub fn prsch9(self) -> &'a mut W {
390        self.variant(DTPRS1FSEL_A::PRSCH9)
391    }
392    #[doc = "PRS Channel 10 selected as fault source 1"]
393    #[inline(always)]
394    pub fn prsch10(self) -> &'a mut W {
395        self.variant(DTPRS1FSEL_A::PRSCH10)
396    }
397    #[doc = "PRS Channel 11 selected as fault source 1"]
398    #[inline(always)]
399    pub fn prsch11(self) -> &'a mut W {
400        self.variant(DTPRS1FSEL_A::PRSCH11)
401    }
402}
403#[doc = "Field `DTFA` reader - DTI Fault Action"]
404pub type DTFA_R = crate::FieldReader<u8, DTFA_A>;
405#[doc = "DTI Fault Action\n\nValue on reset: 0"]
406#[derive(Clone, Copy, Debug, PartialEq, Eq)]
407#[repr(u8)]
408pub enum DTFA_A {
409    #[doc = "0: No action on fault"]
410    NONE = 0,
411    #[doc = "1: Set outputs inactive"]
412    INACTIVE = 1,
413    #[doc = "2: Clear outputs"]
414    CLEAR = 2,
415    #[doc = "3: Tristate outputs"]
416    TRISTATE = 3,
417}
418impl From<DTFA_A> for u8 {
419    #[inline(always)]
420    fn from(variant: DTFA_A) -> Self {
421        variant as _
422    }
423}
424impl DTFA_R {
425    #[doc = "Get enumerated values variant"]
426    #[inline(always)]
427    pub fn variant(&self) -> DTFA_A {
428        match self.bits {
429            0 => DTFA_A::NONE,
430            1 => DTFA_A::INACTIVE,
431            2 => DTFA_A::CLEAR,
432            3 => DTFA_A::TRISTATE,
433            _ => unreachable!(),
434        }
435    }
436    #[doc = "Checks if the value of the field is `NONE`"]
437    #[inline(always)]
438    pub fn is_none(&self) -> bool {
439        *self == DTFA_A::NONE
440    }
441    #[doc = "Checks if the value of the field is `INACTIVE`"]
442    #[inline(always)]
443    pub fn is_inactive(&self) -> bool {
444        *self == DTFA_A::INACTIVE
445    }
446    #[doc = "Checks if the value of the field is `CLEAR`"]
447    #[inline(always)]
448    pub fn is_clear(&self) -> bool {
449        *self == DTFA_A::CLEAR
450    }
451    #[doc = "Checks if the value of the field is `TRISTATE`"]
452    #[inline(always)]
453    pub fn is_tristate(&self) -> bool {
454        *self == DTFA_A::TRISTATE
455    }
456}
457#[doc = "Field `DTFA` writer - DTI Fault Action"]
458pub type DTFA_W<'a, const O: u8> = crate::FieldWriterSafe<'a, u32, DTFC_SPEC, u8, DTFA_A, 2, O>;
459impl<'a, const O: u8> DTFA_W<'a, O> {
460    #[doc = "No action on fault"]
461    #[inline(always)]
462    pub fn none(self) -> &'a mut W {
463        self.variant(DTFA_A::NONE)
464    }
465    #[doc = "Set outputs inactive"]
466    #[inline(always)]
467    pub fn inactive(self) -> &'a mut W {
468        self.variant(DTFA_A::INACTIVE)
469    }
470    #[doc = "Clear outputs"]
471    #[inline(always)]
472    pub fn clear(self) -> &'a mut W {
473        self.variant(DTFA_A::CLEAR)
474    }
475    #[doc = "Tristate outputs"]
476    #[inline(always)]
477    pub fn tristate(self) -> &'a mut W {
478        self.variant(DTFA_A::TRISTATE)
479    }
480}
481#[doc = "Field `DTPRS0FEN` reader - DTI PRS 0 Fault Enable"]
482pub type DTPRS0FEN_R = crate::BitReader<bool>;
483#[doc = "Field `DTPRS0FEN` writer - DTI PRS 0 Fault Enable"]
484pub type DTPRS0FEN_W<'a, const O: u8> = crate::BitWriter<'a, u32, DTFC_SPEC, bool, O>;
485#[doc = "Field `DTPRS1FEN` reader - DTI PRS 1 Fault Enable"]
486pub type DTPRS1FEN_R = crate::BitReader<bool>;
487#[doc = "Field `DTPRS1FEN` writer - DTI PRS 1 Fault Enable"]
488pub type DTPRS1FEN_W<'a, const O: u8> = crate::BitWriter<'a, u32, DTFC_SPEC, bool, O>;
489#[doc = "Field `DTDBGFEN` reader - DTI Debugger Fault Enable"]
490pub type DTDBGFEN_R = crate::BitReader<bool>;
491#[doc = "Field `DTDBGFEN` writer - DTI Debugger Fault Enable"]
492pub type DTDBGFEN_W<'a, const O: u8> = crate::BitWriter<'a, u32, DTFC_SPEC, bool, O>;
493#[doc = "Field `DTLOCKUPFEN` reader - DTI Lockup Fault Enable"]
494pub type DTLOCKUPFEN_R = crate::BitReader<bool>;
495#[doc = "Field `DTLOCKUPFEN` writer - DTI Lockup Fault Enable"]
496pub type DTLOCKUPFEN_W<'a, const O: u8> = crate::BitWriter<'a, u32, DTFC_SPEC, bool, O>;
497impl R {
498    #[doc = "Bits 0:3 - DTI PRS Fault Source 0 Select"]
499    #[inline(always)]
500    pub fn dtprs0fsel(&self) -> DTPRS0FSEL_R {
501        DTPRS0FSEL_R::new((self.bits & 0x0f) as u8)
502    }
503    #[doc = "Bits 8:11 - DTI PRS Fault Source 1 Select"]
504    #[inline(always)]
505    pub fn dtprs1fsel(&self) -> DTPRS1FSEL_R {
506        DTPRS1FSEL_R::new(((self.bits >> 8) & 0x0f) as u8)
507    }
508    #[doc = "Bits 16:17 - DTI Fault Action"]
509    #[inline(always)]
510    pub fn dtfa(&self) -> DTFA_R {
511        DTFA_R::new(((self.bits >> 16) & 3) as u8)
512    }
513    #[doc = "Bit 24 - DTI PRS 0 Fault Enable"]
514    #[inline(always)]
515    pub fn dtprs0fen(&self) -> DTPRS0FEN_R {
516        DTPRS0FEN_R::new(((self.bits >> 24) & 1) != 0)
517    }
518    #[doc = "Bit 25 - DTI PRS 1 Fault Enable"]
519    #[inline(always)]
520    pub fn dtprs1fen(&self) -> DTPRS1FEN_R {
521        DTPRS1FEN_R::new(((self.bits >> 25) & 1) != 0)
522    }
523    #[doc = "Bit 26 - DTI Debugger Fault Enable"]
524    #[inline(always)]
525    pub fn dtdbgfen(&self) -> DTDBGFEN_R {
526        DTDBGFEN_R::new(((self.bits >> 26) & 1) != 0)
527    }
528    #[doc = "Bit 27 - DTI Lockup Fault Enable"]
529    #[inline(always)]
530    pub fn dtlockupfen(&self) -> DTLOCKUPFEN_R {
531        DTLOCKUPFEN_R::new(((self.bits >> 27) & 1) != 0)
532    }
533}
534impl W {
535    #[doc = "Bits 0:3 - DTI PRS Fault Source 0 Select"]
536    #[inline(always)]
537    #[must_use]
538    pub fn dtprs0fsel(&mut self) -> DTPRS0FSEL_W<0> {
539        DTPRS0FSEL_W::new(self)
540    }
541    #[doc = "Bits 8:11 - DTI PRS Fault Source 1 Select"]
542    #[inline(always)]
543    #[must_use]
544    pub fn dtprs1fsel(&mut self) -> DTPRS1FSEL_W<8> {
545        DTPRS1FSEL_W::new(self)
546    }
547    #[doc = "Bits 16:17 - DTI Fault Action"]
548    #[inline(always)]
549    #[must_use]
550    pub fn dtfa(&mut self) -> DTFA_W<16> {
551        DTFA_W::new(self)
552    }
553    #[doc = "Bit 24 - DTI PRS 0 Fault Enable"]
554    #[inline(always)]
555    #[must_use]
556    pub fn dtprs0fen(&mut self) -> DTPRS0FEN_W<24> {
557        DTPRS0FEN_W::new(self)
558    }
559    #[doc = "Bit 25 - DTI PRS 1 Fault Enable"]
560    #[inline(always)]
561    #[must_use]
562    pub fn dtprs1fen(&mut self) -> DTPRS1FEN_W<25> {
563        DTPRS1FEN_W::new(self)
564    }
565    #[doc = "Bit 26 - DTI Debugger Fault Enable"]
566    #[inline(always)]
567    #[must_use]
568    pub fn dtdbgfen(&mut self) -> DTDBGFEN_W<26> {
569        DTDBGFEN_W::new(self)
570    }
571    #[doc = "Bit 27 - DTI Lockup Fault Enable"]
572    #[inline(always)]
573    #[must_use]
574    pub fn dtlockupfen(&mut self) -> DTLOCKUPFEN_W<27> {
575        DTLOCKUPFEN_W::new(self)
576    }
577    #[doc = "Writes raw bits to the register."]
578    #[inline(always)]
579    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
580        self.0.bits(bits);
581        self
582    }
583}
584#[doc = "DTI Fault Configuration 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 [dtfc](index.html) module"]
585pub struct DTFC_SPEC;
586impl crate::RegisterSpec for DTFC_SPEC {
587    type Ux = u32;
588}
589#[doc = "`read()` method returns [dtfc::R](R) reader structure"]
590impl crate::Readable for DTFC_SPEC {
591    type Reader = R;
592}
593#[doc = "`write(|w| ..)` method takes [dtfc::W](W) writer structure"]
594impl crate::Writable for DTFC_SPEC {
595    type Writer = W;
596    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
597    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
598}
599#[doc = "`reset()` method sets DTFC to value 0"]
600impl crate::Resettable for DTFC_SPEC {
601    const RESET_VALUE: Self::Ux = 0;
602}