diff options
-rw-r--r-- | src/GCodes/GCodes2.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/GCodes/GCodes2.cpp b/src/GCodes/GCodes2.cpp index 7bdb66c4..89889dc6 100644 --- a/src/GCodes/GCodes2.cpp +++ b/src/GCodes/GCodes2.cpp @@ -509,6 +509,14 @@ bool GCodes::HandleGcode(GCodeBuffer& gb, const StringRef& reply) THROWS(GCodeEx break; default: +#if HAS_SBC_INTERFACE + // Send unknown non-binary codes to DSF so potential plugins can interpret them + if (reprap.UsingSbcInterface() && reprap.GetSbcInterface().IsConnected() && !gb.IsBinary()) + { + gb.SendToSbc(); + return false; + } +#endif result = TryMacroFile(gb); break; } @@ -4690,6 +4698,14 @@ bool GCodes::HandleMcode(GCodeBuffer& gb, const StringRef& reply) THROWS(GCodeEx break; default: +#if HAS_SBC_INTERFACE + // Send unknown non-binary codes to DSF so potential plugins can interpret them + if (reprap.UsingSbcInterface() && reprap.GetSbcInterface().IsConnected() && !gb.IsBinary()) + { + gb.SendToSbc(); + return false; + } +#endif result = TryMacroFile(gb); break; } |