esp32/esp32_ulp: Fix ULP (FSM) support for S2 and S3.

This change enables the ULP (FSM) for all ESP32 variants rather than
requiring it to be enabled for each board specifically.

It also ensures the correct header file is included for each variant.

Lastly, it updates the IDF version we're builing against to v4.4.2, as that
version contains important fixes to make the ULP actually work on S2/S3
chips. See: https://github.com/espressif/esp-idf/commit/a0e3d48

Signed-off-by: Wilko Nienhaus <wilko.nienhaus@gmail.com>
This commit is contained in:
Wilko Nienhaus 2023-06-04 15:42:13 +03:00 committed by Damien George
parent ea8f0fd896
commit 034502bc72
3 changed files with 12 additions and 3 deletions

View File

@ -50,6 +50,10 @@ CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=y
# ULP coprocessor support # ULP coprocessor support
CONFIG_ESP32_ULP_COPROC_ENABLED=y CONFIG_ESP32_ULP_COPROC_ENABLED=y
CONFIG_ESP32_ULP_COPROC_RESERVE_MEM=2040 CONFIG_ESP32_ULP_COPROC_RESERVE_MEM=2040
CONFIG_ESP32S2_ULP_COPROC_ENABLED=y
CONFIG_ESP32S2_ULP_COPROC_RESERVE_MEM=2040
CONFIG_ESP32S3_ULP_COPROC_ENABLED=y
CONFIG_ESP32S3_ULP_COPROC_RESERVE_MEM=2040
# For cmake build # For cmake build
CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y

View File

@ -26,10 +26,15 @@
#include "py/runtime.h" #include "py/runtime.h"
#if CONFIG_IDF_TARGET_ESP32 || CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3 #if CONFIG_IDF_TARGET_ESP32 || CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3
#if CONFIG_IDF_TARGET_ESP32
#include "esp32/ulp.h" #include "esp32/ulp.h"
#elif CONFIG_IDF_TARGET_ESP32S2
#include "esp32s2/ulp.h"
#elif CONFIG_IDF_TARGET_ESP32S3
#include "esp32s3/ulp.h"
#endif
#include "esp_err.h" #include "esp_err.h"
typedef struct _esp32_ulp_obj_t { typedef struct _esp32_ulp_obj_t {
@ -106,4 +111,4 @@ MP_DEFINE_CONST_OBJ_TYPE(
locals_dict, &esp32_ulp_locals_dict locals_dict, &esp32_ulp_locals_dict
); );
#endif // CONFIG_IDF_TARGET_ESP32 #endif // CONFIG_IDF_TARGET_ESP32 || CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3

View File

@ -141,7 +141,7 @@ function ci_esp32_idf402_setup {
} }
function ci_esp32_idf44_setup { function ci_esp32_idf44_setup {
ci_esp32_setup_helper v4.4 ci_esp32_setup_helper v4.4.2
} }
function ci_esp32_build { function ci_esp32_build {