So the physical build is complete and I wanted to share a couple of

(becker thorne) #1

So the physical build is complete and I wanted to share a couple of pictures of it finished. The table is on wheels (like most things in my garage) and can be dropped down and leveled as required.
I am running into another issue:
When I home the machine (in GRBL Panel), the Z gantry moves up and down (about an inch in both directions), then the the machine moves along the X axis to the right (towards the limit switch), but the Y axis moves to the front (not to the rear, towards the limit switch).
When I invert the homing command (switching from $3=0 to $3=1), the Z gantry cycles all the way down and the lead screw starts to grind against its limits, while the machine continues to move to the left (along the X) and forward (on the Y axis, like before). I usually slap the E-stop at this point to not damage the Z motor or lead screw.
I am sure I am missing something and would love some advice.

(Darrell n) #2

$3 is not the homing invert command. It is $23. It is arranged as a binary number, 00000ZYX. If the Z bit is zero, it homes in one direction, if it is one, it homes in the other direction. You want Z going up during a homing cycle, your Z axis switch should get activated near the top of it’s travel. If it doesn’t hit the switch, it will crash against the end stop.

The X and Y axes work exactly the same way. BTW, I have found that if the Z axis starting position is a negative value, sometimes it will go the wrong way when homing.


(Darrell n) #3

@Hobby_Fab Huh? We are talking about GRBL here, right?

For Direction settings, only the last 3 bits are used… Binary 00000000-00000111, or decimal 0-7.

$3 is the direction bits for machine motion, they must be set so X+ is right, X- is left, Y+ is back, Y- is forward, Z+ is up, Z- is down. You don’t use these bits to set direction for homing, you use $23.

Z axis home is always up, you never home Z to the bottom of it’s travel.


(Darrell n) #4

He clearly said "When I home the machine "… I’d say that indicates a homing problem…


(Jack Daugherty) #5


(Jack Daugherty) #6


(Jack Daugherty) #7

@Jack_Daugherty So $3=2 I believe should be correct.

(Darrell n) #8

@Hobby_Fab I don’t agree. He clearly said twice in his post that this occurred during Homing. My definition of “Homing” is the process that occurs when you hit the Home button on GRBL Panel.

HOMING in the wrong direction is a completely different problem than MOVING in the wrong direction. If the axis moves in the right direction according to the jog controls, ie the Y axis moves back when you hit the Y+ jog button, then the axis is moving in the correct direction, and you DO NOT need to change $3.

If you press the Home button, and the Y Axis moves to the front, when you want it to home positive, (towards the back) reversing the axis travel (Dir Port Invert Mask $3) is definitely NOT the way to fix it. Reversing the Homing Direction Invert Mask bit ($23) is. It works exactly like $3, in terms of one bit per axis.

And if we are bragging, I have built and delivered nearly a hundred custom CNC machines running GRBL. I think I know GRBL pretty well by this point.


(Brandon Satterfield) #9

@Darrell_n I’m always open to learn.
Relating to his previous post you will see that he had a couple of wires crossed on a motor.
His Z homed the correct direction. His X homed the correct direction. His Y did not go the correct direction.
If he changes $23 what would be the result?

(Darrell n) #10


I saw no previous posts in this thread referring to any crossed wires.
There is obviously some confusion here as to what is actually going on. There may be some semantic problems clouding the issue. Interesting to note that the original poster has not offered to clarify anything since his original post.

If this was just a homing issue, which from his description it was, then toggling the $23 Y axis bit would have resulted in Y axis homing in the proper direction, to the rear, which is exactly what he wanted. He did not mention that Y went in anything other than the correct direction when moving it with the jog controls. He specified that it moved in the wrong direction when Homing only. As I said, my definition of “Homing” is pressing the Home button on the Interface screen. If your definition of Homing is something else, I’d be interested to hear it.

If there were a couple of wires reversed on a motor, as you say, then this is a completely different problem and Hobby Fab is correct in recommending changing $3. However, if you change $3, you will also have to change $23 to maintain the correct direction for homing.

Becker Thorne stated “When I invert the homing command (switching from $3=0 to $3=1) the Z gantry…” There are 2 problems with this statement:

  1. Bit 0 is not the control bit for the Z axis, it is for the X axis. I don’t know how this caused his Z axis to reverse direction. The bits in the mask are arranged “00000ZYX”. It is possible he has the motors for the X and Z swapped.
  2. This ($3) is not the Homing direction control, it is the Axis direction control. If the axes are moving in the right direction using the jog buttons, there is no reason to change this value. Don’t get me wrong, inverting a bit in $3 WILL change the homing behaviour, but it will also change the Axis direction when not homing. This is a case of 2 wrongs make a right as far as homing is concerned, but the axis will respond to jog commands (and g-code) in the wrong direction.


(Brandon Satterfield) #11

@Darrell_n I watch all my builders. It’s my job to know where they are at. Agreed there may have been some misplaced labels that has caused confusion, but the guy is just starting.

Hobby-fab being correct… I always really like what that guy says, also hear he’s devilishly handsome.

(Darrell n) #12

@Brandon_Satterfield He may be correct based on some previous thread, I am only going on what I read in this thread. I can’t possibly know anything about other threads on this topic which you guys have previously commented on…

(Michael Forte) #13

Beautiful, clean build! I’m envious of your control box and wiring.

(becker thorne) #14

@Michael_Forte Thanks. I use to build RTUs and large scale SCADA enclosures in a previous life. I love hardware assembly, when the directions are clear ;).

(becker thorne) #15

Sorry for the delayed follow up: its year end at my office and I have a lot of clients asking for last minute design work (graphic design).
Unless I am missing something(s) in the responses so far, it appears some how I have a wrong settings/values in the GRBL code.
I will fire up the CNC tonight and get a screen grab of the present settings and share them here.
Thank you for all your assistance.

(becker thorne) #16

Update: Here is a picture of the current values in the GRBL settings.


(Brandon Satterfield) #17

So your current setting is $3=1
Looking at the chart, also posted by @Jack_Daugherty above
invert X Yes
Invert Y No
Invert Z No.
If X works right and Z works correctly, following the chart, you need a $3 that is yes, yes, no. Which is $3=3.

(becker thorne) #18

@Hobby_Fab I have reviewed the directions (PDF supplied on the product page) and while it is clear on how to change the values, it is also at the same time sparse on the many variables and their resulting actions in the GRBL (like the suggestion of changing the value for $23, from above). I did not find any directions that mention anything other than the “$3=1” command, in that PDF, to change homing direction. I tried this command it did not solve the issue.
If there is a factory reset (so to speak), I would be happy to press it and try again.

(Brandon Satterfield) #19

@becker_thorne this is from the manual.
Happy to reword it now that you better understand what you are trying to do.
“GRBL Settings change:
If an axis such as X, Y, or Z moves in the opposite direction you will need to change the “$3” mapping.

For an understanding of this see the GRBL page: - grbl

Scroll down a bit and you will see a set of numbers “$1” through “$132”, below this is an explanation of what each does.

Related to the example above, if X moves the opposite direction we tell it, we would need to set “$3=1” based on this information:

(Brandon Satterfield) #20

@becker_thorne if you would like to reset everything, sure. Reload GRBL.
How make a change? Type $3=whatever number you need in the bottom of black box you showed earlier where the cursor is blinking. It’s changed.