stm32wb_pac/hsem/
rlr12.rs1#[doc = "Reader of register RLR12"]
2pub type R = crate::R<u32, super::RLR12>;
3#[doc = "Reader of field `LOCK`"]
4pub type LOCK_R = crate::R<bool, bool>;
5#[doc = "Reader of field `COREID`"]
6pub type COREID_R = crate::R<u8, u8>;
7#[doc = "Reader of field `PROCID`"]
8pub type PROCID_R = crate::R<u8, u8>;
9impl R {
10 #[doc = "Bit 31 - lock indication"]
11 #[inline(always)]
12 pub fn lock(&self) -> LOCK_R {
13 LOCK_R::new(((self.bits >> 31) & 0x01) != 0)
14 }
15 #[doc = "Bits 8:11 - Semaphore CoreID"]
16 #[inline(always)]
17 pub fn coreid(&self) -> COREID_R {
18 COREID_R::new(((self.bits >> 8) & 0x0f) as u8)
19 }
20 #[doc = "Bits 0:7 - Semaphore ProcessID"]
21 #[inline(always)]
22 pub fn procid(&self) -> PROCID_R {
23 PROCID_R::new((self.bits & 0xff) as u8)
24 }
25}