Merge pull request #1070 from PavelSindler/show_extruder

show active extruder on status screen corrected
This commit is contained in:
PavelSindler 2018-08-27 05:25:32 +02:00 committed by GitHub
commit 7f9eb7362e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 5 deletions

View file

@ -3162,8 +3162,11 @@ void gcode_M701()
{
printf_P(PSTR("gcode_M701 begin\n"));
if (mmu_enabled)
extr_adj(mmu_extruder);//loads current extruder
if (mmu_enabled)
{
extr_adj(tmp_extruder);//loads current extruder
mmu_extruder = tmp_extruder;
}
else
{
enable_z();
@ -6744,7 +6747,7 @@ if((eSoundMode==e_SOUND_MODE_LOUD)||(eSoundMode==e_SOUND_MODE_ONCE))
case 701: //M701: load filament
{
if (mmu_enabled && code_seen('E'))
mmu_extruder = code_value();
tmp_extruder = code_value();
gcode_M701();
}
break;

View file

@ -530,9 +530,9 @@ void lcdui_print_extruder(void)
{
int chars = 0;
if (mmu_extruder == tmp_extruder)
chars = lcd_printf_P(_N(" T%u"), mmu_extruder);
chars = lcd_printf_P(_N(" T%u"), mmu_extruder+1);
else
chars = lcd_printf_P(_N(" %u>%u"), mmu_extruder, tmp_extruder);
chars = lcd_printf_P(_N(" %u>%u"), mmu_extruder+1, tmp_extruder+1);
lcd_space(5 - chars);
}