Additional limit switches (Over and above XYZ homing switches)



  • Hi.
    To incorporate limit switches at other end of bed from homing, I have wired in series additional micro switches (wired NC obviously). Do I connect to limit switch point E0? How do I configure in config g file? Is it similar to the XYZ switches where I define S1 for NC in M574 or do I need to do something else.
    Trevor



  • So you want to have both X_MIN and X_MAX switches? Since RRF doesn't care which switch it is, putting them in series (NC) should work fine, as it will trigger no matter which switch opens, and RRF will just figure it out based on which direction you are moving the print head.

    For this, I don't think that any changes in config.g would be needed, but you could home the printer in either direction. unless you want to do something like have 2 Z home switches for separate motors.



  • @trev133 Please check this one as it is exactly what I have done. The only difference is that I have dual Y-axis. You must have a look especially over the homing files as they change the switch "mode" between "critical error" to "homing helper", as needed.



  • Thanks Guys for getting back. I have it wired XYZ for homing each on a separate limit switch and circuit and connected to duet accordingly. For the limit at other end of bed I have the 3 axis wired in series. Do I just plug this in to the next vacant end stop point and configure NC.



  • Take a look here: https://forum.duet3d.com/topic/8459/m581-external-trigger

    This is to use an additional endstop input to handle exception cases, which your non-homing endstop triggers would be. This would be axis independent, so it would be active regardless of what axis/direction the tool is moving.

    Edit: I have something similar set up, though currently disconnected. I had intended to use it for Z axis baby stepping up/down using a pair of endstop triggers and some spare 22mm arcade buttons that I had lying around. I made a small box to house the buttons with a 3 wire connector.



  • Hi Guys. Thanks for the input but perhaps it’s my inexperience with the duet controller. I’m still not sure from the various articles where I plug in the wires in series for the limit switches. Is it into the next vacant output on the board? XYZ being used for homing. Sorry for being a pain.



  • @trev133 said in Additional limit switches (Over and above XYZ homing switches):

    Hi Guys. Thanks for the input but perhaps it’s my inexperience with the duet controller. I’m still not sure from the various articles where I plug in the wires in series for the limit switches. Is it into the next vacant output on the board? XYZ being used for homing. Sorry for being a pain.

    Yes pretty much. Assuming you want these switch to do something like an emergency stop if triggered (that's what I do BTW) then you use M581 to detect the trigger and act accordingly. In my case I have an emergency stop button (NC switch) connect to E4 and the limit switches wired in series and connected to E5. So in my config.g I have:

    ; Emergency stops
    M581 E4 S1 T0 C0 ; E4 is emergency stop button, S1 = rising edge, T0 is emergency stop like M112, C0 means any time
    M581 E5 S1 T0 C0 ; E5 is axes limits



  • @deckingman That’s brilliant, Thank You.



  • Hi guy's just one more point. When I go into config. g there is no line item equating to M581. Do I just add this line with relevant factors and is there any precedence where it should be placed in the file?
    Thanks again



  • @trev133 said in Additional limit switches (Over and above XYZ homing switches):

    Hi guy's just one more point. When I go into config. g there is no line item equating to M581. Do I just add this line with relevant factors and is there any precedence where it should be placed in the file?
    Thanks again

    Yes, just add the line and it can go pretty much anywhere in the file. I have my M581 lines at the end of my config.g just because they are sort of "extra commands" so I know where to find them if I need to edit them.

    What happens when you turn on the machine is that the config-g file is read and commands are carried out in sequence from the start of the file so it generally doesn't matter what order they are in. The exceptions to this rule are things like like axis mapping and micro-stepping in conjunction with steps per mm but that's not important for what you need to do here.

    The configuration files, including config.g and macros etc are simple text files so you can use any text editor to modify them. I use notepad++ which is free.

    HTH



  • Ian that’s good info. Thank you
    Trevor



  • @deckingman said in Additional limit switches (Over and above XYZ homing switches):

    Yes pretty much. Assuming you want these switch to do something like an emergency stop if triggered (that's what I do BTW) then you use M581 to detect the trigger and act accordingly. In my case I have an emergency stop button (NC switch) connect to E4 and the limit switches wired in series and connected to E5. So in my config.g I have:
    ; Emergency stops
    M581 E4 S1 T0 C0 ; E4 is emergency stop button, S1 = rising edge, T0 is emergency stop like M112, C0 means any time
    M581 E5 S1 T0 C0 ; E5 is axes limits

    Just about to configure Endstops in config. g as advised. Just checking: I have NC switches connected to point E0 on Duet.
    Do I code it M581 E0 S1 T0 C0 or is it M581 E4 S1 T0 C0



  • @trev133 You need to configure the end stop that you have physically connect the wires to. So if the wires are physically connected to E0 then use M581 E0 etc. The available connections on the Duet main board are Z, Y X , E0 and E1. https://duet3d.dozuki.com/Wiki/Duet_Wiring_Diagrams . End stops E2 to E6 are on the Duex5 expansion board (which I happen to use).



  • Thanks Ian. That’s what I thought. Trevor



  • Just configured it. Works a treat Ian. Thanks for all your help. Really appreciated. Trevor


 

Looks like your connection to Duet3D was lost, please wait while we try to reconnect.