Skip to content

Commit 584dc48

Browse files
committed
feat(lvgl_port): set the lvgl task to run on the same core as the Arduino task by default
1 parent 70e84ec commit 584dc48

File tree

5 files changed

+18
-5
lines changed

5 files changed

+18
-5
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
# ChangeLog
22

3-
## v0.1.5 - 2024-07-08
3+
## v0.1.5 - 2024-07-09
44

55
### Enhancements:
66

77
* feat(gt911): support set I2C address by using RST and INT pins
8+
* feat(lvgl_port): set the lvgl task to run on the same core as the Arduino task by default
89

910
### Bugfixes:
1011

examples/LVGL/v8/Porting/lvgl_port_v8.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
*/
66
#pragma once
77

8+
#include <Arduino.h>
89
#include <ESP_Panel_Library.h>
910
#include <lvgl.h>
1011

@@ -49,7 +50,9 @@
4950
#define LVGL_PORT_TASK_MIN_DELAY_MS (2) // The minimum delay of the LVGL timer task, in milliseconds
5051
#define LVGL_PORT_TASK_STACK_SIZE (6 * 1024) // The stack size of the LVGL timer task, in bytes
5152
#define LVGL_PORT_TASK_PRIORITY (2) // The priority of the LVGL timer task
52-
#define LVGL_PORT_TASK_CORE (-1) // The core of the LVGL timer task, `-1` means the don't specify the core
53+
#define LVGL_PORT_TASK_CORE (ARDUINO_RUNNING_CORE)
54+
// The core of the LVGL timer task, `-1` means the don't specify the core
55+
// Default is the same as the Arduino task
5356
// This can be set to `1` only if the SoCs support dual-core,
5457
// otherwise it should be set to `-1` or `0`
5558

examples/LVGL/v8/Rotation/lvgl_port_v8.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
*/
66
#pragma once
77

8+
#include <Arduino.h>
89
#include <ESP_Panel_Library.h>
910
#include <lvgl.h>
1011

@@ -49,7 +50,9 @@
4950
#define LVGL_PORT_TASK_MIN_DELAY_MS (2) // The minimum delay of the LVGL timer task, in milliseconds
5051
#define LVGL_PORT_TASK_STACK_SIZE (6 * 1024) // The stack size of the LVGL timer task, in bytes
5152
#define LVGL_PORT_TASK_PRIORITY (2) // The priority of the LVGL timer task
52-
#define LVGL_PORT_TASK_CORE (-1) // The core of the LVGL timer task, `-1` means the don't specify the core
53+
#define LVGL_PORT_TASK_CORE (ARDUINO_RUNNING_CORE)
54+
// The core of the LVGL timer task, `-1` means the don't specify the core
55+
// Default is the same as the Arduino task
5356
// This can be set to `1` only if the SoCs support dual-core,
5457
// otherwise it should be set to `-1` or `0`
5558

examples/SquareLine/v8/Porting/lvgl_port_v8.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
*/
66
#pragma once
77

8+
#include <Arduino.h>
89
#include <ESP_Panel_Library.h>
910
#include <lvgl.h>
1011

@@ -49,7 +50,9 @@
4950
#define LVGL_PORT_TASK_MIN_DELAY_MS (2) // The minimum delay of the LVGL timer task, in milliseconds
5051
#define LVGL_PORT_TASK_STACK_SIZE (6 * 1024) // The stack size of the LVGL timer task, in bytes
5152
#define LVGL_PORT_TASK_PRIORITY (2) // The priority of the LVGL timer task
52-
#define LVGL_PORT_TASK_CORE (-1) // The core of the LVGL timer task, `-1` means the don't specify the core
53+
#define LVGL_PORT_TASK_CORE (ARDUINO_RUNNING_CORE)
54+
// The core of the LVGL timer task, `-1` means the don't specify the core
55+
// Default is the same as the Arduino task
5356
// This can be set to `1` only if the SoCs support dual-core,
5457
// otherwise it should be set to `-1` or `0`
5558

examples/SquareLine/v8/WiFiClock/lvgl_port_v8.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
*/
66
#pragma once
77

8+
#include <Arduino.h>
89
#include <ESP_Panel_Library.h>
910
#include <lvgl.h>
1011

@@ -49,7 +50,9 @@
4950
#define LVGL_PORT_TASK_MIN_DELAY_MS (2) // The minimum delay of the LVGL timer task, in milliseconds
5051
#define LVGL_PORT_TASK_STACK_SIZE (6 * 1024) // The stack size of the LVGL timer task, in bytes
5152
#define LVGL_PORT_TASK_PRIORITY (2) // The priority of the LVGL timer task
52-
#define LVGL_PORT_TASK_CORE (-1) // The core of the LVGL timer task, `-1` means the don't specify the core
53+
#define LVGL_PORT_TASK_CORE (ARDUINO_RUNNING_CORE)
54+
// The core of the LVGL timer task, `-1` means the don't specify the core
55+
// Default is the same as the Arduino task
5356
// This can be set to `1` only if the SoCs support dual-core,
5457
// otherwise it should be set to `-1` or `0`
5558

0 commit comments

Comments
 (0)