Skip to content

Commit 31771b3

Browse files
committed
Merge branch 'feat/support_backlight_pwm_freq_conf' into 'master'
Closes #189 See merge request ae_group/ESP32_Display_Panel!14
2 parents 9a8fbf5 + 3d2d797 commit 31771b3

15 files changed

+205
-18
lines changed

CHANGELOG.md

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

3-
## v1.0.2 - 2025-03-24
3+
## v1.0.2 - 2025-04-23
4+
5+
### Enhancements:
6+
7+
* feat(backlight): add PWM parameters configuration (#188)
48

59
### Bugfixes:
610

@@ -9,6 +13,7 @@
913
* fix(docs): update README
1014
* fix(conf): update comments of custom config file
1115
* fix(examples): enable CPU 240M and task WDT default in esp_idf/lvgl_v8_port
16+
* fix(lcd): fix ST7701 mirror issue
1217

1318
## v1.0.1 - 2025-03-13
1419

esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

examples/arduino/board/board_static_config/esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

examples/arduino/gui/lvgl_v8/simple_port/esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

examples/arduino/gui/lvgl_v8/simple_rotation/esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

examples/arduino/gui/lvgl_v8/squareline_port/esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

examples/arduino/gui/lvgl_v8/squareline_wifi_clock/esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

examples/platformio/lvgl_v8_port/src/esp_panel_board_custom_conf.h

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,22 @@
476476
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
477477
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
478478

479+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
480+
/**
481+
* @brief PWM parameters configuration
482+
*/
483+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (5000) // LEDC timer frequency.
484+
// Different backlight driver chips may have different
485+
// frequency limits, please refer to the datasheet of
486+
// the specific chip.
487+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
488+
489+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
490+
// The frequency and duty resolution of the LEDC timer
491+
// need to be properly matched, please refer to:
492+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
493+
#endif
494+
479495
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_CUSTOM
480496

481497
/**
@@ -735,8 +751,8 @@
735751
* 3. Patch version mismatch: No impact on functionality
736752
*/
737753
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
738-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
739-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 2
754+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
755+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
740756

741757
#endif // ESP_PANEL_BOARD_DEFAULT_USE_CUSTOM
742758

src/board/custom/Kconfig.board_custom.backlight

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,23 @@ if ESP_PANEL_BOARD_USE_BACKLIGHT
5757
Active level for backlight control.
5858
endmenu
5959

60+
menu "PWM parameters"
61+
depends on ESP_PANEL_BOARD_BACKLIGHT_TYPE_PWM_LEDC
62+
63+
config ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ
64+
int "Frequency"
65+
default 5000
66+
help
67+
Frequency for PWM control.
68+
69+
config ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION
70+
int "Duty resolution"
71+
default 10
72+
range 1 20
73+
help
74+
Duty resolution for PWM control.
75+
endmenu
76+
6077
config ESP_PANEL_BOARD_BACKLIGHT_IDLE_OFF
6178
bool "Idle off"
6279
default n

src/board/custom/esp_panel_board_kconfig_custom_backlight.h

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,26 @@
4242
#error "Missing configuration: ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL"
4343
#endif
4444
#endif
45+
46+
#if (ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC)
47+
#ifndef ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ
48+
#ifdef CONFIG_ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ
49+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ CONFIG_ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ
50+
#else
51+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ 5000 // Keep the backward compatibility
52+
#endif
53+
#endif
54+
#endif
55+
56+
#if (ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC)
57+
#ifndef ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION
58+
#ifdef CONFIG_ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION
59+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION CONFIG_ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION
60+
#else
61+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION 10 // Keep the backward compatibility
62+
#endif
63+
#endif
64+
#endif
4565
#endif
4666

4767
#ifndef ESP_PANEL_BOARD_BACKLIGHT_IDLE_OFF

src/board/esp_panel_board_default_config.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,10 @@ const BoardConfig ESP_PANEL_BOARD_DEFAULT_CONFIG = {
293293
},
294294
#elif ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
295295
.config = BacklightPWM_LEDC::Config{
296+
.ledc_timer = BacklightPWM_LEDC::LEDC_TimerPartialConfig{
297+
.freq_hz = ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ,
298+
.duty_resolution = ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION,
299+
},
296300
.ledc_channel = BacklightPWM_LEDC::LEDC_ChannelPartialConfig{
297301
.io_num = ESP_PANEL_BOARD_BACKLIGHT_IO,
298302
.on_level = ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL,

src/board/supported/jingcai/BOARD_JINGCAI_ESP32_4848S040C_I_Y_3.h

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,6 +345,23 @@
345345
#define ESP_PANEL_BOARD_BACKLIGHT_IO (38) // Output GPIO pin number
346346
#define ESP_PANEL_BOARD_BACKLIGHT_ON_LEVEL (1) // Active level, 0: low, 1: high
347347

348+
349+
#if ESP_PANEL_BOARD_BACKLIGHT_TYPE == ESP_PANEL_BACKLIGHT_TYPE_PWM_LEDC
350+
/**
351+
* @brief PWM parameters configuration
352+
*/
353+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_FREQ_HZ (1000) // LEDC timer frequency.
354+
// Different backlight driver chips may have different
355+
// frequency limits, please refer to the datasheet of
356+
// the specific chip.
357+
// https://github.com/esp-arduino-libs/ESP32_Display_Panel/issues/188
358+
359+
#define ESP_PANEL_BOARD_BACKLIGHT_PWM_DUTY_RESOLUTION (10) // LEDC timer duty resolution.
360+
// The frequency and duty resolution of the LEDC timer
361+
// need to be properly matched, please refer to:
362+
// https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/ledc.html#supported-range-of-frequency-and-duty-resolutions
363+
#endif
364+
348365
#endif // ESP_PANEL_BOARD_BACKLIGHT_TYPE
349366

350367
/**
@@ -381,7 +398,7 @@
381398
* 3. Patch version mismatch: No impact on functionality
382399
*/
383400
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MAJOR 1
384-
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 0
401+
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_MINOR 1
385402
#define ESP_PANEL_BOARD_CUSTOM_FILE_VERSION_PATCH 0
386403

387404
// *INDENT-ON*

src/drivers/lcd/port/esp_lcd_st7701_rgb.c

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,9 +348,20 @@ static esp_err_t panel_st7701_mirror(esp_lcd_panel_t *panel, bool mirror_x, bool
348348
} else {
349349
st7701->madctl_val &= ~LCD_CMD_ML_BIT;
350350
}
351+
352+
// Enable the Command2 BK0
353+
ESP_RETURN_ON_ERROR(esp_lcd_panel_io_tx_param(io, ST7701_CMD_CND2BKxSEL, (uint8_t []) {
354+
ST7701_CMD_BKxSEL_BYTE0, ST7701_CMD_BKxSEL_BYTE1, ST7701_CMD_BKxSEL_BYTE2, ST7701_CMD_BKxSEL_BYTE3,
355+
ST7701_CMD_BKxSEL_BK0 | ST7701_CMD_CN2_BIT,
356+
}, 5), TAG, "send command failed");
351357
ESP_RETURN_ON_ERROR(esp_lcd_panel_io_tx_param(io, ST7701_CMD_SDIR, (uint8_t[]) {
352358
sdir_val,
353359
}, 1), TAG, "send command failed");;
360+
361+
// Disable Command2
362+
ESP_RETURN_ON_ERROR(esp_lcd_panel_io_tx_param(io, ST7701_CMD_CND2BKxSEL, (uint8_t []) {
363+
ST7701_CMD_BKxSEL_BYTE0, ST7701_CMD_BKxSEL_BYTE1, ST7701_CMD_BKxSEL_BYTE2, ST7701_CMD_BKxSEL_BYTE3, 0,
364+
}, 5), TAG, "send command failed");
354365
ESP_RETURN_ON_ERROR(esp_lcd_panel_io_tx_param(io, LCD_CMD_MADCTL, (uint8_t[]) {
355366
st7701->madctl_val,
356367
}, 1), TAG, "send command failed");;

src/esp_panel_versions.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717

1818
/* File `esp_panel_board_custom_conf.h` */
1919
#define ESP_PANEL_BOARD_CUSTOM_VERSION_MAJOR 1
20-
#define ESP_PANEL_BOARD_CUSTOM_VERSION_MINOR 0
21-
#define ESP_PANEL_BOARD_CUSTOM_VERSION_PATCH 2
20+
#define ESP_PANEL_BOARD_CUSTOM_VERSION_MINOR 1
21+
#define ESP_PANEL_BOARD_CUSTOM_VERSION_PATCH 0
2222

2323
/* File `esp_panel_board_supported_conf.h` */
2424
#define ESP_PANEL_BOARD_SUPPORTED_VERSION_MAJOR 1

tools/check_file_version.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
exclude_dirs = [
99
'./build',
10+
'./examples/platformio/lvgl_v8_port/.pio'
1011
]
1112
internal_version_file = 'src/esp_panel_versions.h'
1213
include_files = [

0 commit comments

Comments
 (0)