Robobo
component_uotghs.h
1 /* ----------------------------------------------------------------------------
2  * SAM Software Package License
3  * ----------------------------------------------------------------------------
4  * Copyright (c) 2012, Atmel Corporation
5  *
6  * All rights reserved.
7  *
8  * Redistribution and use in source and binary forms, with or without
9  * modification, are permitted provided that the following condition is met:
10  *
11  * - Redistributions of source code must retain the above copyright notice,
12  * this list of conditions and the disclaimer below.
13  *
14  * Atmel's name may not be used to endorse or promote products derived from
15  * this software without specific prior written permission.
16  *
17  * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR
18  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
19  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE
20  * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT,
21  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
23  * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
24  * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
25  * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
26  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27  * ----------------------------------------------------------------------------
28  */
29 
30 #ifndef _SAM3XA_UOTGHS_COMPONENT_
31 #define _SAM3XA_UOTGHS_COMPONENT_
32 
33 /* ============================================================================= */
35 /* ============================================================================= */
38 
39 #if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__))
40 
41 typedef struct {
46 } UotghsDevdma;
48 typedef struct {
53 } UotghsHstdma;
55 #define UOTGHSDEVDMA_NUMBER 7
56 #define UOTGHSHSTDMA_NUMBER 7
57 typedef struct {
67  RoReg Reserved1[55];
68  RwReg UOTGHS_DEVEPTCFG[10];
69  RoReg Reserved2[2];
70  RoReg UOTGHS_DEVEPTISR[10];
71  RoReg Reserved3[2];
72  WoReg UOTGHS_DEVEPTICR[10];
73  RoReg Reserved4[2];
74  WoReg UOTGHS_DEVEPTIFR[10];
75  RoReg Reserved5[2];
76  RoReg UOTGHS_DEVEPTIMR[10];
77  RoReg Reserved6[2];
78  WoReg UOTGHS_DEVEPTIER[10];
79  RoReg Reserved7[2];
80  WoReg UOTGHS_DEVEPTIDR[10];
81  RoReg Reserved8[50];
83  RoReg Reserved9[32];
96  RoReg Reserved10[52];
97  RwReg UOTGHS_HSTPIPCFG[10];
98  RoReg Reserved11[2];
99  RoReg UOTGHS_HSTPIPISR[10];
100  RoReg Reserved12[2];
101  WoReg UOTGHS_HSTPIPICR[10];
102  RoReg Reserved13[2];
103  WoReg UOTGHS_HSTPIPIFR[10];
104  RoReg Reserved14[2];
105  RoReg UOTGHS_HSTPIPIMR[10];
106  RoReg Reserved15[2];
107  WoReg UOTGHS_HSTPIPIER[10];
108  RoReg Reserved16[2];
109  WoReg UOTGHS_HSTPIPIDR[10];
110  RoReg Reserved17[2];
111  RwReg UOTGHS_HSTPIPINRQ[10];
112  RoReg Reserved18[2];
113  RwReg UOTGHS_HSTPIPERR[10];
114  RoReg Reserved19[26];
115  UotghsHstdma UOTGHS_HSTDMA[UOTGHSHSTDMA_NUMBER];
116  RoReg Reserved20[32];
121  RoReg Reserved21[7];
123 } Uotghs;
124 #endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */
125 /* -------- UOTGHS_DEVCTRL : (UOTGHS Offset: 0x0000) Device General Control Register -------- */
126 #define UOTGHS_DEVCTRL_UADD_Pos 0
127 #define UOTGHS_DEVCTRL_UADD_Msk (0x7fu << UOTGHS_DEVCTRL_UADD_Pos)
128 #define UOTGHS_DEVCTRL_UADD(value) ((UOTGHS_DEVCTRL_UADD_Msk & ((value) << UOTGHS_DEVCTRL_UADD_Pos)))
129 #define UOTGHS_DEVCTRL_ADDEN (0x1u << 7)
130 #define UOTGHS_DEVCTRL_DETACH (0x1u << 8)
131 #define UOTGHS_DEVCTRL_RMWKUP (0x1u << 9)
132 #define UOTGHS_DEVCTRL_SPDCONF_Pos 10
133 #define UOTGHS_DEVCTRL_SPDCONF_Msk (0x3u << UOTGHS_DEVCTRL_SPDCONF_Pos)
134 #define UOTGHS_DEVCTRL_SPDCONF_NORMAL (0x0u << 10)
135 #define UOTGHS_DEVCTRL_SPDCONF_LOW_POWER (0x1u << 10)
136 #define UOTGHS_DEVCTRL_SPDCONF_HIGH_SPEED (0x2u << 10)
137 #define UOTGHS_DEVCTRL_SPDCONF_FORCED_FS (0x3u << 10)
138 #define UOTGHS_DEVCTRL_LS (0x1u << 12)
139 #define UOTGHS_DEVCTRL_TSTJ (0x1u << 13)
140 #define UOTGHS_DEVCTRL_TSTK (0x1u << 14)
141 #define UOTGHS_DEVCTRL_TSTPCKT (0x1u << 15)
142 #define UOTGHS_DEVCTRL_OPMODE2 (0x1u << 16)
143 /* -------- UOTGHS_DEVISR : (UOTGHS Offset: 0x0004) Device Global Interrupt Status Register -------- */
144 #define UOTGHS_DEVISR_SUSP (0x1u << 0)
145 #define UOTGHS_DEVISR_MSOF (0x1u << 1)
146 #define UOTGHS_DEVISR_SOF (0x1u << 2)
147 #define UOTGHS_DEVISR_EORST (0x1u << 3)
148 #define UOTGHS_DEVISR_WAKEUP (0x1u << 4)
149 #define UOTGHS_DEVISR_EORSM (0x1u << 5)
150 #define UOTGHS_DEVISR_UPRSM (0x1u << 6)
151 #define UOTGHS_DEVISR_PEP_0 (0x1u << 12)
152 #define UOTGHS_DEVISR_PEP_1 (0x1u << 13)
153 #define UOTGHS_DEVISR_PEP_2 (0x1u << 14)
154 #define UOTGHS_DEVISR_PEP_3 (0x1u << 15)
155 #define UOTGHS_DEVISR_PEP_4 (0x1u << 16)
156 #define UOTGHS_DEVISR_PEP_5 (0x1u << 17)
157 #define UOTGHS_DEVISR_PEP_6 (0x1u << 18)
158 #define UOTGHS_DEVISR_PEP_7 (0x1u << 19)
159 #define UOTGHS_DEVISR_PEP_8 (0x1u << 20)
160 #define UOTGHS_DEVISR_PEP_9 (0x1u << 21)
161 #define UOTGHS_DEVISR_DMA_1 (0x1u << 25)
162 #define UOTGHS_DEVISR_DMA_2 (0x1u << 26)
163 #define UOTGHS_DEVISR_DMA_3 (0x1u << 27)
164 #define UOTGHS_DEVISR_DMA_4 (0x1u << 28)
165 #define UOTGHS_DEVISR_DMA_5 (0x1u << 29)
166 #define UOTGHS_DEVISR_DMA_6 (0x1u << 30)
167 /* -------- UOTGHS_DEVICR : (UOTGHS Offset: 0x0008) Device Global Interrupt Clear Register -------- */
168 #define UOTGHS_DEVICR_SUSPC (0x1u << 0)
169 #define UOTGHS_DEVICR_MSOFC (0x1u << 1)
170 #define UOTGHS_DEVICR_SOFC (0x1u << 2)
171 #define UOTGHS_DEVICR_EORSTC (0x1u << 3)
172 #define UOTGHS_DEVICR_WAKEUPC (0x1u << 4)
173 #define UOTGHS_DEVICR_EORSMC (0x1u << 5)
174 #define UOTGHS_DEVICR_UPRSMC (0x1u << 6)
175 /* -------- UOTGHS_DEVIFR : (UOTGHS Offset: 0x000C) Device Global Interrupt Set Register -------- */
176 #define UOTGHS_DEVIFR_SUSPS (0x1u << 0)
177 #define UOTGHS_DEVIFR_MSOFS (0x1u << 1)
178 #define UOTGHS_DEVIFR_SOFS (0x1u << 2)
179 #define UOTGHS_DEVIFR_EORSTS (0x1u << 3)
180 #define UOTGHS_DEVIFR_WAKEUPS (0x1u << 4)
181 #define UOTGHS_DEVIFR_EORSMS (0x1u << 5)
182 #define UOTGHS_DEVIFR_UPRSMS (0x1u << 6)
183 #define UOTGHS_DEVIFR_DMA_1 (0x1u << 25)
184 #define UOTGHS_DEVIFR_DMA_2 (0x1u << 26)
185 #define UOTGHS_DEVIFR_DMA_3 (0x1u << 27)
186 #define UOTGHS_DEVIFR_DMA_4 (0x1u << 28)
187 #define UOTGHS_DEVIFR_DMA_5 (0x1u << 29)
188 #define UOTGHS_DEVIFR_DMA_6 (0x1u << 30)
189 /* -------- UOTGHS_DEVIMR : (UOTGHS Offset: 0x0010) Device Global Interrupt Mask Register -------- */
190 #define UOTGHS_DEVIMR_SUSPE (0x1u << 0)
191 #define UOTGHS_DEVIMR_MSOFE (0x1u << 1)
192 #define UOTGHS_DEVIMR_SOFE (0x1u << 2)
193 #define UOTGHS_DEVIMR_EORSTE (0x1u << 3)
194 #define UOTGHS_DEVIMR_WAKEUPE (0x1u << 4)
195 #define UOTGHS_DEVIMR_EORSME (0x1u << 5)
196 #define UOTGHS_DEVIMR_UPRSME (0x1u << 6)
197 #define UOTGHS_DEVIMR_PEP_0 (0x1u << 12)
198 #define UOTGHS_DEVIMR_PEP_1 (0x1u << 13)
199 #define UOTGHS_DEVIMR_PEP_2 (0x1u << 14)
200 #define UOTGHS_DEVIMR_PEP_3 (0x1u << 15)
201 #define UOTGHS_DEVIMR_PEP_4 (0x1u << 16)
202 #define UOTGHS_DEVIMR_PEP_5 (0x1u << 17)
203 #define UOTGHS_DEVIMR_PEP_6 (0x1u << 18)
204 #define UOTGHS_DEVIMR_PEP_7 (0x1u << 19)
205 #define UOTGHS_DEVIMR_PEP_8 (0x1u << 20)
206 #define UOTGHS_DEVIMR_PEP_9 (0x1u << 21)
207 #define UOTGHS_DEVIMR_DMA_1 (0x1u << 25)
208 #define UOTGHS_DEVIMR_DMA_2 (0x1u << 26)
209 #define UOTGHS_DEVIMR_DMA_3 (0x1u << 27)
210 #define UOTGHS_DEVIMR_DMA_4 (0x1u << 28)
211 #define UOTGHS_DEVIMR_DMA_5 (0x1u << 29)
212 #define UOTGHS_DEVIMR_DMA_6 (0x1u << 30)
213 /* -------- UOTGHS_DEVIDR : (UOTGHS Offset: 0x0014) Device Global Interrupt Disable Register -------- */
214 #define UOTGHS_DEVIDR_SUSPEC (0x1u << 0)
215 #define UOTGHS_DEVIDR_MSOFEC (0x1u << 1)
216 #define UOTGHS_DEVIDR_SOFEC (0x1u << 2)
217 #define UOTGHS_DEVIDR_EORSTEC (0x1u << 3)
218 #define UOTGHS_DEVIDR_WAKEUPEC (0x1u << 4)
219 #define UOTGHS_DEVIDR_EORSMEC (0x1u << 5)
220 #define UOTGHS_DEVIDR_UPRSMEC (0x1u << 6)
221 #define UOTGHS_DEVIDR_PEP_0 (0x1u << 12)
222 #define UOTGHS_DEVIDR_PEP_1 (0x1u << 13)
223 #define UOTGHS_DEVIDR_PEP_2 (0x1u << 14)
224 #define UOTGHS_DEVIDR_PEP_3 (0x1u << 15)
225 #define UOTGHS_DEVIDR_PEP_4 (0x1u << 16)
226 #define UOTGHS_DEVIDR_PEP_5 (0x1u << 17)
227 #define UOTGHS_DEVIDR_PEP_6 (0x1u << 18)
228 #define UOTGHS_DEVIDR_PEP_7 (0x1u << 19)
229 #define UOTGHS_DEVIDR_PEP_8 (0x1u << 20)
230 #define UOTGHS_DEVIDR_PEP_9 (0x1u << 21)
231 #define UOTGHS_DEVIDR_DMA_1 (0x1u << 25)
232 #define UOTGHS_DEVIDR_DMA_2 (0x1u << 26)
233 #define UOTGHS_DEVIDR_DMA_3 (0x1u << 27)
234 #define UOTGHS_DEVIDR_DMA_4 (0x1u << 28)
235 #define UOTGHS_DEVIDR_DMA_5 (0x1u << 29)
236 #define UOTGHS_DEVIDR_DMA_6 (0x1u << 30)
237 /* -------- UOTGHS_DEVIER : (UOTGHS Offset: 0x0018) Device Global Interrupt Enable Register -------- */
238 #define UOTGHS_DEVIER_SUSPES (0x1u << 0)
239 #define UOTGHS_DEVIER_MSOFES (0x1u << 1)
240 #define UOTGHS_DEVIER_SOFES (0x1u << 2)
241 #define UOTGHS_DEVIER_EORSTES (0x1u << 3)
242 #define UOTGHS_DEVIER_WAKEUPES (0x1u << 4)
243 #define UOTGHS_DEVIER_EORSMES (0x1u << 5)
244 #define UOTGHS_DEVIER_UPRSMES (0x1u << 6)
245 #define UOTGHS_DEVIER_PEP_0 (0x1u << 12)
246 #define UOTGHS_DEVIER_PEP_1 (0x1u << 13)
247 #define UOTGHS_DEVIER_PEP_2 (0x1u << 14)
248 #define UOTGHS_DEVIER_PEP_3 (0x1u << 15)
249 #define UOTGHS_DEVIER_PEP_4 (0x1u << 16)
250 #define UOTGHS_DEVIER_PEP_5 (0x1u << 17)
251 #define UOTGHS_DEVIER_PEP_6 (0x1u << 18)
252 #define UOTGHS_DEVIER_PEP_7 (0x1u << 19)
253 #define UOTGHS_DEVIER_PEP_8 (0x1u << 20)
254 #define UOTGHS_DEVIER_PEP_9 (0x1u << 21)
255 #define UOTGHS_DEVIER_DMA_1 (0x1u << 25)
256 #define UOTGHS_DEVIER_DMA_2 (0x1u << 26)
257 #define UOTGHS_DEVIER_DMA_3 (0x1u << 27)
258 #define UOTGHS_DEVIER_DMA_4 (0x1u << 28)
259 #define UOTGHS_DEVIER_DMA_5 (0x1u << 29)
260 #define UOTGHS_DEVIER_DMA_6 (0x1u << 30)
261 /* -------- UOTGHS_DEVEPT : (UOTGHS Offset: 0x001C) Device Endpoint Register -------- */
262 #define UOTGHS_DEVEPT_EPEN0 (0x1u << 0)
263 #define UOTGHS_DEVEPT_EPEN1 (0x1u << 1)
264 #define UOTGHS_DEVEPT_EPEN2 (0x1u << 2)
265 #define UOTGHS_DEVEPT_EPEN3 (0x1u << 3)
266 #define UOTGHS_DEVEPT_EPEN4 (0x1u << 4)
267 #define UOTGHS_DEVEPT_EPEN5 (0x1u << 5)
268 #define UOTGHS_DEVEPT_EPEN6 (0x1u << 6)
269 #define UOTGHS_DEVEPT_EPEN7 (0x1u << 7)
270 #define UOTGHS_DEVEPT_EPEN8 (0x1u << 8)
271 #define UOTGHS_DEVEPT_EPRST0 (0x1u << 16)
272 #define UOTGHS_DEVEPT_EPRST1 (0x1u << 17)
273 #define UOTGHS_DEVEPT_EPRST2 (0x1u << 18)
274 #define UOTGHS_DEVEPT_EPRST3 (0x1u << 19)
275 #define UOTGHS_DEVEPT_EPRST4 (0x1u << 20)
276 #define UOTGHS_DEVEPT_EPRST5 (0x1u << 21)
277 #define UOTGHS_DEVEPT_EPRST6 (0x1u << 22)
278 #define UOTGHS_DEVEPT_EPRST7 (0x1u << 23)
279 #define UOTGHS_DEVEPT_EPRST8 (0x1u << 24)
280 /* -------- UOTGHS_DEVFNUM : (UOTGHS Offset: 0x0020) Device Frame Number Register -------- */
281 #define UOTGHS_DEVFNUM_MFNUM_Pos 0
282 #define UOTGHS_DEVFNUM_MFNUM_Msk (0x7u << UOTGHS_DEVFNUM_MFNUM_Pos)
283 #define UOTGHS_DEVFNUM_FNUM_Pos 3
284 #define UOTGHS_DEVFNUM_FNUM_Msk (0x7ffu << UOTGHS_DEVFNUM_FNUM_Pos)
285 #define UOTGHS_DEVFNUM_FNCERR (0x1u << 15)
286 /* -------- UOTGHS_DEVEPTCFG[10] : (UOTGHS Offset: 0x100) Device Endpoint Configuration Register (n = 0) -------- */
287 #define UOTGHS_DEVEPTCFG_ALLOC (0x1u << 1)
288 #define UOTGHS_DEVEPTCFG_EPBK_Pos 2
289 #define UOTGHS_DEVEPTCFG_EPBK_Msk (0x3u << UOTGHS_DEVEPTCFG_EPBK_Pos)
290 #define UOTGHS_DEVEPTCFG_EPBK_1_BANK (0x0u << 2)
291 #define UOTGHS_DEVEPTCFG_EPBK_2_BANK (0x1u << 2)
292 #define UOTGHS_DEVEPTCFG_EPBK_3_BANK (0x2u << 2)
293 #define UOTGHS_DEVEPTCFG_EPSIZE_Pos 4
294 #define UOTGHS_DEVEPTCFG_EPSIZE_Msk (0x7u << UOTGHS_DEVEPTCFG_EPSIZE_Pos)
295 #define UOTGHS_DEVEPTCFG_EPSIZE_8_BYTE (0x0u << 4)
296 #define UOTGHS_DEVEPTCFG_EPSIZE_16_BYTE (0x1u << 4)
297 #define UOTGHS_DEVEPTCFG_EPSIZE_32_BYTE (0x2u << 4)
298 #define UOTGHS_DEVEPTCFG_EPSIZE_64_BYTE (0x3u << 4)
299 #define UOTGHS_DEVEPTCFG_EPSIZE_128_BYTE (0x4u << 4)
300 #define UOTGHS_DEVEPTCFG_EPSIZE_256_BYTE (0x5u << 4)
301 #define UOTGHS_DEVEPTCFG_EPSIZE_512_BYTE (0x6u << 4)
302 #define UOTGHS_DEVEPTCFG_EPSIZE_1024_BYTE (0x7u << 4)
303 #define UOTGHS_DEVEPTCFG_EPDIR (0x1u << 8)
304 #define UOTGHS_DEVEPTCFG_EPDIR_OUT (0x0u << 8)
305 #define UOTGHS_DEVEPTCFG_EPDIR_IN (0x1u << 8)
306 #define UOTGHS_DEVEPTCFG_AUTOSW (0x1u << 9)
307 #define UOTGHS_DEVEPTCFG_EPTYPE_Pos 11
308 #define UOTGHS_DEVEPTCFG_EPTYPE_Msk (0x3u << UOTGHS_DEVEPTCFG_EPTYPE_Pos)
309 #define UOTGHS_DEVEPTCFG_EPTYPE_CTRL (0x0u << 11)
310 #define UOTGHS_DEVEPTCFG_EPTYPE_ISO (0x1u << 11)
311 #define UOTGHS_DEVEPTCFG_EPTYPE_BLK (0x2u << 11)
312 #define UOTGHS_DEVEPTCFG_EPTYPE_INTRPT (0x3u << 11)
313 #define UOTGHS_DEVEPTCFG_NBTRANS_Pos 13
314 #define UOTGHS_DEVEPTCFG_NBTRANS_Msk (0x3u << UOTGHS_DEVEPTCFG_NBTRANS_Pos)
315 #define UOTGHS_DEVEPTCFG_NBTRANS_0_TRANS (0x0u << 13)
316 #define UOTGHS_DEVEPTCFG_NBTRANS_1_TRANS (0x1u << 13)
317 #define UOTGHS_DEVEPTCFG_NBTRANS_2_TRANS (0x2u << 13)
318 #define UOTGHS_DEVEPTCFG_NBTRANS_3_TRANS (0x3u << 13)
319 /* -------- UOTGHS_DEVEPTISR[10] : (UOTGHS Offset: 0x130) Device Endpoint Status Register (n = 0) -------- */
320 #define UOTGHS_DEVEPTISR_TXINI (0x1u << 0)
321 #define UOTGHS_DEVEPTISR_RXOUTI (0x1u << 1)
322 #define UOTGHS_DEVEPTISR_RXSTPI (0x1u << 2)
323 #define UOTGHS_DEVEPTISR_UNDERFI (0x1u << 2)
324 #define UOTGHS_DEVEPTISR_NAKOUTI (0x1u << 3)
325 #define UOTGHS_DEVEPTISR_HBISOINERRI (0x1u << 3)
326 #define UOTGHS_DEVEPTISR_NAKINI (0x1u << 4)
327 #define UOTGHS_DEVEPTISR_HBISOFLUSHI (0x1u << 4)
328 #define UOTGHS_DEVEPTISR_OVERFI (0x1u << 5)
329 #define UOTGHS_DEVEPTISR_STALLEDI (0x1u << 6)
330 #define UOTGHS_DEVEPTISR_CRCERRI (0x1u << 6)
331 #define UOTGHS_DEVEPTISR_SHORTPACKET (0x1u << 7)
332 #define UOTGHS_DEVEPTISR_DTSEQ_Pos 8
333 #define UOTGHS_DEVEPTISR_DTSEQ_Msk (0x3u << UOTGHS_DEVEPTISR_DTSEQ_Pos)
334 #define UOTGHS_DEVEPTISR_DTSEQ_DATA0 (0x0u << 8)
335 #define UOTGHS_DEVEPTISR_DTSEQ_DATA1 (0x1u << 8)
336 #define UOTGHS_DEVEPTISR_DTSEQ_DATA2 (0x2u << 8)
337 #define UOTGHS_DEVEPTISR_DTSEQ_MDATA (0x3u << 8)
338 #define UOTGHS_DEVEPTISR_ERRORTRANS (0x1u << 10)
339 #define UOTGHS_DEVEPTISR_NBUSYBK_Pos 12
340 #define UOTGHS_DEVEPTISR_NBUSYBK_Msk (0x3u << UOTGHS_DEVEPTISR_NBUSYBK_Pos)
341 #define UOTGHS_DEVEPTISR_NBUSYBK_0_BUSY (0x0u << 12)
342 #define UOTGHS_DEVEPTISR_NBUSYBK_1_BUSY (0x1u << 12)
343 #define UOTGHS_DEVEPTISR_NBUSYBK_2_BUSY (0x2u << 12)
344 #define UOTGHS_DEVEPTISR_NBUSYBK_3_BUSY (0x3u << 12)
345 #define UOTGHS_DEVEPTISR_CURRBK_Pos 14
346 #define UOTGHS_DEVEPTISR_CURRBK_Msk (0x3u << UOTGHS_DEVEPTISR_CURRBK_Pos)
347 #define UOTGHS_DEVEPTISR_CURRBK_BANK0 (0x0u << 14)
348 #define UOTGHS_DEVEPTISR_CURRBK_BANK1 (0x1u << 14)
349 #define UOTGHS_DEVEPTISR_CURRBK_BANK2 (0x2u << 14)
350 #define UOTGHS_DEVEPTISR_RWALL (0x1u << 16)
351 #define UOTGHS_DEVEPTISR_CTRLDIR (0x1u << 17)
352 #define UOTGHS_DEVEPTISR_CFGOK (0x1u << 18)
353 #define UOTGHS_DEVEPTISR_BYCT_Pos 20
354 #define UOTGHS_DEVEPTISR_BYCT_Msk (0x7ffu << UOTGHS_DEVEPTISR_BYCT_Pos)
355 /* -------- UOTGHS_DEVEPTICR[10] : (UOTGHS Offset: 0x160) Device Endpoint Clear Register (n = 0) -------- */
356 #define UOTGHS_DEVEPTICR_TXINIC (0x1u << 0)
357 #define UOTGHS_DEVEPTICR_RXOUTIC (0x1u << 1)
358 #define UOTGHS_DEVEPTICR_RXSTPIC (0x1u << 2)
359 #define UOTGHS_DEVEPTICR_UNDERFIC (0x1u << 2)
360 #define UOTGHS_DEVEPTICR_NAKOUTIC (0x1u << 3)
361 #define UOTGHS_DEVEPTICR_HBISOINERRIC (0x1u << 3)
362 #define UOTGHS_DEVEPTICR_NAKINIC (0x1u << 4)
363 #define UOTGHS_DEVEPTICR_HBISOFLUSHIC (0x1u << 4)
364 #define UOTGHS_DEVEPTICR_OVERFIC (0x1u << 5)
365 #define UOTGHS_DEVEPTICR_STALLEDIC (0x1u << 6)
366 #define UOTGHS_DEVEPTICR_CRCERRIC (0x1u << 6)
367 #define UOTGHS_DEVEPTICR_SHORTPACKETC (0x1u << 7)
368 /* -------- UOTGHS_DEVEPTIFR[10] : (UOTGHS Offset: 0x190) Device Endpoint Set Register (n = 0) -------- */
369 #define UOTGHS_DEVEPTIFR_TXINIS (0x1u << 0)
370 #define UOTGHS_DEVEPTIFR_RXOUTIS (0x1u << 1)
371 #define UOTGHS_DEVEPTIFR_RXSTPIS (0x1u << 2)
372 #define UOTGHS_DEVEPTIFR_UNDERFIS (0x1u << 2)
373 #define UOTGHS_DEVEPTIFR_NAKOUTIS (0x1u << 3)
374 #define UOTGHS_DEVEPTIFR_HBISOINERRIS (0x1u << 3)
375 #define UOTGHS_DEVEPTIFR_NAKINIS (0x1u << 4)
376 #define UOTGHS_DEVEPTIFR_HBISOFLUSHIS (0x1u << 4)
377 #define UOTGHS_DEVEPTIFR_OVERFIS (0x1u << 5)
378 #define UOTGHS_DEVEPTIFR_STALLEDIS (0x1u << 6)
379 #define UOTGHS_DEVEPTIFR_CRCERRIS (0x1u << 6)
380 #define UOTGHS_DEVEPTIFR_SHORTPACKETS (0x1u << 7)
381 #define UOTGHS_DEVEPTIFR_NBUSYBKS (0x1u << 12)
382 /* -------- UOTGHS_DEVEPTIMR[10] : (UOTGHS Offset: 0x1C0) Device Endpoint Mask Register (n = 0) -------- */
383 #define UOTGHS_DEVEPTIMR_TXINE (0x1u << 0)
384 #define UOTGHS_DEVEPTIMR_RXOUTE (0x1u << 1)
385 #define UOTGHS_DEVEPTIMR_RXSTPE (0x1u << 2)
386 #define UOTGHS_DEVEPTIMR_UNDERFE (0x1u << 2)
387 #define UOTGHS_DEVEPTIMR_NAKOUTE (0x1u << 3)
388 #define UOTGHS_DEVEPTIMR_HBISOINERRE (0x1u << 3)
389 #define UOTGHS_DEVEPTIMR_NAKINE (0x1u << 4)
390 #define UOTGHS_DEVEPTIMR_HBISOFLUSHE (0x1u << 4)
391 #define UOTGHS_DEVEPTIMR_OVERFE (0x1u << 5)
392 #define UOTGHS_DEVEPTIMR_STALLEDE (0x1u << 6)
393 #define UOTGHS_DEVEPTIMR_CRCERRE (0x1u << 6)
394 #define UOTGHS_DEVEPTIMR_SHORTPACKETE (0x1u << 7)
395 #define UOTGHS_DEVEPTIMR_MDATAE (0x1u << 8)
396 #define UOTGHS_DEVEPTIMR_DATAXE (0x1u << 9)
397 #define UOTGHS_DEVEPTIMR_ERRORTRANSE (0x1u << 10)
398 #define UOTGHS_DEVEPTIMR_NBUSYBKE (0x1u << 12)
399 #define UOTGHS_DEVEPTIMR_KILLBK (0x1u << 13)
400 #define UOTGHS_DEVEPTIMR_FIFOCON (0x1u << 14)
401 #define UOTGHS_DEVEPTIMR_EPDISHDMA (0x1u << 16)
402 #define UOTGHS_DEVEPTIMR_NYETDIS (0x1u << 17)
403 #define UOTGHS_DEVEPTIMR_RSTDT (0x1u << 18)
404 #define UOTGHS_DEVEPTIMR_STALLRQ (0x1u << 19)
405 /* -------- UOTGHS_DEVEPTIER[10] : (UOTGHS Offset: 0x1F0) Device Endpoint Enable Register (n = 0) -------- */
406 #define UOTGHS_DEVEPTIER_TXINES (0x1u << 0)
407 #define UOTGHS_DEVEPTIER_RXOUTES (0x1u << 1)
408 #define UOTGHS_DEVEPTIER_RXSTPES (0x1u << 2)
409 #define UOTGHS_DEVEPTIER_UNDERFES (0x1u << 2)
410 #define UOTGHS_DEVEPTIER_NAKOUTES (0x1u << 3)
411 #define UOTGHS_DEVEPTIER_HBISOINERRES (0x1u << 3)
412 #define UOTGHS_DEVEPTIER_NAKINES (0x1u << 4)
413 #define UOTGHS_DEVEPTIER_HBISOFLUSHES (0x1u << 4)
414 #define UOTGHS_DEVEPTIER_OVERFES (0x1u << 5)
415 #define UOTGHS_DEVEPTIER_STALLEDES (0x1u << 6)
416 #define UOTGHS_DEVEPTIER_CRCERRES (0x1u << 6)
417 #define UOTGHS_DEVEPTIER_SHORTPACKETES (0x1u << 7)
418 #define UOTGHS_DEVEPTIER_MDATAES (0x1u << 8)
419 #define UOTGHS_DEVEPTIER_DATAXES (0x1u << 9)
420 #define UOTGHS_DEVEPTIER_ERRORTRANSES (0x1u << 10)
421 #define UOTGHS_DEVEPTIER_NBUSYBKES (0x1u << 12)
422 #define UOTGHS_DEVEPTIER_KILLBKS (0x1u << 13)
423 #define UOTGHS_DEVEPTIER_EPDISHDMAS (0x1u << 16)
424 #define UOTGHS_DEVEPTIER_NYETDISS (0x1u << 17)
425 #define UOTGHS_DEVEPTIER_RSTDTS (0x1u << 18)
426 #define UOTGHS_DEVEPTIER_STALLRQS (0x1u << 19)
427 /* -------- UOTGHS_DEVEPTIDR[10] : (UOTGHS Offset: 0x220) Device Endpoint Disable Register (n = 0) -------- */
428 #define UOTGHS_DEVEPTIDR_TXINEC (0x1u << 0)
429 #define UOTGHS_DEVEPTIDR_RXOUTEC (0x1u << 1)
430 #define UOTGHS_DEVEPTIDR_RXSTPEC (0x1u << 2)
431 #define UOTGHS_DEVEPTIDR_UNDERFEC (0x1u << 2)
432 #define UOTGHS_DEVEPTIDR_NAKOUTEC (0x1u << 3)
433 #define UOTGHS_DEVEPTIDR_HBISOINERREC (0x1u << 3)
434 #define UOTGHS_DEVEPTIDR_NAKINEC (0x1u << 4)
435 #define UOTGHS_DEVEPTIDR_HBISOFLUSHEC (0x1u << 4)
436 #define UOTGHS_DEVEPTIDR_OVERFEC (0x1u << 5)
437 #define UOTGHS_DEVEPTIDR_STALLEDEC (0x1u << 6)
438 #define UOTGHS_DEVEPTIDR_CRCERREC (0x1u << 6)
439 #define UOTGHS_DEVEPTIDR_SHORTPACKETEC (0x1u << 7)
440 #define UOTGHS_DEVEPTIDR_MDATEC (0x1u << 8)
441 #define UOTGHS_DEVEPTIDR_DATAXEC (0x1u << 9)
442 #define UOTGHS_DEVEPTIDR_ERRORTRANSEC (0x1u << 10)
443 #define UOTGHS_DEVEPTIDR_NBUSYBKEC (0x1u << 12)
444 #define UOTGHS_DEVEPTIDR_FIFOCONC (0x1u << 14)
445 #define UOTGHS_DEVEPTIDR_EPDISHDMAC (0x1u << 16)
446 #define UOTGHS_DEVEPTIDR_NYETDISC (0x1u << 17)
447 #define UOTGHS_DEVEPTIDR_STALLRQC (0x1u << 19)
448 /* -------- UOTGHS_DEVDMANXTDSC : (UOTGHS Offset: N/A) Device DMA Channel Next Descriptor Address Register -------- */
449 #define UOTGHS_DEVDMANXTDSC_NXT_DSC_ADD_Pos 0
450 #define UOTGHS_DEVDMANXTDSC_NXT_DSC_ADD_Msk (0xffffffffu << UOTGHS_DEVDMANXTDSC_NXT_DSC_ADD_Pos)
451 #define UOTGHS_DEVDMANXTDSC_NXT_DSC_ADD(value) ((UOTGHS_DEVDMANXTDSC_NXT_DSC_ADD_Msk & ((value) << UOTGHS_DEVDMANXTDSC_NXT_DSC_ADD_Pos)))
452 /* -------- UOTGHS_DEVDMAADDRESS : (UOTGHS Offset: N/A) Device DMA Channel Address Register -------- */
453 #define UOTGHS_DEVDMAADDRESS_BUFF_ADD_Pos 0
454 #define UOTGHS_DEVDMAADDRESS_BUFF_ADD_Msk (0xffffffffu << UOTGHS_DEVDMAADDRESS_BUFF_ADD_Pos)
455 #define UOTGHS_DEVDMAADDRESS_BUFF_ADD(value) ((UOTGHS_DEVDMAADDRESS_BUFF_ADD_Msk & ((value) << UOTGHS_DEVDMAADDRESS_BUFF_ADD_Pos)))
456 /* -------- UOTGHS_DEVDMACONTROL : (UOTGHS Offset: N/A) Device DMA Channel Control Register -------- */
457 #define UOTGHS_DEVDMACONTROL_CHANN_ENB (0x1u << 0)
458 #define UOTGHS_DEVDMACONTROL_LDNXT_DSC (0x1u << 1)
459 #define UOTGHS_DEVDMACONTROL_END_TR_EN (0x1u << 2)
460 #define UOTGHS_DEVDMACONTROL_END_B_EN (0x1u << 3)
461 #define UOTGHS_DEVDMACONTROL_END_TR_IT (0x1u << 4)
462 #define UOTGHS_DEVDMACONTROL_END_BUFFIT (0x1u << 5)
463 #define UOTGHS_DEVDMACONTROL_DESC_LD_IT (0x1u << 6)
464 #define UOTGHS_DEVDMACONTROL_BURST_LCK (0x1u << 7)
465 #define UOTGHS_DEVDMACONTROL_BUFF_LENGTH_Pos 16
466 #define UOTGHS_DEVDMACONTROL_BUFF_LENGTH_Msk (0xffffu << UOTGHS_DEVDMACONTROL_BUFF_LENGTH_Pos)
467 #define UOTGHS_DEVDMACONTROL_BUFF_LENGTH(value) ((UOTGHS_DEVDMACONTROL_BUFF_LENGTH_Msk & ((value) << UOTGHS_DEVDMACONTROL_BUFF_LENGTH_Pos)))
468 /* -------- UOTGHS_DEVDMASTATUS : (UOTGHS Offset: N/A) Device DMA Channel Status Register -------- */
469 #define UOTGHS_DEVDMASTATUS_CHANN_ENB (0x1u << 0)
470 #define UOTGHS_DEVDMASTATUS_CHANN_ACT (0x1u << 1)
471 #define UOTGHS_DEVDMASTATUS_END_TR_ST (0x1u << 4)
472 #define UOTGHS_DEVDMASTATUS_END_BF_ST (0x1u << 5)
473 #define UOTGHS_DEVDMASTATUS_DESC_LDST (0x1u << 6)
474 #define UOTGHS_DEVDMASTATUS_BUFF_COUNT_Pos 16
475 #define UOTGHS_DEVDMASTATUS_BUFF_COUNT_Msk (0xffffu << UOTGHS_DEVDMASTATUS_BUFF_COUNT_Pos)
476 #define UOTGHS_DEVDMASTATUS_BUFF_COUNT(value) ((UOTGHS_DEVDMASTATUS_BUFF_COUNT_Msk & ((value) << UOTGHS_DEVDMASTATUS_BUFF_COUNT_Pos)))
477 /* -------- UOTGHS_HSTCTRL : (UOTGHS Offset: 0x0400) Host General Control Register -------- */
478 #define UOTGHS_HSTCTRL_SOFE (0x1u << 8)
479 #define UOTGHS_HSTCTRL_RESET (0x1u << 9)
480 #define UOTGHS_HSTCTRL_RESUME (0x1u << 10)
481 #define UOTGHS_HSTCTRL_SPDCONF_Pos 12
482 #define UOTGHS_HSTCTRL_SPDCONF_Msk (0x3u << UOTGHS_HSTCTRL_SPDCONF_Pos)
483 #define UOTGHS_HSTCTRL_SPDCONF_NORMAL (0x0u << 12)
484 #define UOTGHS_HSTCTRL_SPDCONF_LOW_POWER (0x1u << 12)
485 #define UOTGHS_HSTCTRL_SPDCONF_HIGH_SPEED (0x2u << 12)
486 #define UOTGHS_HSTCTRL_SPDCONF_FORCED_FS (0x3u << 12)
487 /* -------- UOTGHS_HSTISR : (UOTGHS Offset: 0x0404) Host Global Interrupt Status Register -------- */
488 #define UOTGHS_HSTISR_DCONNI (0x1u << 0)
489 #define UOTGHS_HSTISR_DDISCI (0x1u << 1)
490 #define UOTGHS_HSTISR_RSTI (0x1u << 2)
491 #define UOTGHS_HSTISR_RSMEDI (0x1u << 3)
492 #define UOTGHS_HSTISR_RXRSMI (0x1u << 4)
493 #define UOTGHS_HSTISR_HSOFI (0x1u << 5)
494 #define UOTGHS_HSTISR_HWUPI (0x1u << 6)
495 #define UOTGHS_HSTISR_PEP_0 (0x1u << 8)
496 #define UOTGHS_HSTISR_PEP_1 (0x1u << 9)
497 #define UOTGHS_HSTISR_PEP_2 (0x1u << 10)
498 #define UOTGHS_HSTISR_PEP_3 (0x1u << 11)
499 #define UOTGHS_HSTISR_PEP_4 (0x1u << 12)
500 #define UOTGHS_HSTISR_PEP_5 (0x1u << 13)
501 #define UOTGHS_HSTISR_PEP_6 (0x1u << 14)
502 #define UOTGHS_HSTISR_PEP_7 (0x1u << 15)
503 #define UOTGHS_HSTISR_PEP_8 (0x1u << 16)
504 #define UOTGHS_HSTISR_PEP_9 (0x1u << 17)
505 #define UOTGHS_HSTISR_DMA_1 (0x1u << 25)
506 #define UOTGHS_HSTISR_DMA_2 (0x1u << 26)
507 #define UOTGHS_HSTISR_DMA_3 (0x1u << 27)
508 #define UOTGHS_HSTISR_DMA_4 (0x1u << 28)
509 #define UOTGHS_HSTISR_DMA_5 (0x1u << 29)
510 #define UOTGHS_HSTISR_DMA_6 (0x1u << 30)
511 /* -------- UOTGHS_HSTICR : (UOTGHS Offset: 0x0408) Host Global Interrupt Clear Register -------- */
512 #define UOTGHS_HSTICR_DCONNIC (0x1u << 0)
513 #define UOTGHS_HSTICR_DDISCIC (0x1u << 1)
514 #define UOTGHS_HSTICR_RSTIC (0x1u << 2)
515 #define UOTGHS_HSTICR_RSMEDIC (0x1u << 3)
516 #define UOTGHS_HSTICR_RXRSMIC (0x1u << 4)
517 #define UOTGHS_HSTICR_HSOFIC (0x1u << 5)
518 #define UOTGHS_HSTICR_HWUPIC (0x1u << 6)
519 /* -------- UOTGHS_HSTIFR : (UOTGHS Offset: 0x040C) Host Global Interrupt Set Register -------- */
520 #define UOTGHS_HSTIFR_DCONNIS (0x1u << 0)
521 #define UOTGHS_HSTIFR_DDISCIS (0x1u << 1)
522 #define UOTGHS_HSTIFR_RSTIS (0x1u << 2)
523 #define UOTGHS_HSTIFR_RSMEDIS (0x1u << 3)
524 #define UOTGHS_HSTIFR_RXRSMIS (0x1u << 4)
525 #define UOTGHS_HSTIFR_HSOFIS (0x1u << 5)
526 #define UOTGHS_HSTIFR_HWUPIS (0x1u << 6)
527 #define UOTGHS_HSTIFR_DMA_1 (0x1u << 25)
528 #define UOTGHS_HSTIFR_DMA_2 (0x1u << 26)
529 #define UOTGHS_HSTIFR_DMA_3 (0x1u << 27)
530 #define UOTGHS_HSTIFR_DMA_4 (0x1u << 28)
531 #define UOTGHS_HSTIFR_DMA_5 (0x1u << 29)
532 #define UOTGHS_HSTIFR_DMA_6 (0x1u << 30)
533 /* -------- UOTGHS_HSTIMR : (UOTGHS Offset: 0x0410) Host Global Interrupt Mask Register -------- */
534 #define UOTGHS_HSTIMR_DCONNIE (0x1u << 0)
535 #define UOTGHS_HSTIMR_DDISCIE (0x1u << 1)
536 #define UOTGHS_HSTIMR_RSTIE (0x1u << 2)
537 #define UOTGHS_HSTIMR_RSMEDIE (0x1u << 3)
538 #define UOTGHS_HSTIMR_RXRSMIE (0x1u << 4)
539 #define UOTGHS_HSTIMR_HSOFIE (0x1u << 5)
540 #define UOTGHS_HSTIMR_HWUPIE (0x1u << 6)
541 #define UOTGHS_HSTIMR_PEP_0 (0x1u << 8)
542 #define UOTGHS_HSTIMR_PEP_1 (0x1u << 9)
543 #define UOTGHS_HSTIMR_PEP_2 (0x1u << 10)
544 #define UOTGHS_HSTIMR_PEP_3 (0x1u << 11)
545 #define UOTGHS_HSTIMR_PEP_4 (0x1u << 12)
546 #define UOTGHS_HSTIMR_PEP_5 (0x1u << 13)
547 #define UOTGHS_HSTIMR_PEP_6 (0x1u << 14)
548 #define UOTGHS_HSTIMR_PEP_7 (0x1u << 15)
549 #define UOTGHS_HSTIMR_PEP_8 (0x1u << 16)
550 #define UOTGHS_HSTIMR_PEP_9 (0x1u << 17)
551 #define UOTGHS_HSTIMR_DMA_1 (0x1u << 25)
552 #define UOTGHS_HSTIMR_DMA_2 (0x1u << 26)
553 #define UOTGHS_HSTIMR_DMA_3 (0x1u << 27)
554 #define UOTGHS_HSTIMR_DMA_4 (0x1u << 28)
555 #define UOTGHS_HSTIMR_DMA_5 (0x1u << 29)
556 #define UOTGHS_HSTIMR_DMA_6 (0x1u << 30)
557 /* -------- UOTGHS_HSTIDR : (UOTGHS Offset: 0x0414) Host Global Interrupt Disable Register -------- */
558 #define UOTGHS_HSTIDR_DCONNIEC (0x1u << 0)
559 #define UOTGHS_HSTIDR_DDISCIEC (0x1u << 1)
560 #define UOTGHS_HSTIDR_RSTIEC (0x1u << 2)
561 #define UOTGHS_HSTIDR_RSMEDIEC (0x1u << 3)
562 #define UOTGHS_HSTIDR_RXRSMIEC (0x1u << 4)
563 #define UOTGHS_HSTIDR_HSOFIEC (0x1u << 5)
564 #define UOTGHS_HSTIDR_HWUPIEC (0x1u << 6)
565 #define UOTGHS_HSTIDR_PEP_0 (0x1u << 8)
566 #define UOTGHS_HSTIDR_PEP_1 (0x1u << 9)
567 #define UOTGHS_HSTIDR_PEP_2 (0x1u << 10)
568 #define UOTGHS_HSTIDR_PEP_3 (0x1u << 11)
569 #define UOTGHS_HSTIDR_PEP_4 (0x1u << 12)
570 #define UOTGHS_HSTIDR_PEP_5 (0x1u << 13)
571 #define UOTGHS_HSTIDR_PEP_6 (0x1u << 14)
572 #define UOTGHS_HSTIDR_PEP_7 (0x1u << 15)
573 #define UOTGHS_HSTIDR_PEP_8 (0x1u << 16)
574 #define UOTGHS_HSTIDR_PEP_9 (0x1u << 17)
575 #define UOTGHS_HSTIDR_DMA_1 (0x1u << 25)
576 #define UOTGHS_HSTIDR_DMA_2 (0x1u << 26)
577 #define UOTGHS_HSTIDR_DMA_3 (0x1u << 27)
578 #define UOTGHS_HSTIDR_DMA_4 (0x1u << 28)
579 #define UOTGHS_HSTIDR_DMA_5 (0x1u << 29)
580 #define UOTGHS_HSTIDR_DMA_6 (0x1u << 30)
581 /* -------- UOTGHS_HSTIER : (UOTGHS Offset: 0x0418) Host Global Interrupt Enable Register -------- */
582 #define UOTGHS_HSTIER_DCONNIES (0x1u << 0)
583 #define UOTGHS_HSTIER_DDISCIES (0x1u << 1)
584 #define UOTGHS_HSTIER_RSTIES (0x1u << 2)
585 #define UOTGHS_HSTIER_RSMEDIES (0x1u << 3)
586 #define UOTGHS_HSTIER_RXRSMIES (0x1u << 4)
587 #define UOTGHS_HSTIER_HSOFIES (0x1u << 5)
588 #define UOTGHS_HSTIER_HWUPIES (0x1u << 6)
589 #define UOTGHS_HSTIER_PEP_0 (0x1u << 8)
590 #define UOTGHS_HSTIER_PEP_1 (0x1u << 9)
591 #define UOTGHS_HSTIER_PEP_2 (0x1u << 10)
592 #define UOTGHS_HSTIER_PEP_3 (0x1u << 11)
593 #define UOTGHS_HSTIER_PEP_4 (0x1u << 12)
594 #define UOTGHS_HSTIER_PEP_5 (0x1u << 13)
595 #define UOTGHS_HSTIER_PEP_6 (0x1u << 14)
596 #define UOTGHS_HSTIER_PEP_7 (0x1u << 15)
597 #define UOTGHS_HSTIER_PEP_8 (0x1u << 16)
598 #define UOTGHS_HSTIER_PEP_9 (0x1u << 17)
599 #define UOTGHS_HSTIER_DMA_1 (0x1u << 25)
600 #define UOTGHS_HSTIER_DMA_2 (0x1u << 26)
601 #define UOTGHS_HSTIER_DMA_3 (0x1u << 27)
602 #define UOTGHS_HSTIER_DMA_4 (0x1u << 28)
603 #define UOTGHS_HSTIER_DMA_5 (0x1u << 29)
604 #define UOTGHS_HSTIER_DMA_6 (0x1u << 30)
605 /* -------- UOTGHS_HSTPIP : (UOTGHS Offset: 0x0041C) Host Pipe Register -------- */
606 #define UOTGHS_HSTPIP_PEN0 (0x1u << 0)
607 #define UOTGHS_HSTPIP_PEN1 (0x1u << 1)
608 #define UOTGHS_HSTPIP_PEN2 (0x1u << 2)
609 #define UOTGHS_HSTPIP_PEN3 (0x1u << 3)
610 #define UOTGHS_HSTPIP_PEN4 (0x1u << 4)
611 #define UOTGHS_HSTPIP_PEN5 (0x1u << 5)
612 #define UOTGHS_HSTPIP_PEN6 (0x1u << 6)
613 #define UOTGHS_HSTPIP_PEN7 (0x1u << 7)
614 #define UOTGHS_HSTPIP_PEN8 (0x1u << 8)
615 #define UOTGHS_HSTPIP_PRST0 (0x1u << 16)
616 #define UOTGHS_HSTPIP_PRST1 (0x1u << 17)
617 #define UOTGHS_HSTPIP_PRST2 (0x1u << 18)
618 #define UOTGHS_HSTPIP_PRST3 (0x1u << 19)
619 #define UOTGHS_HSTPIP_PRST4 (0x1u << 20)
620 #define UOTGHS_HSTPIP_PRST5 (0x1u << 21)
621 #define UOTGHS_HSTPIP_PRST6 (0x1u << 22)
622 #define UOTGHS_HSTPIP_PRST7 (0x1u << 23)
623 #define UOTGHS_HSTPIP_PRST8 (0x1u << 24)
624 /* -------- UOTGHS_HSTFNUM : (UOTGHS Offset: 0x0420) Host Frame Number Register -------- */
625 #define UOTGHS_HSTFNUM_MFNUM_Pos 0
626 #define UOTGHS_HSTFNUM_MFNUM_Msk (0x7u << UOTGHS_HSTFNUM_MFNUM_Pos)
627 #define UOTGHS_HSTFNUM_MFNUM(value) ((UOTGHS_HSTFNUM_MFNUM_Msk & ((value) << UOTGHS_HSTFNUM_MFNUM_Pos)))
628 #define UOTGHS_HSTFNUM_FNUM_Pos 3
629 #define UOTGHS_HSTFNUM_FNUM_Msk (0x7ffu << UOTGHS_HSTFNUM_FNUM_Pos)
630 #define UOTGHS_HSTFNUM_FNUM(value) ((UOTGHS_HSTFNUM_FNUM_Msk & ((value) << UOTGHS_HSTFNUM_FNUM_Pos)))
631 #define UOTGHS_HSTFNUM_FLENHIGH_Pos 16
632 #define UOTGHS_HSTFNUM_FLENHIGH_Msk (0xffu << UOTGHS_HSTFNUM_FLENHIGH_Pos)
633 #define UOTGHS_HSTFNUM_FLENHIGH(value) ((UOTGHS_HSTFNUM_FLENHIGH_Msk & ((value) << UOTGHS_HSTFNUM_FLENHIGH_Pos)))
634 /* -------- UOTGHS_HSTADDR1 : (UOTGHS Offset: 0x0424) Host Address 1 Register -------- */
635 #define UOTGHS_HSTADDR1_HSTADDRP0_Pos 0
636 #define UOTGHS_HSTADDR1_HSTADDRP0_Msk (0x7fu << UOTGHS_HSTADDR1_HSTADDRP0_Pos)
637 #define UOTGHS_HSTADDR1_HSTADDRP0(value) ((UOTGHS_HSTADDR1_HSTADDRP0_Msk & ((value) << UOTGHS_HSTADDR1_HSTADDRP0_Pos)))
638 #define UOTGHS_HSTADDR1_HSTADDRP1_Pos 8
639 #define UOTGHS_HSTADDR1_HSTADDRP1_Msk (0x7fu << UOTGHS_HSTADDR1_HSTADDRP1_Pos)
640 #define UOTGHS_HSTADDR1_HSTADDRP1(value) ((UOTGHS_HSTADDR1_HSTADDRP1_Msk & ((value) << UOTGHS_HSTADDR1_HSTADDRP1_Pos)))
641 #define UOTGHS_HSTADDR1_HSTADDRP2_Pos 16
642 #define UOTGHS_HSTADDR1_HSTADDRP2_Msk (0x7fu << UOTGHS_HSTADDR1_HSTADDRP2_Pos)
643 #define UOTGHS_HSTADDR1_HSTADDRP2(value) ((UOTGHS_HSTADDR1_HSTADDRP2_Msk & ((value) << UOTGHS_HSTADDR1_HSTADDRP2_Pos)))
644 #define UOTGHS_HSTADDR1_HSTADDRP3_Pos 24
645 #define UOTGHS_HSTADDR1_HSTADDRP3_Msk (0x7fu << UOTGHS_HSTADDR1_HSTADDRP3_Pos)
646 #define UOTGHS_HSTADDR1_HSTADDRP3(value) ((UOTGHS_HSTADDR1_HSTADDRP3_Msk & ((value) << UOTGHS_HSTADDR1_HSTADDRP3_Pos)))
647 /* -------- UOTGHS_HSTADDR2 : (UOTGHS Offset: 0x0428) Host Address 2 Register -------- */
648 #define UOTGHS_HSTADDR2_HSTADDRP4_Pos 0
649 #define UOTGHS_HSTADDR2_HSTADDRP4_Msk (0x7fu << UOTGHS_HSTADDR2_HSTADDRP4_Pos)
650 #define UOTGHS_HSTADDR2_HSTADDRP4(value) ((UOTGHS_HSTADDR2_HSTADDRP4_Msk & ((value) << UOTGHS_HSTADDR2_HSTADDRP4_Pos)))
651 #define UOTGHS_HSTADDR2_HSTADDRP5_Pos 8
652 #define UOTGHS_HSTADDR2_HSTADDRP5_Msk (0x7fu << UOTGHS_HSTADDR2_HSTADDRP5_Pos)
653 #define UOTGHS_HSTADDR2_HSTADDRP5(value) ((UOTGHS_HSTADDR2_HSTADDRP5_Msk & ((value) << UOTGHS_HSTADDR2_HSTADDRP5_Pos)))
654 #define UOTGHS_HSTADDR2_HSTADDRP6_Pos 16
655 #define UOTGHS_HSTADDR2_HSTADDRP6_Msk (0x7fu << UOTGHS_HSTADDR2_HSTADDRP6_Pos)
656 #define UOTGHS_HSTADDR2_HSTADDRP6(value) ((UOTGHS_HSTADDR2_HSTADDRP6_Msk & ((value) << UOTGHS_HSTADDR2_HSTADDRP6_Pos)))
657 #define UOTGHS_HSTADDR2_HSTADDRP7_Pos 24
658 #define UOTGHS_HSTADDR2_HSTADDRP7_Msk (0x7fu << UOTGHS_HSTADDR2_HSTADDRP7_Pos)
659 #define UOTGHS_HSTADDR2_HSTADDRP7(value) ((UOTGHS_HSTADDR2_HSTADDRP7_Msk & ((value) << UOTGHS_HSTADDR2_HSTADDRP7_Pos)))
660 /* -------- UOTGHS_HSTADDR3 : (UOTGHS Offset: 0x042C) Host Address 3 Register -------- */
661 #define UOTGHS_HSTADDR3_HSTADDRP8_Pos 0
662 #define UOTGHS_HSTADDR3_HSTADDRP8_Msk (0x7fu << UOTGHS_HSTADDR3_HSTADDRP8_Pos)
663 #define UOTGHS_HSTADDR3_HSTADDRP8(value) ((UOTGHS_HSTADDR3_HSTADDRP8_Msk & ((value) << UOTGHS_HSTADDR3_HSTADDRP8_Pos)))
664 #define UOTGHS_HSTADDR3_HSTADDRP9_Pos 8
665 #define UOTGHS_HSTADDR3_HSTADDRP9_Msk (0x7fu << UOTGHS_HSTADDR3_HSTADDRP9_Pos)
666 #define UOTGHS_HSTADDR3_HSTADDRP9(value) ((UOTGHS_HSTADDR3_HSTADDRP9_Msk & ((value) << UOTGHS_HSTADDR3_HSTADDRP9_Pos)))
667 /* -------- UOTGHS_HSTPIPCFG[10] : (UOTGHS Offset: 0x500) Host Pipe Configuration Register (n = 0) -------- */
668 #define UOTGHS_HSTPIPCFG_ALLOC (0x1u << 1)
669 #define UOTGHS_HSTPIPCFG_PBK_Pos 2
670 #define UOTGHS_HSTPIPCFG_PBK_Msk (0x3u << UOTGHS_HSTPIPCFG_PBK_Pos)
671 #define UOTGHS_HSTPIPCFG_PBK_1_BANK (0x0u << 2)
672 #define UOTGHS_HSTPIPCFG_PBK_2_BANK (0x1u << 2)
673 #define UOTGHS_HSTPIPCFG_PBK_3_BANK (0x2u << 2)
674 #define UOTGHS_HSTPIPCFG_PSIZE_Pos 4
675 #define UOTGHS_HSTPIPCFG_PSIZE_Msk (0x7u << UOTGHS_HSTPIPCFG_PSIZE_Pos)
676 #define UOTGHS_HSTPIPCFG_PSIZE_8_BYTE (0x0u << 4)
677 #define UOTGHS_HSTPIPCFG_PSIZE_16_BYTE (0x1u << 4)
678 #define UOTGHS_HSTPIPCFG_PSIZE_32_BYTE (0x2u << 4)
679 #define UOTGHS_HSTPIPCFG_PSIZE_64_BYTE (0x3u << 4)
680 #define UOTGHS_HSTPIPCFG_PSIZE_128_BYTE (0x4u << 4)
681 #define UOTGHS_HSTPIPCFG_PSIZE_256_BYTE (0x5u << 4)
682 #define UOTGHS_HSTPIPCFG_PSIZE_512_BYTE (0x6u << 4)
683 #define UOTGHS_HSTPIPCFG_PSIZE_1024_BYTE (0x7u << 4)
684 #define UOTGHS_HSTPIPCFG_PTOKEN_Pos 8
685 #define UOTGHS_HSTPIPCFG_PTOKEN_Msk (0x3u << UOTGHS_HSTPIPCFG_PTOKEN_Pos)
686 #define UOTGHS_HSTPIPCFG_PTOKEN_SETUP (0x0u << 8)
687 #define UOTGHS_HSTPIPCFG_PTOKEN_IN (0x1u << 8)
688 #define UOTGHS_HSTPIPCFG_PTOKEN_OUT (0x2u << 8)
689 #define UOTGHS_HSTPIPCFG_AUTOSW (0x1u << 10)
690 #define UOTGHS_HSTPIPCFG_PTYPE_Pos 12
691 #define UOTGHS_HSTPIPCFG_PTYPE_Msk (0x3u << UOTGHS_HSTPIPCFG_PTYPE_Pos)
692 #define UOTGHS_HSTPIPCFG_PTYPE_CTRL (0x0u << 12)
693 #define UOTGHS_HSTPIPCFG_PTYPE_ISO (0x1u << 12)
694 #define UOTGHS_HSTPIPCFG_PTYPE_BLK (0x2u << 12)
695 #define UOTGHS_HSTPIPCFG_PTYPE_INTRPT (0x3u << 12)
696 #define UOTGHS_HSTPIPCFG_PEPNUM_Pos 16
697 #define UOTGHS_HSTPIPCFG_PEPNUM_Msk (0xfu << UOTGHS_HSTPIPCFG_PEPNUM_Pos)
698 #define UOTGHS_HSTPIPCFG_PEPNUM(value) ((UOTGHS_HSTPIPCFG_PEPNUM_Msk & ((value) << UOTGHS_HSTPIPCFG_PEPNUM_Pos)))
699 #define UOTGHS_HSTPIPCFG_PINGEN (0x1u << 20)
700 #define UOTGHS_HSTPIPCFG_INTFRQ_Pos 24
701 #define UOTGHS_HSTPIPCFG_INTFRQ_Msk (0xffu << UOTGHS_HSTPIPCFG_INTFRQ_Pos)
702 #define UOTGHS_HSTPIPCFG_INTFRQ(value) ((UOTGHS_HSTPIPCFG_INTFRQ_Msk & ((value) << UOTGHS_HSTPIPCFG_INTFRQ_Pos)))
703 #define UOTGHS_HSTPIPCFG_BINTERVAL_Pos 24
704 #define UOTGHS_HSTPIPCFG_BINTERVAL_Msk (0xffu << UOTGHS_HSTPIPCFG_BINTERVAL_Pos)
705 #define UOTGHS_HSTPIPCFG_BINTERVAL(value) ((UOTGHS_HSTPIPCFG_BINTERVAL_Msk & ((value) << UOTGHS_HSTPIPCFG_BINTERVAL_Pos)))
706 /* -------- UOTGHS_HSTPIPISR[10] : (UOTGHS Offset: 0x530) Host Pipe Status Register (n = 0) -------- */
707 #define UOTGHS_HSTPIPISR_RXINI (0x1u << 0)
708 #define UOTGHS_HSTPIPISR_TXOUTI (0x1u << 1)
709 #define UOTGHS_HSTPIPISR_TXSTPI (0x1u << 2)
710 #define UOTGHS_HSTPIPISR_UNDERFI (0x1u << 2)
711 #define UOTGHS_HSTPIPISR_PERRI (0x1u << 3)
712 #define UOTGHS_HSTPIPISR_NAKEDI (0x1u << 4)
713 #define UOTGHS_HSTPIPISR_OVERFI (0x1u << 5)
714 #define UOTGHS_HSTPIPISR_RXSTALLDI (0x1u << 6)
715 #define UOTGHS_HSTPIPISR_CRCERRI (0x1u << 6)
716 #define UOTGHS_HSTPIPISR_SHORTPACKETI (0x1u << 7)
717 #define UOTGHS_HSTPIPISR_DTSEQ_Pos 8
718 #define UOTGHS_HSTPIPISR_DTSEQ_Msk (0x3u << UOTGHS_HSTPIPISR_DTSEQ_Pos)
719 #define UOTGHS_HSTPIPISR_DTSEQ_DATA0 (0x0u << 8)
720 #define UOTGHS_HSTPIPISR_DTSEQ_DATA1 (0x1u << 8)
721 #define UOTGHS_HSTPIPISR_NBUSYBK_Pos 12
722 #define UOTGHS_HSTPIPISR_NBUSYBK_Msk (0x3u << UOTGHS_HSTPIPISR_NBUSYBK_Pos)
723 #define UOTGHS_HSTPIPISR_NBUSYBK_0_BUSY (0x0u << 12)
724 #define UOTGHS_HSTPIPISR_NBUSYBK_1_BUSY (0x1u << 12)
725 #define UOTGHS_HSTPIPISR_NBUSYBK_2_BUSY (0x2u << 12)
726 #define UOTGHS_HSTPIPISR_NBUSYBK_3_BUSY (0x3u << 12)
727 #define UOTGHS_HSTPIPISR_CURRBK_Pos 14
728 #define UOTGHS_HSTPIPISR_CURRBK_Msk (0x3u << UOTGHS_HSTPIPISR_CURRBK_Pos)
729 #define UOTGHS_HSTPIPISR_CURRBK_BANK0 (0x0u << 14)
730 #define UOTGHS_HSTPIPISR_CURRBK_BANK1 (0x1u << 14)
731 #define UOTGHS_HSTPIPISR_CURRBK_BANK2 (0x2u << 14)
732 #define UOTGHS_HSTPIPISR_RWALL (0x1u << 16)
733 #define UOTGHS_HSTPIPISR_CFGOK (0x1u << 18)
734 #define UOTGHS_HSTPIPISR_PBYCT_Pos 20
735 #define UOTGHS_HSTPIPISR_PBYCT_Msk (0x7ffu << UOTGHS_HSTPIPISR_PBYCT_Pos)
736 /* -------- UOTGHS_HSTPIPICR[10] : (UOTGHS Offset: 0x560) Host Pipe Clear Register (n = 0) -------- */
737 #define UOTGHS_HSTPIPICR_RXINIC (0x1u << 0)
738 #define UOTGHS_HSTPIPICR_TXOUTIC (0x1u << 1)
739 #define UOTGHS_HSTPIPICR_TXSTPIC (0x1u << 2)
740 #define UOTGHS_HSTPIPICR_UNDERFIC (0x1u << 2)
741 #define UOTGHS_HSTPIPICR_NAKEDIC (0x1u << 4)
742 #define UOTGHS_HSTPIPICR_OVERFIC (0x1u << 5)
743 #define UOTGHS_HSTPIPICR_RXSTALLDIC (0x1u << 6)
744 #define UOTGHS_HSTPIPICR_CRCERRIC (0x1u << 6)
745 #define UOTGHS_HSTPIPICR_SHORTPACKETIC (0x1u << 7)
746 /* -------- UOTGHS_HSTPIPIFR[10] : (UOTGHS Offset: 0x590) Host Pipe Set Register (n = 0) -------- */
747 #define UOTGHS_HSTPIPIFR_RXINIS (0x1u << 0)
748 #define UOTGHS_HSTPIPIFR_TXOUTIS (0x1u << 1)
749 #define UOTGHS_HSTPIPIFR_TXSTPIS (0x1u << 2)
750 #define UOTGHS_HSTPIPIFR_UNDERFIS (0x1u << 2)
751 #define UOTGHS_HSTPIPIFR_PERRIS (0x1u << 3)
752 #define UOTGHS_HSTPIPIFR_NAKEDIS (0x1u << 4)
753 #define UOTGHS_HSTPIPIFR_OVERFIS (0x1u << 5)
754 #define UOTGHS_HSTPIPIFR_RXSTALLDIS (0x1u << 6)
755 #define UOTGHS_HSTPIPIFR_CRCERRIS (0x1u << 6)
756 #define UOTGHS_HSTPIPIFR_SHORTPACKETIS (0x1u << 7)
757 #define UOTGHS_HSTPIPIFR_NBUSYBKS (0x1u << 12)
758 /* -------- UOTGHS_HSTPIPIMR[10] : (UOTGHS Offset: 0x5C0) Host Pipe Mask Register (n = 0) -------- */
759 #define UOTGHS_HSTPIPIMR_RXINE (0x1u << 0)
760 #define UOTGHS_HSTPIPIMR_TXOUTE (0x1u << 1)
761 #define UOTGHS_HSTPIPIMR_TXSTPE (0x1u << 2)
762 #define UOTGHS_HSTPIPIMR_UNDERFIE (0x1u << 2)
763 #define UOTGHS_HSTPIPIMR_PERRE (0x1u << 3)
764 #define UOTGHS_HSTPIPIMR_NAKEDE (0x1u << 4)
765 #define UOTGHS_HSTPIPIMR_OVERFIE (0x1u << 5)
766 #define UOTGHS_HSTPIPIMR_RXSTALLDE (0x1u << 6)
767 #define UOTGHS_HSTPIPIMR_CRCERRE (0x1u << 6)
768 #define UOTGHS_HSTPIPIMR_SHORTPACKETIE (0x1u << 7)
769 #define UOTGHS_HSTPIPIMR_NBUSYBKE (0x1u << 12)
770 #define UOTGHS_HSTPIPIMR_FIFOCON (0x1u << 14)
771 #define UOTGHS_HSTPIPIMR_PDISHDMA (0x1u << 16)
772 #define UOTGHS_HSTPIPIMR_PFREEZE (0x1u << 17)
773 #define UOTGHS_HSTPIPIMR_RSTDT (0x1u << 18)
774 /* -------- UOTGHS_HSTPIPIER[10] : (UOTGHS Offset: 0x5F0) Host Pipe Enable Register (n = 0) -------- */
775 #define UOTGHS_HSTPIPIER_RXINES (0x1u << 0)
776 #define UOTGHS_HSTPIPIER_TXOUTES (0x1u << 1)
777 #define UOTGHS_HSTPIPIER_TXSTPES (0x1u << 2)
778 #define UOTGHS_HSTPIPIER_UNDERFIES (0x1u << 2)
779 #define UOTGHS_HSTPIPIER_PERRES (0x1u << 3)
780 #define UOTGHS_HSTPIPIER_NAKEDES (0x1u << 4)
781 #define UOTGHS_HSTPIPIER_OVERFIES (0x1u << 5)
782 #define UOTGHS_HSTPIPIER_RXSTALLDES (0x1u << 6)
783 #define UOTGHS_HSTPIPIER_CRCERRES (0x1u << 6)
784 #define UOTGHS_HSTPIPIER_SHORTPACKETIES (0x1u << 7)
785 #define UOTGHS_HSTPIPIER_NBUSYBKES (0x1u << 12)
786 #define UOTGHS_HSTPIPIER_PDISHDMAS (0x1u << 16)
787 #define UOTGHS_HSTPIPIER_PFREEZES (0x1u << 17)
788 #define UOTGHS_HSTPIPIER_RSTDTS (0x1u << 18)
789 /* -------- UOTGHS_HSTPIPIDR[10] : (UOTGHS Offset: 0x620) Host Pipe Disable Register (n = 0) -------- */
790 #define UOTGHS_HSTPIPIDR_RXINEC (0x1u << 0)
791 #define UOTGHS_HSTPIPIDR_TXOUTEC (0x1u << 1)
792 #define UOTGHS_HSTPIPIDR_TXSTPEC (0x1u << 2)
793 #define UOTGHS_HSTPIPIDR_UNDERFIEC (0x1u << 2)
794 #define UOTGHS_HSTPIPIDR_PERREC (0x1u << 3)
795 #define UOTGHS_HSTPIPIDR_NAKEDEC (0x1u << 4)
796 #define UOTGHS_HSTPIPIDR_OVERFIEC (0x1u << 5)
797 #define UOTGHS_HSTPIPIDR_RXSTALLDEC (0x1u << 6)
798 #define UOTGHS_HSTPIPIDR_CRCERREC (0x1u << 6)
799 #define UOTGHS_HSTPIPIDR_SHORTPACKETIEC (0x1u << 7)
800 #define UOTGHS_HSTPIPIDR_NBUSYBKEC (0x1u << 12)
801 #define UOTGHS_HSTPIPIDR_FIFOCONC (0x1u << 14)
802 #define UOTGHS_HSTPIPIDR_PDISHDMAC (0x1u << 16)
803 #define UOTGHS_HSTPIPIDR_PFREEZEC (0x1u << 17)
804 /* -------- UOTGHS_HSTPIPINRQ[10] : (UOTGHS Offset: 0x650) Host Pipe IN Request Register (n = 0) -------- */
805 #define UOTGHS_HSTPIPINRQ_INRQ_Pos 0
806 #define UOTGHS_HSTPIPINRQ_INRQ_Msk (0xffu << UOTGHS_HSTPIPINRQ_INRQ_Pos)
807 #define UOTGHS_HSTPIPINRQ_INRQ(value) ((UOTGHS_HSTPIPINRQ_INRQ_Msk & ((value) << UOTGHS_HSTPIPINRQ_INRQ_Pos)))
808 #define UOTGHS_HSTPIPINRQ_INMODE (0x1u << 8)
809 /* -------- UOTGHS_HSTPIPERR[10] : (UOTGHS Offset: 0x680) Host Pipe Error Register (n = 0) -------- */
810 #define UOTGHS_HSTPIPERR_DATATGL (0x1u << 0)
811 #define UOTGHS_HSTPIPERR_DATAPID (0x1u << 1)
812 #define UOTGHS_HSTPIPERR_PID (0x1u << 2)
813 #define UOTGHS_HSTPIPERR_TIMEOUT (0x1u << 3)
814 #define UOTGHS_HSTPIPERR_CRC16 (0x1u << 4)
815 #define UOTGHS_HSTPIPERR_COUNTER_Pos 5
816 #define UOTGHS_HSTPIPERR_COUNTER_Msk (0x3u << UOTGHS_HSTPIPERR_COUNTER_Pos)
817 #define UOTGHS_HSTPIPERR_COUNTER(value) ((UOTGHS_HSTPIPERR_COUNTER_Msk & ((value) << UOTGHS_HSTPIPERR_COUNTER_Pos)))
818 /* -------- UOTGHS_HSTDMANXTDSC : (UOTGHS Offset: N/A) Host DMA Channel Next Descriptor Address Register -------- */
819 #define UOTGHS_HSTDMANXTDSC_NXT_DSC_ADD_Pos 0
820 #define UOTGHS_HSTDMANXTDSC_NXT_DSC_ADD_Msk (0xffffffffu << UOTGHS_HSTDMANXTDSC_NXT_DSC_ADD_Pos)
821 #define UOTGHS_HSTDMANXTDSC_NXT_DSC_ADD(value) ((UOTGHS_HSTDMANXTDSC_NXT_DSC_ADD_Msk & ((value) << UOTGHS_HSTDMANXTDSC_NXT_DSC_ADD_Pos)))
822 /* -------- UOTGHS_HSTDMAADDRESS : (UOTGHS Offset: N/A) Host DMA Channel Address Register -------- */
823 #define UOTGHS_HSTDMAADDRESS_BUFF_ADD_Pos 0
824 #define UOTGHS_HSTDMAADDRESS_BUFF_ADD_Msk (0xffffffffu << UOTGHS_HSTDMAADDRESS_BUFF_ADD_Pos)
825 #define UOTGHS_HSTDMAADDRESS_BUFF_ADD(value) ((UOTGHS_HSTDMAADDRESS_BUFF_ADD_Msk & ((value) << UOTGHS_HSTDMAADDRESS_BUFF_ADD_Pos)))
826 /* -------- UOTGHS_HSTDMACONTROL : (UOTGHS Offset: N/A) Host DMA Channel Control Register -------- */
827 #define UOTGHS_HSTDMACONTROL_CHANN_ENB (0x1u << 0)
828 #define UOTGHS_HSTDMACONTROL_LDNXT_DSC (0x1u << 1)
829 #define UOTGHS_HSTDMACONTROL_END_TR_EN (0x1u << 2)
830 #define UOTGHS_HSTDMACONTROL_END_B_EN (0x1u << 3)
831 #define UOTGHS_HSTDMACONTROL_END_TR_IT (0x1u << 4)
832 #define UOTGHS_HSTDMACONTROL_END_BUFFIT (0x1u << 5)
833 #define UOTGHS_HSTDMACONTROL_DESC_LD_IT (0x1u << 6)
834 #define UOTGHS_HSTDMACONTROL_BURST_LCK (0x1u << 7)
835 #define UOTGHS_HSTDMACONTROL_BUFF_LENGTH_Pos 16
836 #define UOTGHS_HSTDMACONTROL_BUFF_LENGTH_Msk (0xffffu << UOTGHS_HSTDMACONTROL_BUFF_LENGTH_Pos)
837 #define UOTGHS_HSTDMACONTROL_BUFF_LENGTH(value) ((UOTGHS_HSTDMACONTROL_BUFF_LENGTH_Msk & ((value) << UOTGHS_HSTDMACONTROL_BUFF_LENGTH_Pos)))
838 /* -------- UOTGHS_HSTDMASTATUS : (UOTGHS Offset: N/A) Host DMA Channel Status Register -------- */
839 #define UOTGHS_HSTDMASTATUS_CHANN_ENB (0x1u << 0)
840 #define UOTGHS_HSTDMASTATUS_CHANN_ACT (0x1u << 1)
841 #define UOTGHS_HSTDMASTATUS_END_TR_ST (0x1u << 4)
842 #define UOTGHS_HSTDMASTATUS_END_BF_ST (0x1u << 5)
843 #define UOTGHS_HSTDMASTATUS_DESC_LDST (0x1u << 6)
844 #define UOTGHS_HSTDMASTATUS_BUFF_COUNT_Pos 16
845 #define UOTGHS_HSTDMASTATUS_BUFF_COUNT_Msk (0xffffu << UOTGHS_HSTDMASTATUS_BUFF_COUNT_Pos)
846 #define UOTGHS_HSTDMASTATUS_BUFF_COUNT(value) ((UOTGHS_HSTDMASTATUS_BUFF_COUNT_Msk & ((value) << UOTGHS_HSTDMASTATUS_BUFF_COUNT_Pos)))
847 /* -------- UOTGHS_CTRL : (UOTGHS Offset: 0x0800) General Control Register -------- */
848 #define UOTGHS_CTRL_IDTE (0x1u << 0)
849 #define UOTGHS_CTRL_VBUSTE (0x1u << 1)
850 #define UOTGHS_CTRL_SRPE (0x1u << 2)
851 #define UOTGHS_CTRL_VBERRE (0x1u << 3)
852 #define UOTGHS_CTRL_BCERRE (0x1u << 4)
853 #define UOTGHS_CTRL_ROLEEXE (0x1u << 5)
854 #define UOTGHS_CTRL_HNPERRE (0x1u << 6)
855 #define UOTGHS_CTRL_STOE (0x1u << 7)
856 #define UOTGHS_CTRL_VBUSHWC (0x1u << 8)
857 #define UOTGHS_CTRL_SRPSEL (0x1u << 9)
858 #define UOTGHS_CTRL_SRPREQ (0x1u << 10)
859 #define UOTGHS_CTRL_HNPREQ (0x1u << 11)
860 #define UOTGHS_CTRL_OTGPADE (0x1u << 12)
861 #define UOTGHS_CTRL_VBUSPO (0x1u << 13)
862 #define UOTGHS_CTRL_FRZCLK (0x1u << 14)
863 #define UOTGHS_CTRL_USBE (0x1u << 15)
864 #define UOTGHS_CTRL_TIMVALUE_Pos 16
865 #define UOTGHS_CTRL_TIMVALUE_Msk (0x3u << UOTGHS_CTRL_TIMVALUE_Pos)
866 #define UOTGHS_CTRL_TIMVALUE(value) ((UOTGHS_CTRL_TIMVALUE_Msk & ((value) << UOTGHS_CTRL_TIMVALUE_Pos)))
867 #define UOTGHS_CTRL_TIMPAGE_Pos 20
868 #define UOTGHS_CTRL_TIMPAGE_Msk (0x3u << UOTGHS_CTRL_TIMPAGE_Pos)
869 #define UOTGHS_CTRL_TIMPAGE(value) ((UOTGHS_CTRL_TIMPAGE_Msk & ((value) << UOTGHS_CTRL_TIMPAGE_Pos)))
870 #define UOTGHS_CTRL_UNLOCK (0x1u << 22)
871 #define UOTGHS_CTRL_UIDE (0x1u << 24)
872 #define UOTGHS_CTRL_UIDE_UIMOD (0x0u << 24)
873 #define UOTGHS_CTRL_UIDE_UOTGID (0x1u << 24)
874 #define UOTGHS_CTRL_UIMOD (0x1u << 25)
875 #define UOTGHS_CTRL_UIMOD_Host (0x0u << 25)
876 #define UOTGHS_CTRL_UIMOD_Device (0x1u << 25)
877 /* -------- UOTGHS_SR : (UOTGHS Offset: 0x0804) General Status Register -------- */
878 #define UOTGHS_SR_IDTI (0x1u << 0)
879 #define UOTGHS_SR_VBUSTI (0x1u << 1)
880 #define UOTGHS_SR_SRPI (0x1u << 2)
881 #define UOTGHS_SR_VBERRI (0x1u << 3)
882 #define UOTGHS_SR_BCERRI (0x1u << 4)
883 #define UOTGHS_SR_ROLEEXI (0x1u << 5)
884 #define UOTGHS_SR_HNPERRI (0x1u << 6)
885 #define UOTGHS_SR_STOI (0x1u << 7)
886 #define UOTGHS_SR_VBUSRQ (0x1u << 9)
887 #define UOTGHS_SR_ID (0x1u << 10)
888 #define UOTGHS_SR_VBUS (0x1u << 11)
889 #define UOTGHS_SR_SPEED_Pos 12
890 #define UOTGHS_SR_SPEED_Msk (0x3u << UOTGHS_SR_SPEED_Pos)
891 #define UOTGHS_SR_SPEED_FULL_SPEED (0x0u << 12)
892 #define UOTGHS_SR_SPEED_HIGH_SPEED (0x1u << 12)
893 #define UOTGHS_SR_SPEED_LOW_SPEED (0x2u << 12)
894 #define UOTGHS_SR_CLKUSABLE (0x1u << 14)
895 /* -------- UOTGHS_SCR : (UOTGHS Offset: 0x0808) General Status Clear Register -------- */
896 #define UOTGHS_SCR_IDTIC (0x1u << 0)
897 #define UOTGHS_SCR_VBUSTIC (0x1u << 1)
898 #define UOTGHS_SCR_SRPIC (0x1u << 2)
899 #define UOTGHS_SCR_VBERRIC (0x1u << 3)
900 #define UOTGHS_SCR_BCERRIC (0x1u << 4)
901 #define UOTGHS_SCR_ROLEEXIC (0x1u << 5)
902 #define UOTGHS_SCR_HNPERRIC (0x1u << 6)
903 #define UOTGHS_SCR_STOIC (0x1u << 7)
904 #define UOTGHS_SCR_VBUSRQC (0x1u << 9)
905 /* -------- UOTGHS_SFR : (UOTGHS Offset: 0x080C) General Status Set Register -------- */
906 #define UOTGHS_SFR_IDTIS (0x1u << 0)
907 #define UOTGHS_SFR_VBUSTIS (0x1u << 1)
908 #define UOTGHS_SFR_SRPIS (0x1u << 2)
909 #define UOTGHS_SFR_VBERRIS (0x1u << 3)
910 #define UOTGHS_SFR_BCERRIS (0x1u << 4)
911 #define UOTGHS_SFR_ROLEEXIS (0x1u << 5)
912 #define UOTGHS_SFR_HNPERRIS (0x1u << 6)
913 #define UOTGHS_SFR_STOIS (0x1u << 7)
914 #define UOTGHS_SFR_VBUSRQS (0x1u << 9)
915 /* -------- UOTGHS_FSM : (UOTGHS Offset: 0x082C) General Finite State Machine Register -------- */
916 #define UOTGHS_FSM_DRDSTATE_Pos 0
917 #define UOTGHS_FSM_DRDSTATE_Msk (0xfu << UOTGHS_FSM_DRDSTATE_Pos)
918 #define UOTGHS_FSM_DRDSTATE_A_IDLESTATE (0x0u << 0)
919 #define UOTGHS_FSM_DRDSTATE_A_WAIT_VRISE (0x1u << 0)
920 #define UOTGHS_FSM_DRDSTATE_A_WAIT_BCON (0x2u << 0)
921 #define UOTGHS_FSM_DRDSTATE_A_HOST (0x3u << 0)
922 #define UOTGHS_FSM_DRDSTATE_A_SUSPEND (0x4u << 0)
923 #define UOTGHS_FSM_DRDSTATE_A_PERIPHERAL (0x5u << 0)
924 #define UOTGHS_FSM_DRDSTATE_A_WAIT_VFALL (0x6u << 0)
925 #define UOTGHS_FSM_DRDSTATE_A_VBUS_ERR (0x7u << 0)
926 #define UOTGHS_FSM_DRDSTATE_A_WAIT_DISCHARGE (0x8u << 0)
927 #define UOTGHS_FSM_DRDSTATE_B_IDLE (0x9u << 0)
928 #define UOTGHS_FSM_DRDSTATE_B_PERIPHERAL (0xAu << 0)
929 #define UOTGHS_FSM_DRDSTATE_B_WAIT_BEGIN_HNP (0xBu << 0)
930 #define UOTGHS_FSM_DRDSTATE_B_WAIT_DISCHARGE (0xCu << 0)
931 #define UOTGHS_FSM_DRDSTATE_B_WAIT_ACON (0xDu << 0)
932 #define UOTGHS_FSM_DRDSTATE_B_HOST (0xEu << 0)
933 #define UOTGHS_FSM_DRDSTATE_B_SRP_INIT (0xFu << 0)
936 
937 
938 #endif /* _SAM3XA_UOTGHS_COMPONENT_ */
RwReg UOTGHS_DEVEPT
(Uotghs Offset: 0x001C) Device Endpoint Register
Definition: component_uotghs.h:65
RwReg UOTGHS_HSTFNUM
(Uotghs Offset: 0x0420) Host Frame Number Register
Definition: component_uotghs.h:92
RwReg UOTGHS_HSTDMACONTROL
(UotghsHstdma Offset: 0x8) Host DMA Channel Control Register
Definition: component_uotghs.h:51
RoReg UOTGHS_HSTISR
(Uotghs Offset: 0x0404) Host Global Interrupt Status Register
Definition: component_uotghs.h:85
WoReg UOTGHS_HSTICR
(Uotghs Offset: 0x0408) Host Global Interrupt Clear Register
Definition: component_uotghs.h:86
RwReg UOTGHS_HSTPIP
(Uotghs Offset: 0x0041C) Host Pipe Register
Definition: component_uotghs.h:91
RoReg UOTGHS_DEVIMR
(Uotghs Offset: 0x0010) Device Global Interrupt Mask Register
Definition: component_uotghs.h:62
WoReg UOTGHS_HSTIER
(Uotghs Offset: 0x0418) Host Global Interrupt Enable Register
Definition: component_uotghs.h:90
#define UOTGHSDEVDMA_NUMBER
Uotghs hardware registers.
Definition: component_uotghs.h:55
WoReg UOTGHS_HSTIFR
(Uotghs Offset: 0x040C) Host Global Interrupt Set Register
Definition: component_uotghs.h:87
RwReg UOTGHS_DEVDMASTATUS
(UotghsDevdma Offset: 0xC) Device DMA Channel Status Register
Definition: component_uotghs.h:45
RwReg UOTGHS_HSTADDR1
(Uotghs Offset: 0x0424) Host Address 1 Register
Definition: component_uotghs.h:93
volatile uint32_t RwReg
Definition: sam3n00a.h:54
RwReg UOTGHS_DEVCTRL
(Uotghs Offset: 0x0000) Device General Control Register
Definition: component_uotghs.h:58
RwReg UOTGHS_HSTDMANXTDSC
(UotghsHstdma Offset: 0x0) Host DMA Channel Next Descriptor Address Register
Definition: component_uotghs.h:49
Definition: component_uotghs.h:57
RwReg UOTGHS_CTRL
(Uotghs Offset: 0x0800) General Control Register
Definition: component_uotghs.h:117
volatile uint32_t WoReg
Definition: sam3n00a.h:53
RwReg UOTGHS_HSTCTRL
(Uotghs Offset: 0x0400) Host General Control Register
Definition: component_uotghs.h:84
RwReg UOTGHS_DEVDMACONTROL
(UotghsDevdma Offset: 0x8) Device DMA Channel Control Register
Definition: component_uotghs.h:44
RwReg UOTGHS_DEVDMAADDRESS
(UotghsDevdma Offset: 0x4) Device DMA Channel Address Register
Definition: component_uotghs.h:43
UotghsHstdma hardware registers.
Definition: component_uotghs.h:48
RoReg UOTGHS_DEVFNUM
(Uotghs Offset: 0x0020) Device Frame Number Register
Definition: component_uotghs.h:66
RoReg UOTGHS_SR
(Uotghs Offset: 0x0804) General Status Register
Definition: component_uotghs.h:118
RwReg UOTGHS_DEVDMANXTDSC
(UotghsDevdma Offset: 0x0) Device DMA Channel Next Descriptor Address Register
Definition: component_uotghs.h:42
RwReg UOTGHS_HSTDMAADDRESS
(UotghsHstdma Offset: 0x4) Host DMA Channel Address Register
Definition: component_uotghs.h:50
RwReg UOTGHS_HSTADDR2
(Uotghs Offset: 0x0428) Host Address 2 Register
Definition: component_uotghs.h:94
RoReg UOTGHS_HSTIMR
(Uotghs Offset: 0x0410) Host Global Interrupt Mask Register
Definition: component_uotghs.h:88
WoReg UOTGHS_HSTIDR
(Uotghs Offset: 0x0414) Host Global Interrupt Disable Register
Definition: component_uotghs.h:89
WoReg UOTGHS_DEVIER
(Uotghs Offset: 0x0018) Device Global Interrupt Enable Register
Definition: component_uotghs.h:64
RoReg UOTGHS_FSM
(Uotghs Offset: 0x082C) General Finite State Machine Register
Definition: component_uotghs.h:122
RwReg UOTGHS_HSTDMASTATUS
(UotghsHstdma Offset: 0xC) Host DMA Channel Status Register
Definition: component_uotghs.h:52
volatile const uint32_t RoReg
Definition: sam3n00a.h:49
WoReg UOTGHS_SCR
(Uotghs Offset: 0x0808) General Status Clear Register
Definition: component_uotghs.h:119
RwReg UOTGHS_HSTADDR3
(Uotghs Offset: 0x042C) Host Address 3 Register
Definition: component_uotghs.h:95
WoReg UOTGHS_DEVICR
(Uotghs Offset: 0x0008) Device Global Interrupt Clear Register
Definition: component_uotghs.h:60
WoReg UOTGHS_DEVIDR
(Uotghs Offset: 0x0014) Device Global Interrupt Disable Register
Definition: component_uotghs.h:63
RoReg UOTGHS_DEVISR
(Uotghs Offset: 0x0004) Device Global Interrupt Status Register
Definition: component_uotghs.h:59
WoReg UOTGHS_DEVIFR
(Uotghs Offset: 0x000C) Device Global Interrupt Set Register
Definition: component_uotghs.h:61
UotghsDevdma hardware registers.
Definition: component_uotghs.h:41
WoReg UOTGHS_SFR
(Uotghs Offset: 0x080C) General Status Set Register
Definition: component_uotghs.h:120