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.

M115.cpp 4.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176
  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. #include "../gcode.h"
  23. #include "../../inc/MarlinConfig.h"
  24. #if ENABLED(EXTENDED_CAPABILITIES_REPORT)
  25. static void cap_line(PGM_P const name, bool ena=false) {
  26. SERIAL_ECHOPGM("Cap:");
  27. serialprintPGM(name);
  28. SERIAL_CHAR(':');
  29. SERIAL_ECHOLN(int(ena ? 1 : 0));
  30. }
  31. #endif
  32. /**
  33. * M115: Capabilities string
  34. */
  35. void GcodeSuite::M115() {
  36. SERIAL_ECHOLNPGM(MSG_M115_REPORT);
  37. #if ENABLED(EXTENDED_CAPABILITIES_REPORT)
  38. // SERIAL_XON_XOFF
  39. cap_line(PSTR("SERIAL_XON_XOFF")
  40. #if ENABLED(SERIAL_XON_XOFF)
  41. , true
  42. #endif
  43. );
  44. // BINARY_FILE_TRANSFER (M28 B1)
  45. cap_line(PSTR("BINARY_FILE_TRANSFER")
  46. #if ENABLED(BINARY_FILE_TRANSFER)
  47. , true
  48. #endif
  49. );
  50. // EEPROM (M500, M501)
  51. cap_line(PSTR("EEPROM")
  52. #if ENABLED(EEPROM_SETTINGS)
  53. , true
  54. #endif
  55. );
  56. // Volumetric Extrusion (M200)
  57. cap_line(PSTR("VOLUMETRIC")
  58. #if DISABLED(NO_VOLUMETRICS)
  59. , true
  60. #endif
  61. );
  62. // AUTOREPORT_TEMP (M155)
  63. cap_line(PSTR("AUTOREPORT_TEMP")
  64. #if ENABLED(AUTO_REPORT_TEMPERATURES)
  65. , true
  66. #endif
  67. );
  68. // PROGRESS (M530 S L, M531 <file>, M532 X L)
  69. cap_line(PSTR("PROGRESS"));
  70. // Print Job timer M75, M76, M77
  71. cap_line(PSTR("PRINT_JOB"), true);
  72. // AUTOLEVEL (G29)
  73. cap_line(PSTR("AUTOLEVEL")
  74. #if HAS_AUTOLEVEL
  75. , true
  76. #endif
  77. );
  78. // Z_PROBE (G30)
  79. cap_line(PSTR("Z_PROBE")
  80. #if HAS_BED_PROBE
  81. , true
  82. #endif
  83. );
  84. // MESH_REPORT (M420 V)
  85. cap_line(PSTR("LEVELING_DATA")
  86. #if HAS_LEVELING
  87. , true
  88. #endif
  89. );
  90. // BUILD_PERCENT (M73)
  91. cap_line(PSTR("BUILD_PERCENT")
  92. #if ENABLED(LCD_SET_PROGRESS_MANUALLY)
  93. , true
  94. #endif
  95. );
  96. // SOFTWARE_POWER (M80, M81)
  97. cap_line(PSTR("SOFTWARE_POWER")
  98. #if ENABLED(PSU_CONTROL)
  99. , true
  100. #endif
  101. );
  102. // CASE LIGHTS (M355)
  103. cap_line(PSTR("TOGGLE_LIGHTS")
  104. #if HAS_CASE_LIGHT
  105. , true
  106. #endif
  107. );
  108. cap_line(PSTR("CASE_LIGHT_BRIGHTNESS")
  109. #if HAS_CASE_LIGHT
  110. , PWM_PIN(CASE_LIGHT_PIN)
  111. #endif
  112. );
  113. // EMERGENCY_PARSER (M108, M112, M410, M876)
  114. cap_line(PSTR("EMERGENCY_PARSER")
  115. #if ENABLED(EMERGENCY_PARSER)
  116. , true
  117. #endif
  118. );
  119. // PROMPT SUPPORT (M876)
  120. cap_line(PSTR("PROMPT_SUPPORT")
  121. #if ENABLED(HOST_PROMPT_SUPPORT)
  122. , true
  123. #endif
  124. );
  125. // AUTOREPORT_SD_STATUS (M27 extension)
  126. cap_line(PSTR("AUTOREPORT_SD_STATUS")
  127. #if ENABLED(AUTO_REPORT_SD_STATUS)
  128. , true
  129. #endif
  130. );
  131. // THERMAL_PROTECTION
  132. cap_line(PSTR("THERMAL_PROTECTION")
  133. #if (ENABLED(THERMAL_PROTECTION_HOTENDS) || !EXTRUDERS) && (ENABLED(THERMAL_PROTECTION_BED) || !HAS_HEATED_BED) && (ENABLED(THERMAL_PROTECTION_CHAMBER) || !HAS_HEATED_CHAMBER)
  134. , true
  135. #endif
  136. );
  137. // MOTION_MODES (M80-M89)
  138. cap_line(PSTR("MOTION_MODES")
  139. #if ENABLED(GCODE_MOTION_MODES)
  140. , true
  141. #endif
  142. );
  143. // CHAMBER_TEMPERATURE (M141, M191)
  144. cap_line(PSTR("CHAMBER_TEMPERATURE")
  145. #if HAS_HEATED_CHAMBER
  146. , true
  147. #endif
  148. );
  149. #endif // EXTENDED_CAPABILITIES_REPORT
  150. }