invalid / unknown codes reported on serial
This commit is contained in:
parent
bde1996250
commit
3adedb558b
|
|
@ -3829,7 +3829,10 @@ void process_commands()
|
||||||
eeprom_update_byte((unsigned char *)EEPROM_FARM_MODE, farm_mode);
|
eeprom_update_byte((unsigned char *)EEPROM_FARM_MODE, farm_mode);
|
||||||
lcd_update(2);
|
lcd_update(2);
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
printf("Unknown G code: ");
|
||||||
|
printf(cmdbuffer + bufindr + CMDHDRSIZE);
|
||||||
|
printf("\n");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -3846,7 +3849,10 @@ void process_commands()
|
||||||
|
|
||||||
/*for (++strchr_pointer; *strchr_pointer == ' ' || *strchr_pointer == '\t'; ++strchr_pointer);*/
|
/*for (++strchr_pointer; *strchr_pointer == ' ' || *strchr_pointer == '\t'; ++strchr_pointer);*/
|
||||||
if (*(strchr_pointer+index) < '0' || *(strchr_pointer+index) > '9') {
|
if (*(strchr_pointer+index) < '0' || *(strchr_pointer+index) > '9') {
|
||||||
SERIAL_ECHOLNPGM("Invalid M code");
|
printf("Invalid M code: ");
|
||||||
|
printf(cmdbuffer + bufindr + CMDHDRSIZE);
|
||||||
|
printf("\n");
|
||||||
|
|
||||||
} else
|
} else
|
||||||
switch((int)code_value())
|
switch((int)code_value())
|
||||||
{
|
{
|
||||||
|
|
@ -5928,9 +5934,9 @@ case 404: //M404 Enter the nominal filament width (3mm, 1.75mm ) N<3.0> or disp
|
||||||
break;
|
break;
|
||||||
|
|
||||||
#ifdef LIN_ADVANCE
|
#ifdef LIN_ADVANCE
|
||||||
case 900: // M900: Set LIN_ADVANCE options.
|
case 900: // M900: Set LIN_ADVANCE options.
|
||||||
gcode_M900();
|
gcode_M900();
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
case 907: // M907 Set digital trimpot motor current using axis codes.
|
case 907: // M907 Set digital trimpot motor current using axis codes.
|
||||||
|
|
@ -6147,7 +6153,11 @@ case 404: //M404 Enter the nominal filament width (3mm, 1.75mm ) N<3.0> or disp
|
||||||
gcode_LastN = Stopped_gcode_LastN;
|
gcode_LastN = Stopped_gcode_LastN;
|
||||||
FlushSerialRequestResend();
|
FlushSerialRequestResend();
|
||||||
break;
|
break;
|
||||||
default: SERIAL_ECHOLNPGM("Invalid M code.");
|
default:
|
||||||
|
printf("Unknown M code: ");
|
||||||
|
printf(cmdbuffer + bufindr + CMDHDRSIZE);
|
||||||
|
printf("\n");
|
||||||
|
//SERIAL_ECHO(cmdbuffer + bufindr + CMDHDRSIZE);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // end if(code_seen('M')) (end of M codes)
|
} // end if(code_seen('M')) (end of M codes)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue