Add MKS UI (TFT_LITTLE_VGL_UI) (#18071)
This commit is contained in:
@@ -59,6 +59,12 @@
|
||||
#include "gcode/parser.h"
|
||||
#include "gcode/queue.h"
|
||||
|
||||
#if ENABLED(TFT_LITTLE_VGL_UI)
|
||||
#include "lvgl.h"
|
||||
#include "lcd/extui/lib/mks_ui/inc/tft_lvgl_configuration.h"
|
||||
#include "lcd/extui/lib/mks_ui/inc/draw_ui.h"
|
||||
#endif
|
||||
|
||||
#if ENABLED(DIRECT_STEPPING)
|
||||
#include "feature/direct_stepping.h"
|
||||
#endif
|
||||
@@ -726,6 +732,10 @@ void idle(TERN_(ADVANCED_PAUSE_FEATURE, bool no_stepper_sleep/*=false*/)) {
|
||||
|
||||
// Direct Stepping
|
||||
TERN_(DIRECT_STEPPING, page_manager.write_responses());
|
||||
|
||||
#if ENABLED(TFT_LITTLE_VGL_UI)
|
||||
LV_TASK_HANDLER();
|
||||
#endif
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1141,6 +1151,10 @@ void setup() {
|
||||
SETUP_RUN(page_manager.init());
|
||||
#endif
|
||||
|
||||
#if ENABLED(TFT_LITTLE_VGL_UI)
|
||||
SETUP_RUN(tft_lvgl_init());
|
||||
#endif
|
||||
|
||||
marlin_state = MF_RUNNING;
|
||||
|
||||
SETUP_LOG("setup() completed.");
|
||||
@@ -1173,5 +1187,7 @@ void loop() {
|
||||
|
||||
endstops.event_handler();
|
||||
|
||||
TERN_(TFT_LITTLE_VGL_UI, printer_state_polling());
|
||||
|
||||
} while (ENABLED(__AVR__)); // Loop forever on slower (AVR) boards
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user