Probes are used to find the surface of the work piece. Most commonly this on the Z axis, but FluidNC supports doing it with any axis. The probe circuit is an input to FluidNC, similar to a limit switch. The most common method uses the electrical conductivity of the bit and a metal plate or puck of known thickness on the material to complete a circuit. You could also use any kind of circuit that opens or closes on contact.
FluidNC will move the probe towards the surface. When contact is detected FluidNC will output the location on the serial port and other connected channels. It will then decelerate to a stop to prevent any loss of steps that might occur due to an immediate stop. If you supply the P paramater, FluidNC will zero the axis using the offset provided.
Multipoint surface leveling is not supported by the firmware. A simple GCode version would have too many parameters to make this practical. A much better solution is to have a GUI prompt you for all the grid parameters. Many gcode senders support this. They then alter the streaming gcode to fit the material profile. FluidNC supports this method.
Config Example:
probe:
pin: gpio.34
toolsetter_pin: NO_PIN
check_mode_start: true
hard_stop: false
Make sure the pin has the right attribute for active high or low. You can verify this by sending the '?' status command. You should not see the a "P" in the status response in the Pn: section. If you see the P invert the active state.
Next, manually activate the probe by triggering the switch, completing the circuit or whatever is needed to activate it. While in the active state you should see the P in the Pn: section when you send the ? command.
Until you pass a manual test, you should not attempt a real probe action.
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:
Probe is not in the expected initial state before starting probe cycle when trying to probe. You cannot start a probe cycle if the probe is already active. See the setup section above.