Thread and Timer converted to class (#81)
This commit is contained in:
committed by
GitHub
parent
85e26636a3
commit
854fefa1a1
@@ -12,7 +12,7 @@ bool m5stack_lvgl_init() {
|
||||
static lv_display_t* display = nullptr;
|
||||
|
||||
const lvgl_port_cfg_t lvgl_cfg = {
|
||||
.task_priority = tt::ThreadPriorityHigh,
|
||||
.task_priority = tt::Thread::PriorityHigh,
|
||||
.task_stack = 8096,
|
||||
.task_affinity = -1, // core pinning
|
||||
.task_max_sleep_ms = 500,
|
||||
|
||||
@@ -104,9 +104,9 @@ lv_disp_t* ws3t_display_create() {
|
||||
lvgl_mux = xSemaphoreCreateRecursiveMutex();
|
||||
tt_assert(lvgl_mux);
|
||||
|
||||
tt::Thread* thread = tt::thread_alloc_ex("display_task", 8192, &display_task, nullptr);
|
||||
tt::thread_set_priority(thread, tt::ThreadPriorityHigh); // TODO: try out THREAD_PRIORITY_RENDER
|
||||
tt::thread_start(thread);
|
||||
tt::Thread* thread = new tt::Thread("display_task", 8192, &display_task, nullptr);
|
||||
thread->setPriority(tt::Thread::PriorityHigh); // TODO: try out THREAD_PRIORITY_RENDER
|
||||
thread->start();
|
||||
|
||||
esp_lcd_panel_handle_t panel_handle = NULL;
|
||||
esp_lcd_rgb_panel_config_t panel_config = {
|
||||
|
||||
@@ -14,7 +14,7 @@ bool twodotfour_lvgl_init() {
|
||||
static esp_lcd_touch_handle_t touch_handle;
|
||||
|
||||
const lvgl_port_cfg_t lvgl_cfg = {
|
||||
.task_priority = tt::ThreadPriorityHigh,
|
||||
.task_priority = tt::Thread::PriorityHigh,
|
||||
.task_stack = 8096,
|
||||
.task_affinity = -1, // core pinning
|
||||
.task_max_sleep_ms = 500,
|
||||
|
||||
Reference in New Issue
Block a user