Strange homing behavior in all betas.
-
I noticed a strange behavior while homing, and I checked it through the last several revisions.
When I call to home the X and Y axis, each will move the unintended axis by an amount. For instance:
; homex.g
; called to home the X axis
;
G91 ; relative positioning
G1 H2 X5 Y5 F10000 ; move X away a little so the switch is not pressed
G1 H2 Z3 F2000 ; lift Z 3mm
G1 H1 X-400 F8000 ; move left 400mm, stopping at the endstop
G1 H2 X15 F8000 ; move away for second pass
G4 P500 ; wait 500msec
G1 H1 X-300 F300 ; (second pass)
G1 H2 X5 F8000 ; move away from end
G1 H2 Z-3 F2000 ; lower Z
G90 ; back to absolute positioningG4 P100 ; wait 400ms
This will result in the following action...
Notice that the Y axis has shifted on the move away ( line 8 ) yet it was NOT directed to do so, and repeats the unwanted Y axis movement again at the end. This behavior also occurs similarly on the X axis when the Y axis is homed.
; homey.g
; called to home the y axis
;
G91 ; use relative positioning
G1 H2 X5 Y5 F10000 ; ensure gantry is clear
G1 H2 Z3 F2000 ; lift Z 3mm
G1 H1 Y400 F5000 ; move to the front 400mm, stopping at the endstop
G1 H2 X0 Y15 F5000 ; move away for second pass
G4 P500 ; wait 500msec
G1 H1 Y400 F300 ; (second pass)
G1 H2 Y5 F8000 ; move away from end
G1 H2 Z-3 F2000 ; lower Z
G90 ; back to absolute positioning
G4 P100 ; wait 400msThis results in the following:
Am I neglecting to give some instruction to the axis NOT being homed somehow?
-
@Nuramori said in Strange homing behavior in all betas.:
G1 H2 X5 Y5 F10000 ; move X away a little so the switch is not pressed
That line moves Y by 5mm as well as X
-
Correct, but that's the initial move to set up. there's the other moves that are limited to only a specific axis, but the other axis is also moving.
G1 H2 X15 F8000 ; move away for second pass
this results in an Y axis movementIn the first video, the action at 0:05 is represented by line 7. watch right after there's a shift on the OTHER axis.
-
Ignore my previous reply. It's because your machine is a CoreXY and G1 H2 moves are raw motor moves. So G1 H2 X moves only the X motor, which moves both X and Y axes. A G1 H2 Xaa Yaa move will move just the X axis, and a G1 H2 Xaa Y-aa move will move just the Y axis, assuming your kinematics is standard CoreXY and you haven't altered the motion matrix.
-
@dc42 Thanks. I got it now. I was making it more complicated than necessary.
Now it works as expected with :
; homex.g
; called to home the X axis
;
G91 ; relative positioning
G1 H2 X5 Y5 F10000 ; move X away a little so the switch is not pressed
G1 H2 Z3 F2000 ; lift Z 3mm
G1 H1 X-400 F8000 ; move left 400mm, stopping at the endstop
G1 X5 F8000 ; move away for second pass
G4 P500 ; wait 500msec
G1 H3 X-300 F300 ; (second pass)
G1 X15 F8000 ; move away from end
G1 H2 Z-3 F2000 ; lower Z
G90 ; back to absolute positioning
G4 P100 ; wait 400ms -
@Nuramori, did you mean to have a G1 H3 command?