atsamd51p/etm/
lsr.rs

1#[doc = "Register `LSR` reader"]
2pub type R = crate::R<LsrSpec>;
3#[doc = "Field `Present` reader - "]
4pub type PresentR = crate::BitReader;
5#[doc = "Field `Access` reader - "]
6pub type AccessR = crate::BitReader;
7#[doc = "Field `ByteAcc` reader - "]
8pub type ByteAccR = crate::BitReader;
9impl R {
10    #[doc = "Bit 0"]
11    #[inline(always)]
12    pub fn present(&self) -> PresentR {
13        PresentR::new((self.bits & 1) != 0)
14    }
15    #[doc = "Bit 1"]
16    #[inline(always)]
17    pub fn access(&self) -> AccessR {
18        AccessR::new(((self.bits >> 1) & 1) != 0)
19    }
20    #[doc = "Bit 2"]
21    #[inline(always)]
22    pub fn byte_acc(&self) -> ByteAccR {
23        ByteAccR::new(((self.bits >> 2) & 1) != 0)
24    }
25}
26#[doc = "ETM Lock Status Register\n\nYou can [`read`](crate::Reg::read) this register and get [`lsr::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
27pub struct LsrSpec;
28impl crate::RegisterSpec for LsrSpec {
29    type Ux = u32;
30}
31#[doc = "`read()` method returns [`lsr::R`](R) reader structure"]
32impl crate::Readable for LsrSpec {}
33#[doc = "`reset()` method sets LSR to value 0"]
34impl crate::Resettable for LsrSpec {
35    const RESET_VALUE: u32 = 0;
36}