esp32c3/twai0/
arb_lost_cap.rs

1#[doc = "Register `ARB_LOST_CAP` reader"]
2pub type R = crate::R<ARB_LOST_CAP_SPEC>;
3#[doc = "Field `ARB_LOST_CAP` reader - This register contains information about the bit position of lost arbitration."]
4pub type ARB_LOST_CAP_R = crate::FieldReader;
5impl R {
6    #[doc = "Bits 0:4 - This register contains information about the bit position of lost arbitration."]
7    #[inline(always)]
8    pub fn arb_lost_cap(&self) -> ARB_LOST_CAP_R {
9        ARB_LOST_CAP_R::new((self.bits & 0x1f) as u8)
10    }
11}
12#[cfg(feature = "impl-register-debug")]
13impl core::fmt::Debug for R {
14    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
15        f.debug_struct("ARB_LOST_CAP")
16            .field("arb_lost_cap", &self.arb_lost_cap())
17            .finish()
18    }
19}
20#[doc = "Arbitration Lost Capture Register\n\nYou can [`read`](crate::Reg::read) this register and get [`arb_lost_cap::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
21pub struct ARB_LOST_CAP_SPEC;
22impl crate::RegisterSpec for ARB_LOST_CAP_SPEC {
23    type Ux = u32;
24}
25#[doc = "`read()` method returns [`arb_lost_cap::R`](R) reader structure"]
26impl crate::Readable for ARB_LOST_CAP_SPEC {}
27#[doc = "`reset()` method sets ARB_LOST_CAP to value 0"]
28impl crate::Resettable for ARB_LOST_CAP_SPEC {
29    const RESET_VALUE: u32 = 0;
30}