this repository aim to make the official ST DISCO F746NG demo from STM32Cube_FW_F7_V1.2.0 working on mbed.
Dependencies: BSP_DISCO_F746NG_patch mbed-rtos mbed
patch/inc/GUI_Debug.h@0:c00e6c923941, 2015-11-02 (annotated)
- Committer:
- NirT
- Date:
- Mon Nov 02 23:38:08 2015 +0000
- Revision:
- 0:c00e6c923941
Error: Incomplete type is not allowed in "patch/LwIP/src/include/lwip/dhcp.h", Line: 83, Col: 4; ; and more like this.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
NirT | 0:c00e6c923941 | 1 | /********************************************************************* |
NirT | 0:c00e6c923941 | 2 | * SEGGER Microcontroller GmbH & Co. KG * |
NirT | 0:c00e6c923941 | 3 | * Solutions for real time microcontroller applications * |
NirT | 0:c00e6c923941 | 4 | ********************************************************************** |
NirT | 0:c00e6c923941 | 5 | * * |
NirT | 0:c00e6c923941 | 6 | * (c) 1996 - 2015 SEGGER Microcontroller GmbH & Co. KG * |
NirT | 0:c00e6c923941 | 7 | * * |
NirT | 0:c00e6c923941 | 8 | * Internet: www.segger.com Support: support@segger.com * |
NirT | 0:c00e6c923941 | 9 | * * |
NirT | 0:c00e6c923941 | 10 | ********************************************************************** |
NirT | 0:c00e6c923941 | 11 | |
NirT | 0:c00e6c923941 | 12 | ** emWin V5.28 - Graphical user interface for embedded applications ** |
NirT | 0:c00e6c923941 | 13 | All Intellectual Property rights in the Software belongs to SEGGER. |
NirT | 0:c00e6c923941 | 14 | emWin is protected by international copyright laws. Knowledge of the |
NirT | 0:c00e6c923941 | 15 | source code may not be used to write a similar product. This file may |
NirT | 0:c00e6c923941 | 16 | only be used in accordance with the following terms: |
NirT | 0:c00e6c923941 | 17 | |
NirT | 0:c00e6c923941 | 18 | The software has been licensed to STMicroelectronics International |
NirT | 0:c00e6c923941 | 19 | N.V. a Dutch company with a Swiss branch and its headquarters in Plan- |
NirT | 0:c00e6c923941 | 20 | les-Ouates, Geneva, 39 Chemin du Champ des Filles, Switzerland for the |
NirT | 0:c00e6c923941 | 21 | purposes of creating libraries for ARM Cortex-M-based 32-bit microcon_ |
NirT | 0:c00e6c923941 | 22 | troller products commercialized by Licensee only, sublicensed and dis_ |
NirT | 0:c00e6c923941 | 23 | tributed under the terms and conditions of the End User License Agree_ |
NirT | 0:c00e6c923941 | 24 | ment supplied by STMicroelectronics International N.V. |
NirT | 0:c00e6c923941 | 25 | Full source code is available at: www.segger.com |
NirT | 0:c00e6c923941 | 26 | |
NirT | 0:c00e6c923941 | 27 | We appreciate your understanding and fairness. |
NirT | 0:c00e6c923941 | 28 | ---------------------------------------------------------------------- |
NirT | 0:c00e6c923941 | 29 | File : GUI_Debug.h |
NirT | 0:c00e6c923941 | 30 | Purpose : Debug macros |
NirT | 0:c00e6c923941 | 31 | ---------------------------------------------------------------------- |
NirT | 0:c00e6c923941 | 32 | Debug macros for logging |
NirT | 0:c00e6c923941 | 33 | |
NirT | 0:c00e6c923941 | 34 | In the GUI Simulation, all output is transferred into the log window. |
NirT | 0:c00e6c923941 | 35 | */ |
NirT | 0:c00e6c923941 | 36 | |
NirT | 0:c00e6c923941 | 37 | #ifndef GUI_DEBUG_H |
NirT | 0:c00e6c923941 | 38 | #define GUI_DEBUG_H |
NirT | 0:c00e6c923941 | 39 | |
NirT | 0:c00e6c923941 | 40 | #include <stddef.h> |
NirT | 0:c00e6c923941 | 41 | |
NirT | 0:c00e6c923941 | 42 | #include "GUI.h" |
NirT | 0:c00e6c923941 | 43 | |
NirT | 0:c00e6c923941 | 44 | #define GUI_DEBUG_LEVEL_NOCHECK 0 /* No run time checks are performed */ |
NirT | 0:c00e6c923941 | 45 | #define GUI_DEBUG_LEVEL_CHECK_PARA 1 /* Parameter checks are performed to avoid crashes */ |
NirT | 0:c00e6c923941 | 46 | #define GUI_DEBUG_LEVEL_CHECK_ALL 2 /* Parameter checks and consistency checks are performed */ |
NirT | 0:c00e6c923941 | 47 | #define GUI_DEBUG_LEVEL_LOG_ERRORS 3 /* Errors are recorded */ |
NirT | 0:c00e6c923941 | 48 | #define GUI_DEBUG_LEVEL_LOG_WARNINGS 4 /* Errors & Warnings are recorded */ |
NirT | 0:c00e6c923941 | 49 | #define GUI_DEBUG_LEVEL_LOG_ALL 5 /* Errors, Warnings and Messages are recorded. */ |
NirT | 0:c00e6c923941 | 50 | |
NirT | 0:c00e6c923941 | 51 | #ifndef GUI_DEBUG_LEVEL |
NirT | 0:c00e6c923941 | 52 | #ifdef WIN32 |
NirT | 0:c00e6c923941 | 53 | #define GUI_DEBUG_LEVEL GUI_DEBUG_LEVEL_LOG_WARNINGS /* Simulation should log all warnings */ |
NirT | 0:c00e6c923941 | 54 | #else |
NirT | 0:c00e6c923941 | 55 | #define GUI_DEBUG_LEVEL GUI_DEBUG_LEVEL_CHECK_PARA /* For most targets, min. size is important */ |
NirT | 0:c00e6c923941 | 56 | #endif |
NirT | 0:c00e6c923941 | 57 | #endif |
NirT | 0:c00e6c923941 | 58 | |
NirT | 0:c00e6c923941 | 59 | #define GUI_LOCK_H(hMem) GUI_ALLOC_LockH(hMem) |
NirT | 0:c00e6c923941 | 60 | #define GUI_UNLOCK_H(pMem) GUI_ALLOC_UnlockH((void **)&pMem) |
NirT | 0:c00e6c923941 | 61 | |
NirT | 0:c00e6c923941 | 62 | /******************************************************************* |
NirT | 0:c00e6c923941 | 63 | * |
NirT | 0:c00e6c923941 | 64 | * Commandline |
NirT | 0:c00e6c923941 | 65 | * |
NirT | 0:c00e6c923941 | 66 | ******************************************************************** |
NirT | 0:c00e6c923941 | 67 | */ |
NirT | 0:c00e6c923941 | 68 | |
NirT | 0:c00e6c923941 | 69 | #ifdef WIN32 |
NirT | 0:c00e6c923941 | 70 | #define GUI_DEBUG_GETCMDLINE() SIM_GetCmdLine() |
NirT | 0:c00e6c923941 | 71 | #else |
NirT | 0:c00e6c923941 | 72 | #define GUI_DEBUG_GETCMDLINE() 0 |
NirT | 0:c00e6c923941 | 73 | #endif |
NirT | 0:c00e6c923941 | 74 | |
NirT | 0:c00e6c923941 | 75 | /******************************************************************* |
NirT | 0:c00e6c923941 | 76 | * |
NirT | 0:c00e6c923941 | 77 | * Error macros |
NirT | 0:c00e6c923941 | 78 | * |
NirT | 0:c00e6c923941 | 79 | ******************************************************************** |
NirT | 0:c00e6c923941 | 80 | */ |
NirT | 0:c00e6c923941 | 81 | |
NirT | 0:c00e6c923941 | 82 | /* Make sure the macros are actually defined */ |
NirT | 0:c00e6c923941 | 83 | |
NirT | 0:c00e6c923941 | 84 | #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_LOG_ERRORS |
NirT | 0:c00e6c923941 | 85 | #define GUI_DEBUG_ERROROUT(s) GUI_ErrorOut(s) |
NirT | 0:c00e6c923941 | 86 | #define GUI_DEBUG_ERROROUT1(s,p0) GUI_ErrorOut1(s,p0) |
NirT | 0:c00e6c923941 | 87 | #define GUI_DEBUG_ERROROUT2(s,p0,p1) GUI_ErrorOut2(s,p0,p1) |
NirT | 0:c00e6c923941 | 88 | #define GUI_DEBUG_ERROROUT3(s,p0,p1,p2) GUI_ErrorOut3(s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 89 | #define GUI_DEBUG_ERROROUT4(s,p0,p1,p2,p3) GUI_ErrorOut4(s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 90 | #define GUI_DEBUG_ERROROUT_IF(exp,s) { if (exp) GUI_DEBUG_ERROROUT(s); } |
NirT | 0:c00e6c923941 | 91 | #define GUI_DEBUG_ERROROUT1_IF(exp,s,p0) { if (exp) GUI_DEBUG_ERROROUT1(s,p0); } |
NirT | 0:c00e6c923941 | 92 | #define GUI_DEBUG_ERROROUT2_IF(exp,s,p0,p1) { if (exp) GUI_DEBUG_ERROROUT2(s,p0,p1); } |
NirT | 0:c00e6c923941 | 93 | #define GUI_DEBUG_ERROROUT3_IF(exp,s,p0,p1,p2) { if (exp) GUI_DEBUG_ERROROUT3(s,p0,p1,p2); } |
NirT | 0:c00e6c923941 | 94 | #define GUI_DEBUG_ERROROUT4_IF(exp,s,p0,p1,p2,p3) { if (exp) GUI_DEBUG_ERROROUT4(s,p0,p1,p2,p3); } |
NirT | 0:c00e6c923941 | 95 | #else |
NirT | 0:c00e6c923941 | 96 | #define GUI_DEBUG_ERROROUT(s) |
NirT | 0:c00e6c923941 | 97 | #define GUI_DEBUG_ERROROUT1(s,p0) |
NirT | 0:c00e6c923941 | 98 | #define GUI_DEBUG_ERROROUT2(s,p0,p1) |
NirT | 0:c00e6c923941 | 99 | #define GUI_DEBUG_ERROROUT3(s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 100 | #define GUI_DEBUG_ERROROUT4(s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 101 | #define GUI_DEBUG_ERROROUT_IF(exp,s) |
NirT | 0:c00e6c923941 | 102 | #define GUI_DEBUG_ERROROUT1_IF(exp,s,p0) |
NirT | 0:c00e6c923941 | 103 | #define GUI_DEBUG_ERROROUT2_IF(exp,s,p0,p1) |
NirT | 0:c00e6c923941 | 104 | #define GUI_DEBUG_ERROROUT3_IF(exp,s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 105 | #define GUI_DEBUG_ERROROUT4_IF(exp,s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 106 | #endif |
NirT | 0:c00e6c923941 | 107 | |
NirT | 0:c00e6c923941 | 108 | /******************************************************************* |
NirT | 0:c00e6c923941 | 109 | * |
NirT | 0:c00e6c923941 | 110 | * Warning macros |
NirT | 0:c00e6c923941 | 111 | * |
NirT | 0:c00e6c923941 | 112 | ******************************************************************** |
NirT | 0:c00e6c923941 | 113 | */ |
NirT | 0:c00e6c923941 | 114 | |
NirT | 0:c00e6c923941 | 115 | /* Make sure the macros are actually defined */ |
NirT | 0:c00e6c923941 | 116 | |
NirT | 0:c00e6c923941 | 117 | #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_LOG_WARNINGS |
NirT | 0:c00e6c923941 | 118 | #define GUI_DEBUG_WARN(s) GUI_Warn(s) |
NirT | 0:c00e6c923941 | 119 | #define GUI_DEBUG_WARN1(s,p0) GUI_Warn1(s,p0) |
NirT | 0:c00e6c923941 | 120 | #define GUI_DEBUG_WARN2(s,p0,p1) GUI_Warn2(s,p0,p1) |
NirT | 0:c00e6c923941 | 121 | #define GUI_DEBUG_WARN3(s,p0,p1,p2) GUI_Warn3(s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 122 | #define GUI_DEBUG_WARN4(s,p0,p1,p2,p3) GUI_Warn4(s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 123 | #define GUI_DEBUG_WARN_IF(exp,s) { if (exp) GUI_DEBUG_WARN(s); } |
NirT | 0:c00e6c923941 | 124 | #define GUI_DEBUG_WARN1_IF(exp,s,p0) { if (exp) GUI_DEBUG_WARN1(s,p0); } |
NirT | 0:c00e6c923941 | 125 | #define GUI_DEBUG_WARN2_IF(exp,s,p0,p1) { if (exp) GUI_DEBUG_WARN2(s,p0,p1); } |
NirT | 0:c00e6c923941 | 126 | #define GUI_DEBUG_WARN3_IF(exp,s,p0,p1,p2) { if (exp) GUI_DEBUG_WARN3(s,p0,p1,p2); } |
NirT | 0:c00e6c923941 | 127 | #define GUI_DEBUG_WARN4_IF(exp,s,p0,p1,p2,p3) { if (exp) GUI_DEBUG_WARN4(s,p0,p1,p2,p3); } |
NirT | 0:c00e6c923941 | 128 | #else |
NirT | 0:c00e6c923941 | 129 | #define GUI_DEBUG_WARN(s) |
NirT | 0:c00e6c923941 | 130 | #define GUI_DEBUG_WARN1(s,p0) |
NirT | 0:c00e6c923941 | 131 | #define GUI_DEBUG_WARN2(s,p0,p1) |
NirT | 0:c00e6c923941 | 132 | #define GUI_DEBUG_WARN3(s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 133 | #define GUI_DEBUG_WARN4(s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 134 | #define GUI_DEBUG_WARN_IF(exp,s) |
NirT | 0:c00e6c923941 | 135 | #define GUI_DEBUG_WARN1_IF(exp,s,p0) |
NirT | 0:c00e6c923941 | 136 | #define GUI_DEBUG_WARN2_IF(exp,s,p0,p1) |
NirT | 0:c00e6c923941 | 137 | #define GUI_DEBUG_WARN3_IF(exp,s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 138 | #define GUI_DEBUG_WARN4_IF(exp,s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 139 | #endif |
NirT | 0:c00e6c923941 | 140 | |
NirT | 0:c00e6c923941 | 141 | /******************************************************************* |
NirT | 0:c00e6c923941 | 142 | * |
NirT | 0:c00e6c923941 | 143 | * Logging macros |
NirT | 0:c00e6c923941 | 144 | * |
NirT | 0:c00e6c923941 | 145 | ******************************************************************** |
NirT | 0:c00e6c923941 | 146 | */ |
NirT | 0:c00e6c923941 | 147 | /* Make sure the macros are actually defined */ |
NirT | 0:c00e6c923941 | 148 | |
NirT | 0:c00e6c923941 | 149 | #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_LOG_ALL |
NirT | 0:c00e6c923941 | 150 | #define GUI_DEBUG_LOG(s) GUI_Log(s) |
NirT | 0:c00e6c923941 | 151 | #define GUI_DEBUG_LOG1(s,p0) GUI_Log1(s,p0) |
NirT | 0:c00e6c923941 | 152 | #define GUI_DEBUG_LOG2(s,p0,p1) GUI_Log2(s,p0,p1) |
NirT | 0:c00e6c923941 | 153 | #define GUI_DEBUG_LOG3(s,p0,p1,p2) GUI_Log3(s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 154 | #define GUI_DEBUG_LOG4(s,p0,p1,p2,p3) GUI_Log4(s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 155 | #define GUI_DEBUG_LOG_IF(exp,s) { if (exp) GUI_DEBUG_LOG(s); } |
NirT | 0:c00e6c923941 | 156 | #define GUI_DEBUG_LOG1_IF(exp,s,p0) { if (exp) GUI_DEBUG_LOG1(s,p0); } |
NirT | 0:c00e6c923941 | 157 | #define GUI_DEBUG_LOG2_IF(exp,s,p0,p1) { if (exp) GUI_DEBUG_LOG2(s,p0,p1); } |
NirT | 0:c00e6c923941 | 158 | #define GUI_DEBUG_LOG3_IF(exp,s,p0,p1,p2) { if (exp) GUI_DEBUG_LOG3(s,p0,p1,p2); } |
NirT | 0:c00e6c923941 | 159 | #define GUI_DEBUG_LOG4_IF(exp,s,p0,p1,p2,p3) { if (exp) GUI_DEBUG_LOG4(s,p0,p1,p2,p3); } |
NirT | 0:c00e6c923941 | 160 | #else |
NirT | 0:c00e6c923941 | 161 | #define GUI_DEBUG_LOG(s) |
NirT | 0:c00e6c923941 | 162 | #define GUI_DEBUG_LOG1(s,p0) |
NirT | 0:c00e6c923941 | 163 | #define GUI_DEBUG_LOG2(s,p0,p1) |
NirT | 0:c00e6c923941 | 164 | #define GUI_DEBUG_LOG3(s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 165 | #define GUI_DEBUG_LOG4(s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 166 | #define GUI_DEBUG_LOG_IF(exp,s) |
NirT | 0:c00e6c923941 | 167 | #define GUI_DEBUG_LOG1_IF(exp,s,p0) |
NirT | 0:c00e6c923941 | 168 | #define GUI_DEBUG_LOG2_IF(exp,s,p0,p1) |
NirT | 0:c00e6c923941 | 169 | #define GUI_DEBUG_LOG3_IF(exp,s,p0,p1,p2) |
NirT | 0:c00e6c923941 | 170 | #define GUI_DEBUG_LOG4_IF(exp,s,p0,p1,p2,p3) |
NirT | 0:c00e6c923941 | 171 | #endif |
NirT | 0:c00e6c923941 | 172 | |
NirT | 0:c00e6c923941 | 173 | /******************************************************************* |
NirT | 0:c00e6c923941 | 174 | * |
NirT | 0:c00e6c923941 | 175 | * Asserts |
NirT | 0:c00e6c923941 | 176 | * |
NirT | 0:c00e6c923941 | 177 | ******************************************************************** |
NirT | 0:c00e6c923941 | 178 | */ |
NirT | 0:c00e6c923941 | 179 | #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_LOG_ERRORS |
NirT | 0:c00e6c923941 | 180 | #define GUI_DEBUG_ASSERT(exp) { if (!exp) GUI_DEBUG_ERROROUT(#exp); } |
NirT | 0:c00e6c923941 | 181 | #else |
NirT | 0:c00e6c923941 | 182 | #define GUI_DEBUG_ASSERT(exp) |
NirT | 0:c00e6c923941 | 183 | #endif |
NirT | 0:c00e6c923941 | 184 | |
NirT | 0:c00e6c923941 | 185 | #endif /* LCD_H */ |
NirT | 0:c00e6c923941 | 186 | |
NirT | 0:c00e6c923941 | 187 | |
NirT | 0:c00e6c923941 | 188 | |
NirT | 0:c00e6c923941 | 189 | |
NirT | 0:c00e6c923941 | 190 | /*************************** End of file ****************************/ |