rp2040_pac/clocks/
fc0_status.rs

1#[doc = "Register `FC0_STATUS` reader"]
2pub type R = crate::R<FC0_STATUS_SPEC>;
3#[doc = "Field `PASS` reader - Test passed"]
4pub type PASS_R = crate::BitReader;
5#[doc = "Field `DONE` reader - Test complete"]
6pub type DONE_R = crate::BitReader;
7#[doc = "Field `RUNNING` reader - Test running"]
8pub type RUNNING_R = crate::BitReader;
9#[doc = "Field `WAITING` reader - Waiting for test clock to start"]
10pub type WAITING_R = crate::BitReader;
11#[doc = "Field `FAIL` reader - Test failed"]
12pub type FAIL_R = crate::BitReader;
13#[doc = "Field `SLOW` reader - Test clock slower than expected, only valid when status_done=1"]
14pub type SLOW_R = crate::BitReader;
15#[doc = "Field `FAST` reader - Test clock faster than expected, only valid when status_done=1"]
16pub type FAST_R = crate::BitReader;
17#[doc = "Field `DIED` reader - Test clock stopped during test"]
18pub type DIED_R = crate::BitReader;
19impl R {
20    #[doc = "Bit 0 - Test passed"]
21    #[inline(always)]
22    pub fn pass(&self) -> PASS_R {
23        PASS_R::new((self.bits & 1) != 0)
24    }
25    #[doc = "Bit 4 - Test complete"]
26    #[inline(always)]
27    pub fn done(&self) -> DONE_R {
28        DONE_R::new(((self.bits >> 4) & 1) != 0)
29    }
30    #[doc = "Bit 8 - Test running"]
31    #[inline(always)]
32    pub fn running(&self) -> RUNNING_R {
33        RUNNING_R::new(((self.bits >> 8) & 1) != 0)
34    }
35    #[doc = "Bit 12 - Waiting for test clock to start"]
36    #[inline(always)]
37    pub fn waiting(&self) -> WAITING_R {
38        WAITING_R::new(((self.bits >> 12) & 1) != 0)
39    }
40    #[doc = "Bit 16 - Test failed"]
41    #[inline(always)]
42    pub fn fail(&self) -> FAIL_R {
43        FAIL_R::new(((self.bits >> 16) & 1) != 0)
44    }
45    #[doc = "Bit 20 - Test clock slower than expected, only valid when status_done=1"]
46    #[inline(always)]
47    pub fn slow(&self) -> SLOW_R {
48        SLOW_R::new(((self.bits >> 20) & 1) != 0)
49    }
50    #[doc = "Bit 24 - Test clock faster than expected, only valid when status_done=1"]
51    #[inline(always)]
52    pub fn fast(&self) -> FAST_R {
53        FAST_R::new(((self.bits >> 24) & 1) != 0)
54    }
55    #[doc = "Bit 28 - Test clock stopped during test"]
56    #[inline(always)]
57    pub fn died(&self) -> DIED_R {
58        DIED_R::new(((self.bits >> 28) & 1) != 0)
59    }
60}
61#[doc = "Frequency counter status  
62
63You can [`read`](crate::generic::Reg::read) this register and get [`fc0_status::R`](R).  See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
64pub struct FC0_STATUS_SPEC;
65impl crate::RegisterSpec for FC0_STATUS_SPEC {
66    type Ux = u32;
67}
68#[doc = "`read()` method returns [`fc0_status::R`](R) reader structure"]
69impl crate::Readable for FC0_STATUS_SPEC {}
70#[doc = "`reset()` method sets FC0_STATUS to value 0"]
71impl crate::Resettable for FC0_STATUS_SPEC {
72    const RESET_VALUE: u32 = 0;
73}