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

    M471 with Relative Directory?

    Scheduled Pinned Locked Moved
    General Discussion
    3
    7
    333
    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.
    • DonStaufferundefined
      DonStauffer
      last edited by

      Is there a way I can avoid specifying the entire path on M471 if the directory is in the same directory as the macro file I'm running?

      o_lampeundefined dc42undefined 2 Replies Last reply Reply Quote 0
      • o_lampeundefined
        o_lampe @DonStauffer
        last edited by

        @donstauffer
        with a little luck you can use "./ or ../", where ./ is the current directory and ../ is the parent directory.

        DonStaufferundefined 2 Replies Last reply Reply Quote 0
        • DonStaufferundefined
          DonStauffer @o_lampe
          last edited by

          @o_lampe I tried that.

          1 Reply Last reply Reply Quote 0
          • DonStaufferundefined
            DonStauffer @o_lampe
            last edited by

            @o_lampe

            Error: Failed to rename file or directory ./Test1 to ./Test3

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

              RRF has no concept of a "current directory", that's why you need the path. However, I could change it so that you don't need to provide the path in the new name if it is the same as in the old name.

              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

              DonStaufferundefined 2 Replies Last reply Reply Quote 0
              • DonStaufferundefined
                DonStauffer @dc42
                last edited by DonStauffer

                @dc42 That would be convenient, but wouldn't solve my current challenge. I'm trying to put a macro in a directory which may have been renamed, and have the macro rename a subdirectory. The macro doesn't know if the directory it's in has been renamed. It only knows about subdirectories and what it wants to do about them.

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

                  @dc42 It would be convenient to be able to run a macro using M98 with only a filename and have it assume it's in the same folder as the macro invoking M98. That is, a system of macros in a single folder could all call one another with just their filenames.

                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post
                  Unless otherwise noted, all forum content is licensed under CC-BY-SA