rp2040_pac/clocks/
fc0_result.rs

1#[doc = "Register `FC0_RESULT` reader"]
2pub type R = crate::R<FC0_RESULT_SPEC>;
3#[doc = "Field `FRAC` reader - "]
4pub type FRAC_R = crate::FieldReader;
5#[doc = "Field `KHZ` reader - "]
6pub type KHZ_R = crate::FieldReader<u32>;
7impl R {
8    #[doc = "Bits 0:4"]
9    #[inline(always)]
10    pub fn frac(&self) -> FRAC_R {
11        FRAC_R::new((self.bits & 0x1f) as u8)
12    }
13    #[doc = "Bits 5:29"]
14    #[inline(always)]
15    pub fn khz(&self) -> KHZ_R {
16        KHZ_R::new((self.bits >> 5) & 0x01ff_ffff)
17    }
18}
19#[doc = "Result of frequency measurement, only valid when status_done=1  
20
21You can [`read`](crate::generic::Reg::read) this register and get [`fc0_result::R`](R).  See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
22pub struct FC0_RESULT_SPEC;
23impl crate::RegisterSpec for FC0_RESULT_SPEC {
24    type Ux = u32;
25}
26#[doc = "`read()` method returns [`fc0_result::R`](R) reader structure"]
27impl crate::Readable for FC0_RESULT_SPEC {}
28#[doc = "`reset()` method sets FC0_RESULT to value 0"]
29impl crate::Resettable for FC0_RESULT_SPEC {
30    const RESET_VALUE: u32 = 0;
31}