Odd gcode movement

Maybe I’m missing something but I’m trying Ryan’s video for easy square.

I am running the code in bits first to find my absolute dimensions and make sure it’s all setup right. I know I have other issues but this is perplexing me and it could just be my misunderstanding of how the gcode runs.

When I run these line by line
G28
G00 X30 Y30 F1800
M0 Attach probe
G38.2 Z0
G92 Z0.5
G1 Z5 F900

I noted on the second to last line didn’t touch the surface (another issue I’m working on)

So I tried to run G1 Z-7 F900 and the machine went up again instead of back down. It wasn’t hitting anything it just went opposite of where I wanted.

It’s perplexing me because I’ve seen this randomly but now I can replicate it every time I try this.

If I run up on repetitive it goes up, same for all the other directions it works as expected unless I send a second gcode statement sometimes.

My question is that wrong or how it’s supposed to work?

It’s M83 and I’m a dumbass someone confirm please lol

Okay… I read this:

G28 ; Home all axes of the machine
G00 X30 Y30 F1800 ; Go to the coordinates X30 Y30 from current location at a speed of 1800mm/min in a non-print move
M0 Attach Probe ; Pause and wait for a continue. Display the message "Attach Probe" on the LCD.
G38.2 Z0 ; Probe towards Z=0 uintil the probe is triggered, and stop
G92 Z0.5 ; Assign the current machine position to the Z value of 0.5
G1 Z5 F900 ; Go to the Z position of 5mm, presumably upwards by 4.5mm, given the previous command.

Things that might mess this up…

A G91 command will put everything in relative mode. The G00 X30 Y30 command will still seem to work, immediately after homing, but the probe command will not, and the Z coordinate could be funky. you can fix this with a G90 code at the start if this is an issue. G90 (absolute mode) is safer in any event, and should be a part of your startup code, but it is usually included by default with most CAM

M83 isn’t really a thing for the LowRider, because it specifically deals with the extruder, putting the extruder in relative mode if you have specified absolute mode coordinates.

Try adding G90 to that early on., probably after the G28. Something in your homing sequence may be putting the machine in relative mode (This is often used for the back-off and re-touching the homing switch) and maybe it isn’t being put back.

So I would siggest:

G28
G90
G0 X30 Y390 F1800
M0 Attach Probe
G38.2 Z0 
M400
G92 Z0.5
G0 Z5 F900

Changes:
Insert extra G90 to define absolute coordinate mode
Add M400 (probably unnecessary) command to ensure that we wait for movement to stop
Change lift Z command from G1 to G0 as a non-print or rapid movement.

Further possible modification: Change G38.2 command to G38.2 Z-80 so that the probe will be more guaranteed as an adequate downward movement.

2 Likes

That’s amazing as soon as it’s not frigid in the garage today I’m sneaking away from work to test this out, thank you!! The G90 is probably going to fix a lot of my “problems”, also some good reading on GCode in general.