espressif / openocd-on-esp32

OpenOCD port running on ESP32-S3 microcontrollers
Apache License 2.0
54 stars 5 forks source link

compile error: unknown type name 'lv_disp_rot_t' (OCDOE-9) #4

Closed mthii closed 8 months ago

mthii commented 8 months ago

compile error for the esp32-s3 target(esp-box) after pull, fullclean, and set target again.


esp32/openocd-on-esp32/managed_components/espressif__esp-box/include/bsp/esp-box.h:362:42: error: unknown type name 'lv_disp_rot_t'; did you mean 'lv_disp_t'?
  362 | void bsp_display_rotate(lv_disp_t *disp, lv_disp_rot_t rotation);

esp32/openocd-on-esp32/managed_components/espressif__esp-box/esp-box.c:457:42: error: unknown type name 'lv_disp_rot_t'; did you mean 'lv_disp_t'?
  457 | void bsp_display_rotate(lv_disp_t *disp, lv_disp_rot_t rotation)

$ grep -r lv_disp_rot_t *
'''
I don't find any definition about that.

I don't have the esp-box.
mthii commented 8 months ago

Some lvgl configuration default enabled. I can't disable no need configurations I don't have on menuconfig.

Does the openocd on esp32 really work well on esp32-s3-devkitc with no lcd or esp-box?

Only for the esp-box ?

Editing CMakefile.txt required for the other target board ?

As a basic question, is the openocd on esp32 a kind of jtag probe app like raspberry pi pico probe, or the whole openocd host app instead of pc ?

erhankur commented 8 months ago

Ok. Recently we did lvlg_port update and it caused some build issues with esp-box bsp. Later if you see an issue, please set lvgl_port version like below in the idf_component.yml file.

  espressif/esp_lvgl_port:
    version: "1.4.0"
    rules:
    - if: "target in [esp32s3]"

I will make the necessary updates to fix the compatibility issues.

mthii commented 8 months ago

?? I don't have esp-box, lcd, and lvgl, either. Just esp32-s3-devkitc. So I would like to disable such display devises. I would like to have just openocd and jtag debug probes. I have already commented out such devises in main/idf_component.yml, thouhg, build issues were not solved. Your advise above may be those devises with lcd, I don' have ?

erhankur commented 8 months ago

For the quick fix, please update bottom lines of main/openocd/src/target/espressif/CMakeLists.txt

By default we enabled UI (esp-box) for the ESP32-S3. This CONFIG_UI_ENABLE check should fix your issue.

if(IS_ESPIDF)
    target_sources(espressif PRIVATE esp_ui_dispatcher.c)
    target_include_directories(espressif PRIVATE ${PROJECT_SOURCE_DIR})
    if(CONFIG_UI_ENABLE) 
        target_link_libraries(espressif PRIVATE idf::lvgl__lvgl)
    endif()
endif()
erhankur commented 8 months ago

The master branch is updated. You shouldn't see a build error on ESP32-S3 devkit now. Please let me know the result.

mthii commented 8 months ago

Thnak you for your quick fix. I suceed to compile without any error now. Please close the issue.