Skip to content

Commit 034502b

Browse files
wnienhausdpgeorge
authored andcommitted
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: espressif/esp-idf@a0e3d48 Signed-off-by: Wilko Nienhaus <[email protected]>
1 parent ea8f0fd commit 034502b

File tree

3 files changed

+12
-3
lines changed

3 files changed

+12
-3
lines changed

ports/esp32/boards/sdkconfig.base

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,10 @@ CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=y
5050
# ULP coprocessor support
5151
CONFIG_ESP32_ULP_COPROC_ENABLED=y
5252
CONFIG_ESP32_ULP_COPROC_RESERVE_MEM=2040
53+
CONFIG_ESP32S2_ULP_COPROC_ENABLED=y
54+
CONFIG_ESP32S2_ULP_COPROC_RESERVE_MEM=2040
55+
CONFIG_ESP32S3_ULP_COPROC_ENABLED=y
56+
CONFIG_ESP32S3_ULP_COPROC_RESERVE_MEM=2040
5357

5458
# For cmake build
5559
CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y

ports/esp32/esp32_ulp.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,15 @@
2626

2727
#include "py/runtime.h"
2828

29-
3029
#if CONFIG_IDF_TARGET_ESP32 || CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3
3130

31+
#if CONFIG_IDF_TARGET_ESP32
3232
#include "esp32/ulp.h"
33+
#elif CONFIG_IDF_TARGET_ESP32S2
34+
#include "esp32s2/ulp.h"
35+
#elif CONFIG_IDF_TARGET_ESP32S3
36+
#include "esp32s3/ulp.h"
37+
#endif
3338
#include "esp_err.h"
3439

3540
typedef struct _esp32_ulp_obj_t {
@@ -106,4 +111,4 @@ MP_DEFINE_CONST_OBJ_TYPE(
106111
locals_dict, &esp32_ulp_locals_dict
107112
);
108113

109-
#endif // CONFIG_IDF_TARGET_ESP32
114+
#endif // CONFIG_IDF_TARGET_ESP32 || CONFIG_IDF_TARGET_ESP32S2 || CONFIG_IDF_TARGET_ESP32S3

tools/ci.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ function ci_esp32_idf402_setup {
141141
}
142142

143143
function ci_esp32_idf44_setup {
144-
ci_esp32_setup_helper v4.4
144+
ci_esp32_setup_helper v4.4.2
145145
}
146146

147147
function ci_esp32_build {

0 commit comments

Comments
 (0)