From 4d4e692c8159d26713ebff7bf67b2344c74758ef Mon Sep 17 00:00:00 2001 From: InsanityAutomation <38436470+InsanityAutomation@users.noreply.github.com> Date: Wed, 20 Nov 2019 00:16:43 -0500 Subject: [PATCH] Match onMeshUpdate() index sign (#15920) --- Marlin/src/gcode/bedlevel/abl/G29.cpp | 2 +- Marlin/src/lcd/extensible_ui/lib/lulzbot/marlin_events.cpp | 2 +- Marlin/src/lcd/extensible_ui/ui_api.h | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Marlin/src/gcode/bedlevel/abl/G29.cpp b/Marlin/src/gcode/bedlevel/abl/G29.cpp index c17150f79..448d0d00e 100644 --- a/Marlin/src/gcode/bedlevel/abl/G29.cpp +++ b/Marlin/src/gcode/bedlevel/abl/G29.cpp @@ -678,7 +678,7 @@ G29_TYPE GcodeSuite::G29() { measured_z = 0; - xy_uint8_t meshCount; + xy_int8_t meshCount; // Outer loop is X with PROBE_Y_FIRST enabled // Outer loop is Y with PROBE_Y_FIRST disabled diff --git a/Marlin/src/lcd/extensible_ui/lib/lulzbot/marlin_events.cpp b/Marlin/src/lcd/extensible_ui/lib/lulzbot/marlin_events.cpp index 23b37854e..8bb2477ec 100644 --- a/Marlin/src/lcd/extensible_ui/lib/lulzbot/marlin_events.cpp +++ b/Marlin/src/lcd/extensible_ui/lib/lulzbot/marlin_events.cpp @@ -127,7 +127,7 @@ namespace ExtUI { } #if HAS_LEVELING && HAS_MESH - void onMeshUpdate(const uint8_t, const uint8_t, const float) { + void onMeshUpdate(const int8_t, const int8_t, const float) { } #endif } diff --git a/Marlin/src/lcd/extensible_ui/ui_api.h b/Marlin/src/lcd/extensible_ui/ui_api.h index d92918394..6f852cdd8 100644 --- a/Marlin/src/lcd/extensible_ui/ui_api.h +++ b/Marlin/src/lcd/extensible_ui/ui_api.h @@ -138,7 +138,8 @@ namespace ExtUI { float getMeshPoint(const xy_uint8_t &pos); void setMeshPoint(const xy_uint8_t &pos, const float zval); void onMeshUpdate(const uint8_t xpos, const uint8_t ypos, const float zval); - inline void onMeshUpdate(const xy_uint8_t &pos, const float zval) { onMeshUpdate(pos.x, pos.y, zval); } + inline void onMeshUpdate(const int8_t xpos, const int8_t ypos, const float zval) { onMeshUpdate((uint8_t)xpos, (uint8_t)ypos, zval); } + inline void onMeshUpdate(const xy_int8_t &pos, const float zval) { onMeshUpdate(pos.x, pos.y, zval); } #endif #endif