1#[doc = "Reader of register BSR"]
2pub type R = crate::R<u32, super::BSR>;
3#[doc = "Reader of field `FLVL`"]
4pub type FLVL_R = crate::R<u8, u8>;
5#[doc = "Reader of field `LFSDET`"]
6pub type LFSDET_R = crate::R<bool, bool>;
7#[doc = "Reader of field `AFSDET`"]
8pub type AFSDET_R = crate::R<bool, bool>;
9#[doc = "Reader of field `CNRDY`"]
10pub type CNRDY_R = crate::R<bool, bool>;
11#[doc = "Reader of field `FREQ`"]
12pub type FREQ_R = crate::R<bool, bool>;
13#[doc = "Reader of field `WCKCFG`"]
14pub type WCKCFG_R = crate::R<bool, bool>;
15#[doc = "Reader of field `MUTEDET`"]
16pub type MUTEDET_R = crate::R<bool, bool>;
17#[doc = "Reader of field `OVRUDR`"]
18pub type OVRUDR_R = crate::R<bool, bool>;
19impl R {
20 #[doc = "Bits 16:18 - FIFO level threshold"]
21 #[inline(always)]
22 pub fn flvl(&self) -> FLVL_R {
23 FLVL_R::new(((self.bits >> 16) & 0x07) as u8)
24 }
25 #[doc = "Bit 6 - Late frame synchronization detection"]
26 #[inline(always)]
27 pub fn lfsdet(&self) -> LFSDET_R {
28 LFSDET_R::new(((self.bits >> 6) & 0x01) != 0)
29 }
30 #[doc = "Bit 5 - Anticipated frame synchronization detection"]
31 #[inline(always)]
32 pub fn afsdet(&self) -> AFSDET_R {
33 AFSDET_R::new(((self.bits >> 5) & 0x01) != 0)
34 }
35 #[doc = "Bit 4 - Codec not ready"]
36 #[inline(always)]
37 pub fn cnrdy(&self) -> CNRDY_R {
38 CNRDY_R::new(((self.bits >> 4) & 0x01) != 0)
39 }
40 #[doc = "Bit 3 - FIFO request"]
41 #[inline(always)]
42 pub fn freq(&self) -> FREQ_R {
43 FREQ_R::new(((self.bits >> 3) & 0x01) != 0)
44 }
45 #[doc = "Bit 2 - Wrong clock configuration flag"]
46 #[inline(always)]
47 pub fn wckcfg(&self) -> WCKCFG_R {
48 WCKCFG_R::new(((self.bits >> 2) & 0x01) != 0)
49 }
50 #[doc = "Bit 1 - Mute detection"]
51 #[inline(always)]
52 pub fn mutedet(&self) -> MUTEDET_R {
53 MUTEDET_R::new(((self.bits >> 1) & 0x01) != 0)
54 }
55 #[doc = "Bit 0 - Overrun / underrun"]
56 #[inline(always)]
57 pub fn ovrudr(&self) -> OVRUDR_R {
58 OVRUDR_R::new((self.bits & 0x01) != 0)
59 }
60}