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

Two questions about gcode

Scheduled Pinned Locked Moved
General Discussion
gcode
3
4
225
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
    Froust
    last edited by 20 Jul 2020, 16:04

    Hi

    Is there any way to get result from the console output, for example i sent M303 and i want to use P.I.D. results in my next gcode, like M301 PID results

    And the second question, can i make use console as a one time input for macros:

    M117 "Enter your diameter in console"

    You entering the diameter, click on Enter and its saving without using M200.

    Thanks

    ? 1 Reply Last reply 22 Jul 2020, 06:09 Reply Quote 0
    • undefined
      Phaedrux Moderator
      last edited by 20 Jul 2020, 20:40

      Yes you can send individual gcodes in the console at pretty much any time and have them take effect until the next power cycle. All config is dont by gcodes. Macros are just lists of gcodes. config.g is a macro too and it just happens to be called at startup.

      Specific to your question on PID, sending M303 H0 S60 would tune the heater, and sending M303 afterwards by itself would report what those results were.

      Sending most gcodes by themselves without a parameter will report back the currently set value.

      See the introduction here https://duet3d.dozuki.com/Wiki/Gcode

      Z-Bot CoreXY Build | Thingiverse Profile

      1 Reply Last reply Reply Quote 1
      • ?
        A Former User @Froust
        last edited by 22 Jul 2020, 06:09

        @Froust said in Two questions about gcode:

        Is there any way to get result from the console output, for example i sent M303 and i want to use P.I.D. results in my next gcode, like M301 PID results

        unless the variables you're after is avaiable in the Object Model then you'll need to parse the console output from some other host with more capabilities.

        but do note that the sample output on the wiki is probably not up to date so you should use M409 to look at the available data in your setup.

        @Froust said in Two questions about gcode:

        And the second question, can i make use console as a one time input for macros:
        M117 "Enter your diameter in console"

        you might be able to make a dummy axis to jog to a specific value? but from the M291 docs it looks like it will only do XYZ but poke around and see what you can do?

        1 Reply Last reply Reply Quote 2
        • undefined
          Froust
          last edited by 22 Jul 2020, 09:13

          I'm noob in programming but i will check it, thank you all.

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