Duet3D Logo

    Duet3D

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Documentation
    • Order

    Solved Questions regarding various job time

    Gcode meta commands
    3
    8
    58
    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.
    • modl
      modl last edited by

      Hi everyone
      I have a few questions I couldn't find an answer for in the different documentations and changelogs.

      1. Does job.pauseDuration account for time that passed while the machine was off after a pause. e.g. if i pause my print, wait for 1mn , shut down the printer for 1 minute, then switch the printer back on and resume the print, will job.pauseDuration report 60 or 120 ?

      2. Is there a way to store the start date and time of a print using a macro, as a global variable, at the beginning of a print for later access and operations in other macros ?

      3. Does job.timesLeft.file use simulation mode? Will it take into account pause times determined by a macro ?

      Thank you in advance

      Best

      chrishamm dc42 2 Replies Last reply Reply Quote 0
      • chrishamm
        chrishamm administrators @modl last edited by

        @modl

        1. I think pauseDuration only counts the time the machine is in paused state (pausing/paused/resuming). Making it also count the off time is quite hard because the time is probably unset when the machine comes back online, although I suppose you could save the current datetime when the machine encounters a power loss event. Then you could work it out yourself.

        2. You can calculate that AFAIK because you can substract a number of seconds from state.time.

        3. I think job.timesLeft.file just computes the ETA just by checking how quickly the current print file is being processed. No macro times are taken into account there.

        Duet software engineer

        1 Reply Last reply Reply Quote 0
        • dc42
          dc42 administrators @modl last edited by dc42

          @modl said in Questions regarding various job time:

          Does job.pauseDuration account for time that passed while the machine was off after a pause. e.g. if i pause my print, wait for 1mn , shut down the printer for 1 minute, then switch the printer back on and resume the print, will job.pauseDuration report 60 or 120 ?

          If you shut down the printer and later resume the print, the calculated print finish time based on filament extruded will be wrong, because the amount already extruded isn't saved anywhere. Also job.pauseDuration won't account for any pauses done before the job was restarted, because the pause time (and heating time) are not saved..

          @modl said in Questions regarding various job time:

          Is there a way to store the start date and time of a print using a macro, as a global variable, at the beginning of a print for later access and operations in other macros ?

          You could set a global variable to the current start date/time in start.g.

          @modl said in Questions regarding various job time:

          Does job.timesLeft.file use simulation mode? Will it take into account pause times determined by a macro ?

          No, it works on the proportion of the file that has been printed and the current rate at which the file is being consumed.

          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

          1 Reply Last reply Reply Quote 0
          • modl
            modl last edited by

            Thank you both for your answers I'll work with this in mind for now.

            @dc42 if i set a start date time in the start macro , will it be persistent after machine is powered off, or there is a powerfailure ?

            modl 1 Reply Last reply Reply Quote 0
            • modl
              modl @modl last edited by modl

              i think I have my answer after some testing: no, global variables are not persistent when there is a power failure or emergency cut off. Anyway this can be done ? Like written to a single file using echo and read later ? Can i read strings from another file inside a macro ?

              dc42 1 Reply Last reply Reply Quote 0
              • dc42
                dc42 administrators @modl last edited by dc42

                @modl said in Questions regarding various job time:

                Anyway this can be done ? Like written to a single file using echo and read later ?

                Yes, you can echo a command to a file to set a global variable.

                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

                modl 1 Reply Last reply Reply Quote 0
                • modl
                  modl @dc42 last edited by

                  @dc42 Thank you very much it works, I had to reread the Documentation to remember to use two double quotes to add a double quote to a string, to set globals in a datetime format.

                  dc42 1 Reply Last reply Reply Quote 1
                  • dc42
                    dc42 administrators @modl last edited by

                    @modl I'm glad you got it working. I'll mark this as solved, but you can revert it if you need to.

                    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

                    1 Reply Last reply Reply Quote 0
                    • Topic has been marked as a question  dc42 dc42 
                    • Topic has been marked as solved  dc42 dc42 
                    • First post
                      Last post
                    Unless otherwise noted, all forum content is licensed under CC-BY-SA