Endstop confusion with Duex5 . How do you map them?

  • Here's my build log so you know what I'm talking about...

    Basically: 2 motors for X, 2 motors for Y and 3 for Z.
    Obviously I can't do that on the Duet2 by itself so I also have a Duex5.

    I started with motor assignments as follows: X3:0 Y1:2 and the X and Y min endstops connected to their respective endstop connectors all on teh Duet2. No issues.

    Once X&Y were tested, I started testing 1 Z leadscrew at a time. For wiring routing purposes, I wanted all 3 Z motors connected to the Duex5 so, I assigned Z5 and plugged the motor into drive 5 (E2) and its endstop into E2_STOP. With this configuration, I could move the leadscrew but pressing the endstop switch did nothing. The LEDs on both the endstop itself and the Duex5 both lit and the web interface showed the E2 endstop being triggered but the motor didn't stop. So I connected the endstop to the Z endstop connector on the Duet2 and correctly stopped the motor. The wiring is VERY inconvenient though.

    On to the next leadscrew. I assigned it motor 6 (E3 on the Duex5) with U6 and plugged its endstop into the E3 endstop connector on the Duex5. Again, I can control the motor and I can see the web interface indicating that the E3 endstop has been hit but it doesn't stop the motor.

    So needing to move on, I ultimately mapped X0:5 Y1:6 Z2:3:4 and plugged the 3 Z endstops into the Z, E0 and E1 endstop connectors. The 2nd X and Y motors don't have associated endstops so they're on the Duex5 and of course, extruders will also have to be on the Duex5.

    I have auto Z motor synchronization working now by using the phantom U and V axes but my wiring is not exactly as I'd like it.

    So the big question is... How do you map the endstops on the Duex5 to axes or motors?

  • administrators

    Mapping motor drivers with M584 does not map the endstop ports. So the Z endstop connection remains the same even if you use M584 to drive the Z motor from an output on the DueX5.

    If you create U and V axes then they will use the E0 and E1 endstop connectors, regardless of which outputs you connected the motors to.

  • @dc42 OK so how do the endstop connectors on the Duex5 get used? I'm guessing that they can be used with triggers but let's say I created a W or A axis, would they roll over to the Duex5?

  • @gtj0 said in Endstop confusion with Duex5 . How do you map them?:


    No doubt DC42 will correct me if I'm wrong but seem to remember that additional axes ought to be created with letters in the order UVWAB and C. I also seem to recall that endstops are by default assigned to axes in that order. So E0 is U, E1 is V then if you create a "W" axis, it will use E2, an "A" axis would use E3 etc. I looked in the Wiki but can't find anything documented about that (but I may not have been looking in the right place).

  • I have created a U axis for my 4th axis (problem in DWC with A axis right now!) and a W dummy axis for squaring the gantry. There is no homing switch for the U axis and the homing switch for the W axis is connected to E1. In conclusion the homing switches are mapped in the order the axis are defined, that is what I can tell so far. I had no situation with unused driver "in the middle", but it sounds it would be a lot safer to just match homing switches with the actually used drivers.

    This discussion just answered my problems when adding a dummy rotation axis without affecting the other mappings. I also considered that the homing switches follow the drivers and not the order that the axis are defined!!!

  • administrators

    Older firmware versions required you to create new axes in the order UVWABC, but firmware 1.21 and later allow you to use any order, and endstop inputs are assigned in the order you create them.

  • As I said "in the order you create them". Wouldn't it be less error prone if the endstops inputs are assigned based on the actually used drivers? Because that was my mistake... I already had axis X, Y, Z and dummy U for slave Y and tried "inserting" W before U in M584 and gantry squaring stopped working!

    I fixed it by swapping completely the mapping for axis U and W while I should have just moved the endstop for axis U! Doesn't come "naturally", really!

