Config Example:
probe:
pin: gpio.34
toolsetter_pin: NO_PIN
check_mode_start: true
Make sure the pin has the right attribute for active high or low. You can verify this by sending the '?' status command.
Basic probing uses a G38.2 command to probe to a switch or electrical contact. You can adjust the active state of the signal with the high/low attribute.
If you set check_mode_start: true it will verify the probe is not touched before the move. If it is you will get an alarm 4
If the probe move completes without activating a probe input it will fail with an alarm 5.
If the probe is successful it will issue a message like this [PRB:151.000,149.000,-137.505:1]
with the machine position at the time of the touch specified. The 1
at the end specifies a successful probe. After touching, the machine will decelerate to a stop. This means the machine location will differ from the location in the message after the probe. It is usually only a tiny amount, but you should account for it. The over travel is proportional to the speed. It could break your bit if the over travel is high or the bit is very fragile.
If the probe fails, it will issue a message like this [PRB:0.000,0.000,0.000:0]
. The 0 at the end indicates a failed probe.
You need to specify move axis parameters and a feedrate.
You can probe towards any point in any or multiple axes at once. Soft limts will be respected. If the command requests a maximum travel that exceeds the range and soft limits are true for the axis, you will get an alarm.
The value in the PRB message is the exact point where the probe activates. The machine will then decelerate to a stop. The machine will no longer be at the probe point even if the probe is going slowly. The best way to set a work zero is to use the G10 L2 Px command with x being the coordinate system. P0 would be the current system. P1 through P6 would be used to specify G54-G59. To set the current work Z to 0 after getting [PRB:151.000,149.000,-137.505:1] send G10 L2 P0 Z-137.505, using the z value from the PRB message. If you have a plate or other offset, just add that to the PRB value.
You can use an optional "P" parameter that specifies the thickness (or offset from 0) of the probe device, like a plate or puck.
Upon successful probe the offset of the current system is zeroed with the P value applied. This will makes it much easier for displays and senders to deal with probing.
Example: G38.2 G91 F80 Z-20 P8.00
This will probe an incremental (G91) amount of -20 in Z. It will set the probe location to 8.00 on the Z axis in the current work coordinate system.
Notes: