doug_scott
Posts: 30
Joined: Sun Sep 29, 2019 9:37 am

Odd error messages - Unknown command: "M102"

I am running Marlin 2.0.6 with a MKS SGEN LPC1769 and am just doing some tests with configuring the usage of a filament sensor connected to the TFT and printing from PC using USB. I am getting this throughout the print in the log..

Unknown command: "M102"
Unknown command: "M103"
Unknown command: "M101"
Unknown command: "M102"
Unknown command: "M103"
Unknown command: "M101"
Unknown command: "M102"
Unknown command: "M103"
Unknown command: "M101"
Unknown command: "M102"
Unknown command: "M103"
Unknown command: "M101"
Unknown command: "M103"
Unknown command: "M101"
Unknown command: "M102"
Unknown command: "M103"
Unknown command: "M101"
Unknown command: "M103"
Unknown command: "M101"

The print completes ok, its just these log entries that I find odd. From what I can gather from Google, those codes are to do with starting and stopping extruding. I know that if you don't have the case insensitive option enabled in the firmware you will get similar errors from lower case gcode commands, but there are uppercase, and I have the case insensitive option enabled in the firmware. If I enable verbose logging here is what it logs:

SENT: M105
SENT: G1 X131.090 Y122.610 E0.7103
READ: ok
SENT: M105
READ: ok T:199.89 /200.00 B:70.00 /70.00 @:53 B@:36
SENT: G1 X131.483 Y117.840 E0.0860
READ: ok
SENT: M105
READ: ok T:199.66 /200.00 B:70.08 /70.00 @:61 B@:97
SENT: G1 X132.516 Y117.840 E0.0186
READ: ok
SENT: G1 X133.516 Y117.840 F1279
READ: ok T:199.89 /200.00 B:70.12 /70.00 @:37 B@:0
SENT: M103
READ: ok
SENT: M105
READ: ok
SENT: G1 X133.910 Y122.610 F1279
SENT: G1 X133.910 Y122.824
READ: echo:Unknown command: "M103"
Unknown command: "M103"
READ: ok
READ: ok T:199.89 /200.00 B:70.00 /70.00 @:64 B@:82
READ: ok
SENT: M105
SENT: G1 X133.425 Y117.845 F3900
SENT: M101
READ: ok
READ: ok T:200.00 /200.00 B:70.00 /70.00 @:57 B@:34
READ: ok
SENT: M105
SENT: G1 X133.520 Y117.940 E0.0024 F1705
READ: echo:Unknown command: "M101"
Unknown command: "M101"
READ: ok
READ: ok T:200.14 /200.00 B:69.91 /70.00 @:62 B@:91
READ: ok
SENT: G1 X133.581 Y118.680 E0.0133
SENT: G1 X132.746 Y117.845 E0.0212
READ: ok
SENT: G1 X132.067 Y117.845 E0.0122
READ: ok
SENT: G1 X133.642 Y119.420 E0.0400
READ: ok
SENT: G1 X133.703 Y120.160 E0.0133
READ: ok
SENT: M105
SENT: G1 X131.480 Y117.937 E0.0565
READ: ok
SENT: G1 X131.429 Y118.564 E0.0113
READ: ok T:200.14 /200.00 B:69.91 /70.00 @:64 B@:57
READ: ok
SENT: M105
SENT: G1 X133.764 Y120.899 E0.0593
READ: ok
SENT: G1 X133.825 Y121.639 E0.0133
READ: ok T:200.14 /200.00 B:70.00 /70.00 @:51 B@:0

Any ideas why it doesn't like M101/M102/M103 during a print?
parallyze
Posts: 372
Joined: Fri Jun 05, 2015 4:18 am

Re: Odd error messages - Unknown command: "M102"

Hi,
doug_scott wrote: Thu Sep 03, 2020 4:05 am I am running Marlin 2.0.6 with a MKS SGEN LPC1769 and am just doing some tests with configuring the usage of a filament sensor connected to the TFT and printing from PC using USB. I am getting this throughout the print in the log..
<snip>
Any ideas why it doesn't like M101/M102/M103 during a print?
if I remember correctly that's legacy commands (extruder fwd/rev/off), are you sure you need them? You can disable
the usage of these commands on the gcode tab of your process...

Edit: Description of the gcode tab:
viewtopic.php?t=2366

If you'd like to use the FW Retraction, try replacing the M101-103 commands as mentioned here:
viewtopic.php?t=7869#p45740
S3D-Jake
Posts: 1048
Joined: Wed Jun 20, 2018 12:45 pm

Re: Odd error messages - Unknown command: "M102"

Very true! M101/M102/M103 are legacy commands for controlling the extruder motor. They are useful for support machines that still require legacy code or need special commands that correspond with where these commands would get automatically inserted by Simplify3D. Why they're turned on in your printer's profile is not clear. Also like parallyze said, a very useful trick to utilize firmware retraction is to replace the M101/M102/M103's.
"A bird does not sing because it has an answer. It sings because it has a song."
doug_scott
Posts: 30
Joined: Sun Sep 29, 2019 9:37 am

Re: Odd error messages - Unknown command: "M102"

That was it, oddly enough of the 20 some odd saved settings I have, that was the only one with that enabled, and this was the first time I ran it from the PC. When used from SD card I don't see the error messages in the TFT.

Thanks

Return to “Troubleshooting and Bug Reports”