stm32wb_pac/lptim1/
isr.rs

1#[doc = "Reader of register ISR"]
2pub type R = crate::R<u32, super::ISR>;
3#[doc = "Reader of field `DOWN`"]
4pub type DOWN_R = crate::R<bool, bool>;
5#[doc = "Reader of field `UP`"]
6pub type UP_R = crate::R<bool, bool>;
7#[doc = "Reader of field `ARROK`"]
8pub type ARROK_R = crate::R<bool, bool>;
9#[doc = "Reader of field `CMPOK`"]
10pub type CMPOK_R = crate::R<bool, bool>;
11#[doc = "Reader of field `EXTTRIG`"]
12pub type EXTTRIG_R = crate::R<bool, bool>;
13#[doc = "Reader of field `ARRM`"]
14pub type ARRM_R = crate::R<bool, bool>;
15#[doc = "Reader of field `CMPM`"]
16pub type CMPM_R = crate::R<bool, bool>;
17impl R {
18    #[doc = "Bit 6 - Counter direction change up to down"]
19    #[inline(always)]
20    pub fn down(&self) -> DOWN_R {
21        DOWN_R::new(((self.bits >> 6) & 0x01) != 0)
22    }
23    #[doc = "Bit 5 - Counter direction change down to up"]
24    #[inline(always)]
25    pub fn up(&self) -> UP_R {
26        UP_R::new(((self.bits >> 5) & 0x01) != 0)
27    }
28    #[doc = "Bit 4 - Autoreload register update OK"]
29    #[inline(always)]
30    pub fn arrok(&self) -> ARROK_R {
31        ARROK_R::new(((self.bits >> 4) & 0x01) != 0)
32    }
33    #[doc = "Bit 3 - Compare register update OK"]
34    #[inline(always)]
35    pub fn cmpok(&self) -> CMPOK_R {
36        CMPOK_R::new(((self.bits >> 3) & 0x01) != 0)
37    }
38    #[doc = "Bit 2 - External trigger edge event"]
39    #[inline(always)]
40    pub fn exttrig(&self) -> EXTTRIG_R {
41        EXTTRIG_R::new(((self.bits >> 2) & 0x01) != 0)
42    }
43    #[doc = "Bit 1 - Autoreload match"]
44    #[inline(always)]
45    pub fn arrm(&self) -> ARRM_R {
46        ARRM_R::new(((self.bits >> 1) & 0x01) != 0)
47    }
48    #[doc = "Bit 0 - Compare match"]
49    #[inline(always)]
50    pub fn cmpm(&self) -> CMPM_R {
51        CMPM_R::new((self.bits & 0x01) != 0)
52    }
53}