🚸 G42 P as flag (not bool)

This commit is contained in:
Scott Lahteine 2024-07-26 02:40:35 -05:00
parent 78e111a4d0
commit ad60cdd030

View file

@ -37,7 +37,7 @@
* F<feedrate> : Feedrate in mm/min
* I<index> : X axis point index
* J<index> : Y axis point index
* P<bool> : Flag to put the prove at the given point
* P : Flag to put the probe at the given point
*/
void GcodeSuite::G42() {
if (MOTION_CONDITIONS) {
@ -58,7 +58,7 @@ void GcodeSuite::G42() {
if (hasJ) destination.y = bedlevel.get_mesh_y(iy);
#if HAS_PROBE_XY_OFFSET
if (parser.boolval('P')) {
if (parser.seen_test('P')) {
if (hasI) destination.x -= probe.offset_xy.x;
if (hasJ) destination.y -= probe.offset_xy.y;
}