Browse Source

M706: Only cut filament if the setting is enabled

Guðni Már Gilbert 2 years ago
parent
commit
55d2eaf8c0
1 changed files with 5 additions and 1 deletions
  1. 5 1
      Firmware/Marlin_main.cpp

+ 5 - 1
Firmware/Marlin_main.cpp

@@ -3705,7 +3705,11 @@ static void gcodes_M704_M705_M706(uint16_t gcode)
                 MMU2::mmu2.eject_filament(mmuSlotIndex, false);
                 break;
             case 706:
-                MMU2::mmu2.cut_filament(mmuSlotIndex);
+#ifdef MMU_HAS_CUTTER
+                if (eeprom_read_byte((uint8_t*)EEPROM_MMU_CUTTER_ENABLED) != 0){
+                    MMU2::mmu2.cut_filament(mmuSlotIndex);
+                }
+#endif // MMU_HAS_CUTTER
                 break;
             default:
                 break;