3 Z Axis stall current



  • I'm struggling a bit to sort out stall current detection for end stops on a 3 stepper Z axis used on my coreXY. I have had to abandon physical switches due to 'design' constraints (nowhere sensible to mount them on the frame and I refuse to add them to the bed harness)

    I did use this

    M584 X0.0 Y0.1 Z0.2:0.3:0.4 E0.5 P3                   ; set drive mapping
    
    M574 Z1 S1 P"!io2.in":P"!io3.in":P"!io4.in"           ; configure active-low endstop for low frame position on Z via pin !io2 / !io3.in !/ io4.in
    

    but stall current detection uses M574 Z1 S4 ...

    What comes after S4 to make sure the device knows there are three steppers.

    My process to rough adjust Z is to drive the bed assembly all the way to the bottom of the frame - furthest point from the nozzle. I need each motor to stall out and this will synchronise the steppers to within a few steps of each other. They are mechanically restricted and can go no lower, this position is also where the bed was mechanically levelled.

    I only execute this movement if I have disturbed something in the Z assembly or something untoward happened i.e. hot end crash into the bed or cat attack.


  • Moderator

    Stall detection with multiple Z motors will be nearly impossible.

    If all you want to do is bottom out the Z axis on each motor to a physical stop, just do exactly that with the motor current set very low.



  • I can do that since they are physical stops but will the printer stop trying to drive the Z axis or just keep pounding until it thinks is has 'gone the distance' ?- I don't want to unnecessarily stress things - just want the motors to stop - call it mechanical sympathy.

    The docs seem to imply that each motor stops when stall is detected - but it isn't clear how it knows there are three of them - unless this is derived from M584 - since end stops must be explicitly defined


  • Moderator

    The duet will drive the motor for the entire distance you specify, however, once the motor stalls it won't have any torque to produce movement, so it won't be a problem. Just be sure to set the current low enough that a stall is guaranteed.


  • Moderator

    And yes, if you were using stall detection as an endstop, once one motor stalls it would stop all motors assigned to that axis, just like an endstop switch.

    That's why people split the Z axis into multiple axis for homing in these situations. You could do that too, but your Z axis would have to have enough compliance in the system to allow for some independent movement.

    Since all you seem to want to do is bottom out the Z axis to a physical stop to level it allowing the motors to simply stall against the physical stop would sufficient. Prusa does similar with their printer by sending the X gantry into the top of the frame until both motors stall out.



  • My bed assembly is on a Maxwell coupling based support so I've a lot of freedom. Z axis levelling using steppers and joints that are rigidly bolted to the bed is impossible - just causes binding - ask me how I know (went down this route before I figured out all the implications - enthusiasm trumped understanding).


Log in to reply