Do you think it will be better idea to disable Z axis for testing using the code below:
here’s how to do it. You’ll see two lines in the config.h file like so:
#define HOMING_CYCLE_0 (1<<Z_AXIS) // REQUIRED: First move Z to clear workspace.
#define HOMING_CYCLE_1 ((1<<X_AXIS)|(1<<Y_AXIS)) // OPTIONAL: Then move X,Y at the same time.
Change these two lines to look like:
#define HOMING_CYCLE_0 (1<<X_AXIS)
#define HOMING_CYCLE_1 (1<<Y_AXIS)
That’s it! Re-compile and re-flash Grbl via the uploading procedure outlined in the Grbl Wiki.