diff options
| author | Damien George <damien@micropython.org> | 2023-05-09 09:52:54 +1000 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-06-23 15:34:22 +1000 |
| commit | e4650125b88a35f074097f16d84a8f49bd22ac06 (patch) | |
| tree | 6b87f056d0c23f2eb043fa2da0f949429af50e94 /ports/esp32/modesp32.c | |
| parent | 2af229c3cc55ceefc4cfba0f50092af725c3bfa9 (diff) | |
esp32: Update port to support IDF v5.0.2.
This commit updates the esp32 port to work exclusively with ESP-IDF v5.
IDF v5 is needed for some of the newer ESP32 SoCs to work, and it also
cleans up a lot of the inconsistencies between existing SoCs (eg S2, S3,
and C3).
Support for IDF v4 is dropped because it's a lot of effort to maintain both
versions at the same time.
The following components have been verified to work on the various SoCs:
ESP32 ESP32-S2 ESP32-S3 ESP32-C3
build pass pass pass pass
SPIRAM pass pass pass N/A
REPL (UART) pass pass pass pass
REPL (USB) N/A pass pass N/A
filesystem pass pass pass pass
GPIO pass pass pass pass
SPI pass pass pass pass
I2C pass pass pass pass
PWM pass pass pass pass
ADC pass pass pass pass
WiFi STA pass pass pass pass
WiFi AP pass pass pass pass
BLE pass N/A pass pass
ETH pass -- -- --
PPP pass pass pass --
sockets pass pass pass pass
SSL pass ENOMEM pass pass
RMT pass pass pass pass
NeoPixel pass pass pass pass
I2S pass pass pass N/A
ESPNow pass pass pass pass
ULP-FSM pass pass pass N/A
SDCard pass N/A N/A pass
WDT pass pass pass pass
Signed-off-by: Damien George <damien@micropython.org>
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
Diffstat (limited to 'ports/esp32/modesp32.c')
| -rw-r--r-- | ports/esp32/modesp32.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/ports/esp32/modesp32.c b/ports/esp32/modesp32.c index a18ca4c13..ef3ad0b76 100644 --- a/ports/esp32/modesp32.c +++ b/ports/esp32/modesp32.c @@ -45,10 +45,8 @@ #include "modesp32.h" // These private includes are needed for idf_heap_info. -#if ESP_IDF_VERSION >= ESP_IDF_VERSION_VAL(4, 3, 0) #define MULTI_HEAP_FREERTOS #include "../multi_heap_platform.h" -#endif #include "../heap_private.h" STATIC mp_obj_t esp32_wake_on_touch(const mp_obj_t wake) { @@ -161,9 +159,9 @@ STATIC mp_obj_t esp32_raw_temperature(void) { CLEAR_PERI_REG_MASK(SENS_SAR_TSENS_CTRL_REG, SENS_TSENS_DUMP_OUT); SET_PERI_REG_MASK(SENS_SAR_TSENS_CTRL_REG, SENS_TSENS_POWER_UP_FORCE); SET_PERI_REG_MASK(SENS_SAR_TSENS_CTRL_REG, SENS_TSENS_POWER_UP); - ets_delay_us(100); + esp_rom_delay_us(100); SET_PERI_REG_MASK(SENS_SAR_TSENS_CTRL_REG, SENS_TSENS_DUMP_OUT); - ets_delay_us(5); + esp_rom_delay_us(5); int res = GET_PERI_REG_BITS2(SENS_SAR_SLAVE_ADDR3_REG, SENS_TSENS_OUT, SENS_TSENS_OUT_S); return mp_obj_new_int(res); |
