change(cmake): use lpcore openocd configs with CONFIG_ULP_COPROC_TYPE_LP_CORE

This commit is contained in:
Samuel Obuch
2026-04-02 17:25:49 +02:00
parent 35ee7beb0e
commit 508bb73d76

View File

@@ -6,8 +6,16 @@ function(__get_openocd_options openocd_option_var)
elseif(CONFIG_IDF_TARGET STREQUAL "esp32s2")
set(${openocd_option_var} "-f board/esp32s2-kaluga-1.cfg" PARENT_SCOPE)
elseif(CONFIG_SOC_USB_SERIAL_JTAG_SUPPORTED)
set(${openocd_option_var} "-f board/${CONFIG_IDF_TARGET}-builtin.cfg" PARENT_SCOPE)
if(CONFIG_ULP_COPROC_TYPE_LP_CORE)
set(${openocd_option_var} "-f board/${CONFIG_IDF_TARGET}-lpcore-builtin.cfg" PARENT_SCOPE)
else()
set(${openocd_option_var} "-f board/${CONFIG_IDF_TARGET}-builtin.cfg" PARENT_SCOPE)
endif()
else()
set(${openocd_option_var} "-f board/${CONFIG_IDF_TARGET}-ftdi.cfg" PARENT_SCOPE)
if(CONFIG_ULP_COPROC_TYPE_LP_CORE)
set(${openocd_option_var} "-f board/${CONFIG_IDF_TARGET}-lpcore-ftdi.cfg" PARENT_SCOPE)
else()
set(${openocd_option_var} "-f board/${CONFIG_IDF_TARGET}-ftdi.cfg" PARENT_SCOPE)
endif()
endif()
endfunction()