Gantry ¨Out of Limit¨ travel during independent axes homing
-
Greetings,
I am building a custom 3D Printer. During axes homing tryouts observed that the there is ¨Out of Limit¨travel of Z axis during the following sequence,
Sequence 1 - Home Z Axis : The gantry moved to Z axis home position and the respective end stopper were activated. When tried to move further, not able to move.
Sequence 2 - Executed the Home X, which contains the movement in Z direction (up and down).Even though the Z axis was in home already with the endstoppers activated. Home
X, made the gantry travel out of Z defined axis limit.Is there any kind of interlock provision possible to avoid this kind of issue?
Or should I modify the program?
Home Z macro
G91 ; relative positioning
G1 H2 Z10 F6000 ; lift Z relative to current position
G1 H1 Z550 F1800 ; move Z up until the endstop is triggered
G92 Z0 ; set Z position to axis maximumHome X macro
G91 ; relative positioning
G1 H2 Z10 F6000 ; lift Z relative to current position
G1 H1 X-500 F1800 ; move quickly to X axis endstop and stop there (first pass)
G1 H2 X5 F6000 ; go back a few mm
G1 H1 X-500 F360 ; move slowly to X axis endstop once more (second pass)
G1 H2 Z-10 F6000 ; lower Z again
G90 ; absolute positioning -
@SANJR How have you configured the endstops? Please post all, or at least that part, of your config.g.
You are homing the Z to its maximum position, ie at the maximum end of the Z axis. It looks like this is at around Z=540. But then you set this to Z0 with G92. So the Z is at the maximum, but is also at 0. Any positive move will try and move it past the endstop, and any negative movement will try and take it below zero. So realistically, it can't move!
Check how the Z endstop is set. It should be something like:
M574 Z2 S1 P"io3.in"
Note the
Z2
in the M574 command, which sets the Z endstop to a maximum endstop, rather than a minimum. Then change your homez.g to something like:G91 ; relative positioning G1 H2 Z10 F6000 ; lift Z relative to current position G1 H1 Z550 F1800 ; move Z up until the endstop is triggered G92 Z540 ; set Z position to axis maximum <-- adjust this later to be accurate G1 H2 Z-20 F6000 ; <-- this moves Z away from the endstop G90 ; absolute positioning
However, I think you have a Z probe? Why move the axis all the way to the end of the Z axis, when you can home Z using the probe with G30?
Ian
-
@droftarts Hi
I understand that in the Home Z macro file after the Z axis moves to maximum 540 the gantry is again moved down by 20 mm. This way we can ensure that even when the Home X is called at the Z maximum position we could ensure the Z axis does not travel out of the limits. This is a good idea.
But when the sensors are activated at the Z max postion (the home position). further movements should not be allowed to happen, allowing which may happen to travel this kind of out of limit travel.
Is this kind of normal (or) any interlock commands to prevent the movement?
My endstop config.g files are as follows
; Endstops
M574 X1 S1 P"!1.io0.in"
M574 Y1 S1 P"!1.io1.in+!1.io2.in"
M574 Z2 S1 P"!io0.in+!io1.in+!io2.in+!io3.in" -
@SANJR The endstop provides the position at one end of the axis. M208 provides the 'soft' limits within which the axis can move. Don't set M208 to be more than the range the axis can move, or it can crash. Usually, this is enough, but may not be for bigger machines that can damage themselves if they move too far.
Endstops are only active when called on, with a G1 H1/3/4 move. For all other moves they are ignored. However, this means that you can set them up as a trigger when not being used as endstops, so that if they are hit, they can cause a pause (or whatever other function your require) to be triggered. You can set them up as triggers in config.g, then in your homing macros you unassign them as triggers, assign them as endstops, home the axis, unassign them as endstops, and reassign them as triggers. You can also add limit switches on the other end of the axis to do the same thing.
Ian
-
Thanks for the quick reply
Is it possible by finetuning the macro files to control the movement like anyone of the two options
Option1 : by changing the positioning method from relative to absolute, does the system know it is already in the Z max position? preventing the ¨out of limit travel¨
Modify the Home X file
G90 ; <-- absolute positioning (previously was G91 relative positioning)
G1 H2 Z10 F6000 ; lift Z relative to current position
G1 H1 X-500 F1800 ; move quickly to X axis endstop and stop there (first pass)
G1 H2 X5 F6000 ; go back a few mm
G1 H1 X-500 F360 ; move slowly to X axis endstop once more (second pass)
G1 H2 Z-10 F6000 ; lower Z again
G90 ; absolute positioningOption 2 : removing the Z axis movement in the home x and home y macros
By removing the G1 HZ movement commands only the respective axes will be moved. can this be done? does it affect anyother functionality? -
@SANJR said in Gantry ¨Out of Limit¨ travel during independent axes homing:
Option1 : by changing the positioning method from relative to absolute, does the system know it is already in the Z max position? preventing the ¨out of limit travel¨
Yes, the actual position is always known, and the M208 limits respected, in absolute and relative mode. Makes sure you don't have an M564 S0 (see https://docs.duet3d.com/en/User_manual/Reference/Gcodes#m564-limit-axes) lurking anywhere, which will allow the axes to move beyond the M208 limits.
Option 2 : removing the Z axis movement in the home x and home y macros
Yes, you can do that too. If the Z axis position isn't known, then it's probably safer to NOT move the Z axis on a bigger machine. However, you do run the risk of dragging the nozzle across the bed.
Ian
-
@droftarts Thanks
I will do tryout on both conditions and select the most suitable one.