Setting the G54 position

Hi all, this is my first post so here goes:

I have an X-carve 500x500mm, with GRBL version 1.1g.

The procedure I use to do work is:

  1. Switch on the X-carve
  2. Start Lightburn.
  3. Home the X-carve. The home position is at the front-left
  4. When it has finished homing, I select “Get Position”. where it says X= -100 Y= -150 Z= 0
  5. Select “Go to Origin”, and the X-carve moves to 100mm across and 150 back.
  6. Select “Get Position”. It now says X= 0 Y= 0 Z= 0

I’d like to change G54 so that when I home the machine, the origin is either the same, or to be safe a little way back and right, say X=20, Y=20

Cheers
Peter

It homes front-left? That’s unique as far as I know - They XCarve machines I’m familiar with home to the rear-right.

If you type $# in the console and press enter, it’ll show you what your offset values are. For a 500 x 500 machine, the first line should be -500x and -500y. You can set the offset to a specific value by typing G10 L2 P1 X-500 Y-500 and pressing enter (and replace the -500’s with whatever you like). Or, with the laser head wherever you want zero, type G92 X0 Y0 to set that position as 0x 0y.

This is covered in the docs here:

Thanks for your response.

Rather than setting some large numbers into the X-carve, I thought that I’d nibble away at it so that any changes would be small enough so that if it went pair-shaped, I could easily rectify them.

(1) Start X-carve
(2) Start Lightburn
(3) Home the X-carve.
(4) At this point “Get Position” says that the X:-150, Y:-100. [G54:-149.000,-99.000,-1.000]
(5) I select “Go to Origin” and it moves to position 1.
(6) I enter G10 L2 P1 X-80 Y-80. I thought that -80 would be a nice small number to see what happens.
(7) I home the X-carve again. “Get Position” says X:-169, Y:-169. So it has moved further back.
(8) I select “Go to Origin” and it moves to position 2.
(9) As this was an unexpected result, I tried a smaller move of -20: G10 L2 P1 X-20 Y-20
(10) I home the X-carve again. “Get Position” says X:-229, Y:-229.
(11) I select “Go to Origin” and it moves to position 3.
(12) I then try small positive number, instead of -20 I use 20: G10 L2 P1 X20 Y20
(13) I home the X-carve again. “Get Position” says X:-269, Y:-269.

At this point, I dare not experiment any further as I’m running out of space, each time, no matter whether the value I enter is positive or negative, the X-carve origin moves towards the back of the machine.

X-carve origins

You need to have the machine report work position, not machine position for this to work.

Change $10=0 in Console or Machine Settings. Make note of the current value in case you need to revert.

HI,

Thanks for the suggestion, but it’s already set to $10=0

Here’s the settings:

$$
$0=10
$1=255
$2=0
$3=3
$4=0
$5=0
$6=0
$10=0
$11=0.020
$12=0.002
$13=0
$20=0
$21=0
$22=1
$23=3
$24=25.000
$25=750.000
$26=250
$27=1.000
$30=1000
$31=0
$32=1
$100=40.000
$101=40.000
$102=188.976
$110=8000.000
$111=8000.000
$112=500.000
$120=500.000
$121=500.000
$122=50.000
$130=250.000
$131=250.000
$132=100.000
ok

Can you home the machine, run these commands and return the output?

$#
?

I’m on my other computer at the moment, but when I started investigating, at position 1 on the diagram, it was:

$#
[G54:-149.000,-99.000,-1.000]
[G55:0.000,0.000,0.000]
[G56:0.000,0.000,0.000]
[G57:0.000,0.000,0.000]
[G58:0.000,0.000,0.000]
[G59:0.000,0.000,0.000]
[G28:0.000,0.000,0.000]
[G30:0.000,0.000,0.000]
[G92:0.000,0.000,0.000]
[TLO:0.000]
[PRB:0.000,0.000,0.000:0]
ok

When you get a chance please run those 2 commands live. Want to make sure we’re dealing with specific values.

Here you go (sorry for the delay getting back to you):

$#
[G54:20.000,20.000,-1.000]
[G55:0.000,0.000,0.000]
[G56:0.000,0.000,0.000]
[G57:0.000,0.000,0.000]
[G58:0.000,0.000,0.000]
[G59:0.000,0.000,0.000]
[G28:0.000,0.000,0.000]
[G30:0.000,0.000,0.000]
[G92:0.000,0.000,0.000]
[TLO:0.000]
[PRB:0.000,0.000,0.000:0]
ok

?
<Idle|WPos:-269.000,-269.000,0.000|FS:0,0|Pn:P|WCO:20.000,20.000,-1.000>
ok

So, I did some further investigation and I came across a YouTube article by Barton Dring:

Barton Dring - YouTube

His explanation of “Understanding G-code Coordinate Systems” is superb:

I changed my settings from the earlier suggestion of:

G10 L2 P1 Xval Yval

to

G10 L20 P1 Xval Yval, where I eventually set Xval and Yval to 0.

Now, after homing my X-carve, my Origin is the same as the home position:

$#
[G54:-249.000,-249.000,-1.000]
[G55:0.000,0.000,0.000]
[G56:0.000,0.000,0.000]
[G57:0.000,0.000,0.000]
[G58:0.000,0.000,0.000]
[G59:0.000,0.000,0.000]
[G28:0.000,0.000,0.000]
[G30:0.000,0.000,0.000]
[G92:0.000,0.000,0.000]
[TLO:0.000]
[PRB:0.000,0.000,0.000:0]
ok

?
<Idle|WPos:0.000,0.000,0.000|FS:0,0|Pn:P|WCO:-249.000,-249.000,-1.000>
ok

$G
[GC:G1 G54 G17 G21 G90 G94 M5 M9 T0 F6000 S0]

1 Like

Great. Sounds like you’re in business.

Seems to me you likely always had an offset of some amount already set which was throwing off some of the earlier attempts at determining the right values.

The link for the video is a good one. I remember watching that a while back and being impressed with it.

I really appreciate everyon’s help.

Cheers :slight_smile:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.