46 #if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) 49 typedef volatile const uint32_t
RoReg;
51 typedef volatile uint32_t
RoReg;
53 typedef volatile uint32_t
WoReg;
54 typedef volatile uint32_t
RwReg;
120 void* pfnReset_Handler;
121 void* pfnNMI_Handler;
122 void* pfnHardFault_Handler;
123 void* pfnMemManage_Handler;
124 void* pfnBusFault_Handler;
125 void* pfnUsageFault_Handler;
126 void* pfnReserved1_Handler;
127 void* pfnReserved2_Handler;
128 void* pfnReserved3_Handler;
129 void* pfnReserved4_Handler;
130 void* pfnSVC_Handler;
131 void* pfnDebugMon_Handler;
132 void* pfnReserved5_Handler;
133 void* pfnPendSV_Handler;
134 void* pfnSysTick_Handler;
137 void* pfnSUPC_Handler;
138 void* pfnRSTC_Handler;
139 void* pfnRTC_Handler;
140 void* pfnRTT_Handler;
141 void* pfnWDT_Handler;
142 void* pfnPMC_Handler;
143 void* pfnEFC0_Handler;
144 void* pfnEFC1_Handler;
145 void* pfnUART_Handler;
148 void* pfnPIOA_Handler;
149 void* pfnPIOB_Handler;
154 void* pfnUSART0_Handler;
155 void* pfnUSART1_Handler;
156 void* pfnUSART2_Handler;
158 void* pfnHSMCI_Handler;
159 void* pfnTWI0_Handler;
160 void* pfnTWI1_Handler;
161 void* pfnSPI0_Handler;
163 void* pfnSSC_Handler;
164 void* pfnTC0_Handler;
165 void* pfnTC1_Handler;
166 void* pfnTC2_Handler;
167 void* pfnTC3_Handler;
168 void* pfnTC4_Handler;
169 void* pfnTC5_Handler;
173 void* pfnPWM_Handler;
174 void* pfnADC_Handler;
175 void* pfnDACC_Handler;
176 void* pfnDMAC_Handler;
177 void* pfnUOTGHS_Handler;
178 void* pfnTRNG_Handler;
180 void* pfnCAN0_Handler;
181 void* pfnCAN1_Handler;
186 void NMI_Handler (
void );
188 void MemManage_Handler (
void );
191 void SVC_Handler (
void );
192 void DebugMon_Handler (
void );
193 void PendSV_Handler (
void );
197 void ADC_Handler (
void );
198 void CAN0_Handler (
void );
199 void CAN1_Handler (
void );
200 void DACC_Handler (
void );
201 void DMAC_Handler (
void );
202 void EFC0_Handler (
void );
203 void EFC1_Handler (
void );
204 void HSMCI_Handler (
void );
205 void PIOA_Handler (
void );
206 void PIOB_Handler (
void );
207 void PMC_Handler (
void );
208 void PWM_Handler (
void );
209 void RSTC_Handler (
void );
210 void RTC_Handler (
void );
211 void RTT_Handler (
void );
212 void SPI0_Handler (
void );
213 void SSC_Handler (
void );
214 void SUPC_Handler (
void );
215 void TC0_Handler (
void );
216 void TC1_Handler (
void );
217 void TC2_Handler (
void );
218 void TC3_Handler (
void );
219 void TC4_Handler (
void );
220 void TC5_Handler (
void );
221 void TRNG_Handler (
void );
222 void TWI0_Handler (
void );
223 void TWI1_Handler (
void );
224 void UART_Handler (
void );
225 void UOTGHS_Handler (
void );
226 void USART0_Handler (
void );
227 void USART1_Handler (
void );
228 void USART2_Handler (
void );
229 void WDT_Handler (
void );
235 #define __CM3_REV 0x0200 236 #define __MPU_PRESENT 1 237 #define __NVIC_PRIO_BITS 4 238 #define __Vendor_SysTickConfig 0 245 #if !defined DONT_USE_CMSIS_INIT 257 #include "component/component_adc.h" 258 #include "component/component_can.h" 259 #include "component/component_chipid.h" 260 #include "component/component_dacc.h" 261 #include "component/component_dmac.h" 262 #include "component/component_efc.h" 263 #include "component/component_gpbr.h" 264 #include "component/component_hsmci.h" 265 #include "component/component_matrix.h" 266 #include "component/component_pdc.h" 267 #include "component/component_pio.h" 268 #include "component/component_pmc.h" 269 #include "component/component_pwm.h" 270 #include "component/component_rstc.h" 271 #include "component/component_rtc.h" 272 #include "component/component_rtt.h" 273 #include "component/component_spi.h" 274 #include "component/component_ssc.h" 275 #include "component/component_supc.h" 276 #include "component/component_tc.h" 277 #include "component/component_trng.h" 278 #include "component/component_twi.h" 279 #include "component/component_uart.h" 280 #include "component/component_uotghs.h" 281 #include "component/component_usart.h" 282 #include "component/component_wdt.h" 291 #include "instance/instance_hsmci.h" 292 #include "instance/instance_ssc.h" 293 #include "instance/instance_spi0.h" 294 #include "instance/instance_tc0.h" 295 #include "instance/instance_tc1.h" 296 #include "instance/instance_twi0.h" 297 #include "instance/instance_twi1.h" 298 #include "instance/instance_pwm.h" 299 #include "instance/instance_usart0.h" 300 #include "instance/instance_usart1.h" 301 #include "instance/instance_usart2.h" 302 #include "instance/instance_uotghs.h" 303 #include "instance/instance_can0.h" 304 #include "instance/instance_can1.h" 305 #include "instance/instance_trng.h" 306 #include "instance/instance_adc.h" 307 #include "instance/instance_dmac.h" 308 #include "instance/instance_dacc.h" 309 #include "instance/instance_matrix.h" 310 #include "instance/instance_pmc.h" 311 #include "instance/instance_uart.h" 312 #include "instance/instance_chipid.h" 313 #include "instance/instance_efc0.h" 314 #include "instance/instance_efc1.h" 315 #include "instance/instance_pioa.h" 316 #include "instance/instance_piob.h" 317 #include "instance/instance_rstc.h" 318 #include "instance/instance_supc.h" 319 #include "instance/instance_rtt.h" 320 #include "instance/instance_wdt.h" 321 #include "instance/instance_rtc.h" 322 #include "instance/instance_gpbr.h" 342 #define ID_USART0 (17) 343 #define ID_USART1 (18) 344 #define ID_USART2 (19) 345 #define ID_HSMCI (21) 360 #define ID_UOTGHS (40) 365 #define ID_PERIPH_COUNT (45) 374 #if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) 375 #define HSMCI (0x40000000U) 376 #define SSC (0x40004000U) 377 #define SPI0 (0x40008000U) 378 #define TC0 (0x40080000U) 379 #define TC1 (0x40084000U) 380 #define TWI0 (0x4008C000U) 381 #define PDC_TWI0 (0x4008C100U) 382 #define TWI1 (0x40090000U) 383 #define PDC_TWI1 (0x40090100U) 384 #define PWM (0x40094000U) 385 #define PDC_PWM (0x40094100U) 386 #define USART0 (0x40098000U) 387 #define PDC_USART0 (0x40098100U) 388 #define USART1 (0x4009C000U) 389 #define PDC_USART1 (0x4009C100U) 390 #define USART2 (0x400A0000U) 391 #define PDC_USART2 (0x400A0100U) 392 #define UOTGHS (0x400AC000U) 393 #define CAN0 (0x400B4000U) 394 #define CAN1 (0x400B8000U) 395 #define TRNG (0x400BC000U) 396 #define ADC (0x400C0000U) 397 #define PDC_ADC (0x400C0100U) 398 #define DMAC (0x400C4000U) 399 #define DACC (0x400C8000U) 400 #define PDC_DACC (0x400C8100U) 401 #define MATRIX (0x400E0400U) 402 #define PMC (0x400E0600U) 403 #define UART (0x400E0800U) 404 #define PDC_UART (0x400E0900U) 405 #define CHIPID (0x400E0940U) 406 #define EFC0 (0x400E0A00U) 407 #define EFC1 (0x400E0C00U) 408 #define PIOA (0x400E0E00U) 409 #define PIOB (0x400E1000U) 410 #define RSTC (0x400E1A00U) 411 #define SUPC (0x400E1A10U) 412 #define RTT (0x400E1A30U) 413 #define WDT (0x400E1A50U) 414 #define RTC (0x400E1A60U) 415 #define GPBR (0x400E1A90U) 417 #define HSMCI ((Hsmci *)0x40000000U) 418 #define SSC ((Ssc *)0x40004000U) 419 #define SPI0 ((Spi *)0x40008000U) 420 #define TC0 ((Tc *)0x40080000U) 421 #define TC1 ((Tc *)0x40084000U) 422 #define TWI0 ((Twi *)0x4008C000U) 423 #define PDC_TWI0 ((Pdc *)0x4008C100U) 424 #define TWI1 ((Twi *)0x40090000U) 425 #define PDC_TWI1 ((Pdc *)0x40090100U) 426 #define PWM ((Pwm *)0x40094000U) 427 #define PDC_PWM ((Pdc *)0x40094100U) 428 #define USART0 ((Usart *)0x40098000U) 429 #define PDC_USART0 ((Pdc *)0x40098100U) 430 #define USART1 ((Usart *)0x4009C000U) 431 #define PDC_USART1 ((Pdc *)0x4009C100U) 432 #define USART2 ((Usart *)0x400A0000U) 433 #define PDC_USART2 ((Pdc *)0x400A0100U) 434 #define UOTGHS ((Uotghs *)0x400AC000U) 435 #define CAN0 ((Can *)0x400B4000U) 436 #define CAN1 ((Can *)0x400B8000U) 437 #define TRNG ((Trng *)0x400BC000U) 438 #define ADC ((Adc *)0x400C0000U) 439 #define PDC_ADC ((Pdc *)0x400C0100U) 440 #define DMAC ((Dmac *)0x400C4000U) 441 #define DACC ((Dacc *)0x400C8000U) 442 #define PDC_DACC ((Pdc *)0x400C8100U) 443 #define MATRIX ((Matrix *)0x400E0400U) 444 #define PMC ((Pmc *)0x400E0600U) 445 #define UART ((Uart *)0x400E0800U) 446 #define PDC_UART ((Pdc *)0x400E0900U) 447 #define CHIPID ((Chipid *)0x400E0940U) 448 #define EFC0 ((Efc *)0x400E0A00U) 449 #define EFC1 ((Efc *)0x400E0C00U) 450 #define PIOA ((Pio *)0x400E0E00U) 451 #define PIOB ((Pio *)0x400E1000U) 452 #define RSTC ((Rstc *)0x400E1A00U) 453 #define SUPC ((Supc *)0x400E1A10U) 454 #define RTT ((Rtt *)0x400E1A30U) 455 #define WDT ((Wdt *)0x400E1A50U) 456 #define RTC ((Rtc *)0x400E1A60U) 457 #define GPBR ((Gpbr *)0x400E1A90U) 467 #include "pio/pio_sam3a4c.h" 474 #define IFLASH0_SIZE (0x20000u) 475 #define IFLASH0_PAGE_SIZE (256u) 476 #define IFLASH0_LOCK_REGION_SIZE (16384u) 477 #define IFLASH0_NB_OF_PAGES (512u) 478 #define IFLASH1_SIZE (0x20000u) 479 #define IFLASH1_PAGE_SIZE (256u) 480 #define IFLASH1_LOCK_REGION_SIZE (16384u) 481 #define IFLASH1_NB_OF_PAGES (512u) 482 #define IRAM0_SIZE (0x8000u) 483 #define IRAM1_SIZE (0x8000u) 484 #define IFLASH_SIZE (IFLASH0_SIZE+IFLASH1_SIZE) 485 #define IRAM_SIZE (IRAM0_SIZE+IRAM1_SIZE) 487 #define IFLASH0_ADDR (0x00080000u) 488 #if defined IFLASH0_SIZE 489 #define IFLASH1_ADDR (IFLASH0_ADDR+IFLASH0_SIZE) 491 #define IROM_ADDR (0x00100000u) 492 #define IRAM0_ADDR (0x20000000u) 493 #define IRAM1_ADDR (0x20080000u) 494 #define NFC_RAM_ADDR (0x20100000u) 495 #define UOTGHS_RAM_ADDR (0x20180000u) 496 #define EBI_CS0_ADDR (0x60000000u) 497 #define EBI_CS1_ADDR (0x61000000u) 498 #define EBI_CS2_ADDR (0x62000000u) 499 #define EBI_CS3_ADDR (0x63000000u) 500 #define EBI_CS4_ADDR (0x64000000u) 501 #define EBI_CS5_ADDR (0x65000000u) 502 #define EBI_CS6_ADDR (0x66000000u) 503 #define EBI_CS7_ADDR (0x67000000u) 510 #define CHIP_FREQ_SLCK_RC_MIN (20000UL) 511 #define CHIP_FREQ_SLCK_RC (32000UL) 512 #define CHIP_FREQ_SLCK_RC_MAX (44000UL) 513 #define CHIP_FREQ_MAINCK_RC_4MHZ (4000000UL) 514 #define CHIP_FREQ_MAINCK_RC_8MHZ (8000000UL) 515 #define CHIP_FREQ_MAINCK_RC_12MHZ (12000000UL) 516 #define CHIP_FREQ_CPU_MAX (84000000UL) 517 #define CHIP_FREQ_XTAL_32K (32768UL) 518 #define CHIP_FREQ_XTAL_12M (12000000UL) 521 #define CHIP_FLASH_WRITE_WAIT_STATE (6U) 524 #define CHIP_FREQ_FWS_0 (22500000UL) 525 #define CHIP_FREQ_FWS_1 (34000000UL) 526 #define CHIP_FREQ_FWS_2 (53000000UL) 527 #define CHIP_FREQ_FWS_3 (78000000UL)
Definition: sam3a4c.h:106
volatile const uint32_t RoReg
Definition: sam3a4c.h:49
Definition: sam3a4c.h:104
Definition: sam3a4c.h:107
Definition: sam3n00a.h:102
IRQn
Definition: ARMCM0.h:35
void Reset_Handler(void)
This is the code that gets called on processor reset. To initialize the device, and call the main() r...
Definition: startup_sam3n.c:172
void HardFault_Handler(void)
Definition: FreeRTOS_ARM.c:99
CMSIS Cortex-M3 Core Peripheral Access Layer Header File.
CMSIS Cortex-M# Device Peripheral Access Layer Header File for SAM3 devices.
void SysTick_Handler(void)
SysTick_Handler.
Definition: main.c:78
void UsageFault_Handler(void)
Definition: FreeRTOS_ARM.c:109
Definition: sam3a4c.h:103
volatile uint32_t WoReg
Definition: sam3a4c.h:53
volatile uint32_t RwReg
Definition: sam3a4c.h:54
Definition: sam3a4c.h:100
void BusFault_Handler(void)
Definition: FreeRTOS_ARM.c:104
Definition: sam3a4c.h:101
Definition: sam3a4c.h:102
Definition: sam3a4c.h:108
Definition: sam3a4c.h:109
Definition: sam3a4c.h:105
Definition: sam3a4c.h:111