Octoprint looses USB connection with printer repeatedly

If your cable isn't too long, you can temporarily make a "poor man's shielding"...

  • get some aluminum foil
  • and some Scotch tape
  • cut the aluminum foil in long strips of the same width as the circumference of your serial cable
  • put some Scotch tape on the table upside down (securing the ends)
  • put the aluminum foil strip on top of the tape so that a 1/4" of the tape isn't covered
  • wrap the aluminum foil + tape around the serial cable, aluminum side toward the cable
  • stick the tape so that it stays
  • wrap it again with tape so that none of the aluminum can short to something else (insulating it)

Then put it back into service. A real version of a shielded cable then connects the ground wire to the shielding but this version is good enough. If you find that this poor man's version allows you to connect to your printer, then go buy an expensive one.

If it's a cheap board, it could be a clone FTDI chip, google "ftdi gate". If you have a clone ftdi chip then, good luck.

that's kinda worse possible scenario :frowning: ... since afaik ENDER 3 is a CREALITY I seriously doubt that board uses original FTDI chip as @PythonAteMyPerl already suspected :frowning: ... those chips are so unstable :frowning: ...

Check the board, see if, maybe, between ftdi chip (the only chip after usb connector) and big atmega chip are some 3 or 4 test pins, maybe even 3-4 pin header? try to follow traces from those pins where they go to ftdi chip or to atmega chip... if those pins are exposed you can bypass the crappy chip and connect uart directly from rpi to atmega

of course, before all that, try a decent usb cable (for e.g. the short blue cables being sold on ebay/ali 50% of those don't work at all, and the other 50% work if there's no lot of interference around them) ... see if you have usb cable you got with some MFP printer, those are usually great :smiley: ... also, check, doublecheck and tripple check power to the rpi and remove that 5Vusb tape you added

I have started to get the same problem the last few weeks :frowning: Octoprint on my Pi 3B + have been working well on my Ender 3, but suddenly it has started to get "communication error" mid print.. and about 50% fail rate is starting to become a problem :stuck_out_tongue: Any suggestions is welcommed to say it mildly hehe

Start by posting octoprint.log and a serial.log or the contents of the Terminal tab showing the problem. It's impossible to diagnose the reason for timeout issues without seeing the communication with the printer.

I am having the same issue. My tevo tornado has been printing fine but the last couple days everytime i connect thru octoprint, it will start heating and the my breaker will trip. But if i preheat it through the printers screen with the preset values, it heats up normally. It will also give me the same communication errors and will not work. I have reflashed octoprint and my tevo tornado firmware several times and cannot get it to work normally.
octoprint (1).log (82.5 KB)

It looks like your firmware took a nap and stopped responding so OctoPrint gave up. Per the log, the firmware suggests that it can do autoreporting of temperature but I see no indication of temps coming back from it; it died before that got initiated, I'd guess.

When I print through SD it now works fine and has with octoprint, but now out of nowhere it quits. Could it be my board? I have the MKS Gen L V1.0. it has gone through alot of power shortages due to the breaker tripping, could it have friend something important with communicating through the USB serial in the process? I have a new board coming in and will give that a try to see if anything changes. It also stays connected to octoprint and will even do movements and send the print, but after a minute it disconnects.

I'm pretty sure that foosel asked for the serial.log. You'd want to turn that feature on in Settings, run your printer until it misbehaves and then to upload that here.

serial.log (19.8 KB)

2019-02-02 01:31:17,690 - No response from printer after 3 consecutive communication timeouts, considering it dead. Configure long running commands or increase communication timeout if that happens regularly on specific commands or long moves.

OctoPrint gave up after not hearing back from the printer.

M104 S250 Is there a reason why you're trying to heat the hotend this much? That's pretty hot.

im printing with petg and after a temp tower test came to the conclusion of using 250, but have bounced around from 250-240

is there a reason why it wouldnt be hearing back from my printer? maybe an issue with the usb interface?

From your log:
Send: M155 S2 <-- Automatic Temperature Monitoring, produce a Temperature Message every 2 seconds.

And then, later when you are heating the nozzle:
2019-02-02 01:30:56,674 - Recv: T:77.81 /250.00 B:80.12 /80.00 @:127 B@:17
2019-02-02 01:30:58,673 - Recv: T:83.17 /250.00 B:80.11 /80.00 @:127 B@:17
2019-02-02 01:31:00,674 - Recv: T:88.05 /250.00 B:80.19 /80.00 @:127 B@:9
2019-02-02 01:31:02,676 - Recv: T:93.94 /250.00 B:80.19 /80.00 @:127 B@:8
2019-02-02 01:31:04,673 - Recv: T:98.97 /250.00 B:80.02 /80.00 @:127 B@:24
2019-02-02 01:31:06,674 - Recv: T:104.14 /250.00 B:80.00 /80.00 @:127 B@:25
2019-02-02 01:31:08,673 - Recv: T:109.08 /250.00 B:79.91 /80.00 @:127 B@:32
2019-02-02 01:31:17,690 - No response from printer after 3 consecutive communication timeouts, considering it dead. Configure long running commands or increase communication timeout if that happens regularly on specific commands or long moves.
2019-02-02 01:31:17,708 - Changing monitoring state from "Operational" to "Offline (Error: Too many consecutive timeouts, printer still connected and alive?)"
2019-02-02 01:31:17,718 - Connection closed, closing down monitor
The messages just stop at 2019-02-02 01:31:08,673, until then they had been coming every 2 seconds as requested. So Octoprint times out, ok. But: If the printer has a display, I would like to know: Was ist still alive and responding to button press, was the display updating temperatures. In other words, was Marlin really hung up or has Marlin just lost the USB connection?

Similar for me... I uses OrangePi Lite. I printed only twice with the setup (I had not enough time to massively experiment with this). The first print (20min - xyzcube) went well. But the second stopped midprint (after ~1.5h). I thought maybe my embedded-computer is too small, but the logs reported that everything in the "server" side went "normal" and the connection failed. I tried to preheat the head to remove it from the print, and I get multiple reconnections in the process (which every time rebooted my ender3, so I just unplugged it, and freezed the idea to print with octoprint for a while).

My cable is a short and simple cable, I would be thrilled if the pi-to-printer interference would be the problem.

So just to summarized the possible solutions here:

  • change the usb cable to a shorter one
  • change the usb cable to a short shielded one (maybe shield your cable manually)
  • look into the board and try to shield inner serial cables
  • look into the board and try to shield everything which can be a communication channel

Which is better, using pi powered mode, or separated VCC mode? (I mean if I breake the usb VCC that will help or make it worst?) Any Ender 3 related tip? The prev. problems are get solved with one of these tips or not?

I have been having usb connection problems for several weeks now. This is an old post I created when the problem started.

Now my CR-10 works fine but my ender 3 fails repeatedly within 10 to 20 mins. I have tried ...

  1. moving the power cord from my garage to the house
  2. adding usb isolator
  3. replacing raspberry pi
  4. replacing raspi power adaptor
  5. replacing raspi power cord
  6. replacing ender 3 usb cable
  7. replacing ender 3 controller with an MKS GEN 1.4
  8. tweaking my marlin firmware.

As you can see there is no hardware left to replace except the ender 3 itself but replacing the controller board is the same thing, right? Since I've replaced 100% of the hardware I'm thinking it is software. Either Marlin or Octopi.

Any suggestions?

I fixed it. I realized there was one thing I hadn't replaced, and that was the SD card. When I replaced the raspi I just moved the card over. I took a fresh SD card and loaded the latest octopi and configured a vanilla octoprint with no plugins. The problem is gone.

I'm guessing one of my many plugins was causing the problem. Unfortunately I don't have the time to try plugins one-by-one to isolate the bad one.

So after two weeks of suspecting hardware I've found that the problem was software.

1 Like

Well, that's why "try it in Safe Mode" is usually the first thing we'll suggest here. It will simply load up OctoPrint without any of the plugins which weren't originally bundled.

It's hard to admit but my problem was a raspi supply too weak, just like many others experienced and suggested. I was using a 1 amp cellphone charger and the one I changed to when testing was also 1 amp. Different things would help because the problem was so sensitive. Removing the plugins helped, I assume because there was less load.

The problem wasn't totally fixed until I switched to a 5V 2.5 amp charger.

Thank you for getting back to us with this piece of information - you won't believe how often it is the power supply, and how rarely people believe us when we point that out. The power management on the Pi is finicky at best, and the beast tends to do hilarious things when browning out due to not getting not enough juice. Biggest source of issues at this point really.