Skip to content

Commit 1bb1260

Browse files
Update to ESP-IDF v5.4 and fix warnings (#193)
- Update to ESP-IDF v5.4 - Fixed a lot of new and existing warnings - Fix issue with incorrect `EventFlag` usage in Dispatcher
1 parent fa54eaa commit 1bb1260

File tree

24 files changed

+67
-175
lines changed

24 files changed

+67
-175
lines changed

.github/actions/build-firmware/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ runs:
2020
- name: 'Build'
2121
uses: espressif/esp-idf-ci-action@main
2222
with:
23-
esp_idf_version: v5.3.2
23+
esp_idf_version: v5.4
2424
target: ${{ inputs.arch }}
2525
path: './'
2626
- name: 'Release'

.github/actions/build-sdk/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ runs:
2020
- name: 'Build'
2121
uses: espressif/esp-idf-ci-action@main
2222
with:
23-
esp_idf_version: v5.3.2
23+
esp_idf_version: v5.4
2424
target: ${{ inputs.arch }}
2525
path: './'
2626
- name: 'Release'

App/idf_component.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ dependencies:
1111
version: "1.5.0"
1212
rules:
1313
- if: "target == esp32s3"
14-
idf: '5.3.2'
14+
idf: '5.4'

Boards/CYD-2432S024C/Source/hal/YellowDisplay.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ static bool setBacklight(uint8_t duty) {
4444
.timer_sel = TWODOTFOUR_LCD_BACKLIGHT_LEDC_TIMER,
4545
.duty = duty,
4646
.hpoint = 0,
47+
.sleep_mode = LEDC_SLEEP_MODE_NO_ALIVE_NO_PD,
4748
.flags = {
4849
.output_invert = false
4950
}

Boards/LilygoTdeck/Source/InitHardware.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ static bool init_spi() {
3131
.data5_io_num = 0,
3232
.data6_io_num = 0,
3333
.data7_io_num = 0,
34+
.data_io_default_level = false,
3435
.max_transfer_sz = TDECK_SPI_TRANSFER_SIZE_LIMIT,
3536
.flags = 0,
3637
.isr_cpu_id = ESP_INTR_CPU_AFFINITY_AUTO,

Boards/LilygoTdeck/Source/hal/TdeckDisplay.cpp

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ static bool setBacklight(uint8_t duty) {
4545
.timer_sel = TDECK_LCD_BACKLIGHT_LEDC_TIMER,
4646
.duty = duty,
4747
.hpoint = 0,
48+
.sleep_mode = LEDC_SLEEP_MODE_NO_ALIVE_NO_PD,
4849
.flags = {
4950
.output_invert = 0
5051
}
@@ -68,6 +69,8 @@ bool TdeckDisplay::start() {
6869
.user_ctx = nullptr,
6970
.lcd_cmd_bits = 8,
7071
.lcd_param_bits = 8,
72+
.cs_ena_pretrans = 0,
73+
.cs_ena_posttrans = 0,
7174
.flags = {
7275
.dc_high_on_cmd = 0,
7376
.dc_low_on_data = 0,
@@ -134,6 +137,7 @@ bool TdeckDisplay::start() {
134137
const lvgl_port_display_cfg_t disp_cfg = {
135138
.io_handle = ioHandle,
136139
.panel_handle = panelHandle,
140+
.control_handle = nullptr,
137141
.buffer_size = TDECK_LCD_HORIZONTAL_RESOLUTION * TDECK_LCD_DRAW_BUFFER_HEIGHT * (TDECK_LCD_BITS_PER_PIXEL / 8),
138142
.double_buffer = true, // Disable to free up SPIRAM
139143
.trans_size = 0,
@@ -145,12 +149,15 @@ bool TdeckDisplay::start() {
145149
.mirror_x = true,
146150
.mirror_y = false,
147151
},
152+
.color_format = LV_COLOR_FORMAT_RGB565,
148153
.flags = {
149154
.buff_dma = false,
150155
.buff_spiram = true,
151156
.sw_rotate = false,
152-
.swap_bytes = false
153-
},
157+
.swap_bytes = false,
158+
.full_refresh = false,
159+
.direct_mode = false
160+
}
154161
};
155162

156163
displayHandle = lvgl_port_add_disp(&disp_cfg);

Boards/M5stackCore2/Source/InitBoot.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#include <driver/i2c.h>
22
#include <driver/spi_master.h>
3-
#include <intr_types.h>
3+
#include <esp_intr_types.h>
44
#include "Log.h"
55
#include "hal/Core2DisplayConstants.h"
66
#include "axp192/axp192.h"
@@ -37,7 +37,7 @@ static bool initSpi2() {
3737
.data7_io_num = GPIO_NUM_NC,
3838
.max_transfer_sz = CORE2_LCD_DRAW_BUFFER_SIZE,
3939
.flags = 0,
40-
.isr_cpu_id = INTR_CPU_ID_AUTO,
40+
.isr_cpu_id = ESP_INTR_CPU_AFFINITY_AUTO,
4141
.intr_flags = 0
4242
};
4343

Boards/M5stackCoreS3/Source/InitBoot.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#include <driver/i2c.h>
22
#include <driver/spi_master.h>
3-
#include <intr_types.h>
3+
#include <esp_intr_types.h>
44
#include "Log.h"
55
#include "hal/CoreS3DisplayConstants.h"
66
#include "kernel/Kernel.h"
@@ -28,9 +28,10 @@ static bool initSpi3() {
2828
.data5_io_num = GPIO_NUM_NC,
2929
.data6_io_num = GPIO_NUM_NC,
3030
.data7_io_num = GPIO_NUM_NC,
31+
.data_io_default_level = false,
3132
.max_transfer_sz = CORES3_LCD_DRAW_BUFFER_SIZE,
3233
.flags = 0,
33-
.isr_cpu_id = INTR_CPU_ID_AUTO,
34+
.isr_cpu_id = ESP_INTR_CPU_AFFINITY_AUTO,
3435
.intr_flags = 0
3536
};
3637

Boards/M5stackCoreS3/Source/hal/CoreS3Display.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ bool CoreS3Display::start() {
2929
.user_ctx = nullptr,
3030
.lcd_cmd_bits = 8,
3131
.lcd_param_bits = 8,
32+
.cs_ena_pretrans = 0,
33+
.cs_ena_posttrans = 0,
3234
.flags = {
3335
.dc_high_on_cmd = 0,
3436
.dc_low_on_data = 0,

Boards/UnPhone/Source/InitHardware.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ static bool initSpi() {
2727
.data5_io_num = 0,
2828
.data6_io_num = 0,
2929
.data7_io_num = 0,
30+
.data_io_default_level = false,
3031
.max_transfer_sz = UNPHONE_SPI_TRANSFER_SIZE_LIMIT,
3132
.flags = 0,
3233
.isr_cpu_id = ESP_INTR_CPU_AFFINITY_AUTO,

0 commit comments

Comments
 (0)