Communication Error

I tried to print a file I uploaded to Octoprint and I got the error below.

Communication Error
There was a communication error while talking to your printer. Please consult the terminal output and OctoPrint.log for details.
Error: Printer keeps requesting line 17 again and again, communication stud.

octoprint.log

2020-02-13 09:15:00,885 - octoprint.filemanager.analysis - INFO - Starting analysis of local:PETG/Left_Arm_PET0.2mm.gcode
2020-02-13 09:15:01,937 - octoprint.filemanager.analysis - INFO - Analysis of entry local:PETG/Left_Arm_PET0.2mm.gcode finished, needed 1.05s
2020-02-13 09:15:08,612 - octoprint.printer.standard.job - INFO - Print job selected - origin: local, path: PETG/Left_Arm_PET0.2mm.gcode, owner: jansenchua, user: jansenchua
2020-02-13 09:15:08,646 - octoprint.util.comm - INFO - Changing monitoring state from "Operational" to "Starting"
2020-02-13 09:15:08,658 - octoprint.printer.standard.job - INFO - Print job started - origin: local, path: PETG/Left_Arm_PET0.2mm.gcode, owner: jansenchua, user: jansenchua
2020-02-13 09:15:08,670 - octoprint.util.comm - INFO - Changing monitoring state from "Starting" to "Printing"
2020-02-13 09:15:08,686 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2020-02-13 09:15:08,746 - octoprint.plugins.excluderegion - INFO - File selected, resetting internal state
2020-02-13 09:15:08,852 - octoprint.plugins.excluderegion - INFO - Printing started
2020-02-13 09:15:09,343 - octoprint.util.comm - INFO - Got a resend request from the printer: requested line = 17, current line = 19
| Last lines in terminal:
| Send: N10 M205 X10 Y10 Z0.3 E5.0*13
| Recv: ok N:10
| Send: N11 M205 S0 T0*19
| Recv: ok N:11
| Send: N12 M117 Heating...*65
| Recv: ok N:12
| Send: N13 M300 S2500 P100*39
| Recv: ok N:13
| Send: N14 M104 S220*80
| Recv: ok N:14
| Send: N15 M140 S85*108
| Recv: ok N:15
| Send: N16 G1 Z20*103
| Recv: ok N:16
| Send: N17 G28 X Y*36
| Recv: //sd cmd error cnt:0 len:15 :N17 G28 X Y*36
| Recv: 
| Recv: ok
| Send: N18 M84*38
| Recv: Resend:17
2020-02-13 09:15:09,347 - octoprint.util.comm - INFO - Firmware didn't send an 'ok' with their resend request. That's a known bug with some firmware variants out there. Simulating an ok to continue...
2020-02-13 09:15:09,363 - octoprint.util.comm - INFO - Got a resend request from the printer: requested line = 17, current line = 19
| Last lines in terminal:
| Recv: ok N:14
| Send: N15 M140 S85*108
| Recv: ok N:15
| Send: N16 G1 Z20*103
| Recv: ok N:16
| Send: N17 G28 X Y*36
| Recv: //sd cmd error cnt:0 len:15 :N17 G28 X Y*36
| Recv: 
| Recv: ok
| Send: N18 M84*38
| Recv: Resend:17
| Recv: //last:16 curr:18 rcv:N18 M84*38
| Send: N17 G28 X Y*36
| Recv: 
| Recv: //callback_pf error
| Recv: //sd cmd error cnt:1 len:15 :N17 G28 X Y*36
| Recv: 
| Recv: ok
| Send: N18 M84*38
| Recv: Resend:17

I am using Tronxy D01 Printer with the latest Octopi.

I can control my printer to move as well as heat the extruder and bed with Octopi without a problem.

Appreciate if anyone can help me. I am very new to OctoPrint

Try installing this

and also changing your G28 X Y in your slicer's start code configuration to G28 X0 Y0 and see if it helps. Your printer has a broken firmware (that is making its rounds more and more and causing a lot of users grief - complain to your printer vendor about this please, I can't!), this might successfully work around that.

Hi sorry I am really very very new to raspberry pi and octopi what shall I change the G28 X Y value to?

Also I am using tronxy not anycubic can I still install that plugin?

:face_with_raised_eyebrow:


Yes.

So what's the G28 X Y value?

Learn your g-code...

https://reprap.org/wiki/G-code

it's the command for homing you axis - X0 and Y0 axis in this case.
If you don't know a gcode just google it with something like G28 gcode

Ok thanks guys let me try

Hi I tried installing the plugin that u suggested now when i press print it doesn't show communication error.

however, the printer doesn't move at all... OctoPrint shows printing..

was thinking could u help me go through my gcode in slic3r to see if there is anything wrong. it works for me when i print directly from the microSD in the printer.

I am sorry I am really very new to 3d printing appreciate your help :slight_smile:

start g-code

M201 X500 Y500 Z100 E5000 ; sets maximum accelerations, mm/sec^2
M203 X500 Y500 Z5 E25 ; sets maximum feedrates, mm/sec
M204 S500 T500 ; sets acceleration (S) and retract acceleration (T)
M205 X10 Y10 Z0.3 E5.0 ; sets the jerk limits, mm/sec
M205 S0 T0 ; sets the minimum extruding and travel feed rate, mm/sec

;M117 Heating... ;Put printing message on LCD screen
M300 S2500 P100; Beep
;M221 S{if layer_height<0.075}100{else}95{endif} ; Set flow
M104 S[first_layer_temperature] ; set extruder temp
M140 S[first_layer_bed_temperature] ; set bed temp
G1 Z20 ; this is a good start heating position
G28 X Y; Home XY
M84 ; disable motors
M190 S[first_layer_bed_temperature] ; wait for bed temp
M109 S[first_layer_temperature] ; wait for extruder temp

; Start of print
G21; metric values
G90 ; absolute positioning
M82; set extruder to absolute mode

G28;

; Prepare nozzle
G92 E0 ; Set extrusion distance to 0
G92 E0 ; Set extrusion distance to 0
G1 F1800 E3;
G92 E0 ; Set extrusion distance to 0
G90;


; You may want to adjust the X and Y here so the nozzle is really above the bed!
G1 X5.0 Y5.0 F7200 ; Move to a position in the left front of the bed
G1 Z0.6; Move nozzle above 0.6 mm of the bed

G91 ; Use relative mode
; Make some jerky zick-zack move at the beginning
; This is supposed to get rid of residue at the nozzle
G1 X1.0 Y5.0 Z-0.1 E-1.0 F7200 ; X6 Y10 Z0.1, retract a tiny bit / 120mm/s
G1 X1.0 Y-5.0 Z0.1 E2.0 F7200 ; X7 Y5 Z0.2 extrude a tiny bit
G1 X2.0 Y5.0 Z-0.1 F7200 ; X9 Y10 Z0.1
G1 X2.0 Y-5.0 Z0.1 F7200 ; X11 Y5 Z0.2
G1 X2.0 Y5.0 F7200 ; X13 Y10
G1 X2.0 Y-5.0 F7200 ; X15 Y5

; now print a line of filament to prepare extrusion
G1 Y50 E20 F1000 ; prints a line in the front
G1 Y50 E40 F1000 ; prints a line in the front

; Done with the dancing :)
G92 E0 ; Set extrusion distance to 0
G90 ; switch back to absolute mode

;M117 Printing... ;Put printing message on LCD screen
; Start of actual GCode for the print

End g-code

G4 ; wait
M221 S100
M106 S0 ; turn off cooling fan
M104 S0 ; turn off extruder
M140 S0 ; turn off bed
G91
G1 F1800 E-3
G90
{if layer_z < max_print_height}G1 Z{z_offset+min(layer_z+30, max_print_height)}{endif} ; Move print head up
G28 X0 ; home x and y axis
G1 Y180; Remove Print Position
M84 ; disable motors
M300 S2600 P100; Beep

This start and end g-codes, you have them in the slicer or in OctoPrint?
The codes seem to belong to the slicer because the slicer has to fill in the values for the placeholders in brackets: [something] and do the if cases.

When there are no values for the temperatures, the printer assume 0 (zero) for them and a cold printer does not print.

Those are code for slicer I am wondering if anything could go wrong there. Can u help me to take a look :slight_smile:

Upload your output gcode file so we can take a look at how those placeholders are getting interpreted by Slic3r. Please also verify if you are using Prusa Slic3r, the regular Slic3r application, or some other "slicer" application like Cura, Ideamaker, Simplify3D, etc. There are lots of slicers and they all have different feature sets.

Sorry where can I get the output gcode... I am using prusa slicer