atsamd51j/sercom0/spis/
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 `CTRLB` reader - CTRLB Synchronization Busy"]
8pub type CtrlbR = crate::BitReader;
9#[doc = "Field `LENGTH` reader - LENGTH Synchronization Busy"]
10pub type LengthR = crate::BitReader;
11impl R {
12    #[doc = "Bit 0 - Software Reset Synchronization Busy"]
13    #[inline(always)]
14    pub fn swrst(&self) -> SwrstR {
15        SwrstR::new((self.bits & 1) != 0)
16    }
17    #[doc = "Bit 1 - SERCOM Enable Synchronization Busy"]
18    #[inline(always)]
19    pub fn enable(&self) -> EnableR {
20        EnableR::new(((self.bits >> 1) & 1) != 0)
21    }
22    #[doc = "Bit 2 - CTRLB Synchronization Busy"]
23    #[inline(always)]
24    pub fn ctrlb(&self) -> CtrlbR {
25        CtrlbR::new(((self.bits >> 2) & 1) != 0)
26    }
27    #[doc = "Bit 4 - LENGTH Synchronization Busy"]
28    #[inline(always)]
29    pub fn length(&self) -> LengthR {
30        LengthR::new(((self.bits >> 4) & 1) != 0)
31    }
32}
33#[doc = "SPIS Synchronization Busy\n\nYou can [`read`](crate::Reg::read) this register and get [`syncbusy::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
34pub struct SyncbusySpec;
35impl crate::RegisterSpec for SyncbusySpec {
36    type Ux = u32;
37}
38#[doc = "`read()` method returns [`syncbusy::R`](R) reader structure"]
39impl crate::Readable for SyncbusySpec {}
40#[doc = "`reset()` method sets SYNCBUSY to value 0"]
41impl crate::Resettable for SyncbusySpec {
42    const RESET_VALUE: u32 = 0;
43}