Browse Source

Change Marlin debug flag names to fix conflicts (#12340)

In reference to #11000
Scott Lahteine 5 years ago
parent
commit
b3b4e6dc45
No account linked to committer's email address

+ 0
- 1
Marlin/src/HAL/HAL_STM32/HAL.h View File

23
 #pragma once
23
 #pragma once
24
 
24
 
25
 #define CPU_32_BIT
25
 #define CPU_32_BIT
26
-#undef DEBUG_NONE
27
 
26
 
28
 #ifndef vsnprintf_P
27
 #ifndef vsnprintf_P
29
   #define vsnprintf_P vsnprintf
28
   #define vsnprintf_P vsnprintf

+ 0
- 10
Marlin/src/HAL/HAL_STM32F1/HAL.h View File

27
  */
27
  */
28
 
28
 
29
 #define CPU_32_BIT
29
 #define CPU_32_BIT
30
-#undef DEBUG_NONE
31
 
30
 
32
 #ifndef vsnprintf_P
31
 #ifndef vsnprintf_P
33
   #define vsnprintf_P vsnprintf
32
   #define vsnprintf_P vsnprintf
42
 #include <Arduino.h>
41
 #include <Arduino.h>
43
 
42
 
44
 // --------------------------------------------------------------------------
43
 // --------------------------------------------------------------------------
45
-// Undefine DEBUG_ settings
46
-// --------------------------------------------------------------------------
47
-
48
-
49
-#undef DEBUG_NONE
50
-#undef DEBUG_FAULT
51
-#undef DEBUG_ALL
52
-
53
-// --------------------------------------------------------------------------
54
 // Includes
44
 // Includes
55
 // --------------------------------------------------------------------------
45
 // --------------------------------------------------------------------------
56
 
46
 

+ 0
- 9
Marlin/src/HAL/HAL_STM32F1/README.md View File

13
 #endif
13
 #endif
14
 <>
14
 <>
15
 
15
 
16
-Add the following 3 lines:
17
-<>
18
-#undef DEBUG_NONE
19
-#undef DEBUG_FAULT
20
-#undef DEBUG_ALL
21
-<>
22
-
23
 ### Main developers:
16
 ### Main developers:
24
 Victorpv
17
 Victorpv
25
 xC000005
18
 xC000005
30
 
23
 
31
 PRs should only be sent to Marlin bugfix-2.0.x branch once tested in printing so not to introduce new bugs.
24
 PRs should only be sent to Marlin bugfix-2.0.x branch once tested in printing so not to introduce new bugs.
32
 For testing/dev, you can submit to the above branch
25
 For testing/dev, you can submit to the above branch
33
-
34
-

+ 0
- 1
Marlin/src/HAL/HAL_STM32F4/HAL.h View File

23
 #pragma once
23
 #pragma once
24
 
24
 
25
 #define CPU_32_BIT
25
 #define CPU_32_BIT
26
-#undef DEBUG_NONE
27
 
26
 
28
 #ifndef vsnprintf_P
27
 #ifndef vsnprintf_P
29
   #define vsnprintf_P vsnprintf
28
   #define vsnprintf_P vsnprintf

+ 0
- 1
Marlin/src/HAL/HAL_STM32F7/HAL.h View File

23
 #pragma once
23
 #pragma once
24
 
24
 
25
 #define CPU_32_BIT
25
 #define CPU_32_BIT
26
-#undef DEBUG_NONE
27
 
26
 
28
 #ifndef vsnprintf_P
27
 #ifndef vsnprintf_P
29
   #define vsnprintf_P vsnprintf
28
   #define vsnprintf_P vsnprintf

+ 1
- 1
Marlin/src/core/serial.cpp View File

22
 
22
 
23
 #include "serial.h"
23
 #include "serial.h"
24
 
24
 
25
-uint8_t marlin_debug_flags = DEBUG_NONE;
25
+uint8_t marlin_debug_flags = MARLIN_DEBUG_NONE;
26
 
26
 
27
 const char errormagic[] PROGMEM = "Error:";
27
 const char errormagic[] PROGMEM = "Error:";
28
 const char echomagic[]  PROGMEM = "echo:";
28
 const char echomagic[]  PROGMEM = "echo:";

+ 11
- 11
Marlin/src/core/serial.h View File

27
 /**
27
 /**
28
  * Define debug bit-masks
28
  * Define debug bit-masks
29
  */
29
  */
30
-enum DebugFlags : unsigned char {
31
-  DEBUG_NONE          = 0,
32
-  DEBUG_ECHO          = _BV(0), ///< Echo commands in order as they are processed
33
-  DEBUG_INFO          = _BV(1), ///< Print messages for code that has debug output
34
-  DEBUG_ERRORS        = _BV(2), ///< Not implemented
35
-  DEBUG_DRYRUN        = _BV(3), ///< Ignore temperature setting and E movement commands
36
-  DEBUG_COMMUNICATION = _BV(4), ///< Not implemented
37
-  DEBUG_LEVELING      = _BV(5), ///< Print detailed output for homing and leveling
38
-  DEBUG_MESH_ADJUST   = _BV(6), ///< UBL bed leveling
39
-  DEBUG_ALL           = 0xFF
30
+enum MarlinDebugFlags : uint8_t {
31
+  MARLIN_DEBUG_NONE          = 0,
32
+  MARLIN_DEBUG_ECHO          = _BV(0), ///< Echo commands in order as they are processed
33
+  MARLIN_DEBUG_INFO          = _BV(1), ///< Print messages for code that has debug output
34
+  MARLIN_DEBUG_ERRORS        = _BV(2), ///< Not implemented
35
+  MARLIN_DEBUG_DRYRUN        = _BV(3), ///< Ignore temperature setting and E movement commands
36
+  MARLIN_DEBUG_COMMUNICATION = _BV(4), ///< Not implemented
37
+  MARLIN_DEBUG_LEVELING      = _BV(5), ///< Print detailed output for homing and leveling
38
+  MARLIN_DEBUG_MESH_ADJUST   = _BV(6), ///< UBL bed leveling
39
+  MARLIN_DEBUG_ALL           = 0xFF
40
 };
40
 };
41
 
41
 
42
 extern uint8_t marlin_debug_flags;
42
 extern uint8_t marlin_debug_flags;
43
-#define DEBUGGING(F) (marlin_debug_flags & (DEBUG_## F))
43
+#define DEBUGGING(F) (marlin_debug_flags & (MARLIN_DEBUG_## F))
44
 
44
 
45
 #if TX_BUFFER_SIZE < 1
45
 #if TX_BUFFER_SIZE < 1
46
   #define SERIAL_FLUSHTX_P(p)
46
   #define SERIAL_FLUSHTX_P(p)

+ 1
- 1
Marlin/src/gcode/bedlevel/abl/G29.cpp View File

157
   // G29 Q is also available if debugging
157
   // G29 Q is also available if debugging
158
   #if ENABLED(DEBUG_LEVELING_FEATURE)
158
   #if ENABLED(DEBUG_LEVELING_FEATURE)
159
     const uint8_t old_debug_flags = marlin_debug_flags;
159
     const uint8_t old_debug_flags = marlin_debug_flags;
160
-    if (seenQ) marlin_debug_flags |= DEBUG_LEVELING;
160
+    if (seenQ) marlin_debug_flags |= MARLIN_DEBUG_LEVELING;
161
     if (DEBUGGING(LEVELING)) {
161
     if (DEBUGGING(LEVELING)) {
162
       DEBUG_POS(">>> G29", current_position);
162
       DEBUG_POS(">>> G29", current_position);
163
       log_machine_info();
163
       log_machine_info();

Loading…
Cancel
Save