rp2040_pac/xip_ctrl/
stat.rs

1#[doc = "Register `STAT` reader"]
2pub type R = crate::R<STAT_SPEC>;
3#[doc = "Field `FLUSH_READY` reader - Reads as 0 while a cache flush is in progress, and 1 otherwise.  
4 The cache is flushed whenever the XIP block is reset, and also  
5 when requested via the FLUSH register."]
6pub type FLUSH_READY_R = crate::BitReader;
7#[doc = "Field `FIFO_EMPTY` reader - When 1, indicates the XIP streaming FIFO is completely empty."]
8pub type FIFO_EMPTY_R = crate::BitReader;
9#[doc = "Field `FIFO_FULL` reader - When 1, indicates the XIP streaming FIFO is completely full.  
10 The streaming FIFO is 2 entries deep, so the full and empty  
11 flag allow its level to be ascertained."]
12pub type FIFO_FULL_R = crate::BitReader;
13impl R {
14    #[doc = "Bit 0 - Reads as 0 while a cache flush is in progress, and 1 otherwise.  
15 The cache is flushed whenever the XIP block is reset, and also  
16 when requested via the FLUSH register."]
17    #[inline(always)]
18    pub fn flush_ready(&self) -> FLUSH_READY_R {
19        FLUSH_READY_R::new((self.bits & 1) != 0)
20    }
21    #[doc = "Bit 1 - When 1, indicates the XIP streaming FIFO is completely empty."]
22    #[inline(always)]
23    pub fn fifo_empty(&self) -> FIFO_EMPTY_R {
24        FIFO_EMPTY_R::new(((self.bits >> 1) & 1) != 0)
25    }
26    #[doc = "Bit 2 - When 1, indicates the XIP streaming FIFO is completely full.  
27 The streaming FIFO is 2 entries deep, so the full and empty  
28 flag allow its level to be ascertained."]
29    #[inline(always)]
30    pub fn fifo_full(&self) -> FIFO_FULL_R {
31        FIFO_FULL_R::new(((self.bits >> 2) & 1) != 0)
32    }
33}
34#[doc = "Cache Status  
35
36You can [`read`](crate::generic::Reg::read) this register and get [`stat::R`](R).  See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
37pub struct STAT_SPEC;
38impl crate::RegisterSpec for STAT_SPEC {
39    type Ux = u32;
40}
41#[doc = "`read()` method returns [`stat::R`](R) reader structure"]
42impl crate::Readable for STAT_SPEC {}
43#[doc = "`reset()` method sets STAT to value 0x02"]
44impl crate::Resettable for STAT_SPEC {
45    const RESET_VALUE: u32 = 0x02;
46}