mirror of
https://github.com/espressif/esp-idf.git
synced 2024-09-19 14:26:01 -04:00
change(esp_lcd): rearrange the esp_lcd folder by types
This commit is contained in:
parent
0717e0e4a3
commit
ad84b61e49
@ -6,27 +6,34 @@ endif()
|
||||
|
||||
set(srcs "src/esp_lcd_common.c"
|
||||
"src/esp_lcd_panel_io.c"
|
||||
"src/esp_lcd_panel_io_i2c_v1.c"
|
||||
"src/esp_lcd_panel_io_i2c_v2.c"
|
||||
"src/esp_lcd_panel_io_spi.c"
|
||||
"src/esp_lcd_panel_nt35510.c"
|
||||
"src/esp_lcd_panel_ssd1306.c"
|
||||
"src/esp_lcd_panel_st7789.c"
|
||||
"src/esp_lcd_panel_ops.c")
|
||||
set(includes "include" "interface")
|
||||
set(priv_requires "esp_mm" "esp_psram")
|
||||
set(priv_requires "esp_mm" "esp_psram" "esp_pm" "esp_driver_spi" "esp_driver_i2s")
|
||||
set(public_requires "driver" "esp_driver_gpio" "esp_driver_i2c")
|
||||
|
||||
if(CONFIG_SOC_I2C_SUPPORTED)
|
||||
list(APPEND srcs "i2c/esp_lcd_panel_io_i2c_v1.c" "i2c/esp_lcd_panel_io_i2c_v2.c")
|
||||
endif()
|
||||
|
||||
if(CONFIG_SOC_GPSPI_SUPPORTED)
|
||||
list(APPEND srcs "spi/esp_lcd_panel_io_spi.c")
|
||||
endif()
|
||||
|
||||
if(CONFIG_SOC_I2S_LCD_I80_VARIANT)
|
||||
list(APPEND srcs "src/esp_lcd_panel_io_i2s.c")
|
||||
list(APPEND priv_requires "esp_driver_i2s")
|
||||
list(APPEND srcs "i80/esp_lcd_panel_io_i2s.c")
|
||||
endif()
|
||||
|
||||
if(CONFIG_SOC_LCDCAM_SUPPORTED)
|
||||
list(APPEND srcs "src/esp_lcd_panel_io_i80.c" "src/esp_lcd_panel_rgb.c")
|
||||
list(APPEND includes "rgb/include")
|
||||
list(APPEND srcs "i80/esp_lcd_panel_io_i80.c" "rgb/esp_lcd_panel_rgb.c")
|
||||
endif()
|
||||
|
||||
idf_component_register(SRCS ${srcs}
|
||||
INCLUDE_DIRS ${includes}
|
||||
PRIV_INCLUDE_DIRS "priv_include"
|
||||
PRIV_REQUIRES ${priv_requires}
|
||||
REQUIRES driver esp_driver_gpio esp_driver_spi esp_driver_i2c
|
||||
REQUIRES ${public_requires}
|
||||
LDFRAGMENTS linker.lf)
|
||||
|
@ -3,6 +3,7 @@ menu "LCD and Touch Panel"
|
||||
|
||||
menu "LCD Peripheral Configuration"
|
||||
config LCD_PANEL_IO_FORMAT_BUF_SIZE
|
||||
depends on SOC_LCD_I80_SUPPORTED
|
||||
int "LCD panel io format buffer size"
|
||||
default 32
|
||||
help
|
||||
|
@ -80,7 +80,7 @@ esp_lcd_new_panel_nt35510(const esp_lcd_panel_io_handle_t io, const esp_lcd_pane
|
||||
nt35510->madctl_val |= LCD_CMD_BGR_BIT;
|
||||
break;
|
||||
default:
|
||||
ESP_GOTO_ON_FALSE(false, ESP_ERR_NOT_SUPPORTED, err, TAG, "unsupported color space");
|
||||
ESP_GOTO_ON_FALSE(false, ESP_ERR_NOT_SUPPORTED, err, TAG, "unsupported RGB element order");
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -31,6 +31,7 @@ esp_err_t esp_lcd_panel_del(esp_lcd_panel_handle_t panel)
|
||||
esp_err_t esp_lcd_panel_draw_bitmap(esp_lcd_panel_handle_t panel, int x_start, int y_start, int x_end, int y_end, const void *color_data)
|
||||
{
|
||||
ESP_RETURN_ON_FALSE(panel, ESP_ERR_INVALID_ARG, TAG, "invalid panel handle");
|
||||
ESP_RETURN_ON_FALSE(panel->draw_bitmap, ESP_ERR_NOT_SUPPORTED, TAG, "draw_bitmap is not supported by this panel");
|
||||
return panel->draw_bitmap(panel, x_start, y_start, x_end, y_end, color_data);
|
||||
}
|
||||
|
||||
|
@ -85,7 +85,7 @@ esp_lcd_new_panel_st7789(const esp_lcd_panel_io_handle_t io, const esp_lcd_panel
|
||||
st7789->madctl_val |= LCD_CMD_BGR_BIT;
|
||||
break;
|
||||
default:
|
||||
ESP_GOTO_ON_FALSE(false, ESP_ERR_NOT_SUPPORTED, err, TAG, "unsupported color space");
|
||||
ESP_GOTO_ON_FALSE(false, ESP_ERR_NOT_SUPPORTED, err, TAG, "unsupported RGB element order");
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -4,5 +4,5 @@ set(srcs "test_app_main.c"
|
||||
# In order for the cases defined by `TEST_CASE` to be linked into the final elf,
|
||||
# the component can be registered as WHOLE_ARCHIVE
|
||||
idf_component_register(SRCS ${srcs}
|
||||
PRIV_REQUIRES esp_lcd unity driver
|
||||
PRIV_REQUIRES esp_lcd unity esp_driver_i2c
|
||||
WHOLE_ARCHIVE)
|
||||
|
@ -4,5 +4,5 @@ set(srcs "test_app_main.c"
|
||||
# In order for the cases defined by `TEST_CASE` to be linked into the final elf,
|
||||
# the component can be registered as WHOLE_ARCHIVE
|
||||
idf_component_register(SRCS ${srcs}
|
||||
PRIV_REQUIRES esp_lcd unity driver
|
||||
PRIV_REQUIRES esp_lcd unity esp_driver_spi
|
||||
WHOLE_ARCHIVE)
|
||||
|
@ -174,7 +174,6 @@ INPUT = \
|
||||
$(PROJECT_PATH)/components/esp_hw_support/include/esp_sleep.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/include/esp_lcd_panel_io.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/include/esp_lcd_panel_ops.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/include/esp_lcd_panel_rgb.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/include/esp_lcd_panel_vendor.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/include/esp_lcd_panel_dev.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/include/esp_lcd_panel_ssd1306.h \
|
||||
|
@ -1,5 +1,6 @@
|
||||
INPUT += \
|
||||
$(PROJECT_PATH)/components/driver/touch_sensor/$(IDF_TARGET)/include/driver/touch_sensor.h \
|
||||
$(PROJECT_PATH)/components/esp_lcd/rgb/include/esp_lcd_panel_rgb.h \
|
||||
$(PROJECT_PATH)/components/soc/$(IDF_TARGET)/include/soc/touch_sensor_channel.h \
|
||||
$(PROJECT_PATH)/components/ulp/ulp_common/include/$(IDF_TARGET)/ulp_common_defs.h \
|
||||
$(PROJECT_PATH)/components/ulp/ulp_fsm/include/$(IDF_TARGET)/ulp.h \
|
||||
|
@ -498,5 +498,8 @@ API Reference
|
||||
.. include-build-file:: inc/esp_lcd_types.inc
|
||||
.. include-build-file:: inc/esp_lcd_panel_io.inc
|
||||
.. include-build-file:: inc/esp_lcd_panel_ops.inc
|
||||
.. include-build-file:: inc/esp_lcd_panel_rgb.inc
|
||||
.. include-build-file:: inc/esp_lcd_panel_vendor.inc
|
||||
|
||||
.. only:: SOC_LCD_RGB_SUPPORTED
|
||||
|
||||
.. include-build-file:: inc/esp_lcd_panel_rgb.inc
|
||||
|
Loading…
Reference in New Issue
Block a user