I found something wrong while Z-axis homing.

I found something wrong while Z-axis homing.
You can see normal axis movements after TinyG power-on. Then I try homing in order X Y Z. X and Y goes OK, but when the machine stops immediately after hitting Z-homing switch. The only way to proceed is the RESET button.
My switches are NC, 0V during normal operation (closed state), 3.3 after getting hit (open state).
I checked with multimeter and all is the same for X, Y and Z. But only Z is causing this issue.

How can I debug this? Is it possible to hard reset the TinyG? I already tried factory default and re-flashed firmware (build 440.20, version 0.97, hardware platform 1.00, hardware version 8.00).

Homing worked fine on all XYZ and while searching for X axis loosing steps with @Frank_Herrmann ​ we temporarily disabled Zmax ($zsx) from 1 to 0. After changing $zsx back to 1 (homing only) this problem appeared.
https://youtu.be/0deZsmZaBfg

@sszafran please read this: https://github.com/synthetos/TinyG/wiki/Homing-and-Limits-Setup-and-Troubleshooting maybe this help

One more thing I forgot to mention is that currently TouchPlate widget allows speed 17mm/min or more. It doesn’t move the machine with values <17. And it was OK before disabling Zmax switch.

Thanks @Frank_Herrmann ​, I read this already before connecting TinyG for the first time. I went through most of the wiki documentation. This is strange that it worked fine and one parameter change caused the problem.

@sszafran Do you have soft limits enabled?
If so, are your Zmin and Zmax settings correct?
If soft limits are enabled ($sl=1) AND Z homes, it will set Z=0. If Z=0. is not between Zmin and Zmax, tinyG will freeze as if a limit switch was touched.

@sszafran also to isolate this to TinyG. Can you use coolterm to issue your homing commands. Then see if it still goes into this state? Also what build number are you using? Thanks!

@cmcgrath5035 ​​ The software limits are disabled ($sl=0) and the problem occurs.
@Riley_Porter_ril3y ​​ This is the firmware build I got with the board: 440.20, but I re-flashed it using http://chilipeppr.com to see if that helps (but it didn’t help). I will try coolterm tomorrow, not at home today.

[EDIT] I already tried homing commands from Chilipeppr serial console command line and I still got the problem. Will try other terminal tomorrow.

@Riley_Porter_ril3y The problem is not related to Chilipeppr, but coolterm gives far more detailed output. I created an issue here: https://github.com/synthetos/TinyG/issues/176 and provided link to YouTube recording and also terminal output file. I added also another problem with low value feedrate, which appeared at the same time (after changing $zsx back to 1), so I decided to put it as one issue.

@sszafran I don’t have screw machines, so have to mentally adjust thinking when looking at parameter sets. It does seem a bit odd that Z axis(m3) has the same $tpr as X and Y (4mm) while m4 is provisioned with $tpr=2.1166, which I recognize as same as my ShapeOko spindle(with ACME). Of course m4 is assigned to A axis - is there an active A axis?

@cmcgrath5035 ​ I appreciate all your feedback. The machine is 3040 using exactly the same 4mm/revolution ballscrews on X, Y and Z axis. I don’t use ACME screws here. After tuning parameters (velocity and jerk) machine runs really nice, just I have the mentioned issues with Z homing and low speed feedrate while probing.

@Riley_Porter_ril3y What is the explanation of status codes 28 and 31:
{“er”:{“fb”:440.20,“st”:31,“msg”:“Move time is NAN”}}
{“er”:{“fb”:440.20,“st”:28,“msg”:“Failed to get planner buffer”}}

The above is the output in Coolterm, when problem occurs.

I upgraded TinyG firmware to the newest version today. This is the development version available on the drop-down list after clicking Chilipeppr Programming button. Homing works OK after firmware upgrade. But low speed probing is still freezing the board and RESET is needed. Tomorrow I will try downgrade and see if that helps.
I found few times when using Touch Plate widget first time after RESET that after touching Z=0 the Z-axis returned 3-5 times beeping each time, so resulting clearance height was 6-10mm but reported height was 2mm (clearance height is set to 2mm by default).

Thanks @sszafran I will see what I can replicate the rest of this week / weekend we hear you. We have a new build coming out shortly so we will see what we can do.

The firmware version I have loaded now onto the TinyG v.8 is 442.04 (Experimental).