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.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2020 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 and extended capabilities report
  34. * If a capability is not reported, hosts should assume
  35. * the capability is not present.
  36. */
  37. void GcodeSuite::M115() {
  38. SERIAL_ECHOLNPGM(MSG_M115_REPORT);
  39. #if ENABLED(EXTENDED_CAPABILITIES_REPORT)
  40. // PAREN_COMMENTS
  41. #if ENABLED(PAREN_COMMENTS)
  42. cap_line(PSTR("PAREN_COMMENTS"), true);
  43. #endif
  44. // QUOTED_STRINGS
  45. #if ENABLED(GCODE_QUOTED_STRINGS)
  46. cap_line(PSTR("QUOTED_STRINGS"), true);
  47. #endif
  48. // SERIAL_XON_XOFF
  49. cap_line(PSTR("SERIAL_XON_XOFF")
  50. #if ENABLED(SERIAL_XON_XOFF)
  51. , true
  52. #endif
  53. );
  54. // BINARY_FILE_TRANSFER (M28 B1)
  55. cap_line(PSTR("BINARY_FILE_TRANSFER")
  56. #if ENABLED(BINARY_FILE_TRANSFER)
  57. , true
  58. #endif
  59. );
  60. // EEPROM (M500, M501)
  61. cap_line(PSTR("EEPROM")
  62. #if ENABLED(EEPROM_SETTINGS)
  63. , true
  64. #endif
  65. );
  66. // Volumetric Extrusion (M200)
  67. cap_line(PSTR("VOLUMETRIC")
  68. #if DISABLED(NO_VOLUMETRICS)
  69. , true
  70. #endif
  71. );
  72. // AUTOREPORT_TEMP (M155)
  73. cap_line(PSTR("AUTOREPORT_TEMP")
  74. #if ENABLED(AUTO_REPORT_TEMPERATURES)
  75. , true
  76. #endif
  77. );
  78. // PROGRESS (M530 S L, M531 <file>, M532 X L)
  79. cap_line(PSTR("PROGRESS"));
  80. // Print Job timer M75, M76, M77
  81. cap_line(PSTR("PRINT_JOB"), true);
  82. // AUTOLEVEL (G29)
  83. cap_line(PSTR("AUTOLEVEL")
  84. #if HAS_AUTOLEVEL
  85. , true
  86. #endif
  87. );
  88. // Z_PROBE (G30)
  89. cap_line(PSTR("Z_PROBE")
  90. #if HAS_BED_PROBE
  91. , true
  92. #endif
  93. );
  94. // MESH_REPORT (M420 V)
  95. cap_line(PSTR("LEVELING_DATA")
  96. #if HAS_LEVELING
  97. , true
  98. #endif
  99. );
  100. // BUILD_PERCENT (M73)
  101. cap_line(PSTR("BUILD_PERCENT")
  102. #if ENABLED(LCD_SET_PROGRESS_MANUALLY)
  103. , true
  104. #endif
  105. );
  106. // SOFTWARE_POWER (M80, M81)
  107. cap_line(PSTR("SOFTWARE_POWER")
  108. #if ENABLED(PSU_CONTROL)
  109. , true
  110. #endif
  111. );
  112. // CASE LIGHTS (M355)
  113. cap_line(PSTR("TOGGLE_LIGHTS")
  114. #if HAS_CASE_LIGHT
  115. , true
  116. #endif
  117. );
  118. cap_line(PSTR("CASE_LIGHT_BRIGHTNESS")
  119. #if HAS_CASE_LIGHT
  120. , PWM_PIN(CASE_LIGHT_PIN)
  121. #endif
  122. );
  123. // EMERGENCY_PARSER (M108, M112, M410, M876)
  124. cap_line(PSTR("EMERGENCY_PARSER")
  125. #if ENABLED(EMERGENCY_PARSER)
  126. , true
  127. #endif
  128. );
  129. // PROMPT SUPPORT (M876)
  130. cap_line(PSTR("PROMPT_SUPPORT")
  131. #if ENABLED(HOST_PROMPT_SUPPORT)
  132. , true
  133. #endif
  134. );
  135. // AUTOREPORT_SD_STATUS (M27 extension)
  136. cap_line(PSTR("AUTOREPORT_SD_STATUS")
  137. #if ENABLED(AUTO_REPORT_SD_STATUS)
  138. , true
  139. #endif
  140. );
  141. // THERMAL_PROTECTION
  142. cap_line(PSTR("THERMAL_PROTECTION")
  143. #if (ENABLED(THERMAL_PROTECTION_HOTENDS) || !EXTRUDERS) && (ENABLED(THERMAL_PROTECTION_BED) || !HAS_HEATED_BED) && (ENABLED(THERMAL_PROTECTION_CHAMBER) || !HAS_HEATED_CHAMBER)
  144. , true
  145. #endif
  146. );
  147. // MOTION_MODES (M80-M89)
  148. cap_line(PSTR("MOTION_MODES")
  149. #if ENABLED(GCODE_MOTION_MODES)
  150. , true
  151. #endif
  152. );
  153. // CHAMBER_TEMPERATURE (M141, M191)
  154. cap_line(PSTR("CHAMBER_TEMPERATURE")
  155. #if HAS_HEATED_CHAMBER
  156. , true
  157. #endif
  158. );
  159. #endif // EXTENDED_CAPABILITIES_REPORT
  160. }