• Tags
  • Documentation
  • Order
  • Register
  • Login
Duet3D Logo Duet3D
  • Tags
  • Documentation
  • Order
  • Register
  • Login

Error Handling Mechanism

Scheduled Pinned Locked Moved Solved
Tuning and tweaking
3
7
347
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • undefined
    justus2342
    last edited by justus2342 30 Nov 2022, 10:18

    (Yes, I have seen this topic. But it does not answer my question.)

    I would like to pause print automatically in case of a problem. That problem could be a failing G29 or a accidental violation of the axis limits during the print. Because those problems are very likely indicators for a failing print and (in case of failed G29) might result in hardware damage, if the nozzle crashes into the print bed.

    I worked around a failing G29 with using G32 instead and use a if-metacommand to pause if G29 returns an error. But that is a workaround which does not work, if G29 is called.

    I am looking for a general error handling method. Maybe a gcode-file that is called in case of a warning or another gcode-file in case of error.

    Is there any system-wide error handling mechanism? Or is there any common workaround to catch errors in general?

    Tevo Little Monster (Duet2, Smart Effector, lin Rails, Magb. Arms)
    Anycubic Delta Linear Plus (Duet2, Smart Effector, Magb. Arms)
    Two Trees Sapphire Pro (MKS Robin, Marlin 2.x, D. Extruder)

    undefined undefined 2 Replies Last reply 30 Nov 2022, 12:52 Reply Quote 0
    • undefined justus2342 marked this topic as a question 30 Nov 2022, 12:32
    • undefined
      droftarts administrators @justus2342
      last edited by droftarts 30 Nov 2022, 12:52

      @justus2342 This might be what you are looking for https://docs.duet3d.com/User_manual/RepRapFirmware/Events
      Have a read of that page, and let us know if you have any questions.

      Edit: you can make the logic conditional using Meta/Conditional Gcode. See https://docs.duet3d.com/User_manual/Reference/Gcode_meta_commands

      Ian

      Bed-slinger - Mini5+ WiFi/1LC | RRP Fisher v1 - D2 WiFi | Polargraph - D2 WiFi | TronXY X5S - 6HC/Roto | CNC router - 6HC | Tractus3D T1250 - D2 Eth

      undefined 1 Reply Last reply 30 Nov 2022, 12:58 Reply Quote 0
      • undefined
        justus2342 @droftarts
        last edited by justus2342 30 Nov 2022, 12:58

        @droftarts Thank you for your reply. Yes, I already found that part of the docs. It says:

        An event is one of the following:

        • Heater fault
        • Filament error
        • Driver stall
        • Driver error (e.g. over temperature shutdown, short-to-ground, or closed loop driver error failure to achieve the requested position)
        • Driver warning (e.g. over temperature warning, or phase disconnected)

        Other event types may be added in future, for example MCU over-temperature on a main board or expansion board, or over- and under-voltage.

        But this is handling of just those five specific error-types, not errors in general. Or have I misses/misunderstood something? Especially the both cases I mentioned (move outside axis boundaries and G29 error) seem not be to covered.

        Tevo Little Monster (Duet2, Smart Effector, lin Rails, Magb. Arms)
        Anycubic Delta Linear Plus (Duet2, Smart Effector, Magb. Arms)
        Two Trees Sapphire Pro (MKS Robin, Marlin 2.x, D. Extruder)

        1 Reply Last reply Reply Quote 0
        • undefined
          dc42 administrators @justus2342
          last edited by 30 Nov 2022, 13:13

          @justus2342 said in Error Handling Mechanism:

          I worked around a failing G29 with using G32 instead and use a if-metacommand to pause if G29 returns an error. But that is a workaround which does not work, if G29 is called.

          G29 calls mesh.g if it exists, and if it does not then behaves like G29 S0. So you can create a mesh.g file like this:

          G29 S0 ; probe the bed
          if result > 0
          abort "Bed probing failed"

          Please test this on your machine before relying on it.

          G0/1/2/3 out-of-reachable-area errors abort the job if the machine is in CNC or laser mode. In FDM mode they do not, instead they limit the coordinates to the accessible area, because it is not unusual for parts of the skirt to fall just outside the printable region.

          Duet WiFi hardware designer and firmware engineer
          Please do not ask me for Duet support via PM or email, use the forum
          http://www.escher3d.com, https://miscsolutions.wordpress.com

          undefined 1 Reply Last reply 30 Nov 2022, 13:24 Reply Quote 0
          • undefined
            justus2342 @dc42
            last edited by justus2342 30 Nov 2022, 13:24

            @dc42 said in Error Handling Mechanism:

            G29 calls mesh.g if it exists, and if it does not then behaves like G29 S0. So you can create a mesh.g file like this:

            That looks really promising! Thank you very much! I did not know about that.

            @dc42 said in Error Handling Mechanism:

            G0/1/2/3 out-of-reachable-area errors abort the job if the machine is in CNC or laser mode. In FDM mode they do not [...] because it is not unusual for parts of the skirt to fall just outside the printable region.

            I see your point, but I would like to catch those errors anyway. At least to throw a warning. Is there any chance?

            Maybe the object model can tell me something about the boundaries of the object to be printed? If so, I could check if parts of the print are beyond the printable area before the print starts in start.g

            Tevo Little Monster (Duet2, Smart Effector, lin Rails, Magb. Arms)
            Anycubic Delta Linear Plus (Duet2, Smart Effector, Magb. Arms)
            Two Trees Sapphire Pro (MKS Robin, Marlin 2.x, D. Extruder)

            undefined 1 Reply Last reply 30 Nov 2022, 21:02 Reply Quote 0
            • undefined
              dc42 administrators @justus2342
              last edited by 30 Nov 2022, 21:02

              @justus2342 said in Error Handling Mechanism:

              Maybe the object model can tell me something about the boundaries of the object to be printed? If so, I could check if parts of the print are beyond the printable area before the print starts in start.g

              The OM doesn't know about the boundaries of the object you are about to print when it calls start.g. However, some slicers can put the print object boundaries into GCode commands in your start GCode, so you could check there. See https://forum.duet3d.com/topic/29576/only-probe-where-the-part-will-be-printed to get some ideas.

              Duet WiFi hardware designer and firmware engineer
              Please do not ask me for Duet support via PM or email, use the forum
              http://www.escher3d.com, https://miscsolutions.wordpress.com

              undefined 1 Reply Last reply 1 Dec 2022, 08:14 Reply Quote 0
              • undefined
                justus2342 @dc42
                last edited by 1 Dec 2022, 08:14

                @dc42 Thank you. That is a nice starting point, but I do not like it as error catching mechanism. When I use my usual slicer, the print bed size should be set correctly and I expect no problems. But when the gcode comes from somewhere else – for instance I experiment with some other slicing software – that is where I would like to have those errors caught.

                However. As far as I understand, RRF cannot help me at the moment. Thus I will close this thread as solved and write something in the Firmware Wishlist section.

                Tevo Little Monster (Duet2, Smart Effector, lin Rails, Magb. Arms)
                Anycubic Delta Linear Plus (Duet2, Smart Effector, Magb. Arms)
                Two Trees Sapphire Pro (MKS Robin, Marlin 2.x, D. Extruder)

                1 Reply Last reply Reply Quote 0
                • undefined justus2342 has marked this topic as solved 1 Dec 2022, 08:14
                6 out of 7
                • First post
                  6/7
                  Last post
                Unless otherwise noted, all forum content is licensed under CC-BY-SA