Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]: Successful print reported as Cancelled #53

Open
tophe75 opened this issue Oct 25, 2024 · 9 comments
Open

[BUG]: Successful print reported as Cancelled #53

tophe75 opened this issue Oct 25, 2024 · 9 comments

Comments

@tophe75
Copy link

tophe75 commented Oct 25, 2024

Describe the Bug

P1S finish print successfully reported as candled in OctoPrint, Bambu printer reports print successfully finished.

Expected Behavior

Successful finished print should be reported as successful

Debug Logs

2024-10-25 11:31:15,885 - octoprint.server.heartbeat - INFO - Server heartbeat <3
2024-10-25 11:35:06,944 - octoprint.util.comm - INFO - Changing monitoring state from "Printing from SD" to "Cancelling"
2024-10-25 11:35:06,948 - octoprint.printer.standard.job - INFO - Print job cancelled - origin: sdcard, path: Paddle box .3mf, owner: None, user: None, fileposition: 1, position: {'y': None, 'f': None, 't': None, 'x': None, 'e': None, 'z': None}
2024-10-25 11:35:06,965 - octoprint.plugins.bambu_printer.BambuPrinter - INFO - command sent successfully
2024-10-25 11:35:07,022 - octoprint.access.users - INFO - Cleaning up user session 4BC3AF038A8E4B038B31B7A6DE089DBD for user

Screenshots

Capture

Printer and Plugin Setting Details
Bambulab P1S with AMS, default plugin settings

  • Is your printer connected to Bambu Cloud?
    Yes
  • Is the plugin configured for local access only?
    Yes
@jneilliii jneilliii changed the title [BUG]: [BUG]: Successful print reported as Cancelled Oct 25, 2024
@jneilliii
Copy link
Owner

Was the print started from OctoPrint or by sending to printer from slicer? Would be great to get the full log as an attachment, you can just drag it into the comment here on GitHub.

@tophe75
Copy link
Author

tophe75 commented Oct 25, 2024

Was the print started from OctoPrint or by sending to printer from slicer? Would be great to get the full log as an attachment, you can just drag it into the comment here on GitHub.

I sent the print from the slicer (Orca)
Which log are we talking about?
The plugin_bambu_printer_serial.log only has one line:
2024-10-25 10:30:19,912 Not a valid gcode command "MyPassword"

As for the octoprint log, it is not the hole file but everything from befor starting the print until it is done.
octoprint_short.log

@tophe75
Copy link
Author

tophe75 commented Oct 25, 2024

I found some weird stuff in my OctoPrint installation and custom GCODE Scripts that might be the reason for this behavior, I will try a print tomorrow and let you know if I found something.

For some reason the username and the password was typed in some of the fields:
After tool change, After serial connection to printer is established, Before serial connection to printer is closed

But I will do a test and get back.

@jneilliii
Copy link
Owner

jneilliii commented Oct 25, 2024

I was just about to say to make sure you don't have any gcode scripts configured in OctoPrint to start. Also, make sure in OctoPrint's logging section that the octoprint.plugins.bambu_printer entry is configured for debug at the bottom.

@tophe75
Copy link
Author

tophe75 commented Oct 26, 2024

So I just finished a print, still printing from the slicer (Orca), I get no Print Started nor Print Finished

What I am trying to achieve is for the plugin to get Print Started, Print Finished, Print Paused, Print Canceled, etc and then by using the WLED Connections plugin set status light.

New log file:
plugin_bambu_printer_serial.log

@tophe75
Copy link
Author

tophe75 commented Oct 26, 2024

Update
Starting a print from the printers SD card (not using the slicer or OctoPrint) resulted in a 'Start' flag picked up by OctoPrint using the plugin and also the WLED plugin turned the lights on.

Still getting Cancel when the print finishes
image

plugin_bambu_printer_serial.log

@markwal
Copy link

markwal commented Nov 15, 2024

If you start a print from OctoPrint and it sees "Not SD Printing", it will assume that the print was cancelled. From the plugin code, I can conjecture a couple of ways this could happen:

  • It looks like updating the status will say "Not SD Printing" if the interval timer goes off before the status message comes through and sets print_job.
  • It looks like it may also be possible for "Not SD Printing" to already be in the queue ready to go out when the start print gcode (M24) is sent.

We could introduce some mechanism where after an M24 is processed we pretend there's a print_job for some time interval so that we don't answer incorrectly while waiting for the next MQTT. For the queue's passing each other, I'm not sure. Dumping the outgoing queue when M24 is received might be too late because OctoPrint may already have read the queue before the virtual printer processes the M24.

@jneilliii
Copy link
Owner

wow, @markwal, blast from the past. didn't even know you were still around. always open for suggestions, but I think in this case it may have been related to detecting the start of the print. I have made several tweaks to the current rc branch and relevant rc releases that will probably help drastically in this issue.

@jneilliii
Copy link
Owner

also, as mentioned on the other issue #52

If the file name does not match the project name saved in the 3mf file the print won't get detected as printing when started from printer panel or cloud. This seems to happen probably with 3mf files downloaded directly from printables/makerworld or ones that have been saved locally.

so basically this:
image
needs to match this:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants