Change filament number in T command to alternative if depleted and lcd_autoDepleteEnabled().

This commit is contained in:
Marek Bel 2019-01-04 22:32:48 +01:00
parent d89c03a0f1
commit c080b899c3

View File

@ -78,6 +78,7 @@
#include <avr/pgmspace.h>
#include "Dcodes.h"
#include "AutoDeplete.h"
#ifdef SWSPI
@ -6920,6 +6921,10 @@ if((eSoundMode==e_SOUND_MODE_LOUD)||(eSoundMode==e_SOUND_MODE_ONCE))
}
else {
tmp_extruder = code_value();
if (mmu_enabled && lcd_autoDepleteEnabled())
{
tmp_extruder = ad_getAlternative(tmp_extruder);
}
}
st_synchronize();
snmm_filaments_used |= (1 << tmp_extruder); //for stop print