Cura-OctoPrintPlugin icon indicating copy to clipboard operation
Cura-OctoPrintPlugin copied to clipboard

Plugin gets stuck on "Waiting for Octoprint to connect to the printer".

Open aidenmitchell opened this issue 4 years ago • 27 comments

Octoprint does successfully connect, but Cura gets stuck on "Waiting for Octoprint to connect to the printer".

aidenmitchell avatar Mar 20 '20 19:03 aidenmitchell

Please provide as much information as you can, or I won't be able to tell what is going on.

I guess you use some sort of smart plug or another way to turn on your printer. Which one, and which OctoPrint plugin do you use to control it?

I guess you have your printer turned off (but OctoPrint up and running) before send the print to OctoPrint from inside Cura. Does the printer turn on? After being turned on, does OctoPrint automatically connect to the printer?

When the "Waiting for OctoPrint to connect to the printer" message is shown, does the button to "queue" the print work to upload the print?

What OS do you run Cura on? What version of Cura do you use?

fieldOfView avatar Mar 20 '20 20:03 fieldOfView

Yes, I use a smart plug, it’s a Wemo plug. Plugin: https://github.com/jneilliii/OctoPrint-WemoSwitch

The switch is turned on and Octoprint does connect automatically.

The queue button does upload the print but doesn’t start it.

Cura runs on my Windows 10 machine, version 4.5.

aidenmitchell avatar Mar 20 '20 20:03 aidenmitchell

Can you post a link to your cura.log? It can be found through Help -> Show configuration folder. It is also helpful to have the octoprint.log from the OctoPrint side of things. You can download that via OctoPrint Settings ->OctoPrint -> Logging

fieldOfView avatar Mar 20 '20 20:03 fieldOfView

I don't have a Wemo plug, so I can not test the interoperability between the plugin for that plug and Cura. Let's hope your logs tell me something.

fieldOfView avatar Mar 20 '20 20:03 fieldOfView

Thanks for the logs. Unfortunately, they don't show a lot of detail.

The switch is turned on and Octoprint does connect automatically.

Can you clarify this? Was the switch turned on before you tried to send the print from Cura to OctoPrint? Or was the switch turned on by Cura (via OctoPrint) as you started sending the print from Cura?

If the switch was already on before you hit the button on Cura, I might have been thinking about the issue wrong, and it is probably a duplicate of #136, where Cura is somehow no longer updating the state of the OctoPrint instance. If that happens, Cura could think the printer is not connected even though it is, and it will try to turn on the wemo switch and wait endlessly until the printer gets connected.

fieldOfView avatar Mar 27 '20 08:03 fieldOfView

Cura turned the switch on via Octoprint. On Mar 27, 2020, 1:24 AM -0700, Aldo Hoeben [email protected], wrote:

Thanks for the logs. Unfortunately, they don't show a lot of detail.

The switch is turned on and Octoprint does connect automatically. Can you clarify this? Was the switch turned on before you tried to send the print from Cura to OctoPrint? Or was the switch turned on by Cura (via OctoPrint) as you started sending the print from Cura? If the switch was already on before you hit the button on Cura, I might have been thinking about the issue wrong, and it is probably a duplicate of #136, where Cura is somehow no longer updating the state of the OctoPrint instance. If that happens, Cura could think the printer is not connected even though it is, and it will try to turn on the wemo switch and wait endlessly until the printer gets connected. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

aidenmitchell avatar Mar 27 '20 16:03 aidenmitchell

Sorry to keep asking for clarification, but I'm still trying to find out what does and what does not work.

  • The smart-switch was turned off, and the printer was not "operational" in OctoPrint (because it was off)
  • You sliced a file and pressed the "Print with OctoPrint" button
  • The printer turned on
  • The "Waiting for OctoPrint to connect to the printer" dialog showed in Cura and did not go away

Am I correct sofar?

Was the printer "operational" (connected and ready) in the OctoPrint web interface or was it not?

fieldOfView avatar Mar 27 '20 16:03 fieldOfView

No problem. You are correct so far. The printer was operational in Octoprint.

aidenmitchell avatar Mar 27 '20 17:03 aidenmitchell

Thanks. This is a mystery to me. Did it happen just once, or is it reproducible?

fieldOfView avatar Mar 27 '20 17:03 fieldOfView

I tried multiple times. On Mar 27, 2020, 10:32 AM -0700, Aldo Hoeben [email protected], wrote:

Thanks. This is a mystery to me. Did it happen just once, or is it reproducible? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

aidenmitchell avatar Mar 27 '20 17:03 aidenmitchell

And what happened?

fieldOfView avatar Mar 27 '20 17:03 fieldOfView

Same thing, the printer turns on and Octoprint connects, but Cura gets stuck on "Waiting for Octoprint to connect to the printer".

aidenmitchell avatar Mar 27 '20 20:03 aidenmitchell

I am getting the same issue. Running on the latest master branch. It is weird as the system worked fine before... Suddenly have this issue. I use PSU controll with the PI turning on a relais that I made. Printer turns on fine and connects. Then cura gets stuck at connecting. Like said, this worked in previous versions. Even with the printer turned on and connected the cura instance gets stuck on connecting. Sometimes after restarting cura the issue is gone though. Makes it hard to trace. https://pastebin.com/592m1CfR

7kasper avatar Jun 08 '20 18:06 7kasper

@7kasper please elaborate a little. Is your printer turned on and connected before you try to send the printjob to OctoPrint, or do you let Cura turn on the printer?

fieldOfView avatar Jun 10 '20 05:06 fieldOfView

I was searching Google for an answer and found this post.

I have the exact same setup as the original poster: OctoPrint with Wemo & PortListener plugins (so the printer powers on, OctoPrint connects) Cura correctly powers on the Wemo, and I can see OctoPrint connect, but Cura remains in "waiting for Octoprint to connect".

(while writing this comment, I thought to check for updates in the Marketplace...) After updating OctoPrint Connection to v3.5.14 I can no longer reproduce the issue...! It does exactly as previous versions of OctoPrint w. Cura... when issuing "Print with OctoPrint" Cura powers on the Wemo switch, waits for OctoPrint to connect, then starts printing.

I think 3.5.14 fixed the the issue! :)


OctoPrint version : 1.4.0 OctoPi version : 0.17.0 Wemo Switch plugin version : 0.1.5 PortListener plugin version : 0.1.10

Cura version : 4.6.1 OctoPrint Connection version : 3.5.14

alaorath avatar Jun 13 '20 17:06 alaorath

@7kasper please elaborate a little. Is your printer turned on and connected before you try to send the printjob to OctoPrint, or do you let Cura turn on the printer?

I have tried both and it failed in both instances. In all cases where the printer was off before, it did turn on and autoconnect did connect but cura bang on connecting to printer. The weird thing is.. I have had exactly the issue described but like said after 2 restarts of Cura (not octoprint) it suddenly worked and hasn't stopped working since. Both on printer off start and printer already on start.

7kasper avatar Jun 14 '20 00:06 7kasper

I'm starting to think that this issue (too) is a duplicate of https://github.com/fieldOfView/Cura-OctoPrintPlugin/issues/136, where Cura stops seeing changes in the updates it requests from OctoPrint.

fieldOfView avatar Jun 14 '20 07:06 fieldOfView

Hello,

I also have this issue. However I do not use a smart plug.

Printer : Sidewinder X1 v4 (Powered ON Always) Hardware : Rasperry Pi 4B rev 1.2 OS : Octopi 0.17.0 Octoprint : 1.4.2 Octoprint Connection : 3.5.17 (Cura Plugin)

When in Cura printer settings, I can connect to my printer via OctoPrint. When trying to print I can successfully send to queue, and then manually print via OctoPrint I can upload from my desktop to OctoPrint and manually print without issues.

When I try to print from Cura it gets stuck with the message "waiting for Octoprint to connect to the printer."

  • I have tried to perform the print while Octoprint was connected to the printer.
  • I have tried to perform the print while Octoprint was NOT connected to the printer. (so that Cura can ask it to connect)
  • I have tried changing the setting which says "Connect to printer before sending printjob," then re-running the two tests above.
  • I performed each of these 4 tests after a power cycle of my Raspberry pi and my X1 printer.

UPDATE: 9/18/2020

I found an issue with Sidewinder X1 devices. If you have the power switched to the off position and plug in the Raspberry Pi B4 the USB cable will partially power the device. the X1 will not be able to operate but you will be able to work through the menus. I have re-run my 2 tests to find the same results (stuck waiting) but ensured that the printer was on an operational prior to plugging in the Ocoprint (Raspberry Pi) server.

Wpnx330 avatar Sep 17 '20 22:09 Wpnx330

I have a similar issue.

I am using Ender 3 v2 printer with octoprint on macosx catalina.

I am using cura 4.8 with octoprint connection plugin (latest version) and wemo switch plugin.

When my printer connection is offline and powered down; with the help of octoprint connection plugin and wemo switch i could power up my printer but serial connection is not working.

Error: State: Offline (Error: SerialException: 'read failed: device reports readiness to read but returned no data (device disconnected or multiple access on port?)' @ comm.py:_readline:2916)

When i close cura i can connect to my printer from octoprint web console easily.

I could not connect it from octoprint connection plugin if it is disconnected from octoprint web console.

Edit: If i use another computer for cura it is working. I guess i could not connect octoprint from cura if i use the same computer for octoprint server. No problem i resolved the issue right now.

akiltopu avatar Nov 11 '20 21:11 akiltopu

Having the same issue here. Cura 4.8 + Catalina.

alexose avatar Jan 04 '21 22:01 alexose

Works after downgrading to Cura 4.6.2.

alexose avatar Jan 04 '21 22:01 alexose

I'm a bit late to the game but I'm also having this issue. I have an Ender 5+ that takes about 15 seconds to load after power on. The Cura plugin turns on the printer via PSU control plugin and then tries to connect right away. No connection is made because the printer isn't initialized and Octoprint is not connected to the printer, so the Cura plugin gets stuck trying to connect and never completes.

psiess avatar Feb 26 '21 19:02 psiess

Had the same problem. Fixed it by diconnecting and connecting under "manage printers" -> octoprint, wait for key validation -> disconnect -> wait for key validation again -> connect.

mw75 avatar Mar 02 '21 19:03 mw75

Hi, adding my 2p to this.

My setup: Ender 3 V2 TPLink KP105 Plug Octoprint 1.6.1 Cura 4.9.1

What i have noticed is: 1. settings:

  • auto connect off
  • auto disconnect off socket off printer connected Cura does not try and turn the socket on. Printer gets a SerialException: device reports readiness to read but returned no data error.

settings:

  • auto connect on 10s
  • auto dissconnect on 0s socket off printer dissconnected Cura will turn the printer on and everything behaves as expected.

My preference would be to have the status remain as operational. Could this plugin check the status of the plug and act on that regardless of what state the printer is in? Im assuming it might be checking if the printer is operational and skipping the plug action.

hobbit44 avatar Jun 14 '21 16:06 hobbit44

I have had the same issue, restart of Cura helped.

petr7555 avatar Aug 04 '21 19:08 petr7555

I have had the same issue, restart of Cura helped.

Same. I just had to restart Cura.

looolz avatar Jan 26 '23 18:01 looolz