My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

debug_out.h 3.1KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2019 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
  4. *
  5. * Based on Sprinter and grbl.
  6. * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
  7. *
  8. * This program is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #pragma once
  23. //
  24. // Serial aliases for debugging.
  25. // Include this header after defining DEBUG_OUT
  26. // (or not) in a given .cpp file
  27. //
  28. #undef DEBUG_PRINT_P
  29. #undef DEBUG_ECHO_START
  30. #undef DEBUG_ERROR_START
  31. #undef DEBUG_CHAR
  32. #undef DEBUG_ECHO
  33. #undef DEBUG_ECHO_F
  34. #undef DEBUG_ECHOLN
  35. #undef DEBUG_ECHOPGM
  36. #undef DEBUG_ECHOLNPGM
  37. #undef DEBUG_ECHOPAIR
  38. #undef DEBUG_ECHOPAIR_F
  39. #undef DEBUG_ECHOLNPAIR
  40. #undef DEBUG_ECHOLNPAIR_F
  41. #undef DEBUG_ECHO_MSG
  42. #undef DEBUG_ERROR_MSG
  43. #undef DEBUG_EOL
  44. #undef DEBUG_POS
  45. #undef DEBUG_XYZ
  46. #undef DEBUG_DELAY
  47. #if DEBUG_OUT
  48. #define DEBUG_PRINT_P(P) serialprintPGM(P)
  49. #define DEBUG_ECHO_START SERIAL_ECHO_START
  50. #define DEBUG_ERROR_START SERIAL_ERROR_START
  51. #define DEBUG_CHAR SERIAL_CHAR
  52. #define DEBUG_ECHO SERIAL_ECHO
  53. #define DEBUG_ECHO_F SERIAL_ECHO_F
  54. #define DEBUG_ECHOLN SERIAL_ECHOLN
  55. #define DEBUG_ECHOPGM SERIAL_ECHOPGM
  56. #define DEBUG_ECHOLNPGM SERIAL_ECHOLNPGM
  57. #define DEBUG_ECHOPAIR SERIAL_ECHOPAIR
  58. #define DEBUG_ECHOPAIR_F SERIAL_ECHOPAIR_F
  59. #define DEBUG_ECHOLNPAIR SERIAL_ECHOLNPAIR
  60. #define DEBUG_ECHOLNPAIR_F SERIAL_ECHOLNPAIR_F
  61. #define DEBUG_ECHO_MSG SERIAL_ECHO_MSG
  62. #define DEBUG_ERROR_MSG SERIAL_ERROR_MSG
  63. #define DEBUG_EOL SERIAL_EOL
  64. #define DEBUG_POS SERIAL_POS
  65. #define DEBUG_XYZ SERIAL_XYZ
  66. #define DEBUG_DELAY(ms) serial_delay(ms)
  67. #else
  68. #define DEBUG_PRINT_P(P) NOOP
  69. #define DEBUG_ECHO_START() NOOP
  70. #define DEBUG_ERROR_START() NOOP
  71. #define DEBUG_CHAR(...) NOOP
  72. #define DEBUG_ECHO(...) NOOP
  73. #define DEBUG_ECHO_F(...) NOOP
  74. #define DEBUG_ECHOLN(...) NOOP
  75. #define DEBUG_ECHOPGM(...) NOOP
  76. #define DEBUG_ECHOLNPGM(...) NOOP
  77. #define DEBUG_ECHOPAIR(...) NOOP
  78. #define DEBUG_ECHOPAIR_F(...) NOOP
  79. #define DEBUG_ECHOLNPAIR(...) NOOP
  80. #define DEBUG_ECHOLNPAIR_F(...) NOOP
  81. #define DEBUG_ECHO_MSG(...) NOOP
  82. #define DEBUG_ERROR_MSG(...) NOOP
  83. #define DEBUG_EOL() NOOP
  84. #define DEBUG_POS(...) NOOP
  85. #define DEBUG_XYZ(...) NOOP
  86. #define DEBUG_DELAY(...) NOOP
  87. #endif
  88. #undef DEBUG_OUT