@oozeBot File-dependent M-codes are already sent back to DSF because DSF needs to handle or intercept them:
// Pass file- and system-related commands to the SBC service if they came from somewhere else.
// They will be passed back to us via a binary buffer or separate SPI message if necessary.
if ( reprap.UsingSbcInterface() && reprap.GetSbcInterface().IsConnected() && !gb.IsBinary()
&& ( code == 0 || code == 1
|| code == 20 || code == 21 || code == 22 || code == 23 || code == 24 || code == 26 || code == 27 || code == 28
|| code == 30 || code == 32 || code == 36 || code == 37 || code == 38 || code == 39
|| code == 112
|| code == 470 || code == 471
|| code == 503 || code == 505
|| code == 540 || code == 550 || code == 552 || code == 586 || (code >= 587 && code <= 589)
|| code == 703
|| code == 905 || code == 929 || code == 997 || code == 999
)
)
{
gb.SendToSbc();
return false;
}
I've just added some new code that makes sure unknown G/M-codes are sent back to DSF before the default action is attempted (i.e. execute Mxxx.g or report an error if that fails).