atsam3s2a/udp/
icr.rs

1#[doc = "Register `ICR` writer"]
2pub type W = crate::W<IcrSpec>;
3#[doc = "Field `RXSUSP` writer - Clear UDP Suspend Interrupt"]
4pub type RxsuspW<'a, REG> = crate::BitWriter<'a, REG>;
5#[doc = "Field `RXRSM` writer - Clear UDP Resume Interrupt"]
6pub type RxrsmW<'a, REG> = crate::BitWriter<'a, REG>;
7#[doc = "Field `EXTRSM` writer - "]
8pub type ExtrsmW<'a, REG> = crate::BitWriter<'a, REG>;
9#[doc = "Field `SOFINT` writer - Clear Start Of Frame Interrupt"]
10pub type SofintW<'a, REG> = crate::BitWriter<'a, REG>;
11#[doc = "Field `ENDBUSRES` writer - Clear End of Bus Reset Interrupt"]
12pub type EndbusresW<'a, REG> = crate::BitWriter<'a, REG>;
13#[doc = "Field `WAKEUP` writer - Clear Wakeup Interrupt"]
14pub type WakeupW<'a, REG> = crate::BitWriter<'a, REG>;
15impl W {
16    #[doc = "Bit 8 - Clear UDP Suspend Interrupt"]
17    #[inline(always)]
18    #[must_use]
19    pub fn rxsusp(&mut self) -> RxsuspW<IcrSpec> {
20        RxsuspW::new(self, 8)
21    }
22    #[doc = "Bit 9 - Clear UDP Resume Interrupt"]
23    #[inline(always)]
24    #[must_use]
25    pub fn rxrsm(&mut self) -> RxrsmW<IcrSpec> {
26        RxrsmW::new(self, 9)
27    }
28    #[doc = "Bit 10"]
29    #[inline(always)]
30    #[must_use]
31    pub fn extrsm(&mut self) -> ExtrsmW<IcrSpec> {
32        ExtrsmW::new(self, 10)
33    }
34    #[doc = "Bit 11 - Clear Start Of Frame Interrupt"]
35    #[inline(always)]
36    #[must_use]
37    pub fn sofint(&mut self) -> SofintW<IcrSpec> {
38        SofintW::new(self, 11)
39    }
40    #[doc = "Bit 12 - Clear End of Bus Reset Interrupt"]
41    #[inline(always)]
42    #[must_use]
43    pub fn endbusres(&mut self) -> EndbusresW<IcrSpec> {
44        EndbusresW::new(self, 12)
45    }
46    #[doc = "Bit 13 - Clear Wakeup Interrupt"]
47    #[inline(always)]
48    #[must_use]
49    pub fn wakeup(&mut self) -> WakeupW<IcrSpec> {
50        WakeupW::new(self, 13)
51    }
52}
53#[doc = "Interrupt Clear Register\n\nYou can [`write_with_zero`](crate::generic::Reg::write_with_zero) this register using [`icr::W`](W). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
54pub struct IcrSpec;
55impl crate::RegisterSpec for IcrSpec {
56    type Ux = u32;
57}
58#[doc = "`write(|w| ..)` method takes [`icr::W`](W) writer structure"]
59impl crate::Writable for IcrSpec {
60    type Safety = crate::Unsafe;
61    const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
62    const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
63}