atsam4lc2a_pac/usbc/
udinteset.rs

1#[doc = "Register `UDINTESET` writer"]
2pub struct W(crate::W<UDINTESET_SPEC>);
3impl core::ops::Deref for W {
4    type Target = crate::W<UDINTESET_SPEC>;
5    #[inline(always)]
6    fn deref(&self) -> &Self::Target {
7        &self.0
8    }
9}
10impl core::ops::DerefMut for W {
11    #[inline(always)]
12    fn deref_mut(&mut self) -> &mut Self::Target {
13        &mut self.0
14    }
15}
16impl From<crate::W<UDINTESET_SPEC>> for W {
17    #[inline(always)]
18    fn from(writer: crate::W<UDINTESET_SPEC>) -> Self {
19        W(writer)
20    }
21}
22#[doc = "Field `SUSPES` writer - SUSP Interrupt Enable Set"]
23pub type SUSPES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
24#[doc = "Field `MSOFES` writer - MSOF Interrupt Enable Set"]
25pub type MSOFES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
26#[doc = "Field `SOFES` writer - SOF Interrupt Enable Set"]
27pub type SOFES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
28#[doc = "Field `EORSTES` writer - EORST Interrupt Enable Set"]
29pub type EORSTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
30#[doc = "Field `WAKEUPES` writer - WAKEUP Interrupt Enable Set"]
31pub type WAKEUPES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
32#[doc = "Field `EORSMES` writer - EORSM Interrupt Enable Set"]
33pub type EORSMES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
34#[doc = "Field `UPRSMES` writer - UPRSM Interrupt Enable Set"]
35pub type UPRSMES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
36#[doc = "Field `EP0INTES` writer - EP0INT Interrupt Enable Set"]
37pub type EP0INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
38#[doc = "Field `EP1INTES` writer - EP1INT Interrupt Enable Set"]
39pub type EP1INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
40#[doc = "Field `EP2INTES` writer - EP2INT Interrupt Enable Set"]
41pub type EP2INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
42#[doc = "Field `EP3INTES` writer - EP3INT Interrupt Enable Set"]
43pub type EP3INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
44#[doc = "Field `EP4INTES` writer - EP4INT Interrupt Enable Set"]
45pub type EP4INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
46#[doc = "Field `EP5INTES` writer - EP5INT Interrupt Enable Set"]
47pub type EP5INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
48#[doc = "Field `EP6INTES` writer - EP6INT Interrupt Enable Set"]
49pub type EP6INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
50#[doc = "Field `EP7INTES` writer - EP7INT Interrupt Enable Set"]
51pub type EP7INTES_W<'a, const O: u8> = crate::BitWriter<'a, u32, UDINTESET_SPEC, bool, O>;
52impl W {
53    #[doc = "Bit 0 - SUSP Interrupt Enable Set"]
54    #[inline(always)]
55    #[must_use]
56    pub fn suspes(&mut self) -> SUSPES_W<0> {
57        SUSPES_W::new(self)
58    }
59    #[doc = "Bit 1 - MSOF Interrupt Enable Set"]
60    #[inline(always)]
61    #[must_use]
62    pub fn msofes(&mut self) -> MSOFES_W<1> {
63        MSOFES_W::new(self)
64    }
65    #[doc = "Bit 2 - SOF Interrupt Enable Set"]
66    #[inline(always)]
67    #[must_use]
68    pub fn sofes(&mut self) -> SOFES_W<2> {
69        SOFES_W::new(self)
70    }
71    #[doc = "Bit 3 - EORST Interrupt Enable Set"]
72    #[inline(always)]
73    #[must_use]
74    pub fn eorstes(&mut self) -> EORSTES_W<3> {
75        EORSTES_W::new(self)
76    }
77    #[doc = "Bit 4 - WAKEUP Interrupt Enable Set"]
78    #[inline(always)]
79    #[must_use]
80    pub fn wakeupes(&mut self) -> WAKEUPES_W<4> {
81        WAKEUPES_W::new(self)
82    }
83    #[doc = "Bit 5 - EORSM Interrupt Enable Set"]
84    #[inline(always)]
85    #[must_use]
86    pub fn eorsmes(&mut self) -> EORSMES_W<5> {
87        EORSMES_W::new(self)
88    }
89    #[doc = "Bit 6 - UPRSM Interrupt Enable Set"]
90    #[inline(always)]
91    #[must_use]
92    pub fn uprsmes(&mut self) -> UPRSMES_W<6> {
93        UPRSMES_W::new(self)
94    }
95    #[doc = "Bit 12 - EP0INT Interrupt Enable Set"]
96    #[inline(always)]
97    #[must_use]
98    pub fn ep0intes(&mut self) -> EP0INTES_W<12> {
99        EP0INTES_W::new(self)
100    }
101    #[doc = "Bit 13 - EP1INT Interrupt Enable Set"]
102    #[inline(always)]
103    #[must_use]
104    pub fn ep1intes(&mut self) -> EP1INTES_W<13> {
105        EP1INTES_W::new(self)
106    }
107    #[doc = "Bit 14 - EP2INT Interrupt Enable Set"]
108    #[inline(always)]
109    #[must_use]
110    pub fn ep2intes(&mut self) -> EP2INTES_W<14> {
111        EP2INTES_W::new(self)
112    }
113    #[doc = "Bit 15 - EP3INT Interrupt Enable Set"]
114    #[inline(always)]
115    #[must_use]
116    pub fn ep3intes(&mut self) -> EP3INTES_W<15> {
117        EP3INTES_W::new(self)
118    }
119    #[doc = "Bit 16 - EP4INT Interrupt Enable Set"]
120    #[inline(always)]
121    #[must_use]
122    pub fn ep4intes(&mut self) -> EP4INTES_W<16> {
123        EP4INTES_W::new(self)
124    }
125    #[doc = "Bit 17 - EP5INT Interrupt Enable Set"]
126    #[inline(always)]
127    #[must_use]
128    pub fn ep5intes(&mut self) -> EP5INTES_W<17> {
129        EP5INTES_W::new(self)
130    }
131    #[doc = "Bit 18 - EP6INT Interrupt Enable Set"]
132    #[inline(always)]
133    #[must_use]
134    pub fn ep6intes(&mut self) -> EP6INTES_W<18> {
135        EP6INTES_W::new(self)
136    }
137    #[doc = "Bit 19 - EP7INT Interrupt Enable Set"]
138    #[inline(always)]
139    #[must_use]
140    pub fn ep7intes(&mut self) -> EP7INTES_W<19> {
141        EP7INTES_W::new(self)
142    }
143    #[doc = "Writes raw bits to the register."]
144    #[inline(always)]
145    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
146        self.0.bits(bits);
147        self
148    }
149}
150#[doc = "Device Global Interrupt Enable Set Register\n\nThis register you can [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [udinteset](index.html) module"]
151pub struct UDINTESET_SPEC;
152impl crate::RegisterSpec for UDINTESET_SPEC {
153    type Ux = u32;
154}
155#[doc = "`write(|w| ..)` method takes [udinteset::W](W) writer structure"]
156impl crate::Writable for UDINTESET_SPEC {
157    type Writer = W;
158    const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
159    const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
160}
161#[doc = "`reset()` method sets UDINTESET to value 0"]
162impl crate::Resettable for UDINTESET_SPEC {
163    const RESET_VALUE: Self::Ux = 0;
164}