Skip to content

Commit 6972695

Browse files
authored
IDF master c69f0ec32 (espressif#5449)
esp-dsp: master f4d7d6e esp-face: master 420fc7e esp-rainmaker: f1b82c7 esp32-camera: master 6a9497b esp_littlefs: master b58f00c
1 parent e0e5c88 commit 6972695

File tree

588 files changed

+15429
-1653
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

588 files changed

+15429
-1653
lines changed

Diff for: platform.txt

+9-9
Large diffs are not rendered by default.

Diff for: tools/esptool.py

+130-96
Large diffs are not rendered by default.

Diff for: tools/platformio-build-esp32.py

+10-9
Large diffs are not rendered by default.

Diff for: tools/platformio-build-esp32c3.py

+9-8
Large diffs are not rendered by default.

Diff for: tools/platformio-build-esp32s2.py

+9-9
Large diffs are not rendered by default.

Diff for: tools/sdk/esp32/bin/bootloader_dio_40m.bin

-464 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_dio_80m.bin

-464 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_dout_40m.bin

-464 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_dout_80m.bin

-464 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_qio_40m.bin

-480 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_qio_80m.bin

-480 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_qout_40m.bin

-480 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/bin/bootloader_qout_80m.bin

-480 Bytes
Binary file not shown.

Diff for: tools/sdk/esp32/include/app_update/include/esp_ota_ops.h

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include "esp_partition.h"
1515
#include "esp_image_format.h"
1616
#include "esp_flash_partitions.h"
17+
#include "soc/soc_caps.h"
1718

1819
#ifdef __cplusplus
1920
extern "C"

Diff for: tools/sdk/esp32/include/bootloader_support/include/bootloader_common.h

+24-4
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
#include "esp_flash_partitions.h"
99
#include "esp_image_format.h"
1010
#include "esp_app_format.h"
11-
// RESET_REASON is declared in rom/rtc.h
11+
// [refactor-todo]: we shouldn't expose ROM header files in a public API header, remove them in v5.0
12+
// Tracked in IDF-1968
1213
#if CONFIG_IDF_TARGET_ESP32
1314
#include "esp32/rom/rtc.h"
1415
#elif CONFIG_IDF_TARGET_ESP32S2
@@ -62,18 +63,37 @@ bool bootloader_common_ota_select_valid(const esp_ota_select_entry_t *s);
6263
bool bootloader_common_ota_select_invalid(const esp_ota_select_entry_t *s);
6364

6465
/**
65-
* @brief Check if the GPIO input is a long hold or a short hold.
66+
* @brief Check if a GPIO input is held low for a long period, short period, or not
67+
* at all.
68+
*
69+
* This function will configure the specified GPIO as an input with internal pull-up enabled.
6670
*
67-
* Number of the GPIO input will be configured as an input with internal pull-up enabled.
6871
* If the GPIO input is held low continuously for delay_sec period then it is a long hold.
6972
* If the GPIO input is held low for less period then it is a short hold.
7073
*
7174
* @param[in] num_pin Number of the GPIO input.
7275
* @param[in] delay_sec Input must be driven low for at least this long, continuously.
73-
* @return esp_comm_gpio_hold_t Defines type of hold a GPIO in low state.
76+
* @return esp_comm_gpio_hold_t Type of low level hold detected, if any.
7477
*/
7578
esp_comm_gpio_hold_t bootloader_common_check_long_hold_gpio(uint32_t num_pin, uint32_t delay_sec);
7679

80+
/**
81+
* @brief Check if a GPIO input is held low or high for a long period, short period, or not
82+
* at all.
83+
*
84+
* This function will configure the specified GPIO as an input with internal pull-up enabled.
85+
*
86+
* If the GPIO input is held at 'level' continuously for delay_sec period then it is a long hold.
87+
* If the GPIO input is held at 'level' for less period then it is a short hold.
88+
*
89+
* @param[in] num_pin Number of the GPIO input.
90+
* @param[in] delay_sec Input must be driven to 'level' for at least this long, continuously.
91+
* @param[in] level Input pin level to trigger on hold
92+
* @return esp_comm_gpio_hold_t Type of hold detected, if any.
93+
*/
94+
esp_comm_gpio_hold_t bootloader_common_check_long_hold_gpio_level(uint32_t num_pin, uint32_t delay_sec, bool level);
95+
96+
7797
/**
7898
* @brief Erase the partition data that is specified in the transferred list.
7999
*

Diff for: tools/sdk/esp32/include/bt/include/esp32/include/esp_bt.h

+32
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,38 @@
2525
extern "C" {
2626
#endif
2727

28+
#ifdef CONFIG_BT_ENABLED
29+
30+
#define SOC_MEM_BT_DATA_START 0x3ffae6e0
31+
#define SOC_MEM_BT_DATA_END 0x3ffaff10
32+
#define SOC_MEM_BT_EM_START 0x3ffb0000
33+
#define SOC_MEM_BT_EM_END 0x3ffb7cd8
34+
#define SOC_MEM_BT_EM_BTDM0_START 0x3ffb0000
35+
#define SOC_MEM_BT_EM_BTDM0_END 0x3ffb09a8
36+
#define SOC_MEM_BT_EM_BLE_START 0x3ffb09a8
37+
#define SOC_MEM_BT_EM_BLE_END 0x3ffb1ddc
38+
#define SOC_MEM_BT_EM_BTDM1_START 0x3ffb1ddc
39+
#define SOC_MEM_BT_EM_BTDM1_END 0x3ffb2730
40+
#define SOC_MEM_BT_EM_BREDR_START 0x3ffb2730
41+
#define SOC_MEM_BT_EM_BREDR_NO_SYNC_END 0x3ffb6388 //Not calculate with synchronize connection support
42+
#define SOC_MEM_BT_EM_BREDR_END 0x3ffb7cd8 //Calculate with synchronize connection support
43+
#define SOC_MEM_BT_EM_SYNC0_START 0x3ffb6388
44+
#define SOC_MEM_BT_EM_SYNC0_END 0x3ffb6bf8
45+
#define SOC_MEM_BT_EM_SYNC1_START 0x3ffb6bf8
46+
#define SOC_MEM_BT_EM_SYNC1_END 0x3ffb7468
47+
#define SOC_MEM_BT_EM_SYNC2_START 0x3ffb7468
48+
#define SOC_MEM_BT_EM_SYNC2_END 0x3ffb7cd8
49+
#define SOC_MEM_BT_BSS_START 0x3ffb8000
50+
#define SOC_MEM_BT_BSS_END 0x3ffb9a20
51+
#define SOC_MEM_BT_MISC_START 0x3ffbdb28
52+
#define SOC_MEM_BT_MISC_END 0x3ffbdb5c
53+
54+
#define SOC_MEM_BT_EM_PER_SYNC_SIZE 0x870
55+
56+
#define SOC_MEM_BT_EM_BREDR_REAL_END (SOC_MEM_BT_EM_BREDR_NO_SYNC_END + CONFIG_BTDM_CTRL_BR_EDR_MAX_SYNC_CONN_EFF * SOC_MEM_BT_EM_PER_SYNC_SIZE)
57+
58+
#endif //CONFIG_BT_ENABLED
59+
2860
#define ESP_BT_CONTROLLER_CONFIG_MAGIC_VAL 0x20200622
2961

3062
/**

Diff for: tools/sdk/esp32/include/config/sdkconfig.h

+5-1
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,8 @@
327327
#define CONFIG_FMB_SERIAL_ASCII_BITS_PER_SYMB 8
328328
#define CONFIG_FMB_SERIAL_ASCII_TIMEOUT_RESPOND_MS 1000
329329
#define CONFIG_FMB_PORT_TASK_PRIO 10
330+
#define CONFIG_FMB_PORT_TASK_AFFINITY_CPU0 1
331+
#define CONFIG_FMB_PORT_TASK_AFFINITY 0x0
330332
#define CONFIG_FMB_CONTROLLER_NOTIFY_TIMEOUT 20
331333
#define CONFIG_FMB_CONTROLLER_NOTIFY_QUEUE_SIZE 20
332334
#define CONFIG_FMB_CONTROLLER_STACK_SIZE 4096
@@ -454,6 +456,8 @@
454456
#define CONFIG_MBEDTLS_SSL_PROTO_DTLS 1
455457
#define CONFIG_MBEDTLS_SSL_ALPN 1
456458
#define CONFIG_MBEDTLS_CLIENT_SSL_SESSION_TICKETS 1
459+
#define CONFIG_MBEDTLS_X509_CHECK_KEY_USAGE 1
460+
#define CONFIG_MBEDTLS_X509_CHECK_EXTENDED_KEY_USAGE 1
457461
#define CONFIG_MBEDTLS_SERVER_SSL_SESSION_TICKETS 1
458462
#define CONFIG_MBEDTLS_AES_C 1
459463
#define CONFIG_MBEDTLS_RC4_DISABLED 1
@@ -686,5 +690,5 @@
686690
#define CONFIG_ULP_COPROC_ENABLED CONFIG_ESP32_ULP_COPROC_ENABLED
687691
#define CONFIG_ULP_COPROC_RESERVE_MEM CONFIG_ESP32_ULP_COPROC_RESERVE_MEM
688692
#define CONFIG_WARN_WRITE_STRINGS CONFIG_COMPILER_WARN_WRITE_STRINGS
689-
#define CONFIG_ARDUINO_IDF_COMMIT "d93887f9f"
693+
#define CONFIG_ARDUINO_IDF_COMMIT "c69f0ec32"
690694
#define CONFIG_ARDUINO_IDF_BRANCH "master"

Diff for: tools/sdk/esp32/include/console/esp_console.h

+2
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ typedef struct {
4848
uint32_t task_stack_size; //!< repl task stack size
4949
uint32_t task_priority; //!< repl task priority
5050
const char *prompt; //!< prompt (NULL represents default: "esp> ")
51+
size_t max_cmdline_length; //!< maximum length of a command line. If 0, default value will be used
5152
} esp_console_repl_config_t;
5253

5354
/**
@@ -61,6 +62,7 @@ typedef struct {
6162
.task_stack_size = 4096, \
6263
.task_priority = 2, \
6364
.prompt = NULL, \
65+
.max_cmdline_length = 0, \
6466
}
6567

6668
/**

Diff for: tools/sdk/esp32/include/console/linenoise/linenoise.h

+1
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ void linenoiseSetDumbMode(int set);
7272
bool linenoiseIsDumbMode(void);
7373
void linenoisePrintKeyCodes(void);
7474
void linenoiseAllowEmpty(bool);
75+
int linenoiseSetMaxLineLen(size_t len);
7576

7677
#ifdef __cplusplus
7778
}

Diff for: tools/sdk/esp32/include/driver/include/driver/i2c.h

+7-6
Original file line numberDiff line numberDiff line change
@@ -74,14 +74,15 @@ typedef struct{
7474

7575
union {
7676
struct {
77-
uint32_t clk_speed; /*!< I2C clock frequency for master mode, (no higher than 1MHz for now) */
78-
} master; /*!< I2C master config */
77+
uint32_t clk_speed; /*!< I2C clock frequency for master mode, (no higher than 1MHz for now) */
78+
} master; /*!< I2C master config */
7979
struct {
80-
uint8_t addr_10bit_en; /*!< I2C 10bit address mode enable for slave mode */
81-
uint16_t slave_addr; /*!< I2C address for slave mode */
82-
} slave; /*!< I2C slave config */
80+
uint8_t addr_10bit_en; /*!< I2C 10bit address mode enable for slave mode */
81+
uint16_t slave_addr; /*!< I2C address for slave mode */
82+
uint32_t maximum_speed; /*!< I2C expected clock speed from SCL. */
83+
} slave; /*!< I2C slave config */
8384
};
84-
uint32_t clk_flags; /*!< Bitwise of ``I2C_SCLK_SRC_FLAG_**FOR_DFS**`` for clk source choice*/
85+
uint32_t clk_flags; /*!< Bitwise of ``I2C_SCLK_SRC_FLAG_**FOR_DFS**`` for clk source choice*/
8586
} i2c_config_t;
8687

8788

Diff for: tools/sdk/esp32/include/driver/include/driver/spi_master.h

+5-3
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ typedef struct {
105105
#define SPI_TRANS_VARIABLE_ADDR (1<<6) ///< Use the ``address_bits`` in ``spi_transaction_ext_t`` rather than default value in ``spi_device_interface_config_t``.
106106
#define SPI_TRANS_VARIABLE_DUMMY (1<<7) ///< Use the ``dummy_bits`` in ``spi_transaction_ext_t`` rather than default value in ``spi_device_interface_config_t``.
107107
#define SPI_TRANS_SET_CD (1<<7) ///< Set the CD pin
108-
108+
#define SPI_TRANS_CS_KEEP_ACTIVE (1<<8) ///< Keep CS active after data transfer
109109
/**
110110
* This structure describes one SPI transaction. The descriptor should not be modified until the transaction finishes.
111111
*/
@@ -194,7 +194,8 @@ esp_err_t spi_bus_remove_device(spi_device_handle_t handle);
194194
* @param ticks_to_wait Ticks to wait until there's room in the queue; use portMAX_DELAY to
195195
* never time out.
196196
* @return
197-
* - ESP_ERR_INVALID_ARG if parameter is invalid
197+
* - ESP_ERR_INVALID_ARG if parameter is invalid. This can happen if SPI_DEVICE_CS_KEEP_LOW flag is specified while
198+
* the bus was not acquired (`spi_device_acquire_bus()` should be called first)
198199
* - ESP_ERR_TIMEOUT if there was no room in the queue before ticks_to_wait expired
199200
* - ESP_ERR_NO_MEM if allocating DMA-capable temporary buffer failed
200201
* - ESP_ERR_INVALID_STATE if previous transactions are not finished
@@ -257,7 +258,8 @@ esp_err_t spi_device_transmit(spi_device_handle_t handle, spi_transaction_t *tra
257258
* currently only portMAX_DELAY is supported.
258259
*
259260
* @return
260-
* - ESP_ERR_INVALID_ARG if parameter is invalid
261+
* - ESP_ERR_INVALID_ARG if parameter is invalid. This can happen if SPI_DEVICE_CS_KEEP_LOW flag is specified while
262+
* the bus was not acquired (`spi_device_acquire_bus()` should be called first)
261263
* - ESP_ERR_TIMEOUT if the device cannot get control of the bus before ``ticks_to_wait`` expired
262264
* - ESP_ERR_NO_MEM if allocating DMA-capable temporary buffer failed
263265
* - ESP_ERR_INVALID_STATE if previous transactions are not finished

Diff for: tools/sdk/esp32/include/driver/include/esp_private/gdma.h

+31-2
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,8 @@ typedef enum {
3838
GDMA_TRIG_PERIPH_ADC, /*!< GDMA trigger peripheral: ADC */
3939
GDMA_TRIG_PERIPH_DAC, /*!< GDMA trigger peripheral: DAC */
4040
GDMA_TRIG_PERIPH_LCD, /*!< GDMA trigger peripheral: LCD */
41-
GDMA_TRIG_PERIPH_CAM /*!< GDMA trigger peripheral: CAM */
41+
GDMA_TRIG_PERIPH_CAM, /*!< GDMA trigger peripheral: CAM */
42+
GDMA_TRIG_PERIPH_RMT, /*!< GDMA trigger peripheral: RMT */
4243
} gdma_trigger_peripheral_t;
4344

4445
/**
@@ -58,10 +59,23 @@ typedef struct {
5859
gdma_channel_handle_t sibling_chan; /*!< DMA sibling channel handle (NULL means having sibling is not necessary) */
5960
gdma_channel_direction_t direction; /*!< DMA channel direction */
6061
struct {
61-
int reserve_sibling: 1; /*!< If set, DMA channel allocator would prefer to allocate new channel in a new pair, and reserve sibling channel for future use */
62+
int reserve_sibling: 1; /*!< If set, DMA channel allocator would prefer to allocate new channel in a new pair, and reserve sibling channel for future use */
6263
} flags;
6364
} gdma_channel_alloc_config_t;
6465

66+
/**
67+
* @brief GDMA transfer ability
68+
*
69+
* @note The alignment set in this structure is **not** a guarantee that gdma driver will take care of the nonalignment cases.
70+
* Actually the GDMA driver has no knowledge about the DMA buffer (address and size) used by upper layer.
71+
* So it's the responsibility of the **upper layer** to take care of the buffer address and size.
72+
*
73+
*/
74+
typedef struct {
75+
size_t sram_trans_align; /*!< DMA transfer alignment for memory in SRAM, in bytes. The driver enables/disables burst mode based on this value. 0 means no alignment is required */
76+
size_t psram_trans_align; /*!< DMA transfer alignment for memory in PSRAM, in bytes. The driver sets proper burst block size based on the alignment value. 0 means no alignment is required */
77+
} gdma_transfer_ability_t;
78+
6579
/**
6680
* @brief Type of GDMA event data
6781
*
@@ -79,6 +93,9 @@ typedef struct {
7993
* @param event_data GDMA event data
8094
* @param user_data User registered data from `gdma_register_tx_event_callbacks` or `gdma_register_rx_event_callbacks`
8195
*
96+
* @return Whether a task switch is needed after the callback function returns,
97+
* this is usually due to the callback wakes up some high priority task.
98+
*
8299
*/
83100
typedef bool (*gdma_event_callback_t)(gdma_channel_handle_t dma_chan, gdma_event_data_t *event_data, void *user_data);
84101

@@ -171,6 +188,18 @@ esp_err_t gdma_connect(gdma_channel_handle_t dma_chan, gdma_trigger_t trig_perip
171188
*/
172189
esp_err_t gdma_disconnect(gdma_channel_handle_t dma_chan);
173190

191+
/**
192+
* @brief Set DMA channel transfer ability
193+
*
194+
* @param[in] dma_chan GDMA channel handle, allocated by `gdma_new_channel`
195+
* @param[in] ability Transfer ability, e.g. alignment
196+
* @return
197+
* - ESP_OK: Set DMA channel transfer ability successfully
198+
* - ESP_ERR_INVALID_ARG: Set DMA channel transfer ability failed because of invalid argument
199+
* - ESP_FAIL: Set DMA channel transfer ability failed because of other error
200+
*/
201+
esp_err_t gdma_set_transfer_ability(gdma_channel_handle_t dma_chan, const gdma_transfer_ability_t *ability);
202+
174203
/**
175204
* @brief Apply channel strategy for GDMA channel
176205
*

0 commit comments

Comments
 (0)