efm32g230_pac/timer2/
dtfault.rs1#[doc = "Register `DTFAULT` reader"]
2pub struct R(crate::R<DTFAULT_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<DTFAULT_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<DTFAULT_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<DTFAULT_SPEC>) -> Self {
13 R(reader)
14 }
15}
16#[doc = "Field `DTPRS0F` reader - DTI PRS 0 Fault"]
17pub type DTPRS0F_R = crate::BitReader<bool>;
18#[doc = "Field `DTPRS1F` reader - DTI PRS 1 Fault"]
19pub type DTPRS1F_R = crate::BitReader<bool>;
20#[doc = "Field `DTDBGF` reader - DTI Debugger Fault"]
21pub type DTDBGF_R = crate::BitReader<bool>;
22#[doc = "Field `DTLOCKUPF` reader - DTI Lockup Fault"]
23pub type DTLOCKUPF_R = crate::BitReader<bool>;
24impl R {
25 #[doc = "Bit 0 - DTI PRS 0 Fault"]
26 #[inline(always)]
27 pub fn dtprs0f(&self) -> DTPRS0F_R {
28 DTPRS0F_R::new((self.bits & 1) != 0)
29 }
30 #[doc = "Bit 1 - DTI PRS 1 Fault"]
31 #[inline(always)]
32 pub fn dtprs1f(&self) -> DTPRS1F_R {
33 DTPRS1F_R::new(((self.bits >> 1) & 1) != 0)
34 }
35 #[doc = "Bit 2 - DTI Debugger Fault"]
36 #[inline(always)]
37 pub fn dtdbgf(&self) -> DTDBGF_R {
38 DTDBGF_R::new(((self.bits >> 2) & 1) != 0)
39 }
40 #[doc = "Bit 3 - DTI Lockup Fault"]
41 #[inline(always)]
42 pub fn dtlockupf(&self) -> DTLOCKUPF_R {
43 DTLOCKUPF_R::new(((self.bits >> 3) & 1) != 0)
44 }
45}
46#[doc = "DTI Fault 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 [dtfault](index.html) module"]
47pub struct DTFAULT_SPEC;
48impl crate::RegisterSpec for DTFAULT_SPEC {
49 type Ux = u32;
50}
51#[doc = "`read()` method returns [dtfault::R](R) reader structure"]
52impl crate::Readable for DTFAULT_SPEC {
53 type Reader = R;
54}
55#[doc = "`reset()` method sets DTFAULT to value 0"]
56impl crate::Resettable for DTFAULT_SPEC {
57 #[inline(always)]
58 fn reset_value() -> Self::Ux {
59 0
60 }
61}