CNC will only work with nagative coordinates/numbers
-
Hi All,
So I'm new to this and I am probably missing something obvious (so sorry in advance)
My cnc, when homed moves to the bottom left - as per this image
but to move it to the right (X axis) I have to use negative numbers. Same with the Y and Z axis.
Logic tells me this is incorrect, and when working up a simple square using positive numbers my cnc is unable to produce this shape. I can of course manually edit the Gcode to add a "-" in front of everything but that seems a little silly and counterintuitive.
As an example, this square has a start point at the bottom left (as per my cnc) but uses positive numbers to make the shape towards the right-hand side. My cnc can only make this shape if I use negative coordinates rather than positive ones.
Does anyone know how I can fix this?
-
@mattyd You could check your endstop-definition: does it home to 0,0 and is that defined as min? Same for the M208 config.
The Z-axis is a different shoe. Some want to have Z0 at the top, others on bed level... -
@o_lampe said in CNC will only work with nagative coordinates/numbers:
@mattyd You could check your endstop-definition: does it home to 0,0 and is that defined as min? Same for the M208 config.
The Z-axis is a different shoe. Some want to have Z0 at the top, others on bed level...When homed this is what I see via the control panel
No idea why the tool position for X is at 10, but the Machine Position says it's at its max, logically shouldn't that show x:0 y:0 z:0 ?
-
@mattyd I guess it's time to post your config.g
-
; Configuration file for Duet ; executed by the firmware on start-up ; WorkBee Firmware Version 1.1 global systemSettingsVersion={1.2} ; Configuration files M98 P"config-network.g" M98 P"config-drives.g" M98 P"config-axes.g" M98 P"config-axes-limits.g" M98 P"config-axes-calibration.g" M98 P"config-axes-endstops.g" M98 P"config-probe.g" M98 P"config-spindle.g" M98 P"config-laser.g" ; Other Settings M453 ; Put the machine into CNC Modes G90 ; Set absolute coordinates M140 H-1 ; Disable heated bed M564 S1 H1 ; Disable jog commands when not homed M911 S21.0 R23 P"G91 G1 Z3 F1000" ; Configure power loss resume ; User Configuration files M98 P"config-user-settings.g" M501 ; Load Stored Parameters
btw. my "config-user-settings.g" are empty
-
@mattyd said in CNC will only work with nagative coordinates/numbers:
M98 P"config-axes-limits.g"
M98 P"config-axes-endstops.g"These are the files we are interested in. C'mon, work with me...
-
@o_lampe said in CNC will only work with nagative coordinates/numbers:
@mattyd said in CNC will only work with nagative coordinates/numbers:
M98 P"config-axes-limits.g"
M98 P"config-axes-endstops.g"These are the files we are interested in. C'mon, work with me...
Sorry Here you go
config-axes-limits.g
; Axes Limits configuration executed by config.g M208 X0 Y0 Z0 S1 ; Set axis minima M208 X270 Y270 Z88 ; Set axis maxima
and config-axes-endstops.g
; Endstop configuration executed by config.g M574 X2 P"xstop" S1 ; Set active low X endstop M574 Y2 P"ystop" S1 ; Set active low Y endstop M574 Z2 P"zstop" S1 ; Set active low Z endstop
-
i think've figured it out, and it's all user error!
my mistake was assuming that by homing it the "machine position" should be 0 0 0. This is wrong, the "machine position" SHOULD be 270 270 0.
I totally ignored/forgot about the fact that I can set the "work" position to 0 0 0, which when done so moved the machine to the opposite side, and all the negative numbers become positive and Gcode now "seems" to be working as expected.
At least I think that's correct. More experimantaion is needed
-
@mattyd to set X0 Y0 to set the bottom left and positive movement to be correct you should do the following:
- Set the motor directions using the M569 commands in config.g (or in your case, probably in config-drives.g) so that positive X is to the right and positive Y is away from you.
- Change the M574 commands to set the endstops to low-end (e.g. X1) instead of high end (e.g. X2).
- Change your homing files to move in the negative direction instead of the positive direction.
See https://docs.duet3d.com/en/User_manual/Machine_configuration/Configuration_cartesian. I am assuming that your machine is Cartesian, not CoreXY.