atsamd11c/sercom0/i2cm/
syncbusy.rs

1#[doc = "Register `SYNCBUSY` reader"]
2pub type R = crate::R<SyncbusySpec>;
3#[doc = "Field `SWRST` reader - Software Reset Synchronization Busy"]
4pub type SwrstR = crate::BitReader;
5#[doc = "Field `ENABLE` reader - SERCOM Enable Synchronization Busy"]
6pub type EnableR = crate::BitReader;
7#[doc = "Field `SYSOP` reader - System Operation Synchronization Busy"]
8pub type SysopR = crate::BitReader;
9impl R {
10    #[doc = "Bit 0 - Software Reset Synchronization Busy"]
11    #[inline(always)]
12    pub fn swrst(&self) -> SwrstR {
13        SwrstR::new((self.bits & 1) != 0)
14    }
15    #[doc = "Bit 1 - SERCOM Enable Synchronization Busy"]
16    #[inline(always)]
17    pub fn enable(&self) -> EnableR {
18        EnableR::new(((self.bits >> 1) & 1) != 0)
19    }
20    #[doc = "Bit 2 - System Operation Synchronization Busy"]
21    #[inline(always)]
22    pub fn sysop(&self) -> SysopR {
23        SysopR::new(((self.bits >> 2) & 1) != 0)
24    }
25}
26#[doc = "I2CM Syncbusy\n\nYou can [`read`](crate::Reg::read) this register and get [`syncbusy::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
27pub struct SyncbusySpec;
28impl crate::RegisterSpec for SyncbusySpec {
29    type Ux = u32;
30}
31#[doc = "`read()` method returns [`syncbusy::R`](R) reader structure"]
32impl crate::Readable for SyncbusySpec {}
33#[doc = "`reset()` method sets SYNCBUSY to value 0"]
34impl crate::Resettable for SyncbusySpec {
35    const RESET_VALUE: u32 = 0;
36}