LPCOpen Platform  v1.03
LPCOpen Platform for NXP LPC Microcontrollers
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
chip_lpc407x_8x.h
Go to the documentation of this file.
1 /*
2  * @brief LPC407x/8x basic chip inclusion file
3  *
4  * @note
5  * Copyright(C) NXP Semiconductors, 2012
6  * All rights reserved.
7  *
8  * @par
9  * Software that is described herein is for illustrative purposes only
10  * which provides customers with programming information regarding the
11  * LPC products. This software is supplied "AS IS" without any warranties of
12  * any kind, and NXP Semiconductors and its licensor disclaim any and
13  * all warranties, express or implied, including all implied warranties of
14  * merchantability, fitness for a particular purpose and non-infringement of
15  * intellectual property rights. NXP Semiconductors assumes no responsibility
16  * or liability for the use of the software, conveys no license or rights under any
17  * patent, copyright, mask work right, or any other intellectual property rights in
18  * or to any products. NXP Semiconductors reserves the right to make changes
19  * in the software without notification. NXP Semiconductors also makes no
20  * representation or warranty that such application will be suitable for the
21  * specified use without further testing or modification.
22  *
23  * @par
24  * Permission to use, copy, modify, and distribute this software and its
25  * documentation is hereby granted, under NXP Semiconductors' and its
26  * licensor's relevant copyrights in the software, without fee, provided that it
27  * is used in conjunction with NXP Semiconductors microcontrollers. This
28  * copyright, permission, and disclaimer notice must appear in all copies of
29  * this code.
30  */
31 
32 #ifndef __CHIP_LPC407X_8X_H_
33 #define __CHIP_LPC407X_8X_H_
34 
35 #include "lpc_types.h"
36 #include "sys_config.h"
37 
38 #ifdef __cplusplus
39 extern "C" {
40 #endif
41 
42 #if !defined(CORE_M4)
43 #error CORE_M4 is not defined for the LPC407x/8x architecture
44 #error CORE_M4 should be defined as part of your compiler define list
45 #endif
46 
47 #ifndef CHIP_LPC407X_8X
48 #error CHIP_LPC407X_8X is not defined!
49 #endif
50 
85 #include "adc_001.h"
86 #include "can_001.h"
87 #include "dac_001.h"
88 #include "emc_001.h"
89 #include "enet_002.h"
90 #include "gpdma_001.h"
91 #include "gpio_002.h"
92 #include "i2c_001.h"
93 #include "i2s_001.h"
94 #include "lcd_001.h"
95 #include "mcpwm_001.h"
96 #include "qei_001.h"
97 #include "regfile_001.h"
98 #include "rtc_001.h"
99 #include "sdc_001.h"
100 #include "ssp_001.h"
101 #include "timer_001.h"
102 #include "usart_001.h"
103 #include "wwdt_001.h"
104 #include "cmp_001.h"
105 #include "usb_001.h"
106 #include "eeprom_001.h"
107 #include "crc_001.h"
108 
114 #define LPC_EEPROM_BASE 0x00200080
115 #define LPC_GPDMA_BASE 0x20080000
116 #define LPC_ENET_BASE 0x20084000
117 #define LPC_LCD_BASE 0x20088000
118 #define LPC_USB_BASE 0x2008C000
119 #define LPC_CRC_BASE 0x20090000
120 #define LPC_SPIFI_BASE 0x20094000
121 #define LPC_GPIO0_BASE 0x20098000
122 #define LPC_GPIO1_BASE 0x20098020
123 #define LPC_GPIO2_BASE 0x20098040
124 #define LPC_GPIO3_BASE 0x20098060
125 #define LPC_GPIO4_BASE 0x20098080
126 #define LPC_GPIO5_BASE 0x200980A0
127 #define LPC_EMC_BASE 0x2009C000
128 #define LPC_RTC_BASE 0x40024000
129 #define LPC_REGFILE_BASE 0x40024044
130 #define LPC_WWDT_BASE 0x40000000
131 #define LPC_UART0_BASE 0x4000C000
132 #define LPC_UART1_BASE 0x40010000
133 #define LPC_UART2_BASE 0x40098000
134 #define LPC_UART3_BASE 0x4009C000
135 #define LPC_UART4_BASE 0x400A4000
136 #define LPC_SSP0_BASE 0x40088000
137 #define LPC_SSP1_BASE 0x40030000
138 #define LPC_SSP2_BASE 0x400AC000
139 #define LPC_TIMER0_BASE 0x40004000
140 #define LPC_TIMER1_BASE 0x40008000
141 #define LPC_TIMER2_BASE 0x40090000
142 #define LPC_TIMER3_BASE 0x40094000
143 #define LPC_MCPWM_BASE 0x400B8000
144 #define LPC_PWM0_BASE 0x40014000
145 #define LPC_PWM1_BASE 0x40018000
146 #define LPC_I2C0_BASE 0x4001C000
147 #define LPC_I2C1_BASE 0x4005C000
148 #define LPC_I2C2_BASE 0x400A0000
149 #define LPC_I2S_BASE 0x400A8000
150 #define LPC_CANAF_RAM_BASE 0x40038000
151 #define LPC_CANAF_BASE 0x4003C000
152 #define LPC_CANCR_BASE 0x40040000
153 #define LPC_CAN1_BASE 0x40044000
154 #define LPC_CAN2_BASE 0x40048000
155 #define LPC_QEI_BASE 0x400BC000
156 #define LPC_DAC_BASE 0x4008C000
157 #define LPC_ADC_BASE 0x40034000
158 #define LPC_GPIOINT_BASE 0x40028080
159 #define LPC_IOCON_BASE 0x4002C000
160 #define LPC_SDC_BASE 0x400C0000
161 #define LPC_SYSCTL_BASE 0x400FC000
162 #define LPC_CMP_BASE 0x40020000
163 
164 /* Normalize types */
190 
191 /* Assign LPC_* names to structures mapped to addresses */
192 #define LPC_EEPROM ((IP_EEPROM_001_T *) LPC_EEPROM_BASE)
193 #define LPC_GPDMA ((IP_GPDMA_001_T *) LPC_GPDMA_BASE)
194 #define LPC_EMC ((IP_EMC_001_T *) LPC_EMC_BASE)
195 #define LPC_USB ((IP_USB_001_T *) LPC_USB_BASE)
196 #define LPC_LCD ((IP_LCD_001_T *) LPC_LCD_BASE)
197 #define LPC_ETHERNET ((IP_ENET_002_T *) LPC_ENET_BASE)
198 #define LPC_GPIO ((IP_GPIO_002_T *) LPC_GPIO0_BASE)
199 #define LPC_GPIO1 ((IP_GPIO_002_T *) LPC_GPIO1_BASE)
200 #define LPC_GPIO2 ((IP_GPIO_002_T *) LPC_GPIO2_BASE)
201 #define LPC_GPIO3 ((IP_GPIO_002_T *) LPC_GPIO3_BASE)
202 #define LPC_GPIO4 ((IP_GPIO_002_T *) LPC_GPIO4_BASE)
203 #define LPC_GPIO5 ((IP_GPIO_002_T *) LPC_GPIO5_BASE)
204 #define LPC_RTC ((IP_RTC_001_T *) LPC_RTC_BASE)
205 #define LPC_REGFILE ((IP_REGFILE_001_T *) LPC_REGFILE_BASE)
206 #define LPC_WWDT ((IP_WWDT_001_T *) LPC_WWDT_BASE)
207 #define LPC_UART0 ((IP_USART_001_T *) LPC_UART0_BASE)
208 #define LPC_UART1 ((IP_USART_001_T *) LPC_UART1_BASE)
209 #define LPC_UART2 ((IP_USART_001_T *) LPC_UART2_BASE)
210 #define LPC_UART3 ((IP_USART_001_T *) LPC_UART3_BASE)
211 #define LPC_UART4 ((IP_USART_001_T *) LPC_UART4_BASE)
212 #define LPC_SSP0 ((IP_SSP_001_T *) LPC_SSP0_BASE)
213 #define LPC_SSP1 ((IP_SSP_001_T *) LPC_SSP1_BASE)
214 #define LPC_SSP2 ((IP_SSP_001_T *) LPC_SSP2_BASE)
215 #define LPC_TIMER0 ((IP_TIMER_001_T *) LPC_TIMER0_BASE)
216 #define LPC_TIMER1 ((IP_TIMER_001_T *) LPC_TIMER1_BASE)
217 #define LPC_TIMER2 ((IP_TIMER_001_T *) LPC_TIMER2_BASE)
218 #define LPC_TIMER3 ((IP_TIMER_001_T *) LPC_TIMER3_BASE)
219 #define LPC_MCPWM ((IP_MCPWM_001_T *) LPC_MCPWM_BASE)
220 #define LPC_I2C0 ((IP_I2C_001_T *) LPC_I2C0_BASE)
221 #define LPC_I2C1 ((IP_I2C_001_T *) LPC_I2C1_BASE)
222 #define LPC_I2C2 ((IP_I2C_001_T *) LPC_I2C2_BASE)
223 #define LPC_I2S ((IP_I2S_001_T *) LPC_I2S_BASE)
224 #define LPC_QEI ((IP_QEI_001_T *) LPC_QEI_BASE)
225 #define LPC_DAC ((IP_DAC_001_T *) LPC_DAC_BASE)
226 #define LPC_ADC ((IP_ADC_001_T *) LPC_ADC_BASE)
227 #define LPC_IOCON ((LPC_IOCON_T *) LPC_IOCON_BASE)
228 #define LPC_SDC ((IP_SDC_001_T *) LPC_SDC_BASE)
229 #define LPC_SYSCTL ((LPC_SYSCTL_T *) LPC_SYSCTL_BASE)
230 #define LPC_CMP ((IP_CMP_001_T *) LPC_CMP_BASE)
231 #define LPC_CANAF_RAM ((LPC_CANAF_RAM_T *) LPC_CANAF_RAM_BASE)
232 #define LPC_CANAF ((LPC_CANAF_T *) LPC_CANAF_BASE)
233 #define LPC_CANCR ((LPC_CANCR_T *) LPC_CANCR_BASE)
234 #define LPC_CAN1 ((LPC_CAN_T *) LPC_CAN1_BASE)
235 #define LPC_CAN2 ((LPC_CAN_T *) LPC_CAN2_BASE)
236 #define LPC_CRC ((LPC_CRC_T *) LPC_CRC_BASE)
237 
242 #include "eeprom_17xx_40xx.h"
243 #include "gpio_17xx_40xx.h"
244 #include "uart_17xx_40xx.h"
245 #include "gpdma_17xx_40xx.h"
246 #include "i2c_17xx_40xx.h"
247 #include "i2s_17xx_40xx.h"
248 #include "ssp_17xx_40xx.h"
249 #include "rtc_17xx_40xx.h"
250 #include "emc_17xx_40xx.h"
251 #include "lcd_17xx_40xx.h"
252 #include "adc_17xx_40xx.h"
253 #include "dac_17xx_40xx.h"
254 #include "timer_17xx_40xx.h"
255 #include "iocon_17xx_40xx.h"
256 #include "sysctl_17xx_40xx.h"
257 #include "clock_17xx_40xx.h"
258 #include "fmc_17xx_40xx.h"
259 #include "can_17xx_40xx.h"
260 #include "crc_17xx_40xx.h"
261 #include "enet_17xx_40xx.h"
262 #include "sdc_17xx_40xx.h"
263 #include "sdmmc_17xx_40xx.h"
264 #include "wwdt_17xx_40xx.h"
265 #include "cmp_17xx_40xx.h"
266 #include "spifi_17xx_40xx.h"
267 #include "fpu_init.h"
268 
269 /* FIXME - missing PWM and possibly CREG drivers */
270 
271 #ifdef __cplusplus
272 }
273 #endif
274 
275 #endif /* __CHIP_LPC407X_8X_H_ */