Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions Marlin/src/module/tool_change.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -498,11 +498,7 @@ inline void invalid_extruder_error(const uint8_t e) {
* previous tool out of the way and the new tool into place.
*/
void tool_change(const uint8_t tmp_extruder, const float fr_mm_s/*=0.0*/, bool no_move/*=false*/) {
#if EXTRUDERS < 2

return invalid_extruder_error(tmp_extruder);

#elif ENABLED(MIXING_EXTRUDER) && MIXING_VIRTUAL_TOOLS > 1
#if ENABLED(MIXING_EXTRUDER) && MIXING_VIRTUAL_TOOLS > 1

if (tmp_extruder >= MIXING_VIRTUAL_TOOLS)
return invalid_extruder_error(tmp_extruder);
Expand All @@ -511,6 +507,11 @@ void tool_change(const uint8_t tmp_extruder, const float fr_mm_s/*=0.0*/, bool n
UNUSED(fr_mm_s);
UNUSED(no_move);

#elif EXTRUDERS < 2

if (tmp_extruder) invalid_extruder_error(tmp_extruder);
return;

#else

#if DISABLED(MIXING_EXTRUDER)
Expand Down