-
-
Notifications
You must be signed in to change notification settings - Fork 19.3k
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] M81 not working while printing from SD card #23517
Comments
PS_OFF_CONFIRM when printing from sdcard? |
This shouldn't be the case PS_OFF_CONFIRM is only used in MarlinUI for screen buttons, not on the gcode execution itself. I'll check again. |
I tested another end code
the important bit is waiting for hotend temp with and this works ! so this has something to do with POWER_OFF_WAIT_FOR_COOLDOWN while the job is running |
@mistic100 are you using a suicide pin to power off? |
No, I use the PSU control pin to trigger BTT relay |
There's an omission in the power.cpp code, suicide() is not called when cooldown or delayed power off is selected. But since this isn't the case for you, I'm trying to figure out what might be the issue. When you print with M81 S, does the menu show "Switch power ON" immediately after the end of print, or after cooldown temp has been reached? |
I don't know, each time I wasn't there (sleeping :-) ). I'll make a quick test gcode and report. |
no need, best way is to heat your hotend partially (up to 60°C) and send an M81 S. Make sure to see if the menu changes to "Switch power ON" before the hotend temp drops below 50°C. Also, remember to issue an M80 before you begin, and make sure the menu reads "Switch power OFF" |
I am not perfectly sure but here is what I think I saw : Power off from menu :
Power off from "M81 S" :
|
So, M81 S works? A small delay (1-2sec) is normal. Also, the info screen message is issued immediately with the command, so that's also normal. |
Yes that's what I said in my first message :) the command itself works, just not during a print.
Yes but I noticed a difference in when the menu item changes, might be important. |
Do you have a serial (USB?) connection with the printer? I can give you a build that sends debug output to the serial to see what's going on. |
I have a ESP-01S running ESP3D connected on the serial port, I can also connect Pronterface. If you want I could compile the debug build myself, keeping all my config, just tell me what flags to change. |
gimme 5' |
Hmmm quick update I runned this test code, basically my start gcode + end gcode
And it powered off as expected... Perhaps don't spend more time on the subject, I will try to have a real reproductible scenario. |
Still, try this branch, I've added some serial logging to see what happens with power after M81 is issued. |
Only power.cpp and M80-M81.cpp are changed. |
In what conditions do you want I test ? Just sending "M81 S" over serial after heating up ? |
sending
here is the result
|
All of this is very weird. Currently starting another long print. I'll keep in touch. Perhaps I am just dumb ! |
This is the correct test and expected behavior. Now let's see how it works when issued after a print. |
Today printing from SD card (and switched to Pronterface because yesterday the ESP-01S crashed mid-print...)
And the screen is not showing any prompt, it is on the info screen with the last notification : "31m 27s" Anyway if I push the control button once, the screen stays on the info screen and :
So this has nothing to do with the power off feature but with |
Shouldn't there be a timeout on this prompt like there seems to be the line bellow for edit: now that I think of it, perhaps the whole issue is my ESP-01S ? it is detected like an host.... it would also explain why it crashed yesterday, might not handle the prompt very well. Anyway I will compile without |
Ok, so M81 is ok - there is an issue with suicide() not invoked, I'll open a new pull request for fixing that - so we can close this issue. |
@zeleps may suggest some optimizations :
|
@mistic100 I haven't used I must say though, that a compile time warning is not a good idea: imho, warnings should be about issues that are detected during compile time and can be rectified by changing things in the code. Warning the user about optional actions that may conflict with each other is not really something to show during compilation. This could be something to mention in the gcode reference documentation. |
(idk, I'm just a contributor, I'm not pulling any strings around here) |
To be fair I read all the compilation warnings I got, but I didn't read the documentation from top to bottom (well M81 is short, I could have seen it :-)) Thank you for your time nonetheless |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Did you test the latest
bugfix-2.0.x
code?Yes, and the problem still exists.
Bug Description
I try to have the printer shuts down automatically at the end of the print (from SD card). So I inserted "M81 S" at the very end of my file.
I investigated a bit into M80_M81.cpp and power.cpp but couldn't understand this behavior. Is the firmware preventing to shut downs while the print job is still running ?
Bug Timeline
No response
Expected behavior
The printer should wait to reach 50° on the nozzle then trigger the power supply pin.
Actual behavior
The printer does not shut downs. The menus show "Switch Power ON", indicating the command was somehow acknowledged but it it is still on.
Powerring off from the menu or by sending the command on serial works.
Steps to Reproduce
No response
Version of Marlin Firmware
bugfix-2.0.x 2021-01-08
Printer model
Creality Ender 3
Electronics
BTT SKR Mini E3 3.0
Add-ons
BTT Relay 1.2
Bed Leveling
No response
Your Slicer
Cura
Host Software
No response
Additional information & file uploads
I am running exactly this version of Marlin https://github.com/mistic100/Marlin/tree/custom
this is the bugfix branch from 2021-01-08 + BTT changes for SKR Mini E3 3.0 + my rencent PR #23476 + custom settings
relevant config :
The text was updated successfully, but these errors were encountered: