]> git.sur5r.net Git - freertos/blob - FreeRTOS/Demo/CORTEX_M7_SAMV71_Xplained/libchip_samv7/include/samv7/samv70n19.h
Update version number ready for V8.2.1 release.
[freertos] / FreeRTOS / Demo / CORTEX_M7_SAMV71_Xplained / libchip_samv7 / include / samv7 / samv70n19.h
1 /* ---------------------------------------------------------------------------- */\r
2 /*                  Atmel Microcontroller Software Support                      */\r
3 /*                       SAM Software Package License                           */\r
4 /* ---------------------------------------------------------------------------- */\r
5 /* Copyright (c) 2014, Atmel Corporation                                        */\r
6 /*                                                                              */\r
7 /* All rights reserved.                                                         */\r
8 /*                                                                              */\r
9 /* Redistribution and use in source and binary forms, with or without           */\r
10 /* modification, are permitted provided that the following condition is met:    */\r
11 /*                                                                              */\r
12 /* - Redistributions of source code must retain the above copyright notice,     */\r
13 /* this list of conditions and the disclaimer below.                            */\r
14 /*                                                                              */\r
15 /* Atmel's name may not be used to endorse or promote products derived from     */\r
16 /* this software without specific prior written permission.                     */\r
17 /*                                                                              */\r
18 /* DISCLAIMER:  THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR   */\r
19 /* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */\r
20 /* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE   */\r
21 /* DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT,      */\r
22 /* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT */\r
23 /* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,  */\r
24 /* OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF    */\r
25 /* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING         */\r
26 /* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, */\r
27 /* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.                           */\r
28 /* ---------------------------------------------------------------------------- */\r
29 \r
30 #ifndef _SAMV70N19_\r
31 #define _SAMV70N19_\r
32 \r
33 /** \addtogroup SAMV70N19_definitions SAMV70N19 definitions\r
34   This file defines all structures and symbols for SAMV70N19:\r
35     - registers and bitfields\r
36     - peripheral base address\r
37     - peripheral ID\r
38     - PIO definitions\r
39 */\r
40 /*@{*/\r
41 \r
42 #ifdef __cplusplus\r
43  extern "C" {\r
44 #endif\r
45 \r
46 #if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__))\r
47 #include <stdint.h>\r
48 #endif\r
49 \r
50 /* ************************************************************************** */\r
51 /*   CMSIS DEFINITIONS FOR SAMV70N19 */\r
52 /* ************************************************************************** */\r
53 /** \addtogroup SAMV70N19_cmsis CMSIS Definitions */\r
54 /*@{*/\r
55 \r
56 /**< Interrupt Number Definition */\r
57 typedef enum IRQn\r
58 {\r
59 /******  Cortex-M4 Processor Exceptions Numbers ******************************/\r
60   NonMaskableInt_IRQn   = -14, /**<  2 Non Maskable Interrupt                */\r
61   MemoryManagement_IRQn = -12, /**<  4 Cortex-M4 Memory Management Interrupt */\r
62   BusFault_IRQn         = -11, /**<  5 Cortex-M4 Bus Fault Interrupt         */\r
63   UsageFault_IRQn       = -10, /**<  6 Cortex-M4 Usage Fault Interrupt       */\r
64   SVCall_IRQn           = -5,  /**< 11 Cortex-M4 SV Call Interrupt           */\r
65   DebugMonitor_IRQn     = -4,  /**< 12 Cortex-M4 Debug Monitor Interrupt     */\r
66   PendSV_IRQn           = -2,  /**< 14 Cortex-M4 Pend SV Interrupt           */\r
67   SysTick_IRQn          = -1,  /**< 15 Cortex-M4 System Tick Interrupt       */\r
68 /******  SAMV70N19 specific Interrupt Numbers *********************************/\r
69 \r
70   SUPC_IRQn            =  0, /**<  0 SAMV70N19 Supply Controller (SUPC) */\r
71   RSTC_IRQn            =  1, /**<  1 SAMV70N19 Reset Controller (RSTC) */\r
72   RTC_IRQn             =  2, /**<  2 SAMV70N19 Real Time Clock (RTC) */\r
73   RTT_IRQn             =  3, /**<  3 SAMV70N19 Real Time Timer (RTT) */\r
74   WDT0_IRQn            =  4, /**<  4 SAMV70N19 Watchdog Timer 0 (WDT0) */\r
75   PMC_IRQn             =  5, /**<  5 SAMV70N19 Power Management Controller (PMC) */\r
76   EFC_IRQn             =  6, /**<  6 SAMV70N19 Enhanced Embedded Flash Controller (EFC) */\r
77   UART0_IRQn           =  7, /**<  7 SAMV70N19 UART 0 (UART0) */\r
78   UART1_IRQn           =  8, /**<  8 SAMV70N19 UART 1 (UART1) */\r
79   PIOA_IRQn            = 10, /**< 10 SAMV70N19 Parallel I/O Controller A (PIOA) */\r
80   PIOB_IRQn            = 11, /**< 11 SAMV70N19 Parallel I/O Controller B (PIOB) */\r
81   USART0_IRQn          = 13, /**< 13 SAMV70N19 USART 0 (USART0) */\r
82   USART1_IRQn          = 14, /**< 14 SAMV70N19 USART 1 (USART1) */\r
83   USART2_IRQn          = 15, /**< 15 SAMV70N19 USART 2 (USART2) */\r
84   PIOD_IRQn            = 16, /**< 16 SAMV70N19 Parallel I/O Controller D (PIOD) */\r
85   HSMCI_IRQn           = 18, /**< 18 SAMV70N19 Multimedia Card Interface (HSMCI) */\r
86   TWI0_IRQn            = 19, /**< 19 SAMV70N19 Two Wire Interface 0 HS (TWI0) */\r
87   TWI1_IRQn            = 20, /**< 20 SAMV70N19 Two Wire Interface 1 HS (TWI1) */\r
88   SPI0_IRQn            = 21, /**< 21 SAMV70N19 Serial Peripheral Interface 0 (SPI0) */\r
89   SSC_IRQn             = 22, /**< 22 SAMV70N19 Synchronous Serial Controller (SSC) */\r
90   TC0_IRQn             = 23, /**< 23 SAMV70N19 Timer/Counter 0 (TC0) */\r
91   TC1_IRQn             = 24, /**< 24 SAMV70N19 Timer/Counter 1 (TC1) */\r
92   TC2_IRQn             = 25, /**< 25 SAMV70N19 Timer/Counter 2 (TC2) */\r
93   AFEC0_IRQn           = 29, /**< 29 SAMV70N19 Analog Front End 0 (AFEC0) */\r
94   DACC_IRQn            = 30, /**< 30 SAMV70N19 Digital To Analog Converter (DACC) */\r
95   PWM0_IRQn            = 31, /**< 31 SAMV70N19 Pulse Width Modulation 0 (PWM0) */\r
96   ICM_IRQn             = 32, /**< 32 SAMV70N19 Integrity Check Monitor (ICM) */\r
97   ACC_IRQn             = 33, /**< 33 SAMV70N19 Analog Comparator (ACC) */\r
98   USBHS_IRQn           = 34, /**< 34 SAMV70N19 USB Host / Device Controller (USBHS) */\r
99   GMAC_IRQn            = 39, /**< 39 SAMV70N19 Ethernet MAC (GMAC) */\r
100   AFEC1_IRQn           = 40, /**< 40 SAMV70N19 Analog Front End 1 (AFEC1) */\r
101   TWI2_IRQn            = 41, /**< 41 SAMV70N19 Two Wire Interface 2 HS (TWI2) */\r
102   SPI1_IRQn            = 42, /**< 42 SAMV70N19 Serial Peripheral Interface 1 (SPI1) */\r
103   QSPI_IRQn            = 43, /**< 43 SAMV70N19 Quad I/O Serial Peripheral Interface (QSPI) */\r
104   UART2_IRQn           = 44, /**< 44 SAMV70N19 UART 2 (UART2) */\r
105   UART3_IRQn           = 45, /**< 45 SAMV70N19 UART 3 (UART3) */\r
106   UART4_IRQn           = 46, /**< 46 SAMV70N19 UART 4 (UART4) */\r
107   TC9_IRQn             = 50, /**< 50 SAMV70N19 Timer/Counter 9 (TC9) */\r
108   TC10_IRQn            = 51, /**< 51 SAMV70N19 Timer/Counter 10 (TC10) */\r
109   TC11_IRQn            = 52, /**< 52 SAMV70N19 Timer/Counter 11 (TC11) */\r
110   AES_IRQn             = 56, /**< 56 SAMV70N19 AES (AES) */\r
111   TRNG_IRQn            = 57, /**< 57 SAMV70N19 True Random Generator (TRNG) */\r
112   XDMAC_IRQn           = 58, /**< 58 SAMV70N19 DMA (XDMAC) */\r
113   ISI_IRQn             = 59, /**< 59 SAMV70N19 Camera Interface (ISI) */\r
114   PWM1_IRQn            = 60, /**< 60 SAMV70N19 Pulse Width Modulation 1 (PWM1) */\r
115   WDT1_IRQn            = 63, /**< 63 SAMV70N19 Watchdog Timer 1 (WDT1) */\r
116 \r
117   PERIPH_COUNT_IRQn    = 64  /**< Number of peripheral IDs */\r
118 } IRQn_Type;\r
119 \r
120 typedef struct _DeviceVectors\r
121 {\r
122   /* Stack pointer */\r
123   void* pvStack;\r
124 \r
125   /* Cortex-M handlers */\r
126   void* pfnReset_Handler;\r
127   void* pfnNMI_Handler;\r
128   void* pfnHardFault_Handler;\r
129   void* pfnMemManage_Handler;\r
130   void* pfnBusFault_Handler;\r
131   void* pfnUsageFault_Handler;\r
132   void* pfnReserved1_Handler;\r
133   void* pfnReserved2_Handler;\r
134   void* pfnReserved3_Handler;\r
135   void* pfnReserved4_Handler;\r
136   void* pfnSVC_Handler;\r
137   void* pfnDebugMon_Handler;\r
138   void* pfnReserved5_Handler;\r
139   void* pfnPendSV_Handler;\r
140   void* pfnSysTick_Handler;\r
141 \r
142   /* Peripheral handlers */\r
143   void* pfnSUPC_Handler;   /*  0 Supply Controller */\r
144   void* pfnRSTC_Handler;   /*  1 Reset Controller */\r
145   void* pfnRTC_Handler;    /*  2 Real Time Clock */\r
146   void* pfnRTT_Handler;    /*  3 Real Time Timer */\r
147   void* pfnWDT0_Handler;   /*  4 Watchdog Timer 0 */\r
148   void* pfnPMC_Handler;    /*  5 Power Management Controller */\r
149   void* pfnEFC_Handler;    /*  6 Enhanced Embedded Flash Controller */\r
150   void* pfnUART0_Handler;  /*  7 UART 0 */\r
151   void* pfnUART1_Handler;  /*  8 UART 1 */\r
152   void* pvReserved9;\r
153   void* pfnPIOA_Handler;   /* 10 Parallel I/O Controller A */\r
154   void* pfnPIOB_Handler;   /* 11 Parallel I/O Controller B */\r
155   void* pvReserved12;\r
156   void* pfnUSART0_Handler; /* 13 USART 0 */\r
157   void* pfnUSART1_Handler; /* 14 USART 1 */\r
158   void* pfnUSART2_Handler; /* 15 USART 2 */\r
159   void* pfnPIOD_Handler;   /* 16 Parallel I/O Controller D */\r
160   void* pvReserved17;\r
161   void* pfnHSMCI_Handler;  /* 18 Multimedia Card Interface */\r
162   void* pfnTWI0_Handler;   /* 19 Two Wire Interface 0 HS */\r
163   void* pfnTWI1_Handler;   /* 20 Two Wire Interface 1 HS */\r
164   void* pfnSPI0_Handler;   /* 21 Serial Peripheral Interface 0 */\r
165   void* pfnSSC_Handler;    /* 22 Synchronous Serial Controller */\r
166   void* pfnTC0_Handler;    /* 23 Timer/Counter 0 */\r
167   void* pfnTC1_Handler;    /* 24 Timer/Counter 1 */\r
168   void* pfnTC2_Handler;    /* 25 Timer/Counter 2 */\r
169   void* pvReserved26;\r
170   void* pvReserved27;\r
171   void* pvReserved28;\r
172   void* pfnAFEC0_Handler;  /* 29 Analog Front End 0 */\r
173   void* pfnDACC_Handler;   /* 30 Digital To Analog Converter */\r
174   void* pfnPWM0_Handler;   /* 31 Pulse Width Modulation 0 */\r
175   void* pfnICM_Handler;    /* 32 Integrity Check Monitor */\r
176   void* pfnACC_Handler;    /* 33 Analog Comparator */\r
177   void* pfnUSBHS_Handler;  /* 34 USB Host / Device Controller */\r
178   void* pvReserved35;\r
179   void* pvReserved36;\r
180   void* pvReserved37;\r
181   void* pvReserved38;\r
182   void* pfnGMAC_Handler;   /* 39 Ethernet MAC */\r
183   void* pfnAFEC1_Handler;  /* 40 Analog Front End 1 */\r
184   void* pfnTWI2_Handler;   /* 41 Two Wire Interface 2 HS */\r
185   void* pfnSPI1_Handler;   /* 42 Serial Peripheral Interface 1 */\r
186   void* pfnQSPI_Handler;   /* 43 Quad I/O Serial Peripheral Interface */\r
187   void* pfnUART2_Handler;  /* 44 UART 2 */\r
188   void* pfnUART3_Handler;  /* 45 UART 3 */\r
189   void* pfnUART4_Handler;  /* 46 UART 4 */\r
190   void* pvReserved47;\r
191   void* pvReserved48;\r
192   void* pvReserved49;\r
193   void* pfnTC9_Handler;    /* 50 Timer/Counter 9 */\r
194   void* pfnTC10_Handler;   /* 51 Timer/Counter 10 */\r
195   void* pfnTC11_Handler;   /* 52 Timer/Counter 11 */\r
196   void* pvReserved53;\r
197   void* pvReserved54;\r
198   void* pvReserved55;\r
199   void* pfnAES_Handler;    /* 56 AES */\r
200   void* pfnTRNG_Handler;   /* 57 True Random Generator */\r
201   void* pfnXDMAC_Handler;  /* 58 DMA */\r
202   void* pfnISI_Handler;    /* 59 Camera Interface */\r
203   void* pfnPWM1_Handler;   /* 60 Pulse Width Modulation 1 */\r
204   void* pvReserved61;\r
205   void* pvReserved62;\r
206   void* pfnWDT1_Handler;   /* 63 Watchdog Timer 1 */\r
207 } DeviceVectors;\r
208 \r
209 /* Cortex-M4 core handlers */\r
210 void Reset_Handler      ( void );\r
211 void NMI_Handler        ( void );\r
212 void HardFault_Handler  ( void );\r
213 void MemManage_Handler  ( void );\r
214 void BusFault_Handler   ( void );\r
215 void UsageFault_Handler ( void );\r
216 void SVC_Handler        ( void );\r
217 void DebugMon_Handler   ( void );\r
218 void PendSV_Handler     ( void );\r
219 void SysTick_Handler    ( void );\r
220 \r
221 /* Peripherals handlers */\r
222 void ACC_Handler        ( void );\r
223 void AES_Handler        ( void );\r
224 void AFEC0_Handler      ( void );\r
225 void AFEC1_Handler      ( void );\r
226 void DACC_Handler       ( void );\r
227 void EFC_Handler        ( void );\r
228 void GMAC_Handler       ( void );\r
229 void HSMCI_Handler      ( void );\r
230 void ICM_Handler        ( void );\r
231 void ISI_Handler        ( void );\r
232 void PIOA_Handler       ( void );\r
233 void PIOB_Handler       ( void );\r
234 void PIOD_Handler       ( void );\r
235 void PMC_Handler        ( void );\r
236 void PWM0_Handler       ( void );\r
237 void PWM1_Handler       ( void );\r
238 void QSPI_Handler       ( void );\r
239 void RSTC_Handler       ( void );\r
240 void RTC_Handler        ( void );\r
241 void RTT_Handler        ( void );\r
242 void SPI0_Handler       ( void );\r
243 void SPI1_Handler       ( void );\r
244 void SSC_Handler        ( void );\r
245 void SUPC_Handler       ( void );\r
246 void TC0_Handler        ( void );\r
247 void TC1_Handler        ( void );\r
248 void TC2_Handler        ( void );\r
249 void TC9_Handler        ( void );\r
250 void TC10_Handler       ( void );\r
251 void TC11_Handler       ( void );\r
252 void TRNG_Handler       ( void );\r
253 void TWI0_Handler       ( void );\r
254 void TWI1_Handler       ( void );\r
255 void TWI2_Handler       ( void );\r
256 void UART0_Handler      ( void );\r
257 void UART1_Handler      ( void );\r
258 void UART2_Handler      ( void );\r
259 void UART3_Handler      ( void );\r
260 void UART4_Handler      ( void );\r
261 void USART0_Handler     ( void );\r
262 void USART1_Handler     ( void );\r
263 void USART2_Handler     ( void );\r
264 void USBHS_Handler      ( void );\r
265 void WDT0_Handler       ( void );\r
266 void WDT1_Handler       ( void );\r
267 void XDMAC_Handler      ( void );\r
268 \r
269 /**\r
270  * \brief Configuration of the Cortex-M4 Processor and Core Peripherals\r
271  */\r
272 \r
273 #define __CM4_REV              0x0000 /**< SAMV70N19 core revision number ([15:8] revision number, [7:0] patch number) */\r
274 #define __MPU_PRESENT          1      /**< SAMV70N19 does provide a MPU */\r
275 #define __FPU_PRESENT          1      /**< SAMV70N19 does provide a FPU */\r
276 #define __NVIC_PRIO_BITS       3      /**< SAMV70N19 uses 3 Bits for the Priority Levels */\r
277 #define __Vendor_SysTickConfig 0      /**< Set to 1 if different SysTick Config is used */\r
278 \r
279 /*\r
280  * \brief CMSIS includes\r
281  */\r
282 \r
283 #include <core_cm4.h>\r
284 #if !defined DONT_USE_CMSIS_INIT\r
285 #include "system_sam.h"\r
286 #endif /* DONT_USE_CMSIS_INIT */\r
287 \r
288 /*@}*/\r
289 \r
290 /* ************************************************************************** */\r
291 /**  SOFTWARE PERIPHERAL API DEFINITION FOR SAMV70N19 */\r
292 /* ************************************************************************** */\r
293 /** \addtogroup SAMV70N19_api Peripheral Software API */\r
294 /*@{*/\r
295 \r
296 #include "component/component_acc.h"\r
297 #include "component/component_aes.h"\r
298 #include "component/component_afec.h"\r
299 #include "component/component_chipid.h"\r
300 #include "component/component_dacc.h"\r
301 #include "component/component_efc.h"\r
302 #include "component/component_gmac.h"\r
303 #include "component/component_gpbr.h"\r
304 #include "component/component_hsmci.h"\r
305 #include "component/component_icm.h"\r
306 #include "component/component_isi.h"\r
307 #include "component/component_matrix.h"\r
308 #include "component/component_pio.h"\r
309 #include "component/component_pmc.h"\r
310 #include "component/component_pwm.h"\r
311 #include "component/component_qspi.h"\r
312 #include "component/component_rstc.h"\r
313 #include "component/component_rtc.h"\r
314 #include "component/component_rtt.h"\r
315 #include "component/component_spi.h"\r
316 #include "component/component_ssc.h"\r
317 #include "component/component_supc.h"\r
318 #include "component/component_tc.h"\r
319 #include "component/component_trng.h"\r
320 #include "component/component_twi.h"\r
321 #include "component/component_twihs.h"\r
322 #include "component/component_uart.h"\r
323 #include "component/component_uotghs.h"\r
324 #include "component/component_usart.h"\r
325 #include "component/component_wdt.h"\r
326 #include "component/component_xdmac.h"\r
327 /*@}*/\r
328 \r
329 /* ************************************************************************** */\r
330 /*   REGISTER ACCESS DEFINITIONS FOR SAMV70N19 */\r
331 /* ************************************************************************** */\r
332 /** \addtogroup SAMV70N19_reg Registers Access Definitions */\r
333 /*@{*/\r
334 \r
335 #include "instance/instance_hsmci.h"\r
336 #include "instance/instance_ssc.h"\r
337 #include "instance/instance_spi0.h"\r
338 #include "instance/instance_tc0.h"\r
339 #include "instance/instance_twi0.h"\r
340 #include "instance/instance_twi1.h"\r
341 #include "instance/instance_pwm0.h"\r
342 #include "instance/instance_usart0.h"\r
343 #include "instance/instance_usart1.h"\r
344 #include "instance/instance_usart2.h"\r
345 #include "instance/instance_usbhs.h"\r
346 #include "instance/instance_afec0.h"\r
347 #include "instance/instance_dacc.h"\r
348 #include "instance/instance_acc.h"\r
349 #include "instance/instance_icm.h"\r
350 #include "instance/instance_isi.h"\r
351 #include "instance/instance_gmac.h"\r
352 #include "instance/instance_tc3.h"\r
353 #include "instance/instance_spi1.h"\r
354 #include "instance/instance_pwm1.h"\r
355 #include "instance/instance_twi2.h"\r
356 #include "instance/instance_afec1.h"\r
357 #include "instance/instance_aes.h"\r
358 #include "instance/instance_trng.h"\r
359 #include "instance/instance_xdmac.h"\r
360 #include "instance/instance_qspi.h"\r
361 #include "instance/instance_matrix.h"\r
362 #include "instance/instance_pmc.h"\r
363 #include "instance/instance_uart0.h"\r
364 #include "instance/instance_chipid.h"\r
365 #include "instance/instance_uart1.h"\r
366 #include "instance/instance_efc.h"\r
367 #include "instance/instance_pioa.h"\r
368 #include "instance/instance_piob.h"\r
369 #include "instance/instance_piod.h"\r
370 #include "instance/instance_rstc.h"\r
371 #include "instance/instance_supc.h"\r
372 #include "instance/instance_rtt.h"\r
373 #include "instance/instance_wdt0.h"\r
374 #include "instance/instance_rtc.h"\r
375 #include "instance/instance_gpbr.h"\r
376 #include "instance/instance_wdt1.h"\r
377 #include "instance/instance_uart2.h"\r
378 #include "instance/instance_uart3.h"\r
379 #include "instance/instance_uart4.h"\r
380 /*@}*/\r
381 \r
382 /* ************************************************************************** */\r
383 /*   PERIPHERAL ID DEFINITIONS FOR SAMV70N19 */\r
384 /* ************************************************************************** */\r
385 /** \addtogroup SAMV70N19_id Peripheral Ids Definitions */\r
386 /*@{*/\r
387 \r
388 #define ID_SUPC   ( 0) /**< \brief Supply Controller (SUPC) */\r
389 #define ID_RSTC   ( 1) /**< \brief Reset Controller (RSTC) */\r
390 #define ID_RTC    ( 2) /**< \brief Real Time Clock (RTC) */\r
391 #define ID_RTT    ( 3) /**< \brief Real Time Timer (RTT) */\r
392 #define ID_WDT0   ( 4) /**< \brief Watchdog Timer 0 (WDT0) */\r
393 #define ID_PMC    ( 5) /**< \brief Power Management Controller (PMC) */\r
394 #define ID_EFC    ( 6) /**< \brief Enhanced Embedded Flash Controller (EFC) */\r
395 #define ID_UART0  ( 7) /**< \brief UART 0 (UART0) */\r
396 #define ID_UART1  ( 8) /**< \brief UART 1 (UART1) */\r
397 #define ID_PIOA   (10) /**< \brief Parallel I/O Controller A (PIOA) */\r
398 #define ID_PIOB   (11) /**< \brief Parallel I/O Controller B (PIOB) */\r
399 #define ID_USART0 (13) /**< \brief USART 0 (USART0) */\r
400 #define ID_USART1 (14) /**< \brief USART 1 (USART1) */\r
401 #define ID_USART2 (15) /**< \brief USART 2 (USART2) */\r
402 #define ID_PIOD   (16) /**< \brief Parallel I/O Controller D (PIOD) */\r
403 #define ID_HSMCI  (18) /**< \brief Multimedia Card Interface (HSMCI) */\r
404 #define ID_TWI0   (19) /**< \brief Two Wire Interface 0 HS (TWI0) */\r
405 #define ID_TWI1   (20) /**< \brief Two Wire Interface 1 HS (TWI1) */\r
406 #define ID_SPI0   (21) /**< \brief Serial Peripheral Interface 0 (SPI0) */\r
407 #define ID_SSC    (22) /**< \brief Synchronous Serial Controller (SSC) */\r
408 #define ID_TC0    (23) /**< \brief Timer/Counter 0 (TC0) */\r
409 #define ID_TC1    (24) /**< \brief Timer/Counter 1 (TC1) */\r
410 #define ID_TC2    (25) /**< \brief Timer/Counter 2 (TC2) */\r
411 #define ID_AFEC0  (29) /**< \brief Analog Front End 0 (AFEC0) */\r
412 #define ID_DACC   (30) /**< \brief Digital To Analog Converter (DACC) */\r
413 #define ID_PWM0   (31) /**< \brief Pulse Width Modulation 0 (PWM0) */\r
414 #define ID_ICM    (32) /**< \brief Integrity Check Monitor (ICM) */\r
415 #define ID_ACC    (33) /**< \brief Analog Comparator (ACC) */\r
416 #define ID_USBHS  (34) /**< \brief USB Host / Device Controller (USBHS) */\r
417 #define ID_GMAC   (39) /**< \brief Ethernet MAC (GMAC) */\r
418 #define ID_AFEC1  (40) /**< \brief Analog Front End 1 (AFEC1) */\r
419 #define ID_TWI2   (41) /**< \brief Two Wire Interface 2 HS (TWI2) */\r
420 #define ID_SPI1   (42) /**< \brief Serial Peripheral Interface 1 (SPI1) */\r
421 #define ID_QSPI   (43) /**< \brief Quad I/O Serial Peripheral Interface (QSPI) */\r
422 #define ID_UART2  (44) /**< \brief UART 2 (UART2) */\r
423 #define ID_UART3  (45) /**< \brief UART 3 (UART3) */\r
424 #define ID_UART4  (46) /**< \brief UART 4 (UART4) */\r
425 #define ID_TC9    (50) /**< \brief Timer/Counter 9 (TC9) */\r
426 #define ID_TC10   (51) /**< \brief Timer/Counter 10 (TC10) */\r
427 #define ID_TC11   (52) /**< \brief Timer/Counter 11 (TC11) */\r
428 #define ID_AES    (56) /**< \brief AES (AES) */\r
429 #define ID_TRNG   (57) /**< \brief True Random Generator (TRNG) */\r
430 #define ID_XDMAC  (58) /**< \brief DMA (XDMAC) */\r
431 #define ID_ISI    (59) /**< \brief Camera Interface (ISI) */\r
432 #define ID_PWM1   (60) /**< \brief Pulse Width Modulation 1 (PWM1) */\r
433 #define ID_WDT1   (63) /**< \brief Watchdog Timer 1 (WDT1) */\r
434 \r
435 #define ID_PERIPH_COUNT (64) /**< \brief Number of peripheral IDs */\r
436 /*@}*/\r
437 \r
438 /* ************************************************************************** */\r
439 /*   BASE ADDRESS DEFINITIONS FOR SAMV70N19 */\r
440 /* ************************************************************************** */\r
441 /** \addtogroup SAMV70N19_base Peripheral Base Address Definitions */\r
442 /*@{*/\r
443 \r
444 #if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__))\r
445 #define HSMCI  (0x40000000U) /**< \brief (HSMCI ) Base Address */\r
446 #define SSC    (0x40004000U) /**< \brief (SSC   ) Base Address */\r
447 #define SPI0   (0x40008000U) /**< \brief (SPI0  ) Base Address */\r
448 #define TC0    (0x4000C000U) /**< \brief (TC0   ) Base Address */\r
449 #define TWI0   (0x40018000U) /**< \brief (TWI0  ) Base Address */\r
450 #define TWI1   (0x4001C000U) /**< \brief (TWI1  ) Base Address */\r
451 #define PWM0   (0x40020000U) /**< \brief (PWM0  ) Base Address */\r
452 #define USART0 (0x40024000U) /**< \brief (USART0) Base Address */\r
453 #define USART1 (0x40028000U) /**< \brief (USART1) Base Address */\r
454 #define USART2 (0x4002C000U) /**< \brief (USART2) Base Address */\r
455 #define USBHS  (0x40038000U) /**< \brief (USBHS ) Base Address */\r
456 #define AFEC0  (0x4003C000U) /**< \brief (AFEC0 ) Base Address */\r
457 #define DACC   (0x40040000U) /**< \brief (DACC  ) Base Address */\r
458 #define ACC    (0x40044000U) /**< \brief (ACC   ) Base Address */\r
459 #define ICM    (0x40048000U) /**< \brief (ICM   ) Base Address */\r
460 #define ISI    (0x4004C000U) /**< \brief (ISI   ) Base Address */\r
461 #define GMAC   (0x40050000U) /**< \brief (GMAC  ) Base Address */\r
462 #define TC3    (0x40054000U) /**< \brief (TC3   ) Base Address */\r
463 #define SPI1   (0x40058000U) /**< \brief (SPI1  ) Base Address */\r
464 #define PWM1   (0x4005C000U) /**< \brief (PWM1  ) Base Address */\r
465 #define TWI2   (0x40060000U) /**< \brief (TWI2  ) Base Address */\r
466 #define AFEC1  (0x40064000U) /**< \brief (AFEC1 ) Base Address */\r
467 #define AES    (0x4006C000U) /**< \brief (AES   ) Base Address */\r
468 #define TRNG   (0x40070000U) /**< \brief (TRNG  ) Base Address */\r
469 #define XDMAC  (0x40078000U) /**< \brief (XDMAC ) Base Address */\r
470 #define QSPI   (0x4007C000U) /**< \brief (QSPI  ) Base Address */\r
471 #define MATRIX (0x40088000U) /**< \brief (MATRIX) Base Address */\r
472 #define PMC    (0x400E0600U) /**< \brief (PMC   ) Base Address */\r
473 #define UART0  (0x400E0800U) /**< \brief (UART0 ) Base Address */\r
474 #define CHIPID (0x400E0940U) /**< \brief (CHIPID) Base Address */\r
475 #define UART1  (0x400E0A00U) /**< \brief (UART1 ) Base Address */\r
476 #define EFC    (0x400E0C00U) /**< \brief (EFC   ) Base Address */\r
477 #define PIOA   (0x400E0E00U) /**< \brief (PIOA  ) Base Address */\r
478 #define PIOB   (0x400E1000U) /**< \brief (PIOB  ) Base Address */\r
479 #define PIOD   (0x400E1400U) /**< \brief (PIOD  ) Base Address */\r
480 #define RSTC   (0x400E1800U) /**< \brief (RSTC  ) Base Address */\r
481 #define SUPC   (0x400E1810U) /**< \brief (SUPC  ) Base Address */\r
482 #define RTT    (0x400E1830U) /**< \brief (RTT   ) Base Address */\r
483 #define WDT0   (0x400E1850U) /**< \brief (WDT0  ) Base Address */\r
484 #define RTC    (0x400E1860U) /**< \brief (RTC   ) Base Address */\r
485 #define GPBR   (0x400E1890U) /**< \brief (GPBR  ) Base Address */\r
486 #define WDT1   (0x400E1900U) /**< \brief (WDT1  ) Base Address */\r
487 #define UART2  (0x400E1A00U) /**< \brief (UART2 ) Base Address */\r
488 #define UART3  (0x400E1C00U) /**< \brief (UART3 ) Base Address */\r
489 #define UART4  (0x400E1E00U) /**< \brief (UART4 ) Base Address */\r
490 #else\r
491 #define HSMCI  ((Hsmci  *)0x40000000U) /**< \brief (HSMCI ) Base Address */\r
492 #define SSC    ((Ssc    *)0x40004000U) /**< \brief (SSC   ) Base Address */\r
493 #define SPI0   ((Spi    *)0x40008000U) /**< \brief (SPI0  ) Base Address */\r
494 #define TC0    ((Tc     *)0x4000C000U) /**< \brief (TC0   ) Base Address */\r
495 #define TWI0   ((Twihs  *)0x40018000U) /**< \brief (TWI0  ) Base Address */\r
496 #define TWI1   ((Twi    *)0x4001C000U) /**< \brief (TWI1  ) Base Address */\r
497 #define PWM0   ((Pwm    *)0x40020000U) /**< \brief (PWM0  ) Base Address */\r
498 #define USART0 ((Usart  *)0x40024000U) /**< \brief (USART0) Base Address */\r
499 #define USART1 ((Usart  *)0x40028000U) /**< \brief (USART1) Base Address */\r
500 #define USART2 ((Usart  *)0x4002C000U) /**< \brief (USART2) Base Address */\r
501 #define USBHS  ((Uotghs *)0x40038000U) /**< \brief (USBHS ) Base Address */\r
502 #define AFEC0  ((Afec   *)0x4003C000U) /**< \brief (AFEC0 ) Base Address */\r
503 #define DACC   ((Dacc   *)0x40040000U) /**< \brief (DACC  ) Base Address */\r
504 #define ACC    ((Acc    *)0x40044000U) /**< \brief (ACC   ) Base Address */\r
505 #define ICM    ((Icm    *)0x40048000U) /**< \brief (ICM   ) Base Address */\r
506 #define ISI    ((Isi    *)0x4004C000U) /**< \brief (ISI   ) Base Address */\r
507 #define GMAC   ((Gmac   *)0x40050000U) /**< \brief (GMAC  ) Base Address */\r
508 #define TC3    ((Tc     *)0x40054000U) /**< \brief (TC3   ) Base Address */\r
509 #define SPI1   ((Spi    *)0x40058000U) /**< \brief (SPI1  ) Base Address */\r
510 #define PWM1   ((Pwm    *)0x4005C000U) /**< \brief (PWM1  ) Base Address */\r
511 #define TWI2   ((Twi    *)0x40060000U) /**< \brief (TWI2  ) Base Address */\r
512 #define AFEC1  ((Afec   *)0x40064000U) /**< \brief (AFEC1 ) Base Address */\r
513 #define AES    ((Aes    *)0x4006C000U) /**< \brief (AES   ) Base Address */\r
514 #define TRNG   ((Trng   *)0x40070000U) /**< \brief (TRNG  ) Base Address */\r
515 #define XDMAC  ((Xdmac  *)0x40078000U) /**< \brief (XDMAC ) Base Address */\r
516 #define QSPI   ((Qspi   *)0x4007C000U) /**< \brief (QSPI  ) Base Address */\r
517 #define MATRIX ((Matrix *)0x40088000U) /**< \brief (MATRIX) Base Address */\r
518 #define PMC    ((Pmc    *)0x400E0600U) /**< \brief (PMC   ) Base Address */\r
519 #define UART0  ((Uart   *)0x400E0800U) /**< \brief (UART0 ) Base Address */\r
520 #define CHIPID ((Chipid *)0x400E0940U) /**< \brief (CHIPID) Base Address */\r
521 #define UART1  ((Uart   *)0x400E0A00U) /**< \brief (UART1 ) Base Address */\r
522 #define EFC    ((Efc    *)0x400E0C00U) /**< \brief (EFC   ) Base Address */\r
523 #define PIOA   ((Pio    *)0x400E0E00U) /**< \brief (PIOA  ) Base Address */\r
524 #define PIOB   ((Pio    *)0x400E1000U) /**< \brief (PIOB  ) Base Address */\r
525 #define PIOD   ((Pio    *)0x400E1400U) /**< \brief (PIOD  ) Base Address */\r
526 #define RSTC   ((Rstc   *)0x400E1800U) /**< \brief (RSTC  ) Base Address */\r
527 #define SUPC   ((Supc   *)0x400E1810U) /**< \brief (SUPC  ) Base Address */\r
528 #define RTT    ((Rtt    *)0x400E1830U) /**< \brief (RTT   ) Base Address */\r
529 #define WDT0   ((Wdt    *)0x400E1850U) /**< \brief (WDT0  ) Base Address */\r
530 #define RTC    ((Rtc    *)0x400E1860U) /**< \brief (RTC   ) Base Address */\r
531 #define GPBR   ((Gpbr   *)0x400E1890U) /**< \brief (GPBR  ) Base Address */\r
532 #define WDT1   ((Wdt    *)0x400E1900U) /**< \brief (WDT1  ) Base Address */\r
533 #define UART2  ((Uart   *)0x400E1A00U) /**< \brief (UART2 ) Base Address */\r
534 #define UART3  ((Uart   *)0x400E1C00U) /**< \brief (UART3 ) Base Address */\r
535 #define UART4  ((Uart   *)0x400E1E00U) /**< \brief (UART4 ) Base Address */\r
536 #endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */\r
537 /*@}*/\r
538 \r
539 /* ************************************************************************** */\r
540 /*   PIO DEFINITIONS FOR SAMV70N19 */\r
541 /* ************************************************************************** */\r
542 /** \addtogroup SAMV70N19_pio Peripheral Pio Definitions */\r
543 /*@{*/\r
544 \r
545 #include "pio/pio_samv70n19.h"\r
546 /*@}*/\r
547 \r
548 /* ************************************************************************** */\r
549 /*   MEMORY MAPPING DEFINITIONS FOR SAMV70N19 */\r
550 /* ************************************************************************** */\r
551 \r
552 #define IFLASH_SIZE             (0x100000u)\r
553 #define IFLASH_PAGE_SIZE        (512u)\r
554 #define IFLASH_LOCK_REGION_SIZE (8192u)\r
555 #define IFLASH_NB_OF_PAGES      (1024u)\r
556 #define IFLASH_NB_OF_LOCK_BITS  (32u)\r
557 #define IRAM_SIZE               (0x60000u)\r
558 \r
559 #define QSPIMEM_ADDR  (0x80000000u) /**< QSPI Memory base address */\r
560 #define AXIMX_ADDR    (0xA0000000u) /**< AXI Bus Matrix base address */\r
561 #define ITCM_ADDR     (0x00000000u) /**< Instruction Tightly Coupled Memory base address */\r
562 #define IFLASH_ADDR   (0x00400000u) /**< Internal Flash base address */\r
563 #define IROM_ADDR     (0x00800000u) /**< Internal ROM base address */\r
564 #define DTCM_ADDR     (0x20000000u) /**< Data Tightly Coupled Memory base address */\r
565 #define IRAM_ADDR     (0x20400000u) /**< Internal RAM base address */\r
566 #define EBI_CS0_ADDR  (0x60000000u) /**< EBI Chip Select 0 base address */\r
567 #define EBI_CS1_ADDR  (0x61000000u) /**< EBI Chip Select 1 base address */\r
568 #define EBI_CS2_ADDR  (0x62000000u) /**< EBI Chip Select 2 base address */\r
569 #define EBI_CS3_ADDR  (0x63000000u) /**< EBI Chip Select 3 base address */\r
570 #define SDRAM_CS_ADDR (0x70000000u) /**< SDRAM Chip Select base address */\r
571 \r
572 /* ************************************************************************** */\r
573 /*   MISCELLANEOUS DEFINITIONS FOR SAMV70N19 */\r
574 /* ************************************************************************** */\r
575 \r
576 #define CHIP_JTAGID (0x05B3D03FUL)\r
577 #define CHIP_CIDR   (0xA13D0A00UL)\r
578 #define CHIP_EXID   (0x00000001UL)\r
579 \r
580 /* ************************************************************************** */\r
581 /*   ELECTRICAL DEFINITIONS FOR SAMV70N19 */\r
582 /* ************************************************************************** */\r
583 \r
584 /* Device characteristics */\r
585 #define CHIP_FREQ_SLCK_RC_MIN           (20000UL)\r
586 #define CHIP_FREQ_SLCK_RC               (32000UL)\r
587 #define CHIP_FREQ_SLCK_RC_MAX           (44000UL)\r
588 #define CHIP_FREQ_MAINCK_RC_4MHZ        (4000000UL)\r
589 #define CHIP_FREQ_MAINCK_RC_8MHZ        (8000000UL)\r
590 #define CHIP_FREQ_MAINCK_RC_12MHZ       (12000000UL)\r
591 #define CHIP_FREQ_CPU_MAX               (120000000UL)\r
592 #define CHIP_FREQ_XTAL_32K              (32768UL)\r
593 #define CHIP_FREQ_XTAL_12M              (12000000UL)\r
594 \r
595 /* Embedded Flash Write Wait State */\r
596 #define CHIP_FLASH_WRITE_WAIT_STATE     (6U)\r
597 \r
598 /* Embedded Flash Read Wait State (VDDCORE set at 1.20V) */\r
599 #define CHIP_FREQ_FWS_0                 (20000000UL)  /**< \brief Maximum operating frequency when FWS is 0 */\r
600 #define CHIP_FREQ_FWS_1                 (40000000UL)  /**< \brief Maximum operating frequency when FWS is 1 */\r
601 #define CHIP_FREQ_FWS_2                 (60000000UL)  /**< \brief Maximum operating frequency when FWS is 2 */\r
602 #define CHIP_FREQ_FWS_3                 (80000000UL)  /**< \brief Maximum operating frequency when FWS is 3 */\r
603 #define CHIP_FREQ_FWS_4                 (100000000UL) /**< \brief Maximum operating frequency when FWS is 4 */\r
604 #define CHIP_FREQ_FWS_5                 (123000000UL) /**< \brief Maximum operating frequency when FWS is 5 */\r
605 \r
606 #ifdef __cplusplus\r
607 }\r
608 #endif\r
609 \r
610 /*@}*/\r
611 \r
612 #endif /* _SAMV70N19_ */\r