My Marlin configs for Fabrikator Mini and CTC i3 Pro B
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

M999.cpp 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  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 <https://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #include "../gcode.h"
  23. #include "../../lcd/ultralcd.h" // for lcd_reset_alert_level
  24. #include "../../MarlinCore.h" // for marlin_state
  25. #include "../queue.h" // for flush_and_request_resend
  26. /**
  27. * M999: Restart after being stopped
  28. *
  29. * Default behavior is to flush the serial buffer and request
  30. * a resend to the host starting on the last N line received.
  31. *
  32. * Sending "M999 S1" will resume printing without flushing the
  33. * existing command buffer.
  34. */
  35. void GcodeSuite::M999() {
  36. marlin_state = MF_RUNNING;
  37. ui.reset_alert_level();
  38. if (parser.boolval('S')) return;
  39. queue.flush_and_request_resend();
  40. }