The official mbed C/C SDK provides the software platform and libraries to build your applications.

Fork of mbed by mbed official

Committer:
Mikchel
Date:
Sun May 03 16:04:42 2015 +0000
Revision:
99:7f6c6de930c0
Parent:
93:e188a91d3eaa
12

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Kojto 93:e188a91d3eaa 1 /****************************************************************************************************//**
Kojto 93:e188a91d3eaa 2 * $Id$ LPC407x_8x_177x_8x.h 2012-04-25
Kojto 93:e188a91d3eaa 3 *//**
Kojto 93:e188a91d3eaa 4 * @file LPC407x_8x_177x_8x.h
Kojto 93:e188a91d3eaa 5 *
Kojto 93:e188a91d3eaa 6 * @brief CMSIS Cortex-M4 Cortex-M3 Peripheral Access Layer Header File for
Kojto 93:e188a91d3eaa 7 * NXP LPC407x_8x_177x_8x.
Kojto 93:e188a91d3eaa 8 * @version V0.7
Kojto 93:e188a91d3eaa 9 * @date 20. June 2012
Kojto 93:e188a91d3eaa 10 * @author NXP MCU SW Application Team
Kojto 93:e188a91d3eaa 11 *
Kojto 93:e188a91d3eaa 12 * Copyright(C) 2012, NXP Semiconductor
Kojto 93:e188a91d3eaa 13 * All rights reserved.
Kojto 93:e188a91d3eaa 14 *
Kojto 93:e188a91d3eaa 15 ***********************************************************************
Kojto 93:e188a91d3eaa 16 * Software that is described herein is for illustrative purposes only
Kojto 93:e188a91d3eaa 17 * which provides customers with programming information regarding the
Kojto 93:e188a91d3eaa 18 * products. This software is supplied "AS IS" without any warranties.
Kojto 93:e188a91d3eaa 19 * NXP Semiconductors assumes no responsibility or liability for the
Kojto 93:e188a91d3eaa 20 * use of the software, conveys no license or title under any patent,
Kojto 93:e188a91d3eaa 21 * copyright, or mask work right to the product. NXP Semiconductors
Kojto 93:e188a91d3eaa 22 * reserves the right to make changes in the software without
Kojto 93:e188a91d3eaa 23 * notification. NXP Semiconductors also make no representation or
Kojto 93:e188a91d3eaa 24 * warranty that such application will be suitable for the specified
Kojto 93:e188a91d3eaa 25 * use without further testing or modification.
Kojto 93:e188a91d3eaa 26 * Permission to use, copy, modify, and distribute this software and its
Kojto 93:e188a91d3eaa 27 * documentation is hereby granted, under NXP Semiconductors'
Kojto 93:e188a91d3eaa 28 * relevant copyright in the software, without fee, provided that it
Kojto 93:e188a91d3eaa 29 * is used in conjunction with NXP Semiconductors microcontrollers. This
Kojto 93:e188a91d3eaa 30 * copyright, permission, and disclaimer notice must appear in all copies of
Kojto 93:e188a91d3eaa 31 * this code.
Kojto 93:e188a91d3eaa 32 **********************************************************************/
Kojto 93:e188a91d3eaa 33
Kojto 93:e188a91d3eaa 34 #ifndef __LPC407x_8x_177x_8x_H__
Kojto 93:e188a91d3eaa 35 #define __LPC407x_8x_177x_8x_H__
Kojto 93:e188a91d3eaa 36
Kojto 93:e188a91d3eaa 37 #if defined(__CORTEX_M4) && !defined(CORE_M4)
Kojto 93:e188a91d3eaa 38 #define CORE_M4
Kojto 93:e188a91d3eaa 39 #endif
Kojto 93:e188a91d3eaa 40
Kojto 93:e188a91d3eaa 41 // ##################
Kojto 93:e188a91d3eaa 42 // Code Red - excluded extern "C" as unrequired
Kojto 93:e188a91d3eaa 43 // ##################
Kojto 93:e188a91d3eaa 44 #if 0
Kojto 93:e188a91d3eaa 45 #ifdef __cplusplus
Kojto 93:e188a91d3eaa 46 extern "C" {
Kojto 93:e188a91d3eaa 47 #endif
Kojto 93:e188a91d3eaa 48 #endif
Kojto 93:e188a91d3eaa 49
Kojto 93:e188a91d3eaa 50
Kojto 93:e188a91d3eaa 51 /* ------------------------- Interrupt Number Definition ------------------------ */
Kojto 93:e188a91d3eaa 52
Kojto 93:e188a91d3eaa 53 typedef enum IRQn
Kojto 93:e188a91d3eaa 54 {
Kojto 93:e188a91d3eaa 55 /****** Cortex-M4 Processor Exceptions Numbers ***************************************************/
Kojto 93:e188a91d3eaa 56 Reset_IRQn = -15, /*!< 1 Reset Vector, invoked on Power up and warm reset */
Kojto 93:e188a91d3eaa 57 NonMaskableInt_IRQn = -14, /*!< 2 Non Maskable Interrupt */
Kojto 93:e188a91d3eaa 58 HardFault_IRQn = -13, /*!< 3 Hard Fault, all classes of Fault */
Kojto 93:e188a91d3eaa 59 MemoryManagement_IRQn = -12, /*!< 4 Cortex-M3 Memory Management Interrupt */
Kojto 93:e188a91d3eaa 60 BusFault_IRQn = -11, /*!< 5 Cortex-M3 Bus Fault Interrupt */
Kojto 93:e188a91d3eaa 61 UsageFault_IRQn = -10, /*!< 6 Cortex-M3 Usage Fault Interrupt */
Kojto 93:e188a91d3eaa 62 SVCall_IRQn = -5, /*!< 11 Cortex-M3 SV Call Interrupt */
Kojto 93:e188a91d3eaa 63 DebugMonitor_IRQn = -4, /*!< 12 Cortex-M3 Debug Monitor Interrupt */
Kojto 93:e188a91d3eaa 64 PendSV_IRQn = -2, /*!< 14 Cortex-M3 Pend SV Interrupt */
Kojto 93:e188a91d3eaa 65 SysTick_IRQn = -1, /*!< 15 Cortex-M3 System Tick Interrupt */
Kojto 93:e188a91d3eaa 66
Kojto 93:e188a91d3eaa 67 /****** LPC407x_8x_177x_8x Specific Interrupt Numbers *******************************************************/
Kojto 93:e188a91d3eaa 68 WDT_IRQn = 0, /*!< Watchdog Timer Interrupt */
Kojto 93:e188a91d3eaa 69 TIMER0_IRQn = 1, /*!< Timer0 Interrupt */
Kojto 93:e188a91d3eaa 70 TIMER1_IRQn = 2, /*!< Timer1 Interrupt */
Kojto 93:e188a91d3eaa 71 TIMER2_IRQn = 3, /*!< Timer2 Interrupt */
Kojto 93:e188a91d3eaa 72 TIMER3_IRQn = 4, /*!< Timer3 Interrupt */
Kojto 93:e188a91d3eaa 73 UART0_IRQn = 5, /*!< UART0 Interrupt */
Kojto 93:e188a91d3eaa 74 UART1_IRQn = 6, /*!< UART1 Interrupt */
Kojto 93:e188a91d3eaa 75 UART2_IRQn = 7, /*!< UART2 Interrupt */
Kojto 93:e188a91d3eaa 76 UART3_IRQn = 8, /*!< UART3 Interrupt */
Kojto 93:e188a91d3eaa 77 PWM1_IRQn = 9, /*!< PWM1 Interrupt */
Kojto 93:e188a91d3eaa 78 I2C0_IRQn = 10, /*!< I2C0 Interrupt */
Kojto 93:e188a91d3eaa 79 I2C1_IRQn = 11, /*!< I2C1 Interrupt */
Kojto 93:e188a91d3eaa 80 I2C2_IRQn = 12, /*!< I2C2 Interrupt */
Kojto 93:e188a91d3eaa 81 Reserved0_IRQn = 13, /*!< Reserved */
Kojto 93:e188a91d3eaa 82 SSP0_IRQn = 14, /*!< SSP0 Interrupt */
Kojto 93:e188a91d3eaa 83 SSP1_IRQn = 15, /*!< SSP1 Interrupt */
Kojto 93:e188a91d3eaa 84 PLL0_IRQn = 16, /*!< PLL0 Lock (Main PLL) Interrupt */
Kojto 93:e188a91d3eaa 85 RTC_IRQn = 17, /*!< Real Time Clock Interrupt */
Kojto 93:e188a91d3eaa 86 EINT0_IRQn = 18, /*!< External Interrupt 0 Interrupt */
Kojto 93:e188a91d3eaa 87 EINT1_IRQn = 19, /*!< External Interrupt 1 Interrupt */
Kojto 93:e188a91d3eaa 88 EINT2_IRQn = 20, /*!< External Interrupt 2 Interrupt */
Kojto 93:e188a91d3eaa 89 EINT3_IRQn = 21, /*!< External Interrupt 3 Interrupt */
Kojto 93:e188a91d3eaa 90 ADC_IRQn = 22, /*!< A/D Converter Interrupt */
Kojto 93:e188a91d3eaa 91 BOD_IRQn = 23, /*!< Brown-Out Detect Interrupt */
Kojto 93:e188a91d3eaa 92 USB_IRQn = 24, /*!< USB Interrupt */
Kojto 93:e188a91d3eaa 93 CAN_IRQn = 25, /*!< CAN Interrupt */
Kojto 93:e188a91d3eaa 94 DMA_IRQn = 26, /*!< General Purpose DMA Interrupt */
Kojto 93:e188a91d3eaa 95 I2S_IRQn = 27, /*!< I2S Interrupt */
Kojto 93:e188a91d3eaa 96 ENET_IRQn = 28, /*!< Ethernet Interrupt */
Kojto 93:e188a91d3eaa 97 MCI_IRQn = 29, /*!< SD/MMC card I/F Interrupt */
Kojto 93:e188a91d3eaa 98 MCPWM_IRQn = 30, /*!< Motor Control PWM Interrupt */
Kojto 93:e188a91d3eaa 99 QEI_IRQn = 31, /*!< Quadrature Encoder Interface Interrupt */
Kojto 93:e188a91d3eaa 100 PLL1_IRQn = 32, /*!< PLL1 Lock (USB PLL) Interrupt */
Kojto 93:e188a91d3eaa 101 USBActivity_IRQn = 33, /*!< USB Activity interrupt */
Kojto 93:e188a91d3eaa 102 CANActivity_IRQn = 34, /*!< CAN Activity interrupt */
Kojto 93:e188a91d3eaa 103 UART4_IRQn = 35, /*!< UART4 Interrupt */
Kojto 93:e188a91d3eaa 104 SSP2_IRQn = 36, /*!< SSP2 Interrupt */
Kojto 93:e188a91d3eaa 105 LCD_IRQn = 37, /*!< LCD Interrupt */
Kojto 93:e188a91d3eaa 106 GPIO_IRQn = 38, /*!< GPIO Interrupt */
Kojto 93:e188a91d3eaa 107 PWM0_IRQn = 39, /*!< 39 PWM0 */
Kojto 93:e188a91d3eaa 108 EEPROM_IRQn = 40, /*!< 40 EEPROM */
Kojto 93:e188a91d3eaa 109 CMP0_IRQn = 41, /*!< 41 CMP0 */
Kojto 93:e188a91d3eaa 110 CMP1_IRQn = 42 /*!< 42 CMP1 */
Kojto 93:e188a91d3eaa 111 } IRQn_Type;
Kojto 93:e188a91d3eaa 112
Kojto 93:e188a91d3eaa 113 /* ================================================================================ */
Kojto 93:e188a91d3eaa 114 /* ================ Processor and Core Peripheral Section ================ */
Kojto 93:e188a91d3eaa 115 /* ================================================================================ */
Kojto 93:e188a91d3eaa 116 #ifdef CORE_M4
Kojto 93:e188a91d3eaa 117 /* ----------------Configuration of the cm4 Processor and Core Peripherals---------------- */
Kojto 93:e188a91d3eaa 118 #define __CM4_REV 0x0000 /*!< Cortex-M4 Core Revision */
Kojto 93:e188a91d3eaa 119 #define __MPU_PRESENT 1 /*!< MPU present or not */
Kojto 93:e188a91d3eaa 120 #define __NVIC_PRIO_BITS 5 /*!< Number of Bits used for Priority Levels */
Kojto 93:e188a91d3eaa 121 #define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */
Kojto 93:e188a91d3eaa 122 #define __FPU_PRESENT 1 /*!< FPU present or not */
Kojto 93:e188a91d3eaa 123
Kojto 93:e188a91d3eaa 124
Kojto 93:e188a91d3eaa 125 #include "core_cm4.h" /*!< Cortex-M4 processor and core peripherals */
Kojto 93:e188a91d3eaa 126 #else
Kojto 93:e188a91d3eaa 127 /* Configuration of the Cortex-M3 Processor and Core Peripherals */
Kojto 93:e188a91d3eaa 128 #define __MPU_PRESENT 1 /*!< MPU present or not */
Kojto 93:e188a91d3eaa 129 #define __NVIC_PRIO_BITS 5 /*!< Number of Bits used for Priority Levels */
Kojto 93:e188a91d3eaa 130 #define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */
Kojto 93:e188a91d3eaa 131
Kojto 93:e188a91d3eaa 132
Kojto 93:e188a91d3eaa 133 #include "core_cm3.h" /* Cortex-M3 processor and core peripherals */
Kojto 93:e188a91d3eaa 134
Kojto 93:e188a91d3eaa 135 #endif
Kojto 93:e188a91d3eaa 136
Kojto 93:e188a91d3eaa 137 #include "system_LPC407x_8x_177x_8x.h" /*!< LPC408x_7x System */
Kojto 93:e188a91d3eaa 138
Kojto 93:e188a91d3eaa 139
Kojto 93:e188a91d3eaa 140
Kojto 93:e188a91d3eaa 141
Kojto 93:e188a91d3eaa 142
Kojto 93:e188a91d3eaa 143
Kojto 93:e188a91d3eaa 144 /* ================================================================================ */
Kojto 93:e188a91d3eaa 145 /* ================ Device Specific Peripheral Section ================ */
Kojto 93:e188a91d3eaa 146 /* ================================================================================ */
Kojto 93:e188a91d3eaa 147
Kojto 93:e188a91d3eaa 148 #if defined ( __CC_ARM )
Kojto 93:e188a91d3eaa 149 #pragma anon_unions
Kojto 93:e188a91d3eaa 150 #endif
Kojto 93:e188a91d3eaa 151
Kojto 93:e188a91d3eaa 152 /*------------- General Purpose Direct Memory Access (GPDMA) -----------------*/
Kojto 93:e188a91d3eaa 153 typedef struct /* Common Registers */
Kojto 93:e188a91d3eaa 154 {
Kojto 93:e188a91d3eaa 155 __I uint32_t IntStat;
Kojto 93:e188a91d3eaa 156 __I uint32_t IntTCStat;
Kojto 93:e188a91d3eaa 157 __O uint32_t IntTCClear;
Kojto 93:e188a91d3eaa 158 __I uint32_t IntErrStat;
Kojto 93:e188a91d3eaa 159 __O uint32_t IntErrClr;
Kojto 93:e188a91d3eaa 160 __I uint32_t RawIntTCStat;
Kojto 93:e188a91d3eaa 161 __I uint32_t RawIntErrStat;
Kojto 93:e188a91d3eaa 162 __I uint32_t EnbldChns;
Kojto 93:e188a91d3eaa 163 __IO uint32_t SoftBReq;
Kojto 93:e188a91d3eaa 164 __IO uint32_t SoftSReq;
Kojto 93:e188a91d3eaa 165 __IO uint32_t SoftLBReq;
Kojto 93:e188a91d3eaa 166 __IO uint32_t SoftLSReq;
Kojto 93:e188a91d3eaa 167 __IO uint32_t Config;
Kojto 93:e188a91d3eaa 168 __IO uint32_t Sync;
Kojto 93:e188a91d3eaa 169 } LPC_GPDMA_TypeDef;
Kojto 93:e188a91d3eaa 170
Kojto 93:e188a91d3eaa 171 typedef struct /* Channel Registers */
Kojto 93:e188a91d3eaa 172 {
Kojto 93:e188a91d3eaa 173 __IO uint32_t CSrcAddr;
Kojto 93:e188a91d3eaa 174 __IO uint32_t CDestAddr;
Kojto 93:e188a91d3eaa 175 __IO uint32_t CLLI;
Kojto 93:e188a91d3eaa 176 __IO uint32_t CControl;
Kojto 93:e188a91d3eaa 177 __IO uint32_t CConfig;
Kojto 93:e188a91d3eaa 178 } LPC_GPDMACH_TypeDef;
Kojto 93:e188a91d3eaa 179
Kojto 93:e188a91d3eaa 180 /*------------- System Control (SC) ------------------------------------------*/
Kojto 93:e188a91d3eaa 181 typedef struct
Kojto 93:e188a91d3eaa 182 {
Kojto 93:e188a91d3eaa 183 __IO uint32_t FLASHCFG; /*!< Offset: 0x000 (R/W) Flash Accelerator Configuration Register */
Kojto 93:e188a91d3eaa 184 uint32_t RESERVED0[31];
Kojto 93:e188a91d3eaa 185 __IO uint32_t PLL0CON; /*!< Offset: 0x080 (R/W) PLL0 Control Register */
Kojto 93:e188a91d3eaa 186 __IO uint32_t PLL0CFG; /*!< Offset: 0x084 (R/W) PLL0 Configuration Register */
Kojto 93:e188a91d3eaa 187 __I uint32_t PLL0STAT; /*!< Offset: 0x088 (R/ ) PLL0 Status Register */
Kojto 93:e188a91d3eaa 188 __O uint32_t PLL0FEED; /*!< Offset: 0x08C ( /W) PLL0 Feed Register */
Kojto 93:e188a91d3eaa 189 uint32_t RESERVED1[4];
Kojto 93:e188a91d3eaa 190 __IO uint32_t PLL1CON; /*!< Offset: 0x0A0 (R/W) PLL1 Control Register */
Kojto 93:e188a91d3eaa 191 __IO uint32_t PLL1CFG; /*!< Offset: 0x0A4 (R/W) PLL1 Configuration Register */
Kojto 93:e188a91d3eaa 192 __I uint32_t PLL1STAT; /*!< Offset: 0x0A8 (R/ ) PLL1 Status Register */
Kojto 93:e188a91d3eaa 193 __O uint32_t PLL1FEED; /*!< Offset: 0x0AC ( /W) PLL1 Feed Register */
Kojto 93:e188a91d3eaa 194 uint32_t RESERVED2[4];
Kojto 93:e188a91d3eaa 195 __IO uint32_t PCON; /*!< Offset: 0x0C0 (R/W) Power Control Register */
Kojto 93:e188a91d3eaa 196 __IO uint32_t PCONP; /*!< Offset: 0x0C4 (R/W) Power Control for Peripherals Register */
Kojto 93:e188a91d3eaa 197 __IO uint32_t PCONP1; /*!< Offset: 0x0C8 (R/W) Power Control for Peripherals Register */
Kojto 93:e188a91d3eaa 198 uint32_t RESERVED3[13];
Kojto 93:e188a91d3eaa 199 __IO uint32_t EMCCLKSEL; /*!< Offset: 0x100 (R/W) External Memory Controller Clock Selection Register */
Kojto 93:e188a91d3eaa 200 __IO uint32_t CCLKSEL; /*!< Offset: 0x104 (R/W) CPU Clock Selection Register */
Kojto 93:e188a91d3eaa 201 __IO uint32_t USBCLKSEL; /*!< Offset: 0x108 (R/W) USB Clock Selection Register */
Kojto 93:e188a91d3eaa 202 __IO uint32_t CLKSRCSEL; /*!< Offset: 0x10C (R/W) Clock Source Select Register */
Kojto 93:e188a91d3eaa 203 __IO uint32_t CANSLEEPCLR; /*!< Offset: 0x110 (R/W) CAN Sleep Clear Register */
Kojto 93:e188a91d3eaa 204 __IO uint32_t CANWAKEFLAGS; /*!< Offset: 0x114 (R/W) CAN Wake-up Flags Register */
Kojto 93:e188a91d3eaa 205 uint32_t RESERVED4[10];
Kojto 93:e188a91d3eaa 206 __IO uint32_t EXTINT; /*!< Offset: 0x140 (R/W) External Interrupt Flag Register */
Kojto 93:e188a91d3eaa 207 uint32_t RESERVED5[1];
Kojto 93:e188a91d3eaa 208 __IO uint32_t EXTMODE; /*!< Offset: 0x148 (R/W) External Interrupt Mode Register */
Kojto 93:e188a91d3eaa 209 __IO uint32_t EXTPOLAR; /*!< Offset: 0x14C (R/W) External Interrupt Polarity Register */
Kojto 93:e188a91d3eaa 210 uint32_t RESERVED6[12];
Kojto 93:e188a91d3eaa 211 __IO uint32_t RSID; /*!< Offset: 0x180 (R/W) Reset Source Identification Register */
Kojto 93:e188a91d3eaa 212 uint32_t RESERVED7[7];
Kojto 93:e188a91d3eaa 213 __IO uint32_t SCS; /*!< Offset: 0x1A0 (R/W) System Controls and Status Register */
Kojto 93:e188a91d3eaa 214 __IO uint32_t IRCTRIM; /*!< Offset: 0x1A4 (R/W) Clock Dividers */
Kojto 93:e188a91d3eaa 215 __IO uint32_t PCLKSEL; /*!< Offset: 0x1A8 (R/W) Peripheral Clock Selection Register */
Kojto 93:e188a91d3eaa 216 uint32_t RESERVED8;
Kojto 93:e188a91d3eaa 217 __IO uint32_t PBOOST; /*!< Offset: 0x1B0 (R/W) Power Boost control register */
Kojto 93:e188a91d3eaa 218 __IO uint32_t SPIFICLKSEL;
Kojto 93:e188a91d3eaa 219 __IO uint32_t LCD_CFG; /*!< Offset: 0x1B8 (R/W) LCD Configuration and clocking control Register */
Kojto 93:e188a91d3eaa 220 uint32_t RESERVED10[1];
Kojto 93:e188a91d3eaa 221 __IO uint32_t USBIntSt; /*!< Offset: 0x1C0 (R/W) USB Interrupt Status Register */
Kojto 93:e188a91d3eaa 222 __IO uint32_t DMAREQSEL; /*!< Offset: 0x1C4 (R/W) DMA Request Select Register */
Kojto 93:e188a91d3eaa 223 __IO uint32_t CLKOUTCFG; /*!< Offset: 0x1C8 (R/W) Clock Output Configuration Register */
Kojto 93:e188a91d3eaa 224 __IO uint32_t RSTCON0; /*!< Offset: 0x1CC (R/W) RESET Control0 Register */
Kojto 93:e188a91d3eaa 225 __IO uint32_t RSTCON1; /*!< Offset: 0x1D0 (R/W) RESET Control1 Register */
Kojto 93:e188a91d3eaa 226 uint32_t RESERVED11[2];
Kojto 93:e188a91d3eaa 227 __IO uint32_t EMCDLYCTL; /*!< Offset: 0x1DC (R/W) SDRAM programmable delays */
Kojto 93:e188a91d3eaa 228 __IO uint32_t EMCCAL; /*!< Offset: 0x1E0 (R/W) Calibration of programmable delays */
Kojto 93:e188a91d3eaa 229 } LPC_SC_TypeDef;
Kojto 93:e188a91d3eaa 230 /*------------- Ethernet Media Access Controller (EMAC) ----------------------*/
Kojto 93:e188a91d3eaa 231 typedef struct
Kojto 93:e188a91d3eaa 232 {
Kojto 93:e188a91d3eaa 233 __IO uint32_t MAC1; /* MAC Registers */
Kojto 93:e188a91d3eaa 234 __IO uint32_t MAC2;
Kojto 93:e188a91d3eaa 235 __IO uint32_t IPGT;
Kojto 93:e188a91d3eaa 236 __IO uint32_t IPGR;
Kojto 93:e188a91d3eaa 237 __IO uint32_t CLRT;
Kojto 93:e188a91d3eaa 238 __IO uint32_t MAXF;
Kojto 93:e188a91d3eaa 239 __IO uint32_t SUPP;
Kojto 93:e188a91d3eaa 240 __IO uint32_t TEST;
Kojto 93:e188a91d3eaa 241 __IO uint32_t MCFG;
Kojto 93:e188a91d3eaa 242 __IO uint32_t MCMD;
Kojto 93:e188a91d3eaa 243 __IO uint32_t MADR;
Kojto 93:e188a91d3eaa 244 __O uint32_t MWTD;
Kojto 93:e188a91d3eaa 245 __I uint32_t MRDD;
Kojto 93:e188a91d3eaa 246 __I uint32_t MIND;
Kojto 93:e188a91d3eaa 247 uint32_t RESERVED0[2];
Kojto 93:e188a91d3eaa 248 __IO uint32_t SA0;
Kojto 93:e188a91d3eaa 249 __IO uint32_t SA1;
Kojto 93:e188a91d3eaa 250 __IO uint32_t SA2;
Kojto 93:e188a91d3eaa 251 uint32_t RESERVED1[45];
Kojto 93:e188a91d3eaa 252 __IO uint32_t Command; /* Control Registers */
Kojto 93:e188a91d3eaa 253 __I uint32_t Status;
Kojto 93:e188a91d3eaa 254 __IO uint32_t RxDescriptor;
Kojto 93:e188a91d3eaa 255 __IO uint32_t RxStatus;
Kojto 93:e188a91d3eaa 256 __IO uint32_t RxDescriptorNumber;
Kojto 93:e188a91d3eaa 257 __I uint32_t RxProduceIndex;
Kojto 93:e188a91d3eaa 258 __IO uint32_t RxConsumeIndex;
Kojto 93:e188a91d3eaa 259 __IO uint32_t TxDescriptor;
Kojto 93:e188a91d3eaa 260 __IO uint32_t TxStatus;
Kojto 93:e188a91d3eaa 261 __IO uint32_t TxDescriptorNumber;
Kojto 93:e188a91d3eaa 262 __IO uint32_t TxProduceIndex;
Kojto 93:e188a91d3eaa 263 __I uint32_t TxConsumeIndex;
Kojto 93:e188a91d3eaa 264 uint32_t RESERVED2[10];
Kojto 93:e188a91d3eaa 265 __I uint32_t TSV0;
Kojto 93:e188a91d3eaa 266 __I uint32_t TSV1;
Kojto 93:e188a91d3eaa 267 __I uint32_t RSV;
Kojto 93:e188a91d3eaa 268 uint32_t RESERVED3[3];
Kojto 93:e188a91d3eaa 269 __IO uint32_t FlowControlCounter;
Kojto 93:e188a91d3eaa 270 __I uint32_t FlowControlStatus;
Kojto 93:e188a91d3eaa 271 uint32_t RESERVED4[34];
Kojto 93:e188a91d3eaa 272 __IO uint32_t RxFilterCtrl; /* Rx Filter Registers */
Kojto 93:e188a91d3eaa 273 __I uint32_t RxFilterWoLStatus;
Kojto 93:e188a91d3eaa 274 __O uint32_t RxFilterWoLClear;
Kojto 93:e188a91d3eaa 275 uint32_t RESERVED5;
Kojto 93:e188a91d3eaa 276 __IO uint32_t HashFilterL;
Kojto 93:e188a91d3eaa 277 __IO uint32_t HashFilterH;
Kojto 93:e188a91d3eaa 278 uint32_t RESERVED6[882];
Kojto 93:e188a91d3eaa 279 __I uint32_t IntStatus; /* Module Control Registers */
Kojto 93:e188a91d3eaa 280 __IO uint32_t IntEnable;
Kojto 93:e188a91d3eaa 281 __O uint32_t IntClear;
Kojto 93:e188a91d3eaa 282 __O uint32_t IntSet;
Kojto 93:e188a91d3eaa 283 uint32_t RESERVED7;
Kojto 93:e188a91d3eaa 284 __IO uint32_t PowerDown;
Kojto 93:e188a91d3eaa 285 uint32_t RESERVED8;
Kojto 93:e188a91d3eaa 286 __IO uint32_t Module_ID;
Kojto 93:e188a91d3eaa 287 } LPC_EMAC_TypeDef;
Kojto 93:e188a91d3eaa 288
Kojto 93:e188a91d3eaa 289 /*------------- LCD controller (LCD) -----------------------------------------*/
Kojto 93:e188a91d3eaa 290 typedef struct
Kojto 93:e188a91d3eaa 291 {
Kojto 93:e188a91d3eaa 292 __IO uint32_t TIMH; /* LCD Registers */
Kojto 93:e188a91d3eaa 293 __IO uint32_t TIMV;
Kojto 93:e188a91d3eaa 294 __IO uint32_t POL;
Kojto 93:e188a91d3eaa 295 __IO uint32_t LE;
Kojto 93:e188a91d3eaa 296 __IO uint32_t UPBASE;
Kojto 93:e188a91d3eaa 297 __IO uint32_t LPBASE;
Kojto 93:e188a91d3eaa 298 __IO uint32_t CTRL;
Kojto 93:e188a91d3eaa 299 __IO uint32_t INTMSK;
Kojto 93:e188a91d3eaa 300 __I uint32_t INTRAW;
Kojto 93:e188a91d3eaa 301 __I uint32_t INTSTAT;
Kojto 93:e188a91d3eaa 302 __O uint32_t INTCLR;
Kojto 93:e188a91d3eaa 303 __I uint32_t UPCURR;
Kojto 93:e188a91d3eaa 304 __I uint32_t LPCURR;
Kojto 93:e188a91d3eaa 305 uint32_t RESERVED0[115];
Kojto 93:e188a91d3eaa 306 __IO uint32_t PAL[128];
Kojto 93:e188a91d3eaa 307 uint32_t RESERVED1[256];
Kojto 93:e188a91d3eaa 308 __IO uint32_t CRSR_IMG[256];
Kojto 93:e188a91d3eaa 309 __IO uint32_t CRSR_CTRL;
Kojto 93:e188a91d3eaa 310 __IO uint32_t CRSR_CFG;
Kojto 93:e188a91d3eaa 311 __IO uint32_t CRSR_PAL0;
Kojto 93:e188a91d3eaa 312 __IO uint32_t CRSR_PAL1;
Kojto 93:e188a91d3eaa 313 __IO uint32_t CRSR_XY;
Kojto 93:e188a91d3eaa 314 __IO uint32_t CRSR_CLIP;
Kojto 93:e188a91d3eaa 315 uint32_t RESERVED2[2];
Kojto 93:e188a91d3eaa 316 __IO uint32_t CRSR_INTMSK;
Kojto 93:e188a91d3eaa 317 __O uint32_t CRSR_INTCLR;
Kojto 93:e188a91d3eaa 318 __I uint32_t CRSR_INTRAW;
Kojto 93:e188a91d3eaa 319 __I uint32_t CRSR_INTSTAT;
Kojto 93:e188a91d3eaa 320 } LPC_LCD_TypeDef;
Kojto 93:e188a91d3eaa 321
Kojto 93:e188a91d3eaa 322 /*------------- Universal Serial Bus (USB) -----------------------------------*/
Kojto 93:e188a91d3eaa 323 typedef struct
Kojto 93:e188a91d3eaa 324 {
Kojto 93:e188a91d3eaa 325 __I uint32_t Revision; /* USB Host Registers */
Kojto 93:e188a91d3eaa 326 __IO uint32_t Control;
Kojto 93:e188a91d3eaa 327 __IO uint32_t CommandStatus;
Kojto 93:e188a91d3eaa 328 __IO uint32_t InterruptStatus;
Kojto 93:e188a91d3eaa 329 __IO uint32_t InterruptEnable;
Kojto 93:e188a91d3eaa 330 __IO uint32_t InterruptDisable;
Kojto 93:e188a91d3eaa 331 __IO uint32_t HCCA;
Kojto 93:e188a91d3eaa 332 __I uint32_t PeriodCurrentED;
Kojto 93:e188a91d3eaa 333 __IO uint32_t ControlHeadED;
Kojto 93:e188a91d3eaa 334 __IO uint32_t ControlCurrentED;
Kojto 93:e188a91d3eaa 335 __IO uint32_t BulkHeadED;
Kojto 93:e188a91d3eaa 336 __IO uint32_t BulkCurrentED;
Kojto 93:e188a91d3eaa 337 __I uint32_t DoneHead;
Kojto 93:e188a91d3eaa 338 __IO uint32_t FmInterval;
Kojto 93:e188a91d3eaa 339 __I uint32_t FmRemaining;
Kojto 93:e188a91d3eaa 340 __I uint32_t FmNumber;
Kojto 93:e188a91d3eaa 341 __IO uint32_t PeriodicStart;
Kojto 93:e188a91d3eaa 342 __IO uint32_t LSTreshold;
Kojto 93:e188a91d3eaa 343 __IO uint32_t RhDescriptorA;
Kojto 93:e188a91d3eaa 344 __IO uint32_t RhDescriptorB;
Kojto 93:e188a91d3eaa 345 __IO uint32_t RhStatus;
Kojto 93:e188a91d3eaa 346 __IO uint32_t RhPortStatus1;
Kojto 93:e188a91d3eaa 347 __IO uint32_t RhPortStatus2;
Kojto 93:e188a91d3eaa 348 uint32_t RESERVED0[40];
Kojto 93:e188a91d3eaa 349 __I uint32_t Module_ID;
Kojto 93:e188a91d3eaa 350
Kojto 93:e188a91d3eaa 351 __I uint32_t IntSt; /* USB On-The-Go Registers */
Kojto 93:e188a91d3eaa 352 __IO uint32_t IntEn;
Kojto 93:e188a91d3eaa 353 __O uint32_t IntSet;
Kojto 93:e188a91d3eaa 354 __O uint32_t IntClr;
Kojto 93:e188a91d3eaa 355 __IO uint32_t StCtrl;
Kojto 93:e188a91d3eaa 356 __IO uint32_t Tmr;
Kojto 93:e188a91d3eaa 357 uint32_t RESERVED1[58];
Kojto 93:e188a91d3eaa 358
Kojto 93:e188a91d3eaa 359 __I uint32_t DevIntSt; /* USB Device Interrupt Registers */
Kojto 93:e188a91d3eaa 360 __IO uint32_t DevIntEn;
Kojto 93:e188a91d3eaa 361 __O uint32_t DevIntClr;
Kojto 93:e188a91d3eaa 362 __O uint32_t DevIntSet;
Kojto 93:e188a91d3eaa 363
Kojto 93:e188a91d3eaa 364 __O uint32_t CmdCode; /* USB Device SIE Command Registers */
Kojto 93:e188a91d3eaa 365 __I uint32_t CmdData;
Kojto 93:e188a91d3eaa 366
Kojto 93:e188a91d3eaa 367 __I uint32_t RxData; /* USB Device Transfer Registers */
Kojto 93:e188a91d3eaa 368 __O uint32_t TxData;
Kojto 93:e188a91d3eaa 369 __I uint32_t RxPLen;
Kojto 93:e188a91d3eaa 370 __O uint32_t TxPLen;
Kojto 93:e188a91d3eaa 371 __IO uint32_t Ctrl;
Kojto 93:e188a91d3eaa 372 __O uint32_t DevIntPri;
Kojto 93:e188a91d3eaa 373
Kojto 93:e188a91d3eaa 374 __I uint32_t EpIntSt; /* USB Device Endpoint Interrupt Regs */
Kojto 93:e188a91d3eaa 375 __IO uint32_t EpIntEn;
Kojto 93:e188a91d3eaa 376 __O uint32_t EpIntClr;
Kojto 93:e188a91d3eaa 377 __O uint32_t EpIntSet;
Kojto 93:e188a91d3eaa 378 __O uint32_t EpIntPri;
Kojto 93:e188a91d3eaa 379
Kojto 93:e188a91d3eaa 380 __IO uint32_t ReEp; /* USB Device Endpoint Realization Reg*/
Kojto 93:e188a91d3eaa 381 __O uint32_t EpInd;
Kojto 93:e188a91d3eaa 382 __IO uint32_t MaxPSize;
Kojto 93:e188a91d3eaa 383
Kojto 93:e188a91d3eaa 384 __I uint32_t DMARSt; /* USB Device DMA Registers */
Kojto 93:e188a91d3eaa 385 __O uint32_t DMARClr;
Kojto 93:e188a91d3eaa 386 __O uint32_t DMARSet;
Kojto 93:e188a91d3eaa 387 uint32_t RESERVED2[9];
Kojto 93:e188a91d3eaa 388 __IO uint32_t UDCAH;
Kojto 93:e188a91d3eaa 389 __I uint32_t EpDMASt;
Kojto 93:e188a91d3eaa 390 __O uint32_t EpDMAEn;
Kojto 93:e188a91d3eaa 391 __O uint32_t EpDMADis;
Kojto 93:e188a91d3eaa 392 __I uint32_t DMAIntSt;
Kojto 93:e188a91d3eaa 393 __IO uint32_t DMAIntEn;
Kojto 93:e188a91d3eaa 394 uint32_t RESERVED3[2];
Kojto 93:e188a91d3eaa 395 __I uint32_t EoTIntSt;
Kojto 93:e188a91d3eaa 396 __O uint32_t EoTIntClr;
Kojto 93:e188a91d3eaa 397 __O uint32_t EoTIntSet;
Kojto 93:e188a91d3eaa 398 __I uint32_t NDDRIntSt;
Kojto 93:e188a91d3eaa 399 __O uint32_t NDDRIntClr;
Kojto 93:e188a91d3eaa 400 __O uint32_t NDDRIntSet;
Kojto 93:e188a91d3eaa 401 __I uint32_t SysErrIntSt;
Kojto 93:e188a91d3eaa 402 __O uint32_t SysErrIntClr;
Kojto 93:e188a91d3eaa 403 __O uint32_t SysErrIntSet;
Kojto 93:e188a91d3eaa 404 uint32_t RESERVED4[15];
Kojto 93:e188a91d3eaa 405
Kojto 93:e188a91d3eaa 406 union {
Kojto 93:e188a91d3eaa 407 __I uint32_t I2C_RX; /* USB OTG I2C Registers */
Kojto 93:e188a91d3eaa 408 __O uint32_t I2C_TX;
Kojto 93:e188a91d3eaa 409 };
Kojto 93:e188a91d3eaa 410 __IO uint32_t I2C_STS;
Kojto 93:e188a91d3eaa 411 __IO uint32_t I2C_CTL;
Kojto 93:e188a91d3eaa 412 __IO uint32_t I2C_CLKHI;
Kojto 93:e188a91d3eaa 413 __O uint32_t I2C_CLKLO;
Kojto 93:e188a91d3eaa 414 uint32_t RESERVED5[824];
Kojto 93:e188a91d3eaa 415
Kojto 93:e188a91d3eaa 416 union {
Kojto 93:e188a91d3eaa 417 __IO uint32_t USBClkCtrl; /* USB Clock Control Registers */
Kojto 93:e188a91d3eaa 418 __IO uint32_t OTGClkCtrl;
Kojto 93:e188a91d3eaa 419 };
Kojto 93:e188a91d3eaa 420 union {
Kojto 93:e188a91d3eaa 421 __I uint32_t USBClkSt;
Kojto 93:e188a91d3eaa 422 __I uint32_t OTGClkSt;
Kojto 93:e188a91d3eaa 423 };
Kojto 93:e188a91d3eaa 424 } LPC_USB_TypeDef;
Kojto 93:e188a91d3eaa 425
Kojto 93:e188a91d3eaa 426 /*------------- CRC Engine (CRC) -----------------------------------------*/
Kojto 93:e188a91d3eaa 427 typedef struct
Kojto 93:e188a91d3eaa 428 {
Kojto 93:e188a91d3eaa 429 __IO uint32_t MODE;
Kojto 93:e188a91d3eaa 430 __IO uint32_t SEED;
Kojto 93:e188a91d3eaa 431 union {
Kojto 93:e188a91d3eaa 432 __I uint32_t SUM;
Kojto 93:e188a91d3eaa 433 struct {
Kojto 93:e188a91d3eaa 434 __O uint32_t DATA;
Kojto 93:e188a91d3eaa 435 } WR_DATA_DWORD;
Kojto 93:e188a91d3eaa 436
Kojto 93:e188a91d3eaa 437 struct {
Kojto 93:e188a91d3eaa 438 __O uint16_t DATA;
Kojto 93:e188a91d3eaa 439 uint16_t RESERVED;
Kojto 93:e188a91d3eaa 440 }WR_DATA_WORD;
Kojto 93:e188a91d3eaa 441
Kojto 93:e188a91d3eaa 442 struct {
Kojto 93:e188a91d3eaa 443 __O uint8_t DATA;
Kojto 93:e188a91d3eaa 444 uint8_t RESERVED[3];
Kojto 93:e188a91d3eaa 445 }WR_DATA_BYTE;
Kojto 93:e188a91d3eaa 446 };
Kojto 93:e188a91d3eaa 447 } LPC_CRC_TypeDef;
Kojto 93:e188a91d3eaa 448 /*------------- General Purpose Input/Output (GPIO) --------------------------*/
Kojto 93:e188a91d3eaa 449 typedef struct
Kojto 93:e188a91d3eaa 450 {
Kojto 93:e188a91d3eaa 451 __IO uint32_t DIR;
Kojto 93:e188a91d3eaa 452 uint32_t RESERVED0[3];
Kojto 93:e188a91d3eaa 453 __IO uint32_t MASK;
Kojto 93:e188a91d3eaa 454 __IO uint32_t PIN;
Kojto 93:e188a91d3eaa 455 __IO uint32_t SET;
Kojto 93:e188a91d3eaa 456 __O uint32_t CLR;
Kojto 93:e188a91d3eaa 457 } LPC_GPIO_TypeDef;
Kojto 93:e188a91d3eaa 458
Kojto 93:e188a91d3eaa 459 typedef struct
Kojto 93:e188a91d3eaa 460 {
Kojto 93:e188a91d3eaa 461 __I uint32_t IntStatus;
Kojto 93:e188a91d3eaa 462 __I uint32_t IO0IntStatR;
Kojto 93:e188a91d3eaa 463 __I uint32_t IO0IntStatF;
Kojto 93:e188a91d3eaa 464 __O uint32_t IO0IntClr;
Kojto 93:e188a91d3eaa 465 __IO uint32_t IO0IntEnR;
Kojto 93:e188a91d3eaa 466 __IO uint32_t IO0IntEnF;
Kojto 93:e188a91d3eaa 467 uint32_t RESERVED0[3];
Kojto 93:e188a91d3eaa 468 __I uint32_t IO2IntStatR;
Kojto 93:e188a91d3eaa 469 __I uint32_t IO2IntStatF;
Kojto 93:e188a91d3eaa 470 __O uint32_t IO2IntClr;
Kojto 93:e188a91d3eaa 471 __IO uint32_t IO2IntEnR;
Kojto 93:e188a91d3eaa 472 __IO uint32_t IO2IntEnF;
Kojto 93:e188a91d3eaa 473 } LPC_GPIOINT_TypeDef;
Kojto 93:e188a91d3eaa 474
Kojto 93:e188a91d3eaa 475 /*------------- External Memory Controller (EMC) -----------------------------*/
Kojto 93:e188a91d3eaa 476 typedef struct
Kojto 93:e188a91d3eaa 477 {
Kojto 93:e188a91d3eaa 478 __IO uint32_t Control;
Kojto 93:e188a91d3eaa 479 __I uint32_t Status;
Kojto 93:e188a91d3eaa 480 __IO uint32_t Config;
Kojto 93:e188a91d3eaa 481 uint32_t RESERVED0[5];
Kojto 93:e188a91d3eaa 482 __IO uint32_t DynamicControl;
Kojto 93:e188a91d3eaa 483 __IO uint32_t DynamicRefresh;
Kojto 93:e188a91d3eaa 484 __IO uint32_t DynamicReadConfig;
Kojto 93:e188a91d3eaa 485 uint32_t RESERVED1[1];
Kojto 93:e188a91d3eaa 486 __IO uint32_t DynamicRP;
Kojto 93:e188a91d3eaa 487 __IO uint32_t DynamicRAS;
Kojto 93:e188a91d3eaa 488 __IO uint32_t DynamicSREX;
Kojto 93:e188a91d3eaa 489 __IO uint32_t DynamicAPR;
Kojto 93:e188a91d3eaa 490 __IO uint32_t DynamicDAL;
Kojto 93:e188a91d3eaa 491 __IO uint32_t DynamicWR;
Kojto 93:e188a91d3eaa 492 __IO uint32_t DynamicRC;
Kojto 93:e188a91d3eaa 493 __IO uint32_t DynamicRFC;
Kojto 93:e188a91d3eaa 494 __IO uint32_t DynamicXSR;
Kojto 93:e188a91d3eaa 495 __IO uint32_t DynamicRRD;
Kojto 93:e188a91d3eaa 496 __IO uint32_t DynamicMRD;
Kojto 93:e188a91d3eaa 497 uint32_t RESERVED2[9];
Kojto 93:e188a91d3eaa 498 __IO uint32_t StaticExtendedWait;
Kojto 93:e188a91d3eaa 499 uint32_t RESERVED3[31];
Kojto 93:e188a91d3eaa 500 __IO uint32_t DynamicConfig0;
Kojto 93:e188a91d3eaa 501 __IO uint32_t DynamicRasCas0;
Kojto 93:e188a91d3eaa 502 uint32_t RESERVED4[6];
Kojto 93:e188a91d3eaa 503 __IO uint32_t DynamicConfig1;
Kojto 93:e188a91d3eaa 504 __IO uint32_t DynamicRasCas1;
Kojto 93:e188a91d3eaa 505 uint32_t RESERVED5[6];
Kojto 93:e188a91d3eaa 506 __IO uint32_t DynamicConfig2;
Kojto 93:e188a91d3eaa 507 __IO uint32_t DynamicRasCas2;
Kojto 93:e188a91d3eaa 508 uint32_t RESERVED6[6];
Kojto 93:e188a91d3eaa 509 __IO uint32_t DynamicConfig3;
Kojto 93:e188a91d3eaa 510 __IO uint32_t DynamicRasCas3;
Kojto 93:e188a91d3eaa 511 uint32_t RESERVED7[38];
Kojto 93:e188a91d3eaa 512 __IO uint32_t StaticConfig0;
Kojto 93:e188a91d3eaa 513 __IO uint32_t StaticWaitWen0;
Kojto 93:e188a91d3eaa 514 __IO uint32_t StaticWaitOen0;
Kojto 93:e188a91d3eaa 515 __IO uint32_t StaticWaitRd0;
Kojto 93:e188a91d3eaa 516 __IO uint32_t StaticWaitPage0;
Kojto 93:e188a91d3eaa 517 __IO uint32_t StaticWaitWr0;
Kojto 93:e188a91d3eaa 518 __IO uint32_t StaticWaitTurn0;
Kojto 93:e188a91d3eaa 519 uint32_t RESERVED8[1];
Kojto 93:e188a91d3eaa 520 __IO uint32_t StaticConfig1;
Kojto 93:e188a91d3eaa 521 __IO uint32_t StaticWaitWen1;
Kojto 93:e188a91d3eaa 522 __IO uint32_t StaticWaitOen1;
Kojto 93:e188a91d3eaa 523 __IO uint32_t StaticWaitRd1;
Kojto 93:e188a91d3eaa 524 __IO uint32_t StaticWaitPage1;
Kojto 93:e188a91d3eaa 525 __IO uint32_t StaticWaitWr1;
Kojto 93:e188a91d3eaa 526 __IO uint32_t StaticWaitTurn1;
Kojto 93:e188a91d3eaa 527 uint32_t RESERVED9[1];
Kojto 93:e188a91d3eaa 528 __IO uint32_t StaticConfig2;
Kojto 93:e188a91d3eaa 529 __IO uint32_t StaticWaitWen2;
Kojto 93:e188a91d3eaa 530 __IO uint32_t StaticWaitOen2;
Kojto 93:e188a91d3eaa 531 __IO uint32_t StaticWaitRd2;
Kojto 93:e188a91d3eaa 532 __IO uint32_t StaticWaitPage2;
Kojto 93:e188a91d3eaa 533 __IO uint32_t StaticWaitWr2;
Kojto 93:e188a91d3eaa 534 __IO uint32_t StaticWaitTurn2;
Kojto 93:e188a91d3eaa 535 uint32_t RESERVED10[1];
Kojto 93:e188a91d3eaa 536 __IO uint32_t StaticConfig3;
Kojto 93:e188a91d3eaa 537 __IO uint32_t StaticWaitWen3;
Kojto 93:e188a91d3eaa 538 __IO uint32_t StaticWaitOen3;
Kojto 93:e188a91d3eaa 539 __IO uint32_t StaticWaitRd3;
Kojto 93:e188a91d3eaa 540 __IO uint32_t StaticWaitPage3;
Kojto 93:e188a91d3eaa 541 __IO uint32_t StaticWaitWr3;
Kojto 93:e188a91d3eaa 542 __IO uint32_t StaticWaitTurn3;
Kojto 93:e188a91d3eaa 543 } LPC_EMC_TypeDef;
Kojto 93:e188a91d3eaa 544
Kojto 93:e188a91d3eaa 545 /*------------- Watchdog Timer (WDT) -----------------------------------------*/
Kojto 93:e188a91d3eaa 546 typedef struct
Kojto 93:e188a91d3eaa 547 {
Kojto 93:e188a91d3eaa 548 __IO uint8_t MOD;
Kojto 93:e188a91d3eaa 549 uint8_t RESERVED0[3];
Kojto 93:e188a91d3eaa 550 __IO uint32_t TC;
Kojto 93:e188a91d3eaa 551 __O uint8_t FEED;
Kojto 93:e188a91d3eaa 552 uint8_t RESERVED1[3];
Kojto 93:e188a91d3eaa 553 __I uint32_t TV;
Kojto 93:e188a91d3eaa 554 uint32_t RESERVED2;
Kojto 93:e188a91d3eaa 555 __IO uint32_t WARNINT;
Kojto 93:e188a91d3eaa 556 __IO uint32_t WINDOW;
Kojto 93:e188a91d3eaa 557 } LPC_WDT_TypeDef;
Kojto 93:e188a91d3eaa 558
Kojto 93:e188a91d3eaa 559 /*------------- Timer (TIM) --------------------------------------------------*/
Kojto 93:e188a91d3eaa 560 typedef struct
Kojto 93:e188a91d3eaa 561 {
Kojto 93:e188a91d3eaa 562 __IO uint32_t IR; /*!< Offset: 0x000 Interrupt Register (R/W) */
Kojto 93:e188a91d3eaa 563 __IO uint32_t TCR; /*!< Offset: 0x004 Timer Control Register (R/W) */
Kojto 93:e188a91d3eaa 564 __IO uint32_t TC; /*!< Offset: 0x008 Timer Counter Register (R/W) */
Kojto 93:e188a91d3eaa 565 __IO uint32_t PR; /*!< Offset: 0x00C Prescale Register (R/W) */
Kojto 93:e188a91d3eaa 566 __IO uint32_t PC; /*!< Offset: 0x010 Prescale Counter Register (R/W) */
Kojto 93:e188a91d3eaa 567 __IO uint32_t MCR; /*!< Offset: 0x014 Match Control Register (R/W) */
Kojto 93:e188a91d3eaa 568 __IO uint32_t MR0; /*!< Offset: 0x018 Match Register 0 (R/W) */
Kojto 93:e188a91d3eaa 569 __IO uint32_t MR1; /*!< Offset: 0x01C Match Register 1 (R/W) */
Kojto 93:e188a91d3eaa 570 __IO uint32_t MR2; /*!< Offset: 0x020 Match Register 2 (R/W) */
Kojto 93:e188a91d3eaa 571 __IO uint32_t MR3; /*!< Offset: 0x024 Match Register 3 (R/W) */
Kojto 93:e188a91d3eaa 572 __IO uint32_t CCR; /*!< Offset: 0x028 Capture Control Register (R/W) */
Kojto 93:e188a91d3eaa 573 __I uint32_t CR0; /*!< Offset: 0x02C Capture Register 0 (R/ ) */
Kojto 93:e188a91d3eaa 574 __I uint32_t CR1; /*!< Offset: 0x030 Capture Register 1 (R/ ) */
Kojto 93:e188a91d3eaa 575 uint32_t RESERVED0[2];
Kojto 93:e188a91d3eaa 576 __IO uint32_t EMR; /*!< Offset: 0x03C External Match Register (R/W) */
Kojto 93:e188a91d3eaa 577 uint32_t RESERVED1[12];
Kojto 93:e188a91d3eaa 578 __IO uint32_t CTCR; /*!< Offset: 0x070 Count Control Register (R/W) */
Kojto 93:e188a91d3eaa 579 } LPC_TIM_TypeDef;
Kojto 93:e188a91d3eaa 580
Kojto 93:e188a91d3eaa 581
Kojto 93:e188a91d3eaa 582 /*------------- Pulse-Width Modulation (PWM) ---------------------------------*/
Kojto 93:e188a91d3eaa 583 typedef struct
Kojto 93:e188a91d3eaa 584 {
Kojto 93:e188a91d3eaa 585 __IO uint32_t IR; /*!< Offset: 0x000 Interrupt Register (R/W) */
Kojto 93:e188a91d3eaa 586 __IO uint32_t TCR; /*!< Offset: 0x004 Timer Control Register (R/W) */
Kojto 93:e188a91d3eaa 587 __IO uint32_t TC; /*!< Offset: 0x008 Timer Counter Register (R/W) */
Kojto 93:e188a91d3eaa 588 __IO uint32_t PR; /*!< Offset: 0x00C Prescale Register (R/W) */
Kojto 93:e188a91d3eaa 589 __IO uint32_t PC; /*!< Offset: 0x010 Prescale Counter Register (R/W) */
Kojto 93:e188a91d3eaa 590 __IO uint32_t MCR; /*!< Offset: 0x014 Match Control Register (R/W) */
Kojto 93:e188a91d3eaa 591 __IO uint32_t MR0; /*!< Offset: 0x018 Match Register 0 (R/W) */
Kojto 93:e188a91d3eaa 592 __IO uint32_t MR1; /*!< Offset: 0x01C Match Register 1 (R/W) */
Kojto 93:e188a91d3eaa 593 __IO uint32_t MR2; /*!< Offset: 0x020 Match Register 2 (R/W) */
Kojto 93:e188a91d3eaa 594 __IO uint32_t MR3; /*!< Offset: 0x024 Match Register 3 (R/W) */
Kojto 93:e188a91d3eaa 595 __IO uint32_t CCR; /*!< Offset: 0x028 Capture Control Register (R/W) */
Kojto 93:e188a91d3eaa 596 __I uint32_t CR0; /*!< Offset: 0x02C Capture Register 0 (R/ ) */
Kojto 93:e188a91d3eaa 597 __I uint32_t CR1; /*!< Offset: 0x030 Capture Register 1 (R/ ) */
Kojto 93:e188a91d3eaa 598 __I uint32_t CR2; /*!< Offset: 0x034 Capture Register 2 (R/ ) */
Kojto 93:e188a91d3eaa 599 __I uint32_t CR3; /*!< Offset: 0x038 Capture Register 3 (R/ ) */
Kojto 93:e188a91d3eaa 600 uint32_t RESERVED0;
Kojto 93:e188a91d3eaa 601 __IO uint32_t MR4; /*!< Offset: 0x040 Match Register 4 (R/W) */
Kojto 93:e188a91d3eaa 602 __IO uint32_t MR5; /*!< Offset: 0x044 Match Register 5 (R/W) */
Kojto 93:e188a91d3eaa 603 __IO uint32_t MR6; /*!< Offset: 0x048 Match Register 6 (R/W) */
Kojto 93:e188a91d3eaa 604 __IO uint32_t PCR; /*!< Offset: 0x04C PWM Control Register (R/W) */
Kojto 93:e188a91d3eaa 605 __IO uint32_t LER; /*!< Offset: 0x050 Load Enable Register (R/W) */
Kojto 93:e188a91d3eaa 606 uint32_t RESERVED1[7];
Kojto 93:e188a91d3eaa 607 __IO uint32_t CTCR; /*!< Offset: 0x070 Counter Control Register (R/W) */
Kojto 93:e188a91d3eaa 608 } LPC_PWM_TypeDef;
Kojto 93:e188a91d3eaa 609
Kojto 93:e188a91d3eaa 610 /*------------- Universal Asynchronous Receiver Transmitter (UARTx) -----------*/
Kojto 93:e188a91d3eaa 611 /* There are three types of UARTs on the chip:
Kojto 93:e188a91d3eaa 612 (1) UART0,UART2, and UART3 are the standard UART.
Kojto 93:e188a91d3eaa 613 (2) UART1 is the standard with modem capability.
Kojto 93:e188a91d3eaa 614 (3) USART(UART4) is the sync/async UART with smart card capability.
Kojto 93:e188a91d3eaa 615 More details can be found on the Users Manual. */
Kojto 93:e188a91d3eaa 616
Kojto 93:e188a91d3eaa 617 #if 0
Kojto 93:e188a91d3eaa 618 typedef struct
Kojto 93:e188a91d3eaa 619 {
Kojto 93:e188a91d3eaa 620 union {
Kojto 93:e188a91d3eaa 621 __I uint8_t RBR;
Kojto 93:e188a91d3eaa 622 __O uint8_t THR;
Kojto 93:e188a91d3eaa 623 __IO uint8_t DLL;
Kojto 93:e188a91d3eaa 624 uint32_t RESERVED0;
Kojto 93:e188a91d3eaa 625 };
Kojto 93:e188a91d3eaa 626 union {
Kojto 93:e188a91d3eaa 627 __IO uint8_t DLM;
Kojto 93:e188a91d3eaa 628 __IO uint32_t IER;
Kojto 93:e188a91d3eaa 629 };
Kojto 93:e188a91d3eaa 630 union {
Kojto 93:e188a91d3eaa 631 __I uint32_t IIR;
Kojto 93:e188a91d3eaa 632 __O uint8_t FCR;
Kojto 93:e188a91d3eaa 633 };
Kojto 93:e188a91d3eaa 634 __IO uint8_t LCR;
Kojto 93:e188a91d3eaa 635 uint8_t RESERVED1[7];
Kojto 93:e188a91d3eaa 636 __I uint8_t LSR;
Kojto 93:e188a91d3eaa 637 uint8_t RESERVED2[7];
Kojto 93:e188a91d3eaa 638 __IO uint8_t SCR;
Kojto 93:e188a91d3eaa 639 uint8_t RESERVED3[3];
Kojto 93:e188a91d3eaa 640 __IO uint32_t ACR;
Kojto 93:e188a91d3eaa 641 __IO uint8_t ICR;
Kojto 93:e188a91d3eaa 642 uint8_t RESERVED4[3];
Kojto 93:e188a91d3eaa 643 __IO uint8_t FDR;
Kojto 93:e188a91d3eaa 644 uint8_t RESERVED5[7];
Kojto 93:e188a91d3eaa 645 __IO uint8_t TER;
Kojto 93:e188a91d3eaa 646 uint8_t RESERVED6[39];
Kojto 93:e188a91d3eaa 647 __I uint8_t FIFOLVL;
Kojto 93:e188a91d3eaa 648 } LPC_UART_TypeDef;
Kojto 93:e188a91d3eaa 649 #else
Kojto 93:e188a91d3eaa 650 typedef struct
Kojto 93:e188a91d3eaa 651 {
Kojto 93:e188a91d3eaa 652 union
Kojto 93:e188a91d3eaa 653 {
Kojto 93:e188a91d3eaa 654 __I uint8_t RBR;
Kojto 93:e188a91d3eaa 655 __O uint8_t THR;
Kojto 93:e188a91d3eaa 656 __IO uint8_t DLL;
Kojto 93:e188a91d3eaa 657 uint32_t RESERVED0;
Kojto 93:e188a91d3eaa 658 };
Kojto 93:e188a91d3eaa 659 union
Kojto 93:e188a91d3eaa 660 {
Kojto 93:e188a91d3eaa 661 __IO uint8_t DLM;
Kojto 93:e188a91d3eaa 662 __IO uint32_t IER;
Kojto 93:e188a91d3eaa 663 };
Kojto 93:e188a91d3eaa 664 union
Kojto 93:e188a91d3eaa 665 {
Kojto 93:e188a91d3eaa 666 __I uint32_t IIR;
Kojto 93:e188a91d3eaa 667 __O uint8_t FCR;
Kojto 93:e188a91d3eaa 668 };
Kojto 93:e188a91d3eaa 669 __IO uint8_t LCR;
Kojto 93:e188a91d3eaa 670 uint8_t RESERVED1[7];//Reserved
Kojto 93:e188a91d3eaa 671 __I uint8_t LSR;
Kojto 93:e188a91d3eaa 672 uint8_t RESERVED2[7];//Reserved
Kojto 93:e188a91d3eaa 673 __IO uint8_t SCR;
Kojto 93:e188a91d3eaa 674 uint8_t RESERVED3[3];//Reserved
Kojto 93:e188a91d3eaa 675 __IO uint32_t ACR;
Kojto 93:e188a91d3eaa 676 __IO uint8_t ICR;
Kojto 93:e188a91d3eaa 677 uint8_t RESERVED4[3];//Reserved
Kojto 93:e188a91d3eaa 678 __IO uint8_t FDR;
Kojto 93:e188a91d3eaa 679 uint8_t RESERVED5[7];//Reserved
Kojto 93:e188a91d3eaa 680 __IO uint8_t TER;
Kojto 93:e188a91d3eaa 681 uint8_t RESERVED8[27];//Reserved
Kojto 93:e188a91d3eaa 682 __IO uint8_t RS485CTRL;
Kojto 93:e188a91d3eaa 683 uint8_t RESERVED9[3];//Reserved
Kojto 93:e188a91d3eaa 684 __IO uint8_t ADRMATCH;
Kojto 93:e188a91d3eaa 685 uint8_t RESERVED10[3];//Reserved
Kojto 93:e188a91d3eaa 686 __IO uint8_t RS485DLY;
Kojto 93:e188a91d3eaa 687 uint8_t RESERVED11[3];//Reserved
Kojto 93:e188a91d3eaa 688 __I uint8_t FIFOLVL;
Kojto 93:e188a91d3eaa 689 }LPC_UART_TypeDef;
Kojto 93:e188a91d3eaa 690 #endif
Kojto 93:e188a91d3eaa 691
Kojto 93:e188a91d3eaa 692
Kojto 93:e188a91d3eaa 693 typedef struct
Kojto 93:e188a91d3eaa 694 {
Kojto 93:e188a91d3eaa 695 union {
Kojto 93:e188a91d3eaa 696 __I uint8_t RBR;
Kojto 93:e188a91d3eaa 697 __O uint8_t THR;
Kojto 93:e188a91d3eaa 698 __IO uint8_t DLL;
Kojto 93:e188a91d3eaa 699 uint32_t RESERVED0;
Kojto 93:e188a91d3eaa 700 };
Kojto 93:e188a91d3eaa 701 union {
Kojto 93:e188a91d3eaa 702 __IO uint8_t DLM;
Kojto 93:e188a91d3eaa 703 __IO uint32_t IER;
Kojto 93:e188a91d3eaa 704 };
Kojto 93:e188a91d3eaa 705 union {
Kojto 93:e188a91d3eaa 706 __I uint32_t IIR;
Kojto 93:e188a91d3eaa 707 __O uint8_t FCR;
Kojto 93:e188a91d3eaa 708 };
Kojto 93:e188a91d3eaa 709 __IO uint8_t LCR;
Kojto 93:e188a91d3eaa 710 uint8_t RESERVED1[3];
Kojto 93:e188a91d3eaa 711 __IO uint8_t MCR;
Kojto 93:e188a91d3eaa 712 uint8_t RESERVED2[3];
Kojto 93:e188a91d3eaa 713 __I uint8_t LSR;
Kojto 93:e188a91d3eaa 714 uint8_t RESERVED3[3];
Kojto 93:e188a91d3eaa 715 __I uint8_t MSR;
Kojto 93:e188a91d3eaa 716 uint8_t RESERVED4[3];
Kojto 93:e188a91d3eaa 717 __IO uint8_t SCR;
Kojto 93:e188a91d3eaa 718 uint8_t RESERVED5[3];
Kojto 93:e188a91d3eaa 719 __IO uint32_t ACR;
Kojto 93:e188a91d3eaa 720 uint32_t RESERVED6;
Kojto 93:e188a91d3eaa 721 __IO uint32_t FDR;
Kojto 93:e188a91d3eaa 722 uint32_t RESERVED7;
Kojto 93:e188a91d3eaa 723 __IO uint8_t TER;
Kojto 93:e188a91d3eaa 724 uint8_t RESERVED8[27];
Kojto 93:e188a91d3eaa 725 __IO uint8_t RS485CTRL;
Kojto 93:e188a91d3eaa 726 uint8_t RESERVED9[3];
Kojto 93:e188a91d3eaa 727 __IO uint8_t ADRMATCH;
Kojto 93:e188a91d3eaa 728 uint8_t RESERVED10[3];
Kojto 93:e188a91d3eaa 729 __IO uint8_t RS485DLY;
Kojto 93:e188a91d3eaa 730 uint8_t RESERVED11[3];
Kojto 93:e188a91d3eaa 731 __I uint8_t FIFOLVL;
Kojto 93:e188a91d3eaa 732 } LPC_UART1_TypeDef;
Kojto 93:e188a91d3eaa 733
Kojto 93:e188a91d3eaa 734 typedef struct
Kojto 93:e188a91d3eaa 735 {
Kojto 93:e188a91d3eaa 736 union {
Kojto 93:e188a91d3eaa 737 __I uint32_t RBR; /*!< Offset: 0x000 Receiver Buffer Register (R/ ) */
Kojto 93:e188a91d3eaa 738 __O uint32_t THR; /*!< Offset: 0x000 Transmit Holding Register ( /W) */
Kojto 93:e188a91d3eaa 739 __IO uint32_t DLL; /*!< Offset: 0x000 Divisor Latch LSB (R/W) */
Kojto 93:e188a91d3eaa 740 };
Kojto 93:e188a91d3eaa 741 union {
Kojto 93:e188a91d3eaa 742 __IO uint32_t DLM; /*!< Offset: 0x004 Divisor Latch MSB (R/W) */
Kojto 93:e188a91d3eaa 743 __IO uint32_t IER; /*!< Offset: 0x000 Interrupt Enable Register (R/W) */
Kojto 93:e188a91d3eaa 744 };
Kojto 93:e188a91d3eaa 745 union {
Kojto 93:e188a91d3eaa 746 __I uint32_t IIR; /*!< Offset: 0x008 Interrupt ID Register (R/ ) */
Kojto 93:e188a91d3eaa 747 __O uint32_t FCR; /*!< Offset: 0x008 FIFO Control Register ( /W) */
Kojto 93:e188a91d3eaa 748 };
Kojto 93:e188a91d3eaa 749 __IO uint32_t LCR; /*!< Offset: 0x00C Line Control Register (R/W) */
Kojto 93:e188a91d3eaa 750 __IO uint32_t MCR; /*!< Offset: 0x010 Modem control Register (R/W) */
Kojto 93:e188a91d3eaa 751 __I uint32_t LSR; /*!< Offset: 0x014 Line Status Register (R/ ) */
Kojto 93:e188a91d3eaa 752 __I uint32_t MSR; /*!< Offset: 0x018 Modem status Register (R/ ) */
Kojto 93:e188a91d3eaa 753 __IO uint32_t SCR; /*!< Offset: 0x01C Scratch Pad Register (R/W) */
Kojto 93:e188a91d3eaa 754 __IO uint32_t ACR; /*!< Offset: 0x020 Auto-baud Control Register (R/W) */
Kojto 93:e188a91d3eaa 755 __IO uint32_t ICR; /*!< Offset: 0x024 irDA Control Register (R/W) */
Kojto 93:e188a91d3eaa 756 __IO uint32_t FDR; /*!< Offset: 0x028 Fractional Divider Register (R/W) */
Kojto 93:e188a91d3eaa 757 __IO uint32_t OSR; /*!< Offset: 0x02C Over sampling Register (R/W) */
Kojto 93:e188a91d3eaa 758 __O uint32_t POP; /*!< Offset: 0x030 NHP Pop Register (W) */
Kojto 93:e188a91d3eaa 759 __IO uint32_t MODE; /*!< Offset: 0x034 NHP Mode selection Register (W) */
Kojto 93:e188a91d3eaa 760 uint32_t RESERVED0[2];
Kojto 93:e188a91d3eaa 761 __IO uint32_t HDEN; /*!< Offset: 0x040 Half duplex Enable Register (R/W) */
Kojto 93:e188a91d3eaa 762 uint32_t RESERVED1;
Kojto 93:e188a91d3eaa 763 __IO uint32_t SCI_CTRL; /*!< Offset: 0x048 Smart card Interface Control Register (R/W) */
Kojto 93:e188a91d3eaa 764 __IO uint32_t RS485CTRL; /*!< Offset: 0x04C RS-485/EIA-485 Control Register (R/W) */
Kojto 93:e188a91d3eaa 765 __IO uint32_t ADRMATCH; /*!< Offset: 0x050 RS-485/EIA-485 address match Register (R/W) */
Kojto 93:e188a91d3eaa 766 __IO uint32_t RS485DLY; /*!< Offset: 0x054 RS-485/EIA-485 direction control delay Register (R/W) */
Kojto 93:e188a91d3eaa 767 __IO uint32_t SYNCCTRL; /*!< Offset: 0x058 Synchronous Mode Control Register (R/W ) */
Kojto 93:e188a91d3eaa 768 __IO uint32_t TER; /*!< Offset: 0x05C Transmit Enable Register (R/W) */
Kojto 93:e188a91d3eaa 769 uint32_t RESERVED2[989];
Kojto 93:e188a91d3eaa 770 __I uint32_t CFG; /*!< Offset: 0xFD4 Configuration Register (R) */
Kojto 93:e188a91d3eaa 771 __O uint32_t INTCE; /*!< Offset: 0xFD8 Interrupt Clear Enable Register (W) */
Kojto 93:e188a91d3eaa 772 __O uint32_t INTSE; /*!< Offset: 0xFDC Interrupt Set Enable Register (W) */
Kojto 93:e188a91d3eaa 773 __I uint32_t INTS; /*!< Offset: 0xFE0 Interrupt Status Register (R) */
Kojto 93:e188a91d3eaa 774 __I uint32_t INTE; /*!< Offset: 0xFE4 Interrupt Enable Register (R) */
Kojto 93:e188a91d3eaa 775 __O uint32_t INTCS; /*!< Offset: 0xFE8 Interrupt Clear Status Register (W) */
Kojto 93:e188a91d3eaa 776 __O uint32_t INTSS; /*!< Offset: 0xFEC Interrupt Set Status Register (W) */
Kojto 93:e188a91d3eaa 777 uint32_t RESERVED3[3];
Kojto 93:e188a91d3eaa 778 __I uint32_t MID; /*!< Offset: 0xFFC Module Identification Register (R) */
Kojto 93:e188a91d3eaa 779 } LPC_UART4_TypeDef;
Kojto 93:e188a91d3eaa 780 /*------------- Inter-Integrated Circuit (I2C) -------------------------------*/
Kojto 93:e188a91d3eaa 781 typedef struct
Kojto 93:e188a91d3eaa 782 {
Kojto 93:e188a91d3eaa 783 __IO uint32_t CONSET; /*!< Offset: 0x000 I2C Control Set Register (R/W) */
Kojto 93:e188a91d3eaa 784 __I uint32_t STAT; /*!< Offset: 0x004 I2C Status Register (R/ ) */
Kojto 93:e188a91d3eaa 785 __IO uint32_t DAT; /*!< Offset: 0x008 I2C Data Register (R/W) */
Kojto 93:e188a91d3eaa 786 __IO uint32_t ADR0; /*!< Offset: 0x00C I2C Slave Address Register 0 (R/W) */
Kojto 93:e188a91d3eaa 787 __IO uint32_t SCLH; /*!< Offset: 0x010 SCH Duty Cycle Register High Half Word (R/W) */
Kojto 93:e188a91d3eaa 788 __IO uint32_t SCLL; /*!< Offset: 0x014 SCL Duty Cycle Register Low Half Word (R/W) */
Kojto 93:e188a91d3eaa 789 __O uint32_t CONCLR; /*!< Offset: 0x018 I2C Control Clear Register ( /W) */
Kojto 93:e188a91d3eaa 790 __IO uint32_t MMCTRL; /*!< Offset: 0x01C Monitor mode control register (R/W) */
Kojto 93:e188a91d3eaa 791 __IO uint32_t ADR1; /*!< Offset: 0x020 I2C Slave Address Register 1 (R/W) */
Kojto 93:e188a91d3eaa 792 __IO uint32_t ADR2; /*!< Offset: 0x024 I2C Slave Address Register 2 (R/W) */
Kojto 93:e188a91d3eaa 793 __IO uint32_t ADR3; /*!< Offset: 0x028 I2C Slave Address Register 3 (R/W) */
Kojto 93:e188a91d3eaa 794 __I uint32_t DATA_BUFFER; /*!< Offset: 0x02C Data buffer register ( /W) */
Kojto 93:e188a91d3eaa 795 __IO uint32_t MASK0; /*!< Offset: 0x030 I2C Slave address mask register 0 (R/W) */
Kojto 93:e188a91d3eaa 796 __IO uint32_t MASK1; /*!< Offset: 0x034 I2C Slave address mask register 1 (R/W) */
Kojto 93:e188a91d3eaa 797 __IO uint32_t MASK2; /*!< Offset: 0x038 I2C Slave address mask register 2 (R/W) */
Kojto 93:e188a91d3eaa 798 __IO uint32_t MASK3; /*!< Offset: 0x03C I2C Slave address mask register 3 (R/W) */
Kojto 93:e188a91d3eaa 799 } LPC_I2C_TypeDef;
Kojto 93:e188a91d3eaa 800
Kojto 93:e188a91d3eaa 801 /*------------- Real-Time Clock (RTC) ----------------------------------------*/
Kojto 93:e188a91d3eaa 802 typedef struct
Kojto 93:e188a91d3eaa 803 {
Kojto 93:e188a91d3eaa 804 __IO uint8_t ILR;
Kojto 93:e188a91d3eaa 805 uint8_t RESERVED0[7];
Kojto 93:e188a91d3eaa 806 __IO uint8_t CCR;
Kojto 93:e188a91d3eaa 807 uint8_t RESERVED1[3];
Kojto 93:e188a91d3eaa 808 __IO uint8_t CIIR;
Kojto 93:e188a91d3eaa 809 uint8_t RESERVED2[3];
Kojto 93:e188a91d3eaa 810 __IO uint8_t AMR;
Kojto 93:e188a91d3eaa 811 uint8_t RESERVED3[3];
Kojto 93:e188a91d3eaa 812 __I uint32_t CTIME0;
Kojto 93:e188a91d3eaa 813 __I uint32_t CTIME1;
Kojto 93:e188a91d3eaa 814 __I uint32_t CTIME2;
Kojto 93:e188a91d3eaa 815 __IO uint8_t SEC;
Kojto 93:e188a91d3eaa 816 uint8_t RESERVED4[3];
Kojto 93:e188a91d3eaa 817 __IO uint8_t MIN;
Kojto 93:e188a91d3eaa 818 uint8_t RESERVED5[3];
Kojto 93:e188a91d3eaa 819 __IO uint8_t HOUR;
Kojto 93:e188a91d3eaa 820 uint8_t RESERVED6[3];
Kojto 93:e188a91d3eaa 821 __IO uint8_t DOM;
Kojto 93:e188a91d3eaa 822 uint8_t RESERVED7[3];
Kojto 93:e188a91d3eaa 823 __IO uint8_t DOW;
Kojto 93:e188a91d3eaa 824 uint8_t RESERVED8[3];
Kojto 93:e188a91d3eaa 825 __IO uint16_t DOY;
Kojto 93:e188a91d3eaa 826 uint16_t RESERVED9;
Kojto 93:e188a91d3eaa 827 __IO uint8_t MONTH;
Kojto 93:e188a91d3eaa 828 uint8_t RESERVED10[3];
Kojto 93:e188a91d3eaa 829 __IO uint16_t YEAR;
Kojto 93:e188a91d3eaa 830 uint16_t RESERVED11;
Kojto 93:e188a91d3eaa 831 __IO uint32_t CALIBRATION;
Kojto 93:e188a91d3eaa 832 __IO uint32_t GPREG0;
Kojto 93:e188a91d3eaa 833 __IO uint32_t GPREG1;
Kojto 93:e188a91d3eaa 834 __IO uint32_t GPREG2;
Kojto 93:e188a91d3eaa 835 __IO uint32_t GPREG3;
Kojto 93:e188a91d3eaa 836 __IO uint32_t GPREG4;
Kojto 93:e188a91d3eaa 837 __IO uint8_t RTC_AUXEN;
Kojto 93:e188a91d3eaa 838 uint8_t RESERVED12[3];
Kojto 93:e188a91d3eaa 839 __IO uint8_t RTC_AUX;
Kojto 93:e188a91d3eaa 840 uint8_t RESERVED13[3];
Kojto 93:e188a91d3eaa 841 __IO uint8_t ALSEC;
Kojto 93:e188a91d3eaa 842 uint8_t RESERVED14[3];
Kojto 93:e188a91d3eaa 843 __IO uint8_t ALMIN;
Kojto 93:e188a91d3eaa 844 uint8_t RESERVED15[3];
Kojto 93:e188a91d3eaa 845 __IO uint8_t ALHOUR;
Kojto 93:e188a91d3eaa 846 uint8_t RESERVED16[3];
Kojto 93:e188a91d3eaa 847 __IO uint8_t ALDOM;
Kojto 93:e188a91d3eaa 848 uint8_t RESERVED17[3];
Kojto 93:e188a91d3eaa 849 __IO uint8_t ALDOW;
Kojto 93:e188a91d3eaa 850 uint8_t RESERVED18[3];
Kojto 93:e188a91d3eaa 851 __IO uint16_t ALDOY;
Kojto 93:e188a91d3eaa 852 uint16_t RESERVED19;
Kojto 93:e188a91d3eaa 853 __IO uint8_t ALMON;
Kojto 93:e188a91d3eaa 854 uint8_t RESERVED20[3];
Kojto 93:e188a91d3eaa 855 __IO uint16_t ALYEAR;
Kojto 93:e188a91d3eaa 856 uint16_t RESERVED21;
Kojto 93:e188a91d3eaa 857 __IO uint32_t ERSTATUS;
Kojto 93:e188a91d3eaa 858 __IO uint32_t ERCONTROL;
Kojto 93:e188a91d3eaa 859 __IO uint32_t ERCOUNTERS;
Kojto 93:e188a91d3eaa 860 uint32_t RESERVED22;
Kojto 93:e188a91d3eaa 861 __IO uint32_t ERFIRSTSTAMP0;
Kojto 93:e188a91d3eaa 862 __IO uint32_t ERFIRSTSTAMP1;
Kojto 93:e188a91d3eaa 863 __IO uint32_t ERFIRSTSTAMP2;
Kojto 93:e188a91d3eaa 864 uint32_t RESERVED23;
Kojto 93:e188a91d3eaa 865 __IO uint32_t ERLASTSTAMP0;
Kojto 93:e188a91d3eaa 866 __IO uint32_t ERLASTSTAMP1;
Kojto 93:e188a91d3eaa 867 __IO uint32_t ERLASTSTAMP2;
Kojto 93:e188a91d3eaa 868 } LPC_RTC_TypeDef;
Kojto 93:e188a91d3eaa 869
Kojto 93:e188a91d3eaa 870
Kojto 93:e188a91d3eaa 871
Kojto 93:e188a91d3eaa 872 /*------------- Pin Connect Block (PINCON) -----------------------------------*/
Kojto 93:e188a91d3eaa 873 typedef struct
Kojto 93:e188a91d3eaa 874 {
Kojto 93:e188a91d3eaa 875 __IO uint32_t P0_0; /* 0x000 */
Kojto 93:e188a91d3eaa 876 __IO uint32_t P0_1;
Kojto 93:e188a91d3eaa 877 __IO uint32_t P0_2;
Kojto 93:e188a91d3eaa 878 __IO uint32_t P0_3;
Kojto 93:e188a91d3eaa 879 __IO uint32_t P0_4;
Kojto 93:e188a91d3eaa 880 __IO uint32_t P0_5;
Kojto 93:e188a91d3eaa 881 __IO uint32_t P0_6;
Kojto 93:e188a91d3eaa 882 __IO uint32_t P0_7;
Kojto 93:e188a91d3eaa 883
Kojto 93:e188a91d3eaa 884 __IO uint32_t P0_8; /* 0x020 */
Kojto 93:e188a91d3eaa 885 __IO uint32_t P0_9;
Kojto 93:e188a91d3eaa 886 __IO uint32_t P0_10;
Kojto 93:e188a91d3eaa 887 __IO uint32_t P0_11;
Kojto 93:e188a91d3eaa 888 __IO uint32_t P0_12;
Kojto 93:e188a91d3eaa 889 __IO uint32_t P0_13;
Kojto 93:e188a91d3eaa 890 __IO uint32_t P0_14;
Kojto 93:e188a91d3eaa 891 __IO uint32_t P0_15;
Kojto 93:e188a91d3eaa 892
Kojto 93:e188a91d3eaa 893 __IO uint32_t P0_16; /* 0x040 */
Kojto 93:e188a91d3eaa 894 __IO uint32_t P0_17;
Kojto 93:e188a91d3eaa 895 __IO uint32_t P0_18;
Kojto 93:e188a91d3eaa 896 __IO uint32_t P0_19;
Kojto 93:e188a91d3eaa 897 __IO uint32_t P0_20;
Kojto 93:e188a91d3eaa 898 __IO uint32_t P0_21;
Kojto 93:e188a91d3eaa 899 __IO uint32_t P0_22;
Kojto 93:e188a91d3eaa 900 __IO uint32_t P0_23;
Kojto 93:e188a91d3eaa 901
Kojto 93:e188a91d3eaa 902 __IO uint32_t P0_24; /* 0x060 */
Kojto 93:e188a91d3eaa 903 __IO uint32_t P0_25;
Kojto 93:e188a91d3eaa 904 __IO uint32_t P0_26;
Kojto 93:e188a91d3eaa 905 __IO uint32_t P0_27;
Kojto 93:e188a91d3eaa 906 __IO uint32_t P0_28;
Kojto 93:e188a91d3eaa 907 __IO uint32_t P0_29;
Kojto 93:e188a91d3eaa 908 __IO uint32_t P0_30;
Kojto 93:e188a91d3eaa 909 __IO uint32_t P0_31;
Kojto 93:e188a91d3eaa 910
Kojto 93:e188a91d3eaa 911 __IO uint32_t P1_0; /* 0x080 */
Kojto 93:e188a91d3eaa 912 __IO uint32_t P1_1;
Kojto 93:e188a91d3eaa 913 __IO uint32_t P1_2;
Kojto 93:e188a91d3eaa 914 __IO uint32_t P1_3;
Kojto 93:e188a91d3eaa 915 __IO uint32_t P1_4;
Kojto 93:e188a91d3eaa 916 __IO uint32_t P1_5;
Kojto 93:e188a91d3eaa 917 __IO uint32_t P1_6;
Kojto 93:e188a91d3eaa 918 __IO uint32_t P1_7;
Kojto 93:e188a91d3eaa 919
Kojto 93:e188a91d3eaa 920 __IO uint32_t P1_8; /* 0x0A0 */
Kojto 93:e188a91d3eaa 921 __IO uint32_t P1_9;
Kojto 93:e188a91d3eaa 922 __IO uint32_t P1_10;
Kojto 93:e188a91d3eaa 923 __IO uint32_t P1_11;
Kojto 93:e188a91d3eaa 924 __IO uint32_t P1_12;
Kojto 93:e188a91d3eaa 925 __IO uint32_t P1_13;
Kojto 93:e188a91d3eaa 926 __IO uint32_t P1_14;
Kojto 93:e188a91d3eaa 927 __IO uint32_t P1_15;
Kojto 93:e188a91d3eaa 928
Kojto 93:e188a91d3eaa 929 __IO uint32_t P1_16; /* 0x0C0 */
Kojto 93:e188a91d3eaa 930 __IO uint32_t P1_17;
Kojto 93:e188a91d3eaa 931 __IO uint32_t P1_18;
Kojto 93:e188a91d3eaa 932 __IO uint32_t P1_19;
Kojto 93:e188a91d3eaa 933 __IO uint32_t P1_20;
Kojto 93:e188a91d3eaa 934 __IO uint32_t P1_21;
Kojto 93:e188a91d3eaa 935 __IO uint32_t P1_22;
Kojto 93:e188a91d3eaa 936 __IO uint32_t P1_23;
Kojto 93:e188a91d3eaa 937
Kojto 93:e188a91d3eaa 938 __IO uint32_t P1_24; /* 0x0E0 */
Kojto 93:e188a91d3eaa 939 __IO uint32_t P1_25;
Kojto 93:e188a91d3eaa 940 __IO uint32_t P1_26;
Kojto 93:e188a91d3eaa 941 __IO uint32_t P1_27;
Kojto 93:e188a91d3eaa 942 __IO uint32_t P1_28;
Kojto 93:e188a91d3eaa 943 __IO uint32_t P1_29;
Kojto 93:e188a91d3eaa 944 __IO uint32_t P1_30;
Kojto 93:e188a91d3eaa 945 __IO uint32_t P1_31;
Kojto 93:e188a91d3eaa 946
Kojto 93:e188a91d3eaa 947 __IO uint32_t P2_0; /* 0x100 */
Kojto 93:e188a91d3eaa 948 __IO uint32_t P2_1;
Kojto 93:e188a91d3eaa 949 __IO uint32_t P2_2;
Kojto 93:e188a91d3eaa 950 __IO uint32_t P2_3;
Kojto 93:e188a91d3eaa 951 __IO uint32_t P2_4;
Kojto 93:e188a91d3eaa 952 __IO uint32_t P2_5;
Kojto 93:e188a91d3eaa 953 __IO uint32_t P2_6;
Kojto 93:e188a91d3eaa 954 __IO uint32_t P2_7;
Kojto 93:e188a91d3eaa 955
Kojto 93:e188a91d3eaa 956 __IO uint32_t P2_8; /* 0x120 */
Kojto 93:e188a91d3eaa 957 __IO uint32_t P2_9;
Kojto 93:e188a91d3eaa 958 __IO uint32_t P2_10;
Kojto 93:e188a91d3eaa 959 __IO uint32_t P2_11;
Kojto 93:e188a91d3eaa 960 __IO uint32_t P2_12;
Kojto 93:e188a91d3eaa 961 __IO uint32_t P2_13;
Kojto 93:e188a91d3eaa 962 __IO uint32_t P2_14;
Kojto 93:e188a91d3eaa 963 __IO uint32_t P2_15;
Kojto 93:e188a91d3eaa 964
Kojto 93:e188a91d3eaa 965 __IO uint32_t P2_16; /* 0x140 */
Kojto 93:e188a91d3eaa 966 __IO uint32_t P2_17;
Kojto 93:e188a91d3eaa 967 __IO uint32_t P2_18;
Kojto 93:e188a91d3eaa 968 __IO uint32_t P2_19;
Kojto 93:e188a91d3eaa 969 __IO uint32_t P2_20;
Kojto 93:e188a91d3eaa 970 __IO uint32_t P2_21;
Kojto 93:e188a91d3eaa 971 __IO uint32_t P2_22;
Kojto 93:e188a91d3eaa 972 __IO uint32_t P2_23;
Kojto 93:e188a91d3eaa 973
Kojto 93:e188a91d3eaa 974 __IO uint32_t P2_24; /* 0x160 */
Kojto 93:e188a91d3eaa 975 __IO uint32_t P2_25;
Kojto 93:e188a91d3eaa 976 __IO uint32_t P2_26;
Kojto 93:e188a91d3eaa 977 __IO uint32_t P2_27;
Kojto 93:e188a91d3eaa 978 __IO uint32_t P2_28;
Kojto 93:e188a91d3eaa 979 __IO uint32_t P2_29;
Kojto 93:e188a91d3eaa 980 __IO uint32_t P2_30;
Kojto 93:e188a91d3eaa 981 __IO uint32_t P2_31;
Kojto 93:e188a91d3eaa 982
Kojto 93:e188a91d3eaa 983 __IO uint32_t P3_0; /* 0x180 */
Kojto 93:e188a91d3eaa 984 __IO uint32_t P3_1;
Kojto 93:e188a91d3eaa 985 __IO uint32_t P3_2;
Kojto 93:e188a91d3eaa 986 __IO uint32_t P3_3;
Kojto 93:e188a91d3eaa 987 __IO uint32_t P3_4;
Kojto 93:e188a91d3eaa 988 __IO uint32_t P3_5;
Kojto 93:e188a91d3eaa 989 __IO uint32_t P3_6;
Kojto 93:e188a91d3eaa 990 __IO uint32_t P3_7;
Kojto 93:e188a91d3eaa 991
Kojto 93:e188a91d3eaa 992 __IO uint32_t P3_8; /* 0x1A0 */
Kojto 93:e188a91d3eaa 993 __IO uint32_t P3_9;
Kojto 93:e188a91d3eaa 994 __IO uint32_t P3_10;
Kojto 93:e188a91d3eaa 995 __IO uint32_t P3_11;
Kojto 93:e188a91d3eaa 996 __IO uint32_t P3_12;
Kojto 93:e188a91d3eaa 997 __IO uint32_t P3_13;
Kojto 93:e188a91d3eaa 998 __IO uint32_t P3_14;
Kojto 93:e188a91d3eaa 999 __IO uint32_t P3_15;
Kojto 93:e188a91d3eaa 1000
Kojto 93:e188a91d3eaa 1001 __IO uint32_t P3_16; /* 0x1C0 */
Kojto 93:e188a91d3eaa 1002 __IO uint32_t P3_17;
Kojto 93:e188a91d3eaa 1003 __IO uint32_t P3_18;
Kojto 93:e188a91d3eaa 1004 __IO uint32_t P3_19;
Kojto 93:e188a91d3eaa 1005 __IO uint32_t P3_20;
Kojto 93:e188a91d3eaa 1006 __IO uint32_t P3_21;
Kojto 93:e188a91d3eaa 1007 __IO uint32_t P3_22;
Kojto 93:e188a91d3eaa 1008 __IO uint32_t P3_23;
Kojto 93:e188a91d3eaa 1009
Kojto 93:e188a91d3eaa 1010 __IO uint32_t P3_24; /* 0x1E0 */
Kojto 93:e188a91d3eaa 1011 __IO uint32_t P3_25;
Kojto 93:e188a91d3eaa 1012 __IO uint32_t P3_26;
Kojto 93:e188a91d3eaa 1013 __IO uint32_t P3_27;
Kojto 93:e188a91d3eaa 1014 __IO uint32_t P3_28;
Kojto 93:e188a91d3eaa 1015 __IO uint32_t P3_29;
Kojto 93:e188a91d3eaa 1016 __IO uint32_t P3_30;
Kojto 93:e188a91d3eaa 1017 __IO uint32_t P3_31;
Kojto 93:e188a91d3eaa 1018
Kojto 93:e188a91d3eaa 1019 __IO uint32_t P4_0; /* 0x200 */
Kojto 93:e188a91d3eaa 1020 __IO uint32_t P4_1;
Kojto 93:e188a91d3eaa 1021 __IO uint32_t P4_2;
Kojto 93:e188a91d3eaa 1022 __IO uint32_t P4_3;
Kojto 93:e188a91d3eaa 1023 __IO uint32_t P4_4;
Kojto 93:e188a91d3eaa 1024 __IO uint32_t P4_5;
Kojto 93:e188a91d3eaa 1025 __IO uint32_t P4_6;
Kojto 93:e188a91d3eaa 1026 __IO uint32_t P4_7;
Kojto 93:e188a91d3eaa 1027
Kojto 93:e188a91d3eaa 1028 __IO uint32_t P4_8; /* 0x220 */
Kojto 93:e188a91d3eaa 1029 __IO uint32_t P4_9;
Kojto 93:e188a91d3eaa 1030 __IO uint32_t P4_10;
Kojto 93:e188a91d3eaa 1031 __IO uint32_t P4_11;
Kojto 93:e188a91d3eaa 1032 __IO uint32_t P4_12;
Kojto 93:e188a91d3eaa 1033 __IO uint32_t P4_13;
Kojto 93:e188a91d3eaa 1034 __IO uint32_t P4_14;
Kojto 93:e188a91d3eaa 1035 __IO uint32_t P4_15;
Kojto 93:e188a91d3eaa 1036
Kojto 93:e188a91d3eaa 1037 __IO uint32_t P4_16; /* 0x240 */
Kojto 93:e188a91d3eaa 1038 __IO uint32_t P4_17;
Kojto 93:e188a91d3eaa 1039 __IO uint32_t P4_18;
Kojto 93:e188a91d3eaa 1040 __IO uint32_t P4_19;
Kojto 93:e188a91d3eaa 1041 __IO uint32_t P4_20;
Kojto 93:e188a91d3eaa 1042 __IO uint32_t P4_21;
Kojto 93:e188a91d3eaa 1043 __IO uint32_t P4_22;
Kojto 93:e188a91d3eaa 1044 __IO uint32_t P4_23;
Kojto 93:e188a91d3eaa 1045
Kojto 93:e188a91d3eaa 1046 __IO uint32_t P4_24; /* 0x260 */
Kojto 93:e188a91d3eaa 1047 __IO uint32_t P4_25;
Kojto 93:e188a91d3eaa 1048 __IO uint32_t P4_26;
Kojto 93:e188a91d3eaa 1049 __IO uint32_t P4_27;
Kojto 93:e188a91d3eaa 1050 __IO uint32_t P4_28;
Kojto 93:e188a91d3eaa 1051 __IO uint32_t P4_29;
Kojto 93:e188a91d3eaa 1052 __IO uint32_t P4_30;
Kojto 93:e188a91d3eaa 1053 __IO uint32_t P4_31;
Kojto 93:e188a91d3eaa 1054
Kojto 93:e188a91d3eaa 1055 __IO uint32_t P5_0; /* 0x280 */
Kojto 93:e188a91d3eaa 1056 __IO uint32_t P5_1;
Kojto 93:e188a91d3eaa 1057 __IO uint32_t P5_2;
Kojto 93:e188a91d3eaa 1058 __IO uint32_t P5_3;
Kojto 93:e188a91d3eaa 1059 __IO uint32_t P5_4; /* 0x290 */
Kojto 93:e188a91d3eaa 1060 } LPC_IOCON_TypeDef;
Kojto 93:e188a91d3eaa 1061
Kojto 93:e188a91d3eaa 1062
Kojto 93:e188a91d3eaa 1063
Kojto 93:e188a91d3eaa 1064
Kojto 93:e188a91d3eaa 1065
Kojto 93:e188a91d3eaa 1066
Kojto 93:e188a91d3eaa 1067 /*------------- Synchronous Serial Communication (SSP) -----------------------*/
Kojto 93:e188a91d3eaa 1068 typedef struct
Kojto 93:e188a91d3eaa 1069 {
Kojto 93:e188a91d3eaa 1070 __IO uint32_t CR0; /*!< Offset: 0x000 Control Register 0 (R/W) */
Kojto 93:e188a91d3eaa 1071 __IO uint32_t CR1; /*!< Offset: 0x004 Control Register 1 (R/W) */
Kojto 93:e188a91d3eaa 1072 __IO uint32_t DR; /*!< Offset: 0x008 Data Register (R/W) */
Kojto 93:e188a91d3eaa 1073 __I uint32_t SR; /*!< Offset: 0x00C Status Registe (R/ ) */
Kojto 93:e188a91d3eaa 1074 __IO uint32_t CPSR; /*!< Offset: 0x010 Clock Prescale Register (R/W) */
Kojto 93:e188a91d3eaa 1075 __IO uint32_t IMSC; /*!< Offset: 0x014 Interrupt Mask Set and Clear Register (R/W) */
Kojto 93:e188a91d3eaa 1076 __IO uint32_t RIS; /*!< Offset: 0x018 Raw Interrupt Status Register (R/W) */
Kojto 93:e188a91d3eaa 1077 __IO uint32_t MIS; /*!< Offset: 0x01C Masked Interrupt Status Register (R/W) */
Kojto 93:e188a91d3eaa 1078 __IO uint32_t ICR; /*!< Offset: 0x020 SSPICR Interrupt Clear Register (R/W) */
Kojto 93:e188a91d3eaa 1079 __IO uint32_t DMACR;
Kojto 93:e188a91d3eaa 1080 } LPC_SSP_TypeDef;
Kojto 93:e188a91d3eaa 1081
Kojto 93:e188a91d3eaa 1082 /*------------- Analog-to-Digital Converter (ADC) ----------------------------*/
Kojto 93:e188a91d3eaa 1083 typedef struct
Kojto 93:e188a91d3eaa 1084 {
Kojto 93:e188a91d3eaa 1085 __IO uint32_t CR; /*!< Offset: 0x000 A/D Control Register (R/W) */
Kojto 93:e188a91d3eaa 1086 __IO uint32_t GDR; /*!< Offset: 0x004 A/D Global Data Register (R/W) */
Kojto 93:e188a91d3eaa 1087 uint32_t RESERVED0;
Kojto 93:e188a91d3eaa 1088 __IO uint32_t INTEN; /*!< Offset: 0x00C A/D Interrupt Enable Register (R/W) */
Kojto 93:e188a91d3eaa 1089 __IO uint32_t DR[8]; /*!< Offset: 0x010-0x02C A/D Channel 0..7 Data Register (R/W) */
Kojto 93:e188a91d3eaa 1090 __I uint32_t STAT; /*!< Offset: 0x030 A/D Status Register (R/ ) */
Kojto 93:e188a91d3eaa 1091 __IO uint32_t ADTRM;
Kojto 93:e188a91d3eaa 1092 } LPC_ADC_TypeDef;
Kojto 93:e188a91d3eaa 1093
Kojto 93:e188a91d3eaa 1094 /*------------- Controller Area Network (CAN) --------------------------------*/
Kojto 93:e188a91d3eaa 1095 typedef struct
Kojto 93:e188a91d3eaa 1096 {
Kojto 93:e188a91d3eaa 1097 __IO uint32_t mask[512]; /* ID Masks */
Kojto 93:e188a91d3eaa 1098 } LPC_CANAF_RAM_TypeDef;
Kojto 93:e188a91d3eaa 1099
Kojto 93:e188a91d3eaa 1100 typedef struct /* Acceptance Filter Registers */
Kojto 93:e188a91d3eaa 1101 {
Kojto 93:e188a91d3eaa 1102 ///Offset: 0x00000000 - Acceptance Filter Register
Kojto 93:e188a91d3eaa 1103 __IO uint32_t AFMR;
Kojto 93:e188a91d3eaa 1104
Kojto 93:e188a91d3eaa 1105 ///Offset: 0x00000004 - Standard Frame Individual Start Address Register
Kojto 93:e188a91d3eaa 1106 __IO uint32_t SFF_sa;
Kojto 93:e188a91d3eaa 1107
Kojto 93:e188a91d3eaa 1108 ///Offset: 0x00000008 - Standard Frame Group Start Address Register
Kojto 93:e188a91d3eaa 1109 __IO uint32_t SFF_GRP_sa;
Kojto 93:e188a91d3eaa 1110
Kojto 93:e188a91d3eaa 1111 ///Offset: 0x0000000C - Extended Frame Start Address Register
Kojto 93:e188a91d3eaa 1112 __IO uint32_t EFF_sa;
Kojto 93:e188a91d3eaa 1113
Kojto 93:e188a91d3eaa 1114 ///Offset: 0x00000010 - Extended Frame Group Start Address Register
Kojto 93:e188a91d3eaa 1115 __IO uint32_t EFF_GRP_sa;
Kojto 93:e188a91d3eaa 1116
Kojto 93:e188a91d3eaa 1117 ///Offset: 0x00000014 - End of AF Tables register
Kojto 93:e188a91d3eaa 1118 __IO uint32_t ENDofTable;
Kojto 93:e188a91d3eaa 1119
Kojto 93:e188a91d3eaa 1120 ///Offset: 0x00000018 - LUT Error Address register
Kojto 93:e188a91d3eaa 1121 __I uint32_t LUTerrAd;
Kojto 93:e188a91d3eaa 1122
Kojto 93:e188a91d3eaa 1123 ///Offset: 0x0000001C - LUT Error Register
Kojto 93:e188a91d3eaa 1124 __I uint32_t LUTerr;
Kojto 93:e188a91d3eaa 1125
Kojto 93:e188a91d3eaa 1126 ///Offset: 0x00000020 - CAN Central Transmit Status Register
Kojto 93:e188a91d3eaa 1127 __IO uint32_t FCANIE;
Kojto 93:e188a91d3eaa 1128
Kojto 93:e188a91d3eaa 1129 ///Offset: 0x00000024 - FullCAN Interrupt and Capture registers 0
Kojto 93:e188a91d3eaa 1130 __IO uint32_t FCANIC0;
Kojto 93:e188a91d3eaa 1131
Kojto 93:e188a91d3eaa 1132 ///Offset: 0x00000028 - FullCAN Interrupt and Capture registers 1
Kojto 93:e188a91d3eaa 1133 __IO uint32_t FCANIC1;
Kojto 93:e188a91d3eaa 1134 } LPC_CANAF_TypeDef;
Kojto 93:e188a91d3eaa 1135
Kojto 93:e188a91d3eaa 1136 typedef struct /* Central Registers */
Kojto 93:e188a91d3eaa 1137 {
Kojto 93:e188a91d3eaa 1138 __I uint32_t TxSR;
Kojto 93:e188a91d3eaa 1139 __I uint32_t RxSR;
Kojto 93:e188a91d3eaa 1140 __I uint32_t MSR;
Kojto 93:e188a91d3eaa 1141 } LPC_CANCR_TypeDef;
Kojto 93:e188a91d3eaa 1142
Kojto 93:e188a91d3eaa 1143 typedef struct /* Controller Registers */
Kojto 93:e188a91d3eaa 1144 {
Kojto 93:e188a91d3eaa 1145 ///Offset: 0x00000000 - Controls the operating mode of the CAN Controller
Kojto 93:e188a91d3eaa 1146 __IO uint32_t MOD;
Kojto 93:e188a91d3eaa 1147
Kojto 93:e188a91d3eaa 1148 ///Offset: 0x00000004 - Command bits that affect the state
Kojto 93:e188a91d3eaa 1149 __O uint32_t CMR;
Kojto 93:e188a91d3eaa 1150
Kojto 93:e188a91d3eaa 1151 ///Offset: 0x00000008 - Global Controller Status and Error Counters
Kojto 93:e188a91d3eaa 1152 __IO uint32_t GSR;
Kojto 93:e188a91d3eaa 1153
Kojto 93:e188a91d3eaa 1154 ///Offset: 0x0000000C - Interrupt status, Arbitration Lost Capture, Error Code Capture
Kojto 93:e188a91d3eaa 1155 __I uint32_t ICR;
Kojto 93:e188a91d3eaa 1156
Kojto 93:e188a91d3eaa 1157 ///Offset: 0x00000010 - Interrupt Enable Register
Kojto 93:e188a91d3eaa 1158 __IO uint32_t IER;
Kojto 93:e188a91d3eaa 1159
Kojto 93:e188a91d3eaa 1160 ///Offset: 0x00000014 - Bus Timing Register
Kojto 93:e188a91d3eaa 1161 __IO uint32_t BTR;
Kojto 93:e188a91d3eaa 1162
Kojto 93:e188a91d3eaa 1163 ///Offset: 0x00000018 - Error Warning Limit
Kojto 93:e188a91d3eaa 1164 __IO uint32_t EWL;
Kojto 93:e188a91d3eaa 1165
Kojto 93:e188a91d3eaa 1166 ///Offset: 0x0000001C - Status Register
Kojto 93:e188a91d3eaa 1167 __I uint32_t SR;
Kojto 93:e188a91d3eaa 1168
Kojto 93:e188a91d3eaa 1169 ///Offset: 0x00000020 - Receive frame status
Kojto 93:e188a91d3eaa 1170 __IO uint32_t RFS;
Kojto 93:e188a91d3eaa 1171
Kojto 93:e188a91d3eaa 1172 ///Offset: 0x00000024 - Received Identifier
Kojto 93:e188a91d3eaa 1173 __IO uint32_t RID;
Kojto 93:e188a91d3eaa 1174
Kojto 93:e188a91d3eaa 1175 ///Offset: 0x00000028 - Received data bytes 1-4
Kojto 93:e188a91d3eaa 1176 __IO uint32_t RDA;
Kojto 93:e188a91d3eaa 1177
Kojto 93:e188a91d3eaa 1178 ///Offset: 0x0000002C - Received data bytes 5-8
Kojto 93:e188a91d3eaa 1179 __IO uint32_t RDB;
Kojto 93:e188a91d3eaa 1180
Kojto 93:e188a91d3eaa 1181 ///Offset: 0x00000030 - Transmit frame info (Tx Buffer 1)
Kojto 93:e188a91d3eaa 1182 __IO uint32_t TFI1;
Kojto 93:e188a91d3eaa 1183
Kojto 93:e188a91d3eaa 1184 ///Offset: 0x00000034 - Transmit Identifier (Tx Buffer 1)
Kojto 93:e188a91d3eaa 1185 __IO uint32_t TID1;
Kojto 93:e188a91d3eaa 1186
Kojto 93:e188a91d3eaa 1187 ///Offset: 0x00000038 - Transmit data bytes 1-4 (Tx Buffer 1)
Kojto 93:e188a91d3eaa 1188 __IO uint32_t TDA1;
Kojto 93:e188a91d3eaa 1189
Kojto 93:e188a91d3eaa 1190 ///Offset: 0x0000003C - Transmit data bytes 5-8 (Tx Buffer 1)
Kojto 93:e188a91d3eaa 1191 __IO uint32_t TDB1;
Kojto 93:e188a91d3eaa 1192
Kojto 93:e188a91d3eaa 1193 ///Offset: 0x00000040 - Transmit frame info (Tx Buffer 2)
Kojto 93:e188a91d3eaa 1194 __IO uint32_t TFI2;
Kojto 93:e188a91d3eaa 1195
Kojto 93:e188a91d3eaa 1196 ///Offset: 0x00000044 - Transmit Identifier (Tx Buffer 2)
Kojto 93:e188a91d3eaa 1197 __IO uint32_t TID2;
Kojto 93:e188a91d3eaa 1198
Kojto 93:e188a91d3eaa 1199 ///Offset: 0x00000048 - Transmit data bytes 1-4 (Tx Buffer 2)
Kojto 93:e188a91d3eaa 1200 __IO uint32_t TDA2;
Kojto 93:e188a91d3eaa 1201
Kojto 93:e188a91d3eaa 1202 ///Offset: 0x0000004C - Transmit data bytes 5-8 (Tx Buffer 2)
Kojto 93:e188a91d3eaa 1203 __IO uint32_t TDB2;
Kojto 93:e188a91d3eaa 1204
Kojto 93:e188a91d3eaa 1205 ///Offset: 0x00000050 - Transmit frame info (Tx Buffer 3)
Kojto 93:e188a91d3eaa 1206 __IO uint32_t TFI3;
Kojto 93:e188a91d3eaa 1207
Kojto 93:e188a91d3eaa 1208 ///Offset: 0x00000054 - Transmit Identifier (Tx Buffer 3)
Kojto 93:e188a91d3eaa 1209 __IO uint32_t TID3;
Kojto 93:e188a91d3eaa 1210
Kojto 93:e188a91d3eaa 1211 ///Offset: 0x00000058 - Transmit data bytes 1-4 (Tx Buffer 3)
Kojto 93:e188a91d3eaa 1212 __IO uint32_t TDA3;
Kojto 93:e188a91d3eaa 1213
Kojto 93:e188a91d3eaa 1214 ///Offset: 0x0000005C - Transmit data bytes 5-8 (Tx Buffer 3)
Kojto 93:e188a91d3eaa 1215 __IO uint32_t TDB3;
Kojto 93:e188a91d3eaa 1216 } LPC_CAN_TypeDef;
Kojto 93:e188a91d3eaa 1217
Kojto 93:e188a91d3eaa 1218 /*------------- Digital-to-Analog Converter (DAC) ----------------------------*/
Kojto 93:e188a91d3eaa 1219 typedef struct
Kojto 93:e188a91d3eaa 1220 {
Kojto 93:e188a91d3eaa 1221 __IO uint32_t CR;
Kojto 93:e188a91d3eaa 1222 __IO uint32_t CTRL;
Kojto 93:e188a91d3eaa 1223 __IO uint32_t CNTVAL;
Kojto 93:e188a91d3eaa 1224 } LPC_DAC_TypeDef;
Kojto 93:e188a91d3eaa 1225
Kojto 93:e188a91d3eaa 1226
Kojto 93:e188a91d3eaa 1227 /*------------- Inter IC Sound (I2S) -----------------------------------------*/
Kojto 93:e188a91d3eaa 1228 typedef struct
Kojto 93:e188a91d3eaa 1229 {
Kojto 93:e188a91d3eaa 1230 __IO uint32_t DAO;
Kojto 93:e188a91d3eaa 1231 __IO uint32_t DAI;
Kojto 93:e188a91d3eaa 1232 __O uint32_t TXFIFO;
Kojto 93:e188a91d3eaa 1233 __I uint32_t RXFIFO;
Kojto 93:e188a91d3eaa 1234 __I uint32_t STATE;
Kojto 93:e188a91d3eaa 1235 __IO uint32_t DMA1;
Kojto 93:e188a91d3eaa 1236 __IO uint32_t DMA2;
Kojto 93:e188a91d3eaa 1237 __IO uint32_t IRQ;
Kojto 93:e188a91d3eaa 1238 __IO uint32_t TXRATE;
Kojto 93:e188a91d3eaa 1239 __IO uint32_t RXRATE;
Kojto 93:e188a91d3eaa 1240 __IO uint32_t TXBITRATE;
Kojto 93:e188a91d3eaa 1241 __IO uint32_t RXBITRATE;
Kojto 93:e188a91d3eaa 1242 __IO uint32_t TXMODE;
Kojto 93:e188a91d3eaa 1243 __IO uint32_t RXMODE;
Kojto 93:e188a91d3eaa 1244 } LPC_I2S_TypeDef;
Kojto 93:e188a91d3eaa 1245
Kojto 93:e188a91d3eaa 1246
Kojto 93:e188a91d3eaa 1247
Kojto 93:e188a91d3eaa 1248
Kojto 93:e188a91d3eaa 1249
Kojto 93:e188a91d3eaa 1250
Kojto 93:e188a91d3eaa 1251 /*------------- Motor Control Pulse-Width Modulation (MCPWM) -----------------*/
Kojto 93:e188a91d3eaa 1252 typedef struct
Kojto 93:e188a91d3eaa 1253 {
Kojto 93:e188a91d3eaa 1254 __I uint32_t CON;
Kojto 93:e188a91d3eaa 1255 __O uint32_t CON_SET;
Kojto 93:e188a91d3eaa 1256 __O uint32_t CON_CLR;
Kojto 93:e188a91d3eaa 1257 __I uint32_t CAPCON;
Kojto 93:e188a91d3eaa 1258 __O uint32_t CAPCON_SET;
Kojto 93:e188a91d3eaa 1259 __O uint32_t CAPCON_CLR;
Kojto 93:e188a91d3eaa 1260 __IO uint32_t TC0;
Kojto 93:e188a91d3eaa 1261 __IO uint32_t TC1;
Kojto 93:e188a91d3eaa 1262 __IO uint32_t TC2;
Kojto 93:e188a91d3eaa 1263 __IO uint32_t LIM0;
Kojto 93:e188a91d3eaa 1264 __IO uint32_t LIM1;
Kojto 93:e188a91d3eaa 1265 __IO uint32_t LIM2;
Kojto 93:e188a91d3eaa 1266 __IO uint32_t MAT0;
Kojto 93:e188a91d3eaa 1267 __IO uint32_t MAT1;
Kojto 93:e188a91d3eaa 1268 __IO uint32_t MAT2;
Kojto 93:e188a91d3eaa 1269 __IO uint32_t DT;
Kojto 93:e188a91d3eaa 1270 __IO uint32_t CP;
Kojto 93:e188a91d3eaa 1271 __IO uint32_t CAP0;
Kojto 93:e188a91d3eaa 1272 __IO uint32_t CAP1;
Kojto 93:e188a91d3eaa 1273 __IO uint32_t CAP2;
Kojto 93:e188a91d3eaa 1274 __I uint32_t INTEN;
Kojto 93:e188a91d3eaa 1275 __O uint32_t INTEN_SET;
Kojto 93:e188a91d3eaa 1276 __O uint32_t INTEN_CLR;
Kojto 93:e188a91d3eaa 1277 __I uint32_t CNTCON;
Kojto 93:e188a91d3eaa 1278 __O uint32_t CNTCON_SET;
Kojto 93:e188a91d3eaa 1279 __O uint32_t CNTCON_CLR;
Kojto 93:e188a91d3eaa 1280 __I uint32_t INTF;
Kojto 93:e188a91d3eaa 1281 __O uint32_t INTF_SET;
Kojto 93:e188a91d3eaa 1282 __O uint32_t INTF_CLR;
Kojto 93:e188a91d3eaa 1283 __O uint32_t CAP_CLR;
Kojto 93:e188a91d3eaa 1284 } LPC_MCPWM_TypeDef;
Kojto 93:e188a91d3eaa 1285
Kojto 93:e188a91d3eaa 1286 /*------------- Quadrature Encoder Interface (QEI) ---------------------------*/
Kojto 93:e188a91d3eaa 1287 typedef struct
Kojto 93:e188a91d3eaa 1288 {
Kojto 93:e188a91d3eaa 1289 __O uint32_t CON;
Kojto 93:e188a91d3eaa 1290 __I uint32_t STAT;
Kojto 93:e188a91d3eaa 1291 __IO uint32_t CONF;
Kojto 93:e188a91d3eaa 1292 __I uint32_t POS;
Kojto 93:e188a91d3eaa 1293 __IO uint32_t MAXPOS;
Kojto 93:e188a91d3eaa 1294 __IO uint32_t CMPOS0;
Kojto 93:e188a91d3eaa 1295 __IO uint32_t CMPOS1;
Kojto 93:e188a91d3eaa 1296 __IO uint32_t CMPOS2;
Kojto 93:e188a91d3eaa 1297 __I uint32_t INXCNT;
Kojto 93:e188a91d3eaa 1298 __IO uint32_t INXCMP0;
Kojto 93:e188a91d3eaa 1299 __IO uint32_t LOAD;
Kojto 93:e188a91d3eaa 1300 __I uint32_t TIME;
Kojto 93:e188a91d3eaa 1301 __I uint32_t VEL;
Kojto 93:e188a91d3eaa 1302 __I uint32_t CAP;
Kojto 93:e188a91d3eaa 1303 __IO uint32_t VELCOMP;
Kojto 93:e188a91d3eaa 1304 __IO uint32_t FILTERPHA;
Kojto 93:e188a91d3eaa 1305 __IO uint32_t FILTERPHB;
Kojto 93:e188a91d3eaa 1306 __IO uint32_t FILTERINX;
Kojto 93:e188a91d3eaa 1307 __IO uint32_t WINDOW;
Kojto 93:e188a91d3eaa 1308 __IO uint32_t INXCMP1;
Kojto 93:e188a91d3eaa 1309 __IO uint32_t INXCMP2;
Kojto 93:e188a91d3eaa 1310 uint32_t RESERVED0[993];
Kojto 93:e188a91d3eaa 1311 __O uint32_t IEC;
Kojto 93:e188a91d3eaa 1312 __O uint32_t IES;
Kojto 93:e188a91d3eaa 1313 __I uint32_t INTSTAT;
Kojto 93:e188a91d3eaa 1314 __I uint32_t IE;
Kojto 93:e188a91d3eaa 1315 __O uint32_t CLR;
Kojto 93:e188a91d3eaa 1316 __O uint32_t SET;
Kojto 93:e188a91d3eaa 1317 } LPC_QEI_TypeDef;
Kojto 93:e188a91d3eaa 1318
Kojto 93:e188a91d3eaa 1319 /*------------- SD/MMC card Interface (MCI)-----------------------------------*/
Kojto 93:e188a91d3eaa 1320 typedef struct
Kojto 93:e188a91d3eaa 1321 {
Kojto 93:e188a91d3eaa 1322 __IO uint32_t POWER;
Kojto 93:e188a91d3eaa 1323 __IO uint32_t CLOCK;
Kojto 93:e188a91d3eaa 1324 __IO uint32_t ARGUMENT;
Kojto 93:e188a91d3eaa 1325 __IO uint32_t COMMAND;
Kojto 93:e188a91d3eaa 1326 __I uint32_t RESP_CMD;
Kojto 93:e188a91d3eaa 1327 __I uint32_t RESP0;
Kojto 93:e188a91d3eaa 1328 __I uint32_t RESP1;
Kojto 93:e188a91d3eaa 1329 __I uint32_t RESP2;
Kojto 93:e188a91d3eaa 1330 __I uint32_t RESP3;
Kojto 93:e188a91d3eaa 1331 __IO uint32_t DATATMR;
Kojto 93:e188a91d3eaa 1332 __IO uint32_t DATALEN;
Kojto 93:e188a91d3eaa 1333 __IO uint32_t DATACTRL;
Kojto 93:e188a91d3eaa 1334 __I uint32_t DATACNT;
Kojto 93:e188a91d3eaa 1335 __I uint32_t STATUS;
Kojto 93:e188a91d3eaa 1336 __O uint32_t CLEAR;
Kojto 93:e188a91d3eaa 1337 __IO uint32_t MASK0;
Kojto 93:e188a91d3eaa 1338 uint32_t RESERVED0[2];
Kojto 93:e188a91d3eaa 1339 __I uint32_t FIFOCNT;
Kojto 93:e188a91d3eaa 1340 uint32_t RESERVED1[13];
Kojto 93:e188a91d3eaa 1341 __IO uint32_t FIFO[16];
Kojto 93:e188a91d3eaa 1342 } LPC_MCI_TypeDef;
Kojto 93:e188a91d3eaa 1343
Kojto 93:e188a91d3eaa 1344
Kojto 93:e188a91d3eaa 1345
Kojto 93:e188a91d3eaa 1346
Kojto 93:e188a91d3eaa 1347
Kojto 93:e188a91d3eaa 1348
Kojto 93:e188a91d3eaa 1349
Kojto 93:e188a91d3eaa 1350
Kojto 93:e188a91d3eaa 1351
Kojto 93:e188a91d3eaa 1352
Kojto 93:e188a91d3eaa 1353 /*------------- EEPROM Controller (EEPROM) -----------------------------------*/
Kojto 93:e188a91d3eaa 1354 typedef struct
Kojto 93:e188a91d3eaa 1355 {
Kojto 93:e188a91d3eaa 1356 __IO uint32_t CMD; /* 0x0080 */
Kojto 93:e188a91d3eaa 1357 __IO uint32_t ADDR;
Kojto 93:e188a91d3eaa 1358 __IO uint32_t WDATA;
Kojto 93:e188a91d3eaa 1359 __IO uint32_t RDATA;
Kojto 93:e188a91d3eaa 1360 __IO uint32_t WSTATE; /* 0x0090 */
Kojto 93:e188a91d3eaa 1361 __IO uint32_t CLKDIV;
Kojto 93:e188a91d3eaa 1362 __IO uint32_t PWRDWN; /* 0x0098 */
Kojto 93:e188a91d3eaa 1363 uint32_t RESERVED0[975];
Kojto 93:e188a91d3eaa 1364 __IO uint32_t INT_CLR_ENABLE; /* 0x0FD8 */
Kojto 93:e188a91d3eaa 1365 __IO uint32_t INT_SET_ENABLE;
Kojto 93:e188a91d3eaa 1366 __IO uint32_t INT_STATUS; /* 0x0FE0 */
Kojto 93:e188a91d3eaa 1367 __IO uint32_t INT_ENABLE;
Kojto 93:e188a91d3eaa 1368 __IO uint32_t INT_CLR_STATUS;
Kojto 93:e188a91d3eaa 1369 __IO uint32_t INT_SET_STATUS;
Kojto 93:e188a91d3eaa 1370 } LPC_EEPROM_TypeDef;
Kojto 93:e188a91d3eaa 1371
Kojto 93:e188a91d3eaa 1372
Kojto 93:e188a91d3eaa 1373 /*------------- COMPARATOR ----------------------------------------------------*/
Kojto 93:e188a91d3eaa 1374
Kojto 93:e188a91d3eaa 1375 typedef struct { /*!< (@ 0x40020000) COMPARATOR Structure */
Kojto 93:e188a91d3eaa 1376 __IO uint32_t CTRL; /*!< (@ 0x40020000) Comparator block control register */
Kojto 93:e188a91d3eaa 1377 __IO uint32_t CTRL0; /*!< (@ 0x40020004) Comparator 0 control register */
Kojto 93:e188a91d3eaa 1378 __IO uint32_t CTRL1; /*!< (@ 0x40020008) Comparator 1 control register */
Kojto 93:e188a91d3eaa 1379 } LPC_COMPARATOR_Type;
Kojto 93:e188a91d3eaa 1380
Kojto 93:e188a91d3eaa 1381
Kojto 93:e188a91d3eaa 1382 #if defined ( __CC_ARM )
Kojto 93:e188a91d3eaa 1383 #pragma no_anon_unions
Kojto 93:e188a91d3eaa 1384 #endif
Kojto 93:e188a91d3eaa 1385
Kojto 93:e188a91d3eaa 1386 /******************************************************************************/
Kojto 93:e188a91d3eaa 1387 /* Peripheral memory map */
Kojto 93:e188a91d3eaa 1388 /******************************************************************************/
Kojto 93:e188a91d3eaa 1389 /* Base addresses */
Kojto 93:e188a91d3eaa 1390 #define LPC_FLASH_BASE (0x00000000UL)
Kojto 93:e188a91d3eaa 1391 #define LPC_RAM_BASE (0x10000000UL)
Kojto 93:e188a91d3eaa 1392 #define LPC_PERI_RAM_BASE (0x20000000UL)
Kojto 93:e188a91d3eaa 1393 #define LPC_APB0_BASE (0x40000000UL)
Kojto 93:e188a91d3eaa 1394 #define LPC_APB1_BASE (0x40080000UL)
Kojto 93:e188a91d3eaa 1395 #define LPC_AHBRAM1_BASE (0x20004000UL)
Kojto 93:e188a91d3eaa 1396 #define LPC_AHB_BASE (0x20080000UL)
Kojto 93:e188a91d3eaa 1397 #define LPC_CM3_BASE (0xE0000000UL)
Kojto 93:e188a91d3eaa 1398
Kojto 93:e188a91d3eaa 1399 /* APB0 peripherals */
Kojto 93:e188a91d3eaa 1400 #define LPC_WDT_BASE (LPC_APB0_BASE + 0x00000)
Kojto 93:e188a91d3eaa 1401 #define LPC_TIM0_BASE (LPC_APB0_BASE + 0x04000)
Kojto 93:e188a91d3eaa 1402 #define LPC_TIM1_BASE (LPC_APB0_BASE + 0x08000)
Kojto 93:e188a91d3eaa 1403 #define LPC_UART0_BASE (LPC_APB0_BASE + 0x0C000)
Kojto 93:e188a91d3eaa 1404 #define LPC_UART1_BASE (LPC_APB0_BASE + 0x10000)
Kojto 93:e188a91d3eaa 1405 #define LPC_PWM0_BASE (LPC_APB0_BASE + 0x14000)
Kojto 93:e188a91d3eaa 1406 #define LPC_PWM1_BASE (LPC_APB0_BASE + 0x18000)
Kojto 93:e188a91d3eaa 1407 #define LPC_I2C0_BASE (LPC_APB0_BASE + 0x1C000)
Kojto 93:e188a91d3eaa 1408 #define LPC_COMPARATOR_BASE (LPC_APB0_BASE + 0x20000)
Kojto 93:e188a91d3eaa 1409 #define LPC_RTC_BASE (LPC_APB0_BASE + 0x24000)
Kojto 93:e188a91d3eaa 1410 #define LPC_GPIOINT_BASE (LPC_APB0_BASE + 0x28080)
Kojto 93:e188a91d3eaa 1411 #define LPC_IOCON_BASE (LPC_APB0_BASE + 0x2C000)
Kojto 93:e188a91d3eaa 1412 #define LPC_SSP1_BASE (LPC_APB0_BASE + 0x30000)
Kojto 93:e188a91d3eaa 1413 #define LPC_ADC_BASE (LPC_APB0_BASE + 0x34000)
Kojto 93:e188a91d3eaa 1414 #define LPC_CANAF_RAM_BASE (LPC_APB0_BASE + 0x38000)
Kojto 93:e188a91d3eaa 1415 #define LPC_CANAF_BASE (LPC_APB0_BASE + 0x3C000)
Kojto 93:e188a91d3eaa 1416 #define LPC_CANCR_BASE (LPC_APB0_BASE + 0x40000)
Kojto 93:e188a91d3eaa 1417 #define LPC_CAN1_BASE (LPC_APB0_BASE + 0x44000)
Kojto 93:e188a91d3eaa 1418 #define LPC_CAN2_BASE (LPC_APB0_BASE + 0x48000)
Kojto 93:e188a91d3eaa 1419 #define LPC_I2C1_BASE (LPC_APB0_BASE + 0x5C000)
Kojto 93:e188a91d3eaa 1420
Kojto 93:e188a91d3eaa 1421 /* APB1 peripherals */
Kojto 93:e188a91d3eaa 1422 #define LPC_SSP0_BASE (LPC_APB1_BASE + 0x08000)
Kojto 93:e188a91d3eaa 1423 #define LPC_DAC_BASE (LPC_APB1_BASE + 0x0C000)
Kojto 93:e188a91d3eaa 1424 #define LPC_TIM2_BASE (LPC_APB1_BASE + 0x10000)
Kojto 93:e188a91d3eaa 1425 #define LPC_TIM3_BASE (LPC_APB1_BASE + 0x14000)
Kojto 93:e188a91d3eaa 1426 #define LPC_UART2_BASE (LPC_APB1_BASE + 0x18000)
Kojto 93:e188a91d3eaa 1427 #define LPC_UART3_BASE (LPC_APB1_BASE + 0x1C000)
Kojto 93:e188a91d3eaa 1428 #define LPC_I2C2_BASE (LPC_APB1_BASE + 0x20000)
Kojto 93:e188a91d3eaa 1429 #define LPC_UART4_BASE (LPC_APB1_BASE + 0x24000)
Kojto 93:e188a91d3eaa 1430 #define LPC_I2S_BASE (LPC_APB1_BASE + 0x28000)
Kojto 93:e188a91d3eaa 1431 #define LPC_SSP2_BASE (LPC_APB1_BASE + 0x2C000)
Kojto 93:e188a91d3eaa 1432 #define LPC_MCPWM_BASE (LPC_APB1_BASE + 0x38000)
Kojto 93:e188a91d3eaa 1433 #define LPC_QEI_BASE (LPC_APB1_BASE + 0x3C000)
Kojto 93:e188a91d3eaa 1434 #define LPC_MCI_BASE (LPC_APB1_BASE + 0x40000)
Kojto 93:e188a91d3eaa 1435 #define LPC_SC_BASE (LPC_APB1_BASE + 0x7C000)
Kojto 93:e188a91d3eaa 1436
Kojto 93:e188a91d3eaa 1437 /* AHB peripherals */
Kojto 93:e188a91d3eaa 1438 #define LPC_GPDMA_BASE (LPC_AHB_BASE + 0x00000)
Kojto 93:e188a91d3eaa 1439 #define LPC_GPDMACH0_BASE (LPC_AHB_BASE + 0x00100)
Kojto 93:e188a91d3eaa 1440 #define LPC_GPDMACH1_BASE (LPC_AHB_BASE + 0x00120)
Kojto 93:e188a91d3eaa 1441 #define LPC_GPDMACH2_BASE (LPC_AHB_BASE + 0x00140)
Kojto 93:e188a91d3eaa 1442 #define LPC_GPDMACH3_BASE (LPC_AHB_BASE + 0x00160)
Kojto 93:e188a91d3eaa 1443 #define LPC_GPDMACH4_BASE (LPC_AHB_BASE + 0x00180)
Kojto 93:e188a91d3eaa 1444 #define LPC_GPDMACH5_BASE (LPC_AHB_BASE + 0x001A0)
Kojto 93:e188a91d3eaa 1445 #define LPC_GPDMACH6_BASE (LPC_AHB_BASE + 0x001C0)
Kojto 93:e188a91d3eaa 1446 #define LPC_GPDMACH7_BASE (LPC_AHB_BASE + 0x001E0)
Kojto 93:e188a91d3eaa 1447 #define LPC_EMAC_BASE (LPC_AHB_BASE + 0x04000)
Kojto 93:e188a91d3eaa 1448 #define LPC_LCD_BASE (LPC_AHB_BASE + 0x08000)
Kojto 93:e188a91d3eaa 1449 #define LPC_USB_BASE (LPC_AHB_BASE + 0x0C000)
Kojto 93:e188a91d3eaa 1450 #define LPC_CRC_BASE (LPC_AHB_BASE + 0x10000)
Kojto 93:e188a91d3eaa 1451 #define LPC_GPIO0_BASE (LPC_AHB_BASE + 0x18000)
Kojto 93:e188a91d3eaa 1452 #define LPC_GPIO1_BASE (LPC_AHB_BASE + 0x18020)
Kojto 93:e188a91d3eaa 1453 #define LPC_GPIO2_BASE (LPC_AHB_BASE + 0x18040)
Kojto 93:e188a91d3eaa 1454 #define LPC_GPIO3_BASE (LPC_AHB_BASE + 0x18060)
Kojto 93:e188a91d3eaa 1455 #define LPC_GPIO4_BASE (LPC_AHB_BASE + 0x18080)
Kojto 93:e188a91d3eaa 1456 #define LPC_GPIO5_BASE (LPC_AHB_BASE + 0x180A0)
Kojto 93:e188a91d3eaa 1457 #define LPC_EMC_BASE (LPC_AHB_BASE + 0x1C000)
Kojto 93:e188a91d3eaa 1458
Kojto 93:e188a91d3eaa 1459 #define LPC_EEPROM_BASE (LPC_FLASH_BASE+ 0x200080)
Kojto 93:e188a91d3eaa 1460
Kojto 93:e188a91d3eaa 1461
Kojto 93:e188a91d3eaa 1462 /******************************************************************************/
Kojto 93:e188a91d3eaa 1463 /* Peripheral declaration */
Kojto 93:e188a91d3eaa 1464 /******************************************************************************/
Kojto 93:e188a91d3eaa 1465 #define LPC_SC ((LPC_SC_TypeDef *) LPC_SC_BASE )
Kojto 93:e188a91d3eaa 1466 #define LPC_WDT ((LPC_WDT_TypeDef *) LPC_WDT_BASE )
Kojto 93:e188a91d3eaa 1467 #define LPC_TIM0 ((LPC_TIM_TypeDef *) LPC_TIM0_BASE )
Kojto 93:e188a91d3eaa 1468 #define LPC_TIM1 ((LPC_TIM_TypeDef *) LPC_TIM1_BASE )
Kojto 93:e188a91d3eaa 1469 #define LPC_TIM2 ((LPC_TIM_TypeDef *) LPC_TIM2_BASE )
Kojto 93:e188a91d3eaa 1470 #define LPC_TIM3 ((LPC_TIM_TypeDef *) LPC_TIM3_BASE )
Kojto 93:e188a91d3eaa 1471 #define LPC_UART0 ((LPC_UART_TypeDef *) LPC_UART0_BASE )
Kojto 93:e188a91d3eaa 1472 #define LPC_UART1 ((LPC_UART1_TypeDef *) LPC_UART1_BASE )
Kojto 93:e188a91d3eaa 1473 #define LPC_UART2 ((LPC_UART_TypeDef *) LPC_UART2_BASE )
Kojto 93:e188a91d3eaa 1474 #define LPC_UART3 ((LPC_UART_TypeDef *) LPC_UART3_BASE )
Kojto 93:e188a91d3eaa 1475 #define LPC_UART4 ((LPC_UART4_TypeDef *) LPC_UART4_BASE )
Kojto 93:e188a91d3eaa 1476 #define LPC_PWM0 ((LPC_PWM_TypeDef *) LPC_PWM0_BASE )
Kojto 93:e188a91d3eaa 1477 #define LPC_PWM1 ((LPC_PWM_TypeDef *) LPC_PWM1_BASE )
Kojto 93:e188a91d3eaa 1478 #define LPC_I2C0 ((LPC_I2C_TypeDef *) LPC_I2C0_BASE )
Kojto 93:e188a91d3eaa 1479 #define LPC_I2C1 ((LPC_I2C_TypeDef *) LPC_I2C1_BASE )
Kojto 93:e188a91d3eaa 1480 #define LPC_I2C2 ((LPC_I2C_TypeDef *) LPC_I2C2_BASE )
Kojto 93:e188a91d3eaa 1481 #define LPC_I2S ((LPC_I2S_TypeDef *) LPC_I2S_BASE )
Kojto 93:e188a91d3eaa 1482 #define LPC_COMPARATOR ((LPC_COMPARATOR_Type *) LPC_COMPARATOR_BASE)
Kojto 93:e188a91d3eaa 1483 #define LPC_RTC ((LPC_RTC_TypeDef *) LPC_RTC_BASE )
Kojto 93:e188a91d3eaa 1484 #define LPC_GPIOINT ((LPC_GPIOINT_TypeDef *) LPC_GPIOINT_BASE )
Kojto 93:e188a91d3eaa 1485 #define LPC_IOCON ((LPC_IOCON_TypeDef *) LPC_IOCON_BASE )
Kojto 93:e188a91d3eaa 1486 #define LPC_SSP0 ((LPC_SSP_TypeDef *) LPC_SSP0_BASE )
Kojto 93:e188a91d3eaa 1487 #define LPC_SSP1 ((LPC_SSP_TypeDef *) LPC_SSP1_BASE )
Kojto 93:e188a91d3eaa 1488 #define LPC_SSP2 ((LPC_SSP_TypeDef *) LPC_SSP2_BASE )
Kojto 93:e188a91d3eaa 1489 #define LPC_ADC ((LPC_ADC_TypeDef *) LPC_ADC_BASE )
Kojto 93:e188a91d3eaa 1490 #define LPC_DAC ((LPC_DAC_TypeDef *) LPC_DAC_BASE )
Kojto 93:e188a91d3eaa 1491 #define LPC_CANAF_RAM ((LPC_CANAF_RAM_TypeDef *) LPC_CANAF_RAM_BASE)
Kojto 93:e188a91d3eaa 1492 #define LPC_CANAF ((LPC_CANAF_TypeDef *) LPC_CANAF_BASE )
Kojto 93:e188a91d3eaa 1493 #define LPC_CANCR ((LPC_CANCR_TypeDef *) LPC_CANCR_BASE )
Kojto 93:e188a91d3eaa 1494 #define LPC_CAN1 ((LPC_CAN_TypeDef *) LPC_CAN1_BASE )
Kojto 93:e188a91d3eaa 1495 #define LPC_CAN2 ((LPC_CAN_TypeDef *) LPC_CAN2_BASE )
Kojto 93:e188a91d3eaa 1496 #define LPC_MCPWM ((LPC_MCPWM_TypeDef *) LPC_MCPWM_BASE )
Kojto 93:e188a91d3eaa 1497 #define LPC_QEI ((LPC_QEI_TypeDef *) LPC_QEI_BASE )
Kojto 93:e188a91d3eaa 1498 #define LPC_MCI ((LPC_MCI_TypeDef *) LPC_MCI_BASE )
Kojto 93:e188a91d3eaa 1499 #define LPC_GPDMA ((LPC_GPDMA_TypeDef *) LPC_GPDMA_BASE )
Kojto 93:e188a91d3eaa 1500 #define LPC_GPDMACH0 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH0_BASE )
Kojto 93:e188a91d3eaa 1501 #define LPC_GPDMACH1 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH1_BASE )
Kojto 93:e188a91d3eaa 1502 #define LPC_GPDMACH2 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH2_BASE )
Kojto 93:e188a91d3eaa 1503 #define LPC_GPDMACH3 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH3_BASE )
Kojto 93:e188a91d3eaa 1504 #define LPC_GPDMACH4 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH4_BASE )
Kojto 93:e188a91d3eaa 1505 #define LPC_GPDMACH5 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH5_BASE )
Kojto 93:e188a91d3eaa 1506 #define LPC_GPDMACH6 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH6_BASE )
Kojto 93:e188a91d3eaa 1507 #define LPC_GPDMACH7 ((LPC_GPDMACH_TypeDef *) LPC_GPDMACH7_BASE )
Kojto 93:e188a91d3eaa 1508 #define LPC_EMAC ((LPC_EMAC_TypeDef *) LPC_EMAC_BASE )
Kojto 93:e188a91d3eaa 1509 #define LPC_LCD ((LPC_LCD_TypeDef *) LPC_LCD_BASE )
Kojto 93:e188a91d3eaa 1510 #define LPC_USB ((LPC_USB_TypeDef *) LPC_USB_BASE )
Kojto 93:e188a91d3eaa 1511 #define LPC_GPIO0 ((LPC_GPIO_TypeDef *) LPC_GPIO0_BASE )
Kojto 93:e188a91d3eaa 1512 #define LPC_GPIO1 ((LPC_GPIO_TypeDef *) LPC_GPIO1_BASE )
Kojto 93:e188a91d3eaa 1513 #define LPC_GPIO2 ((LPC_GPIO_TypeDef *) LPC_GPIO2_BASE )
Kojto 93:e188a91d3eaa 1514 #define LPC_GPIO3 ((LPC_GPIO_TypeDef *) LPC_GPIO3_BASE )
Kojto 93:e188a91d3eaa 1515 #define LPC_GPIO4 ((LPC_GPIO_TypeDef *) LPC_GPIO4_BASE )
Kojto 93:e188a91d3eaa 1516 #define LPC_GPIO5 ((LPC_GPIO_TypeDef *) LPC_GPIO5_BASE )
Kojto 93:e188a91d3eaa 1517 #define LPC_EMC ((LPC_EMC_TypeDef *) LPC_EMC_BASE )
Kojto 93:e188a91d3eaa 1518 #define LPC_CRC ((LPC_CRC_TypeDef *) LPC_CRC_BASE )
Kojto 93:e188a91d3eaa 1519 #define LPC_EEPROM ((LPC_EEPROM_TypeDef *) LPC_EEPROM_BASE )
Kojto 93:e188a91d3eaa 1520
Kojto 93:e188a91d3eaa 1521
Kojto 93:e188a91d3eaa 1522
Kojto 93:e188a91d3eaa 1523 #endif // __LPC407x_8x_177x_8x_H__