mirror of
https://github.com/MarlinFirmware/Marlin.git
synced 2024-11-28 22:35:21 +00:00
Fix Anycubic I3 Mega (S) original screen % display (#19210)
This commit is contained in:
parent
0c85e2838c
commit
2212bf85b7
@ -28,6 +28,7 @@
|
|||||||
#include "../../../../inc/MarlinConfig.h"
|
#include "../../../../inc/MarlinConfig.h"
|
||||||
#include "../../ui_api.h"
|
#include "../../ui_api.h"
|
||||||
#include "../../../../MarlinCore.h" // for quickstop_stepper and disable_steppers
|
#include "../../../../MarlinCore.h" // for quickstop_stepper and disable_steppers
|
||||||
|
#include "../../../../module/motion.h" // for A20 read printing speed feedrate_percentage
|
||||||
|
|
||||||
// command sending macro's with debugging capability
|
// command sending macro's with debugging capability
|
||||||
#define SEND_PGM(x) send_P(PSTR(x))
|
#define SEND_PGM(x) send_P(PSTR(x))
|
||||||
@ -412,6 +413,7 @@ void AnycubicTFTClass::RenderCurrentFileList() {
|
|||||||
uint16_t selectedNumber = 0;
|
uint16_t selectedNumber = 0;
|
||||||
SelectedDirectory[0] = 0;
|
SelectedDirectory[0] = 0;
|
||||||
SelectedFile[0] = 0;
|
SelectedFile[0] = 0;
|
||||||
|
ExtUI::FileList currentFileList;
|
||||||
|
|
||||||
SENDLINE_PGM("FN "); // Filelist start
|
SENDLINE_PGM("FN "); // Filelist start
|
||||||
|
|
||||||
@ -427,7 +429,7 @@ void AnycubicTFTClass::RenderCurrentFileList() {
|
|||||||
|
|
||||||
if (SpecialMenu)
|
if (SpecialMenu)
|
||||||
RenderSpecialMenu(selectedNumber);
|
RenderSpecialMenu(selectedNumber);
|
||||||
else
|
else if (selectedNumber <= currentFileList.count())
|
||||||
RenderCurrentFolder(selectedNumber);
|
RenderCurrentFolder(selectedNumber);
|
||||||
}
|
}
|
||||||
SENDLINE_PGM("END"); // Filelist stop
|
SENDLINE_PGM("END"); // Filelist stop
|
||||||
@ -804,7 +806,6 @@ void AnycubicTFTClass::GetCommandFromTFT() {
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 20: { // A20 read printing speed
|
case 20: { // A20 read printing speed
|
||||||
int16_t feedrate_percentage = 100;
|
|
||||||
|
|
||||||
if (CodeSeen('S'))
|
if (CodeSeen('S'))
|
||||||
feedrate_percentage = constrain(CodeValue(), 40, 999);
|
feedrate_percentage = constrain(CodeValue(), 40, 999);
|
||||||
|
Loading…
Reference in New Issue
Block a user