refactor serial follow up (some reboot fix)#20938
refactor serial follow up (some reboot fix)#20938GMagician wants to merge 1 commit intoMarlinFirmware:bugfix-2.0.xfrom GMagician:prevent-divide-by-0
Conversation
|
It would be good to take a look in the serial methods code before the recent changes, as before we had no issues. |
|
The problem described above was present previously but it never triggered. In the new serial code, I've merged all I'm not fond of the fix here, since it changes the behavior of the print code to pass the issue, but it'll break elsewhere where |
|
If you don't mind, I'll use your fix in my kill all serial bugs PR here: #20932, so you can close this one. |
It's ok to mee |
|
Can you try the pushed fix in #20932 to see if it works ? |
No it doesn't, it prints G29 T with chars and not with numbers |
|
@X-Ryl669 I think that Marlin needs chars as signed otherwise when doing: SERIAL_ECHO(' ') and SERIAL_ECHO(i) (with i as uint8_t) should always print a letter and that's not what should do. |
|
My error here. |
|
Wait...there are some parts in marlin that send uint8_t and needs a single byte... Things turn out to be harder |
|
We'll continue discussion in the PR's thread, if you don't mind. |
Yep, Better |
Fix a divide by 0 issue that may cause boards reboot