These are the examples provided for [[/users/frank26080115/libraries/LPC1700CMSIS_Lib/]] Note, the entire "program" is not compilable!
SSP/sc16is750_int/lpc17xx_libcfg.h@0:bf7b9fba3924, 2011-03-20 (annotated)
- Committer:
- frank26080115
- Date:
- Sun Mar 20 05:38:56 2011 +0000
- Revision:
- 0:bf7b9fba3924
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
frank26080115 | 0:bf7b9fba3924 | 1 | /***********************************************************************//** |
frank26080115 | 0:bf7b9fba3924 | 2 | * @file lpc17xx_libcfg.h |
frank26080115 | 0:bf7b9fba3924 | 3 | * @purpose Library configuration file |
frank26080115 | 0:bf7b9fba3924 | 4 | * @version 2.0 |
frank26080115 | 0:bf7b9fba3924 | 5 | * @date 21. May. 2010 |
frank26080115 | 0:bf7b9fba3924 | 6 | * @author NXP MCU SW Application Team |
frank26080115 | 0:bf7b9fba3924 | 7 | ************************************************************************** |
frank26080115 | 0:bf7b9fba3924 | 8 | * Software that is described herein is for illustrative purposes only |
frank26080115 | 0:bf7b9fba3924 | 9 | * which provides customers with programming information regarding the |
frank26080115 | 0:bf7b9fba3924 | 10 | * products. This software is supplied "AS IS" without any warranties. |
frank26080115 | 0:bf7b9fba3924 | 11 | * NXP Semiconductors assumes no responsibility or liability for the |
frank26080115 | 0:bf7b9fba3924 | 12 | * use of the software, conveys no license or title under any patent, |
frank26080115 | 0:bf7b9fba3924 | 13 | * copyright, or mask work right to the product. NXP Semiconductors |
frank26080115 | 0:bf7b9fba3924 | 14 | * reserves the right to make changes in the software without |
frank26080115 | 0:bf7b9fba3924 | 15 | * notification. NXP Semiconductors also make no representation or |
frank26080115 | 0:bf7b9fba3924 | 16 | * warranty that such application will be suitable for the specified |
frank26080115 | 0:bf7b9fba3924 | 17 | * use without further testing or modification. |
frank26080115 | 0:bf7b9fba3924 | 18 | **************************************************************************/ |
frank26080115 | 0:bf7b9fba3924 | 19 | |
frank26080115 | 0:bf7b9fba3924 | 20 | #ifndef LPC17XX_LIBCFG_H_ |
frank26080115 | 0:bf7b9fba3924 | 21 | #define LPC17XX_LIBCFG_H_ |
frank26080115 | 0:bf7b9fba3924 | 22 | |
frank26080115 | 0:bf7b9fba3924 | 23 | #include "lpc_types.h" |
frank26080115 | 0:bf7b9fba3924 | 24 | |
frank26080115 | 0:bf7b9fba3924 | 25 | |
frank26080115 | 0:bf7b9fba3924 | 26 | /************************** DEBUG MODE DEFINITIONS *********************************/ |
frank26080115 | 0:bf7b9fba3924 | 27 | /* Un-comment the line below to compile the library in DEBUG mode, this will expanse |
frank26080115 | 0:bf7b9fba3924 | 28 | the "CHECK_PARAM" macro in the FW library code */ |
frank26080115 | 0:bf7b9fba3924 | 29 | |
frank26080115 | 0:bf7b9fba3924 | 30 | #define DEBUG |
frank26080115 | 0:bf7b9fba3924 | 31 | |
frank26080115 | 0:bf7b9fba3924 | 32 | |
frank26080115 | 0:bf7b9fba3924 | 33 | /******************* PERIPHERAL FW LIBRARY CONFIGURATION DEFINITIONS ***********************/ |
frank26080115 | 0:bf7b9fba3924 | 34 | |
frank26080115 | 0:bf7b9fba3924 | 35 | /* Comment the line below to disable the specific peripheral inclusion */ |
frank26080115 | 0:bf7b9fba3924 | 36 | |
frank26080115 | 0:bf7b9fba3924 | 37 | /* DEBUG_FRAMWORK ------------------------------ */ |
frank26080115 | 0:bf7b9fba3924 | 38 | #define _DBGFWK |
frank26080115 | 0:bf7b9fba3924 | 39 | |
frank26080115 | 0:bf7b9fba3924 | 40 | /* GPIO ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 41 | #define _GPIO |
frank26080115 | 0:bf7b9fba3924 | 42 | |
frank26080115 | 0:bf7b9fba3924 | 43 | /* EXTI ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 44 | //#define _EXTI |
frank26080115 | 0:bf7b9fba3924 | 45 | |
frank26080115 | 0:bf7b9fba3924 | 46 | /* UART ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 47 | #define _UART |
frank26080115 | 0:bf7b9fba3924 | 48 | #define _UART0 |
frank26080115 | 0:bf7b9fba3924 | 49 | //#define _UART1 |
frank26080115 | 0:bf7b9fba3924 | 50 | //#define _UART2 |
frank26080115 | 0:bf7b9fba3924 | 51 | //#define _UART3 |
frank26080115 | 0:bf7b9fba3924 | 52 | |
frank26080115 | 0:bf7b9fba3924 | 53 | /* SPI ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 54 | //#define _SPI |
frank26080115 | 0:bf7b9fba3924 | 55 | |
frank26080115 | 0:bf7b9fba3924 | 56 | /* SSP ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 57 | #define _SSP |
frank26080115 | 0:bf7b9fba3924 | 58 | //#define _SSP0 |
frank26080115 | 0:bf7b9fba3924 | 59 | //#define _SSP1 |
frank26080115 | 0:bf7b9fba3924 | 60 | |
frank26080115 | 0:bf7b9fba3924 | 61 | /* SYSTICK --------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 62 | //#define _SYSTICK |
frank26080115 | 0:bf7b9fba3924 | 63 | |
frank26080115 | 0:bf7b9fba3924 | 64 | /* I2C ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 65 | //#define _I2C |
frank26080115 | 0:bf7b9fba3924 | 66 | //#define _I2C0 |
frank26080115 | 0:bf7b9fba3924 | 67 | //#define _I2C1 |
frank26080115 | 0:bf7b9fba3924 | 68 | //#define _I2C2 |
frank26080115 | 0:bf7b9fba3924 | 69 | |
frank26080115 | 0:bf7b9fba3924 | 70 | /* TIMER ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 71 | //#define _TIM |
frank26080115 | 0:bf7b9fba3924 | 72 | |
frank26080115 | 0:bf7b9fba3924 | 73 | /* WDT ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 74 | //#define _WDT |
frank26080115 | 0:bf7b9fba3924 | 75 | |
frank26080115 | 0:bf7b9fba3924 | 76 | |
frank26080115 | 0:bf7b9fba3924 | 77 | /* GPDMA ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 78 | //#define _GPDMA |
frank26080115 | 0:bf7b9fba3924 | 79 | |
frank26080115 | 0:bf7b9fba3924 | 80 | |
frank26080115 | 0:bf7b9fba3924 | 81 | /* DAC ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 82 | //#define _DAC |
frank26080115 | 0:bf7b9fba3924 | 83 | |
frank26080115 | 0:bf7b9fba3924 | 84 | /* DAC ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 85 | //#define _ADC |
frank26080115 | 0:bf7b9fba3924 | 86 | |
frank26080115 | 0:bf7b9fba3924 | 87 | |
frank26080115 | 0:bf7b9fba3924 | 88 | /* PWM ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 89 | //#define _PWM |
frank26080115 | 0:bf7b9fba3924 | 90 | //#define _PWM1 |
frank26080115 | 0:bf7b9fba3924 | 91 | |
frank26080115 | 0:bf7b9fba3924 | 92 | /* RTC ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 93 | //#define _RTC |
frank26080115 | 0:bf7b9fba3924 | 94 | |
frank26080115 | 0:bf7b9fba3924 | 95 | /* I2S ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 96 | //#define _I2S |
frank26080115 | 0:bf7b9fba3924 | 97 | |
frank26080115 | 0:bf7b9fba3924 | 98 | /* USB device ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 99 | //#define _USBDEV |
frank26080115 | 0:bf7b9fba3924 | 100 | //#define _USB_DMA |
frank26080115 | 0:bf7b9fba3924 | 101 | |
frank26080115 | 0:bf7b9fba3924 | 102 | /* QEI ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 103 | //#define _QEI |
frank26080115 | 0:bf7b9fba3924 | 104 | |
frank26080115 | 0:bf7b9fba3924 | 105 | /* MCPWM ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 106 | //#define _MCPWM |
frank26080115 | 0:bf7b9fba3924 | 107 | |
frank26080115 | 0:bf7b9fba3924 | 108 | /* CAN--------------------------------*/ |
frank26080115 | 0:bf7b9fba3924 | 109 | //#define _CAN |
frank26080115 | 0:bf7b9fba3924 | 110 | |
frank26080115 | 0:bf7b9fba3924 | 111 | /* RIT ------------------------------- */ |
frank26080115 | 0:bf7b9fba3924 | 112 | //#define _RIT |
frank26080115 | 0:bf7b9fba3924 | 113 | |
frank26080115 | 0:bf7b9fba3924 | 114 | /* EMAC ------------------------------ */ |
frank26080115 | 0:bf7b9fba3924 | 115 | //#define _EMAC |
frank26080115 | 0:bf7b9fba3924 | 116 | |
frank26080115 | 0:bf7b9fba3924 | 117 | |
frank26080115 | 0:bf7b9fba3924 | 118 | /************************** GLOBAL/PUBLIC MACRO DEFINITIONS *********************************/ |
frank26080115 | 0:bf7b9fba3924 | 119 | |
frank26080115 | 0:bf7b9fba3924 | 120 | #ifdef DEBUG |
frank26080115 | 0:bf7b9fba3924 | 121 | /******************************************************************************* |
frank26080115 | 0:bf7b9fba3924 | 122 | * @brief The CHECK_PARAM macro is used for function's parameters check. |
frank26080115 | 0:bf7b9fba3924 | 123 | * It is used only if the library is compiled in DEBUG mode. |
frank26080115 | 0:bf7b9fba3924 | 124 | * @param[in] expr - If expr is false, it calls check_failed() function |
frank26080115 | 0:bf7b9fba3924 | 125 | * which reports the name of the source file and the source |
frank26080115 | 0:bf7b9fba3924 | 126 | * line number of the call that failed. |
frank26080115 | 0:bf7b9fba3924 | 127 | * - If expr is true, it returns no value. |
frank26080115 | 0:bf7b9fba3924 | 128 | * @return None |
frank26080115 | 0:bf7b9fba3924 | 129 | *******************************************************************************/ |
frank26080115 | 0:bf7b9fba3924 | 130 | #define CHECK_PARAM(expr) ((expr) ? (void)0 : check_failed((uint8_t *)__FILE__, __LINE__)) |
frank26080115 | 0:bf7b9fba3924 | 131 | #else |
frank26080115 | 0:bf7b9fba3924 | 132 | #define CHECK_PARAM(expr) |
frank26080115 | 0:bf7b9fba3924 | 133 | #endif /* DEBUG */ |
frank26080115 | 0:bf7b9fba3924 | 134 | |
frank26080115 | 0:bf7b9fba3924 | 135 | |
frank26080115 | 0:bf7b9fba3924 | 136 | |
frank26080115 | 0:bf7b9fba3924 | 137 | /************************** GLOBAL/PUBLIC FUNCTION DECLARATION *********************************/ |
frank26080115 | 0:bf7b9fba3924 | 138 | |
frank26080115 | 0:bf7b9fba3924 | 139 | #ifdef DEBUG |
frank26080115 | 0:bf7b9fba3924 | 140 | void check_failed(uint8_t *file, uint32_t line); |
frank26080115 | 0:bf7b9fba3924 | 141 | #endif |
frank26080115 | 0:bf7b9fba3924 | 142 | |
frank26080115 | 0:bf7b9fba3924 | 143 | |
frank26080115 | 0:bf7b9fba3924 | 144 | #endif /* LPC17XX_LIBCFG_H_ */ |