Duet3D Logo

    Duet3D

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

    Different configurations based on switch/input setting

    Firmware wishlist
    2
    3
    264
    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.
    • rubillos
      rubillos last edited by

      I’m setting up a printer with multiple tool heads and would like to be able to have connecting a cable change the configuration of the Duet.

      Something like having a command which specifies one ore more input lines (e.g. GPIO 1-3, with pull-up option) which then specify the folder for the system commands (like M505).

      Each tool head’s cable would set the binary values of the specified input lines to different states to indicate which configuration to use. Something like:

      Tool 1 - GPIO1=gnd, GPIO2=gnd, GPIO3=gnd - config is in folder “Config-0”
      Tool 2 - GPIO1=open, GPIO2=gnd, GPIO3=gnd - config is in folder “Config-1”
      Tool 3 - GPIO1=gnd, GPIO2=open, GPIO3=gnd - config is in folder “Config 2”
      etc...

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

        That will be easier to do when I have implemented conditional GCode. But I think it's possible now using firmware 2.03beta. You would need to set up your default configuration in config.g, then at the end of config.g set up M281 triggers for endstop inputs that define the machine configuration. Then M282 commands to poll them, because there won't be any edges. Then in your trigger files, use M505 to set the folder, followed by M98 P"config.g".

        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

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

          @dc42 That sounds like it will do exactly what I want, thanks!

          (Assuming you meant M581 and M582? Those are listed in the current docs; is 2.03beta required, or will they work in the current release build?)

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