Firmware reported an error // OctoPrint will disconnect // error: Missing linenumber

What is the problem?
I've been print with my custom korsel/delta (atmega - running Repetier firmware) directly from computer for awhile.
I found out how interesting octoprint is and set it up, manage to get the basic operation work well,
ie: turn on/off -set fan/temperature, home, extrude/retract, & send several g-code comand in terminal tab.
but.
I can't print anything via octoprint.
upload several gcode created on slic3r and cura(repetier) from my computer.
but each time i tried to run it always get this eror report:
firmware reported an error // OctoPrint will disconnect // error: Missing linenumber

i realy confused on how to get the line number into gcode from repetier.

What did you already try to solve it?

find the explanation about line number on sites but getting hard to find relevant topic/solution/explanation about getting line number to g.code.

planing to update repetier firmware on the atmega but still find if there is another solution because dont want to risk recalibrate the printer because it will takes time.

considering back to old school printing directly from computer.

desperate.

Additional information about your setup (OctoPrint version, OctoPi version, printer, firmware, octoprint.log, serial.log or output on terminal tab, ...)

octoprint version 1.3.8
octo pi version 0.14

custom korsel/delta with atmega
running Repetier_0.92.9

log:

  1. Recv: SelectExtruder:0
  2. Recv: FlowMultiply:100
  3. Recv: X:0.00 Y:0.00 Z:136.800 E:0.0000
  4. Recv: ok 127
  5. Recv: wait
  6. Send: N128 M105*44
  7. Recv: ok 128
  8. Recv: T:25.58 /0 @:0
  9. Changing monitoring state from "Operational" to "Printing"
  10. Send: N0 M110 N0*125
  11. Recv: ok
  12. Send: N1 M104 S200*102
  13. Recv: ok 1
  14. Send: N2 G28*17
  15. Recv: TargetExtr0:200
  16. Recv: ok 2
  17. Send: N3 G1 Z5 F2000*0
  18. Recv: SelectExtruder:0
  19. Recv: FlowMultiply:100
  20. Recv: X:0.00 Y:0.00 Z:136.800 E:0.0000
  21. Recv: ok 3
  22. Send: m106 s175
  23. Send: g1 x0 y80 z5 f2000
  24. Send: N4 M109 S200*110
  25. Recv: Error:Missing linenumber
  26. Changing monitoring state from "Printing" to "Error: Missing linenumber"
  27. Changing monitoring state from "Error: Missing linenumber" to "Offline (Error: Missing linenumber)"
  28. Connection closed, closing down monitor
  29. Connecting to: /dev/ttyACM0
  30. Changing monitoring state from "Offline" to "Opening serial port"
  31. Connected to: Serial<id=0x6afbda70, open=True>(port='/dev/ttyACM0', baudrate=115200, bytesize=8, parity='N', stopbits=1, timeout=10.0, xonxoff=False, rtscts=False, dsrdtr=False), starting monitor
  32. Changing monitoring state from "Opening serial port" to "Connecting"
  33. Recv: 143.17 /200 @:255
  34. Send: N0 M110 N0*125
  35. Recv: T:144.88 /200 @:255
  36. Recv: T:146.59 /200 @:255
  37. Recv:
  38. Recv: T:138.12 /200 @:255
  39. Recv: T:139.60 /200 @:255
  40. Recv: T:141.27 /200 @:255
  41. Recv: T:143.17 /200 @:255
  42. Recv: T:144.88 /200 @:255
  43. Recv: T:146.59 /200 @:255
  44. Recv: start
  45. Send: N0 M110 N0*125
  46. Recv: Transformation matrix: 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000
  47. Recv: Free RAM:1264
  48. Recv: Autoretract:0
  49. Recv: X:0.00 Y:0.00 Z:0.000 E:0.0000
  50. Recv: SelectExtruder:0
  51. Recv: FlowMultiply:100
  52. Recv: ok
  53. Changing monitoring state from "Connecting" to "Operational"
  54. Send: N1 M105*38
  55. Recv: ok 1
  56. Recv: T:0.00 /0 @:0
  57. Send: N0 M110 N0*125
  58. Recv: ok
  59. Send: N1 M115*39
  60. Recv: ok 1
  61. Send: N2 M21*18
  62. Recv: FIRMWARE_NAME:Repetier_0.92.9 FIRMWARE_URL:https://github.com/repetier/Repetier-Firmware/ PROTOCOL_VERSION:1.0 MACHINE_TYPE:Delta EXTRUDER_COUNT:1 REPETIER_PROTOCOL:3
  63. Recv: Printed filament:106.22m Printing time:1 days 6 hours 21 min
  64. Recv: PrinterMode:FFF
  65. Recv: ok 2
  66. Send: N3 M115*37
  67. Recv: ok 3
  68. Send: N4 M21*20
  69. Recv: FIRMWARE_NAME:Repetier_0.92.9 FIRMWARE_URL:https://github.com/repetier/Repetier-Firmware/ PROTOCOL_VERSION:1.0 MACHINE_TYPE:Delta EXTRUDER_COUNT:1 REPETIER_PROTOCOL:3
  70. Recv: Printed filament:106.22m Printing time:1 days 6 hours 21 min
  71. Recv: PrinterMode:FFF
  72. Recv: ok 4

Ill take a stab at this one but it looks like a good ol' rabbits hole. So I think the issue is at line 22 of the "log:" m106 s175. that is a command that only is available in RepRapFirmwares one of which is repetier. In the RepRap wiki its M106: Fan On now at the bottom of that section there is this note

If M104 is (or becomes) active on a heater (or other device) with a feedback sensor it will correct any M106 initiated control output value change in the time it takes for the PID (of other feedback) loop to adjust it back to minimum error. It may not be easy to observe a change in the temperature (process value) due to this brief change in the control value

Now if you look back into the "log:" you can see on line "12" the M104 command has already been issued and so on line "22" when you send the m106 command it causes the above noted nuance which causes missing line number issue leaving line "23" unnumbered. Okay so that's what i think is happening now possible solution would be to remove m106 from being sent which idk where that is coming from? maybe you do. if not than you could have the M104 command sent later on, after the m106 command.. The M104 seems to be a start.gcode addition by cura or slic3r. another spot of interests is on line "24" right before the error is thrown the M109 command is sent which seems to be the same as a M104 command which is where the rabbits hole begins. I did not venture in.
But the m106 command is gotta be the culprit in some way shape or form and so maybe now you can figure out what is best for you to do in my opinion it would be too find the m106 command and stop it from entering the gcode or move it too send sooner than the M104 command by adding it to the start.gcode in cura or slic3r.

I'm not sure I agree with the assessment by @freshnew. I think the note is for Teacup firmware, not Repetier. M104 is set extruder temperature and M106 is set the part cooling fan speed.

Lines 22 and 23 are sent without line numbers or checksums and the printer is complaining about that.

Why lines 22 and 23 are being sent without line numbers is the mystery. I do notice that lines 22 and 23 have lowercase commands which isn't strictly kosher. Look at the GCode that you uploaded and see if lines 22 and 23 are in there (not at the same line numbers). Check your slicer for start Gcode that has lowercase commands and switch them to uppercase. Do you have scripts defined in OctoPrint?

I can solve this mystery. GCODE is supposed to be upper case. OctoPrint depends on this and will only prefix line numbers to actual GCODE commands. There are firmwares out there, e.g. Smoothieware, that allow in-band commands to be sent that are not GCODE and are actually handled differently from GCODE, so prefixing line numbers there might cause issues.

Repetier always expects line numbers (and checksums) with all sent commands though, and hence complains here.

Fix your GCODE to not contain lower case "GCODE" commands by turning the m106 s175 into M106 S175 and the g1 x0 y80 z5 f2000 into G1 X0 Y80 Z5 F2000 (probably in your slicer's start GCODE?) and things should work just fine.

Hey heeey... it works!!! thnx very much guys!
thnx for the insighful analysis @freshnew
thnx to point out the anomaly @b-morgan
you-are-amazing! @foosel !!!

i'm totally newb with all the electronic and programing stuff and been self reseach from all over the web & pretty sure miss alot of basic stuff.

THANK YOU !!

1 Like