Unfortunately this is not an issue where I simply configured the motor direction wrongly (printer been working fine for years, I just recently switched my Z probe). Instead I have the following:
When I start my printer and home all the axes except for Z, then use G30 to home Z, it works perfectly fine.
But when instead of G30 I first do a fast homing of the Z-axis by executing the following code:
G1 H1 Z-600 F300 ; fast homing
G1 Z2 ; move away a bit
G30 ; final slow homing
... the bed moves in the wrong direction when G30 is executed. Instead of moving up towards the nozzle, it slowly moves down 10-20mm and then rapidly further down and reports probe was not triggered. Immediately after that it executes a second probing where the directions are then correct (up slowly, down quickly), however due to the distance between probe and bed by then, it also reports that probe was not triggered.
My Z-Probe, which is an Euclid type probe with a MSW (hence a relatively high trigger height), is configured as follows:
M574 Z1 S2
M558 A5 S0.03 P5 C"^io2.in" H1.5 F80 T10000 ; set Z probe type to unmodulated and the dive height + speeds
G31 P500 X-15 Y5 Z17.0
Interestingly when I change the trigger height from Z17.0 to Z1, everything works fine.
I would say that this is a bug in the firmware (I have 3.4 installed) as the trigger height value might be unusually high but let me know your opinion.
Any workaround if this is a bug?