Closed ellensp closed 7 months ago
After digging around the code for a few days adding copious debugging statements Iv found the bug.
In Marlin/src/feature/bedlevel/ubl/ubl_motion.cpp
while (cnt) {
This loop never finishes and causes variable to roll over
the variable cnt is of type xy_uint8_t, ie is has a x and a y component
If I change it to
while (cnt.x || cnt.y) {
The while loop completes and G26 finishes as expected and the out of bounds move is eradicated.
I found this was modified in https://github.com/MarlinFirmware/Marlin/pull/15204/files#diff-7324a55a5383deb69d8d9506f87fe29a9046235946fcf89373d774af6144d1e7
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Did you test the latest
bugfix-2.1.x
code?Yes, and the problem still exists.
Bug Description
G26 with SEGMENT_LEVELED_MOVES disabled using UBL results in very long out of bounds moves in X and Y This issue happens on real hardware and simulated
Eg a 200x200 bed, X and Y moves to around 5000mm!
Bug Timeline
Unknown
Expected behavior
G26 should print a test pattern on the bed
Actual behavior
G26 Starts to print the test pattern then X and Y pull a buzz light year, (to infinity and beyond)
Steps to Reproduce
Version of Marlin Firmware
Bugfix-2.1.x
Printer model
Simulated
Electronics
Simulatoed
LCD/Controller
REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER
Other add-ons
FIX_MOUNTED_PROBE
Bed Leveling
UBL Bilinear mesh
Additional information & file uploads
Configuration.zip May be related to