Skip to content

Commit 3640d4d

Browse files
committed
Provide DBG_NONE/ERROR/ etc. values in case ArduinoDebugUtils is not compiled in (which is the case when working with Uno WiFi Rev. 2
1 parent 41e2392 commit 3640d4d

File tree

1 file changed

+18
-5
lines changed

1 file changed

+18
-5
lines changed

src/AIoTC_Config.h

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,24 @@
3131
#endif
3232

3333
#if defined(ARDUINO_AVR_UNO_WIFI_REV2)
34-
#define DEBUG_ERROR
35-
#define DEBUG_WARNING
36-
#define DEBUG_INFO
37-
#define DEBUG_DEBUG
38-
#define DEBUG_VERBOSE
34+
/* Define debug macros which effectively removes them from the
35+
* the codebase for Arduino Uno WiFi. Rev. 2.
36+
*/
37+
# define DEBUG_ERROR
38+
# define DEBUG_WARNING
39+
# define DEBUG_INFO
40+
# define DEBUG_DEBUG
41+
# define DEBUG_VERBOSE
42+
/* Provide defines for constants provided within Arduino_DebugUtils
43+
* in order to allow older sketches using those constants to still
44+
* compile.
45+
*/
46+
# define DBG_NONE -1
47+
# define DBG_ERROR 0
48+
# define DBG_WARNING 1
49+
# define DBG_INFO 2
50+
# define DBG_DEBUG 3
51+
# define DBG_VERBOSE 4
3952
#endif
4053

4154
#ifndef DEBUG_ERROR

0 commit comments

Comments
 (0)