Giter VIP home page Giter VIP logo

Comments (4)

Desuuuu avatar Desuuuu commented on September 12, 2024

The thing is, the touchscreen doesn't really cancel the print, it simply asks the host (OctoPrint, ...) to cancel it.

It makes more sense to me to let the host send the DGUS_PRINT_END considering that.

For OctoPrint, it is as simple as adding a GCode script for After print job is cancelled in the settings with the right command.

from klipper.

ReXT3D avatar ReXT3D commented on September 12, 2024

A good workaround. I suggested the above because I am a big fan of avoiding "distributed features". Ideally it would be great if DGUS_PRINT_START and DGUS_PRINT_END were not required at all. Again, pardon my ignorance if I am completely out to lunch due to lack of knowledge of the implementation (I do not understand the exact reason for why the start and end commands are required).

For example, when using Marlin, the moment a print starts the print screen appears on the LCD without any special commands being issued from the host. With Klipper on the other hand the print screen does not appear until after bed and extruder heating completes. This is with DGUS_PRINT_START being the first line in the start GCODE in Cura.

from klipper.

Desuuuu avatar Desuuuu commented on September 12, 2024

Marlin (in the case of using serial) does some guess work to know the print status (using the print counter IIRC, which starts when heating up).

It's integrated in the core of Marlin so that ui modules simply get notified when the print status changes, regardless if you're printing over serial or directly from the SD card (and it's pretty reliable).

With Klipper by default you can get a rudimentary status based on whether there are commands coming in. It's not particularly reliable (it doesn't play well with pauses for example).

While you could implement the same logic as in Marlin and get a somewhat reliable status, it's still pretty complicated to handle every case properly. Considering the fact that the user already had to setup the host to work with Klipper, I don't think it's a lot of extra work to add two commands to the start/end scripts and this has the advantage of being 100% reliable.

With Klipper on the other hand the print screen does not appear until after bed and extruder heating completes. This is with DGUS_PRINT_START being the first line in the start GCODE in Cura.

That's simply because Cura puts your start script after heating is done (this makes sense if you're adding a wipe line for example).

Add the command to the Before print job starts script in OctoPrint and you'll get the behaviour you want.

from klipper.

ReXT3D avatar ReXT3D commented on September 12, 2024

Thank you - I appreciate your explanation of the Marlin auto-detection and differences in Klipper. I would have not been able to dig into the code to search for this due to time limitations.

My comments about avoiding distributed features stem from lots of experience in architectural design of complex aerospace systems, not software design specifically.

I think this can now be closed, thank you!

from klipper.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.