add m118 support
rodzic
2cdea0bf1d
commit
bfc54aeb82
|
@ -2052,6 +2052,11 @@ void Commands::processMCode(GCode *com) {
|
|||
UI_STATUS_UPD_RAM(com->text);
|
||||
}
|
||||
break;
|
||||
case 118: // M118 message to host
|
||||
if(com->hasString()) {
|
||||
Com::printF(com->text);
|
||||
}
|
||||
break;
|
||||
case 119: // M119
|
||||
Commands::waitUntilEndOfAllMoves();
|
||||
Endstops::update();
|
||||
|
|
|
@ -773,7 +773,7 @@ bool GCode::parseAscii(char *line,bool fromSerial)
|
|||
params |= 2;
|
||||
if(M > 255) params |= 4096;
|
||||
// handle non standard text arguments that some M codes have
|
||||
if (M == 20 || M == 23 || M == 28 || M == 29 || M == 30 || M == 32 || M == 36 || M == 117)
|
||||
if (M == 20 || M == 23 || M == 28 || M == 29 || M == 30 || M == 32 || M == 36 || M == 117 || M == 118)
|
||||
{
|
||||
// after M command we got a filename or text
|
||||
char digit;
|
||||
|
@ -793,6 +793,8 @@ bool GCode::parseAscii(char *line,bool fromSerial)
|
|||
{
|
||||
if((M != 117 && M != 20 && *pos==' ') || *pos=='*') break;
|
||||
pos++; // find a space as file name end
|
||||
if((M != 118 && M != 20 && *pos==' ') || *pos=='*') break;
|
||||
pos++; // find a space as file name end
|
||||
}
|
||||
*pos = 0; // truncate filename by erasing space with null, also skips checksum
|
||||
waitUntilAllCommandsAreParsed = true; // don't risk string be deleted
|
||||
|
|
Ładowanie…
Reference in New Issue