projekty/Source/example1/src/include/lp2119.h

Go to the documentation of this file.
00001 /**************************** lpc2119.h *********************************/
00002 /* Copyright 2004/06/15 Aeolus Development                              */
00003 /* All rights reserved.                                                 */
00004 /*                                                                      */
00005 /* Redistribution and use in source and binary forms, with or without   */
00006 /* modification, are permitted provided that the following conditions   */
00007 /* are met:                                                             */
00008 /* 1. Redistributions of source code must retain the above copyright    */
00009 /*   notice, this list of conditions and the following disclaimer.      */
00010 /* 2. Redistributions in binary form must reproduce the above copyright */
00011 /*   notice, this list of conditions and the following disclaimer in the*/
00012 /*   documentation and/or other materials provided with the             */
00013 /*   distribution.                                                      */
00014 /* 3. The name of the Aeolus Development or its contributors may not be */
00015 /* used to endorse or promote products derived from this software       */
00016 /* without specific prior written permission.                           */
00017 /*                                                                      */
00018 /* THIS SOFTWARE IS PROVIDED BY THE AEOULUS DEVELOPMENT "AS IS" AND ANY */
00019 /* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE    */
00020 /* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR   */
00021 /* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AEOLUS DEVELOPMENT BE  */
00022 /* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR  */
00023 /* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF */
00024 /* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR      */
00025 /* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,*/
00026 /* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE */
00027 /* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,    */
00028 /* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.                   */
00029 /*                                                                      */
00030 /*  Register definitions for LPC2119/LPC2129/LPC2194/LPC2292/LPC2294.   */
00031 /* Works with the appropriate link script to set up the register        */
00032 /* addresses.                                                           */
00033 /************************************************************************/
00034 /*
00035 *   TLIB revision history:
00036 *   1 lpc2119.h 16-Jul-2004,11:49:34,`RADSETT' Original archived version.
00037 *   TLIB revision history ends.
00038 */
00039 
00040 /* lint -library*/
00041 #ifndef LPC2119__H
00042 #define LPC2119__H
00043 
00044 /* WD */
00045 extern volatile unsigned char WDMOD;
00046 extern volatile unsigned int WDTC;
00047 extern volatile unsigned char WDFEED;
00048 extern volatile const unsigned int WDTV;
00049 
00050 /* TIMER 0 */
00051 
00052 extern volatile unsigned char T0IR;
00053 extern volatile unsigned char T0TCR;
00054 extern volatile unsigned int T0TC;
00055 extern volatile unsigned int T0PR;
00056 extern volatile unsigned int T0PC;
00057 extern volatile unsigned short T0MCR;
00058 extern volatile unsigned int T0MR0;
00059 extern volatile unsigned int T0MR1;
00060 extern volatile unsigned int T0MR2;
00061 extern volatile unsigned int T0MR3;
00062 extern volatile unsigned short T0CCR;
00063 extern volatile const unsigned int T0CR0;
00064 extern volatile const unsigned int T0CR1;
00065 extern volatile const unsigned int T0CR2;
00066 extern volatile unsigned short T0EMR;
00067 
00068 /* TIMER 1 */
00069 
00070 extern volatile unsigned char T1IR;
00071 extern volatile unsigned char T1TCR;
00072 extern volatile unsigned int T1TC;
00073 extern volatile unsigned int T1PR;
00074 extern volatile unsigned int T1PC;
00075 extern volatile unsigned short T1MCR;
00076 extern volatile unsigned int T1MR0;
00077 extern volatile unsigned int T1MR1;
00078 extern volatile unsigned int T1MR2;
00079 extern volatile unsigned int T1MR3;
00080 extern volatile unsigned short T1CCR;
00081 extern volatile const unsigned int T1CR0;
00082 extern volatile const unsigned int T1CR1;
00083 extern volatile const unsigned int T1CR2;
00084 extern volatile const unsigned int T1CR3;
00085 extern volatile unsigned short T1EMR;
00086 
00087 /* UART 0 */
00088 
00089 extern volatile const unsigned char U0RBR;
00090 extern volatile unsigned char U0THR;
00091 extern volatile unsigned char U0DLL;
00092 extern volatile unsigned char U0IER;
00093 extern volatile unsigned char U0DLM;
00094 extern volatile const unsigned char U0IIR;
00095 extern volatile unsigned char U0FCR;
00096 extern volatile unsigned char U0LCR;
00097 extern volatile const unsigned char U0LSR;
00098 extern volatile unsigned char U0SCR;
00099 
00100 /* UART 1 */
00101 
00102 extern volatile const unsigned char U1RBR;
00103 extern volatile unsigned char U1THR;
00104 extern volatile unsigned char U1DLL;
00105 extern volatile unsigned char U1IER;
00106 extern volatile unsigned char U1DLM;
00107 extern volatile const unsigned char U1IIR;
00108 extern volatile unsigned char U1FCR;
00109 extern volatile unsigned char U1LCR;
00110 extern volatile unsigned char U1MCR;
00111 extern volatile const unsigned char U1LSR;
00112 extern volatile const unsigned char U1MSR;
00113 extern volatile unsigned char U1SCR;
00114 
00115 /* PWM */
00116 
00117 extern volatile unsigned short PWMIR;
00118 extern volatile unsigned char PWMTCR;
00119 extern volatile unsigned int PWMTC;
00120 extern volatile unsigned int PWMPR;
00121 extern volatile unsigned int PWMPC;
00122 extern volatile unsigned int PWMMCR;
00123 extern volatile unsigned int PWMMR0;
00124 extern volatile unsigned int PWMMR1;
00125 extern volatile unsigned int PWMMR2;
00126 extern volatile unsigned int PWMMR3;
00127 extern volatile unsigned int PWMMR4;
00128 extern volatile unsigned int PWMMR5;
00129 extern volatile unsigned int PWMMR6;
00130 extern volatile unsigned short PWMPCR;
00131 extern volatile unsigned char PWMLER;
00132 
00133 /* IIC */
00134 
00135 extern volatile unsigned char I2CONSET;
00136 extern volatile const unsigned char I2STAT;
00137 extern volatile unsigned char I2DAT;
00138 extern volatile unsigned char I2ADR;
00139 extern volatile unsigned short I2SCLH;
00140 extern volatile unsigned short I2SCLL;
00141 extern volatile unsigned char I2CONCLR;
00142 
00143 /* SPI/SPI0 */
00144 
00145 extern volatile unsigned char S0PCR;
00146 extern volatile const unsigned char S0PSR;
00147 extern volatile unsigned char S0PPR;
00148 extern volatile unsigned char S0PCCR;
00149 extern volatile unsigned char S0PINT;
00150 
00151         /* Synonyms for compatibility with the 210x series.     */
00152 extern volatile unsigned char SPCR;
00153 extern volatile const unsigned char SPSR;
00154 extern volatile unsigned char SPPR;
00155 extern volatile unsigned char SPCCR;
00156 extern volatile unsigned char SPINT;
00157 
00158 /* RTC */
00159 
00160 extern volatile unsigned char ILR;
00161 extern volatile const unsigned char CTC;
00162 extern volatile unsigned char CCR;
00163 extern volatile unsigned char CIIR;
00164 extern volatile unsigned char AMR;
00165 extern volatile unsigned int CTIME0;
00166 extern volatile unsigned int CTIME1;
00167 extern volatile unsigned int CTIME2;
00168 extern volatile unsigned char SEC;
00169 extern volatile unsigned char MINUTE;   /* MIN conflicts with linker    */
00170 extern volatile unsigned char HOUR;
00171 extern volatile unsigned char DOM;
00172 extern volatile unsigned char DOW;
00173 extern volatile unsigned short DOY;
00174 extern volatile unsigned MONTH;
00175 extern volatile unsigned short YEAR;
00176 extern volatile unsigned char ALSEC;
00177 extern volatile unsigned char ALMIN;
00178 extern volatile unsigned char ALHOUR;
00179 extern volatile unsigned char ALDOM;
00180 extern volatile unsigned char ALDOW;
00181 extern volatile unsigned short ALDOY;
00182 extern volatile unsigned char ALMON;
00183 extern volatile unsigned short ALYEAR;
00184 extern volatile unsigned short PREINT;
00185 extern volatile unsigned short PREFRAC;
00186 
00187 /* GPIO PORT0 */
00188 
00189 extern volatile const unsigned int IO0PIN;
00190 extern unsigned int IO0DIR;
00191 extern volatile unsigned int IO0CLR;
00192 extern volatile unsigned int IO0SET;
00193 
00194         /* Synonyms for compatibility with the 210x series.     */
00195 extern volatile const unsigned int IOPIN;
00196 extern unsigned int IODIR;
00197 extern volatile unsigned int IOCLR;
00198 extern volatile unsigned int IOSET;
00199 
00200 /* GPIO PORT1 */
00201 
00202 extern volatile const unsigned int IO1PIN;
00203 extern unsigned int IO1DIR;
00204 extern volatile unsigned int IO1CLR;
00205 extern volatile unsigned int IO1SET;
00206 
00207 /* GPIO PORT2 */
00208 
00209 extern volatile const unsigned int IO2PIN;
00210 extern unsigned int IO2DIR;
00211 extern volatile unsigned int IO2CLR;
00212 extern volatile unsigned int IO2SET;
00213 
00214 /* GPIO PORT3 */
00215 
00216 extern volatile const unsigned int IO3PIN;
00217 extern unsigned int IO3DIR;
00218 extern volatile unsigned int IO3CLR;
00219 extern volatile unsigned int IO3SET;
00220 
00221 /* PIN CONNECT BLOCK */
00222 
00223 extern unsigned int PINSEL0;
00224 extern unsigned int PINSEL1;
00225 extern unsigned int PINSEL2;
00226 
00227 /* SPI1 */
00228 
00229 extern volatile unsigned char S1PCR;
00230 extern volatile const unsigned char S1PSR;
00231 extern volatile unsigned char S1PPR;
00232 extern volatile unsigned char S1PCCR;
00233 extern volatile unsigned char S1PINT;
00234 
00235 /* ADC */
00236 
00237         /* Renamed from AD... to prevent ld conflict. */
00238 extern volatile unsigned int A2DCR;
00239 extern volatile unsigned int A2DDR;
00240 
00241 /* CAN */
00242 
00243 extern volatile unsigned int CAN_RECV[0x200];
00244 extern volatile unsigned int AFMR;
00245 extern volatile unsigned int SFF_sa;
00246 extern volatile unsigned int SFF_GRP_sa;
00247 extern volatile unsigned int EFF_sa;
00248 extern volatile unsigned int EFF_GRP_sa;
00249 extern volatile unsigned int ENDofTable;
00250 extern const volatile unsigned int LUTerrAd;
00251 extern const volatile unsigned int LUTerr;
00252 extern const volatile unsigned int CANTxSR;
00253 extern const volatile unsigned int CANRxSR;
00254 extern const volatile unsigned int CANMSR;
00255 
00256 /* CAN1 Interface */
00257 
00258 extern volatile unsigned int C1MOD;
00259 extern volatile unsigned int C1CMR;
00260 extern const volatile unsigned int C1GSR;
00261 extern const volatile unsigned int C1ICR;
00262 extern volatile unsigned int C1IER;
00263 extern volatile unsigned int C1BTR;
00264 extern volatile unsigned int C1EWL;
00265 extern const volatile unsigned int C1SR;
00266 extern volatile unsigned int C1RFS;
00267 extern volatile unsigned int C1RID;
00268 extern volatile unsigned int C1RDA;
00269 extern volatile unsigned int C1RDB;
00270 extern volatile unsigned int C1TFI1;
00271 extern volatile unsigned int C1TID1;
00272 extern volatile unsigned int C1TDA1;
00273 extern volatile unsigned int C1TDB1;
00274 extern volatile unsigned int C1TFI2;
00275 extern volatile unsigned int C1TID2;
00276 extern volatile unsigned int C1TDA2;
00277 extern volatile unsigned int C1TDB2;
00278 extern volatile unsigned int C1TFI3;
00279 extern volatile unsigned int C1TID3;
00280 extern volatile unsigned int C1TDA3;
00281 extern volatile unsigned int C1TDB3;
00282 
00283 /* CAN2 Interface */
00284 
00285 extern volatile unsigned int C2MOD;
00286 extern volatile unsigned int C2CMR;
00287 extern const volatile unsigned int C2GSR;
00288 extern const volatile unsigned int C2ICR;
00289 extern volatile unsigned int C2IER;
00290 extern volatile unsigned int C2BTR;
00291 extern volatile unsigned int C2EWL;
00292 extern const volatile unsigned int C2SR;
00293 extern volatile unsigned int C2RFS;
00294 extern volatile unsigned int C2RID;
00295 extern volatile unsigned int C2RDA;
00296 extern volatile unsigned int C2RDB;
00297 extern volatile unsigned int C2TFI1;
00298 extern volatile unsigned int C2TID1;
00299 extern volatile unsigned int C2TDA1;
00300 extern volatile unsigned int C2TDB1;
00301 extern volatile unsigned int C2TFI2;
00302 extern volatile unsigned int C2TID2;
00303 extern volatile unsigned int C2TDA2;
00304 extern volatile unsigned int C2TDB2;
00305 extern volatile unsigned int C2TFI3;
00306 extern volatile unsigned int C2TID3;
00307 extern volatile unsigned int C2TDA3;
00308 extern volatile unsigned int C2TDB3;
00309 
00310 /* CAN3 Interface */
00311 
00312 extern volatile unsigned int C3MOD;
00313 extern volatile unsigned int C3CMR;
00314 extern const volatile unsigned int C3GSR;
00315 extern const volatile unsigned int C3ICR;
00316 extern volatile unsigned int C3IER;
00317 extern volatile unsigned int C3BTR;
00318 extern volatile unsigned int C3EWL;
00319 extern const volatile unsigned int C3SR;
00320 extern volatile unsigned int C3RFS;
00321 extern volatile unsigned int C3RID;
00322 extern volatile unsigned int C3RDA;
00323 extern volatile unsigned int C3RDB;
00324 extern volatile unsigned int C3TFI1;
00325 extern volatile unsigned int C3TID1;
00326 extern volatile unsigned int C3TDA1;
00327 extern volatile unsigned int C3TDB1;
00328 extern volatile unsigned int C3TFI2;
00329 extern volatile unsigned int C3TID2;
00330 extern volatile unsigned int C3TDA2;
00331 extern volatile unsigned int C3TDB2;
00332 extern volatile unsigned int C3TFI3;
00333 extern volatile unsigned int C3TID3;
00334 extern volatile unsigned int C3TDA3;
00335 extern volatile unsigned int C3TDB3;
00336 
00337 /* CAN4 Interface */
00338 
00339 extern volatile unsigned int C4MOD;
00340 extern volatile unsigned int C4CMR;
00341 extern const volatile unsigned int C4GSR;
00342 extern const volatile unsigned int C4ICR;
00343 extern volatile unsigned int C4IER;
00344 extern volatile unsigned int C4BTR;
00345 extern volatile unsigned int C4EWL;
00346 extern const volatile unsigned int C4SR;
00347 extern volatile unsigned int C4RFS;
00348 extern volatile unsigned int C4RID;
00349 extern volatile unsigned int C4RDA;
00350 extern volatile unsigned int C4RDB;
00351 extern volatile unsigned int C4TFI1;
00352 extern volatile unsigned int C4TID1;
00353 extern volatile unsigned int C4TDA1;
00354 extern volatile unsigned int C4TDB1;
00355 extern volatile unsigned int C4TFI2;
00356 extern volatile unsigned int C4TID2;
00357 extern volatile unsigned int C4TDA2;
00358 extern volatile unsigned int C4TDB2;
00359 extern volatile unsigned int C4TFI3;
00360 extern volatile unsigned int C4TID3;
00361 extern volatile unsigned int C4TDA3;
00362 extern volatile unsigned int C4TDB3;
00363 
00364 /* SYSTEM CONTROL BLOCK */
00365         /* MAM */
00366 
00367 extern unsigned char MAMCR;
00368 extern unsigned char MAMTIM;
00369 
00370 
00371 extern unsigned char MEMAP;
00372 
00373         /* PLL */
00374 
00375 extern volatile unsigned char PLLCON;
00376 extern volatile unsigned char PLLCFG;
00377 extern volatile const unsigned short PLLSTAT;
00378 extern volatile unsigned char PLLFEED;
00379 
00380         /* POWER CONTROL */
00381 
00382 extern volatile unsigned char PCON;
00383 extern volatile unsigned short PCONP;
00384 
00385         /* VPB */
00386 
00387 extern volatile unsigned char VPBDIV;
00388 
00389         /* EXTERNAL INTERUPT/WAKE */
00390 
00391 extern volatile unsigned char EXTINT;
00392 extern volatile unsigned char EXTWAKE;
00393 extern volatile unsigned char EXTMODE;
00394 extern volatile unsigned char EXTPOLAR;
00395 
00396 /* External Memory Controller- EMC */
00397 
00398 extern volatile unsigned int BCFG0;
00399 extern volatile unsigned int BCFG1;
00400 extern volatile unsigned int BCFG2;
00401 extern volatile unsigned int BCFG3;
00402 
00403 
00404 /* Vector Interrupt Controller (VIC) */
00405 
00406 extern volatile const unsigned int VICIRQStatus;
00407 extern volatile const unsigned int VICFIQStatus;
00408 extern volatile const unsigned int VICRawIntr;
00409 extern volatile unsigned int VICIntSelect;
00410 extern volatile unsigned int VICIntEnable;
00411 extern volatile unsigned int VICIntEnClr;
00412 extern volatile unsigned int VICSoftInt;
00413 extern volatile unsigned int VICSoftIntClear;
00414 extern volatile unsigned int VICProtection;
00415 extern void (* volatile VICVectAddrRead)( void);
00416 extern void (* volatile VICDefVectAddr)( void);
00417 extern void (* volatile VICVectAddr[16])(void);
00418 extern volatile unsigned int VICVectCntl[16];
00419 
00420         /*  The list of interrupts is variant specific so it's          */
00421         /* included here rather than in lpc_sys.h                       */
00422 
00423         /*  List of interrupt sources.                                  */
00424 #define WDT             ((INTERRUPT_SOURCE)0u)  /*  Watchdog timer.     */
00425 #define SW              ((INTERRUPT_SOURCE)1u)  /*  Software interrupt. */
00426 #define DBGCOMMRX       ((INTERRUPT_SOURCE)2u)  /*  Debug comm receive. */
00427 #define DBGCOMMTX       ((INTERRUPT_SOURCE)3u)  /*  Debug comm transmit.*/
00428 #define TIMER0          ((INTERRUPT_SOURCE)4u)  /*  Timer # 0.          */
00429 #define TIMER1          ((INTERRUPT_SOURCE)5u)  /*  Timer # 1.          */
00430 #define UART0           ((INTERRUPT_SOURCE)6u)  /*  UART # 0.           */
00431 #define UART1           ((INTERRUPT_SOURCE)7u)  /*  UART # 1.           */
00432 #define PWM0            ((INTERRUPT_SOURCE)8u)  /*  PWM.                */
00433 #define I2C             ((INTERRUPT_SOURCE)9u)  /*  IIC.                */
00434 #define SPI             ((INTERRUPT_SOURCE)10u) /*  SPI 0.              */
00435 #define SPI0            ((INTERRUPT_SOURCE)10u) /*  SPI 0.              */
00436 #define SPI1            ((INTERRUPT_SOURCE)11u) /*  SPI 1.              */
00437 #define PLL             ((INTERRUPT_SOURCE)12u) /*  PLL.                */
00438 #define RTC             ((INTERRUPT_SOURCE)13u) /*  Real time clock.    */
00439 #define EINT0           ((INTERRUPT_SOURCE)14u) /*  External int # 0.   */
00440 #define EINT1           ((INTERRUPT_SOURCE)15u) /*  External int # 1.   */
00441 #define EINT2           ((INTERRUPT_SOURCE)16u) /*  External int # 2.   */
00442 #define EINT3           ((INTERRUPT_SOURCE)17u) /*  External int # 3.   */
00443 #define AD              ((INTERRUPT_SOURCE)18u) /*  A/D Convertor.      */
00444 #define CANACCFILT      ((INTERRUPT_SOURCE)19u) /*  CAN and Acceptance  */
00445                                                 /* Filter.              */
00446 #define CAN1TX          ((INTERRUPT_SOURCE)20u) /*  CAN 1 Tx.           */
00447 #define CAN2TX          ((INTERRUPT_SOURCE)21u) /*  CAN 2 Tx.           */
00448 #define CAN3TX          ((INTERRUPT_SOURCE)22u) /*  CAN 3 Tx.           */
00449 #define CAN4TX          ((INTERRUPT_SOURCE)23u) /*  CAN 4 Tx.           */
00450 #define CAN1RX          ((INTERRUPT_SOURCE)26u) /*  CAN 1 Rx.           */
00451 #define CAN2RX          ((INTERRUPT_SOURCE)27u) /*  CAN 2 Rx.           */
00452 #define CAN3RX          ((INTERRUPT_SOURCE)28u) /*  CAN 3 Rx.           */
00453 #define CAN4RX          ((INTERRUPT_SOURCE)29u) /*  CAN 4 Rx.           */
00454 
00455 #define MAX_INTERRUPT_SOURCE ((INTERRUPT_SOURCE)30u)    /*  End of the list.*/
00456 
00457 #endif /* LPC2119__H */

Generated on Fri Sep 21 13:41:54 2007 for example1 by  doxygen 1.4.7