diff --git a/components/bt/esp_ble_mesh/mesh_core/prov.c b/components/bt/esp_ble_mesh/mesh_core/prov.c index c83bfed91b2f..4e9813f7c60f 100644 --- a/components/bt/esp_ble_mesh/mesh_core/prov.c +++ b/components/bt/esp_ble_mesh/mesh_core/prov.c @@ -74,6 +74,7 @@ #define START_PAYLOAD_MAX 20 #define CONT_PAYLOAD_MAX 23 +#define START_LAST_SEG_MAX 2 #define START_LAST_SEG(gpc) (gpc >> 2) #define CONT_SEG_INDEX(gpc) (gpc >> 2) @@ -1563,6 +1564,12 @@ static void gen_prov_start(struct prov_rx *rx, struct net_buf_simple *buf) return; } + if (START_LAST_SEG(rx->gpc) > START_LAST_SEG_MAX) { + BT_ERR("Invalid SegN 0x%02x", START_LAST_SEG(rx->gpc)); + prov_send_fail_msg(PROV_ERR_UNEXP_ERR); + return; + } + if (link.rx.buf->len > link.rx.buf->size) { BT_ERR("Too large provisioning PDU (%u bytes)", link.rx.buf->len); diff --git a/components/bt/esp_ble_mesh/mesh_core/provisioner_prov.c b/components/bt/esp_ble_mesh/mesh_core/provisioner_prov.c index 6a8038462469..4945e1faee0e 100644 --- a/components/bt/esp_ble_mesh/mesh_core/provisioner_prov.c +++ b/components/bt/esp_ble_mesh/mesh_core/provisioner_prov.c @@ -74,6 +74,7 @@ _Static_assert(BLE_MESH_MAX_CONN >= CONFIG_BLE_MESH_PBG_SAME_TIME, #define START_PAYLOAD_MAX 20 #define CONT_PAYLOAD_MAX 23 +#define START_LAST_SEG_MAX 2 #define START_LAST_SEG(gpc) (gpc >> 2) #define CONT_SEG_INDEX(gpc) (gpc >> 2) @@ -2980,6 +2981,12 @@ static void gen_prov_start(const uint8_t idx, struct prov_rx *rx, struct net_buf return; } + if (START_LAST_SEG(rx->gpc) > START_LAST_SEG_MAX) { + BT_ERR("Invalid SegN 0x%02x", START_LAST_SEG(rx->gpc)); + close_link(idx, CLOSE_REASON_FAILED); + return; + } + if (link[idx].rx.buf->len > link[idx].rx.buf->size) { BT_ERR("Too large provisioning PDU (%u bytes)", link[idx].rx.buf->len); diff --git a/components/bt/host/bluedroid/btc/profile/std/spp/btc_spp.c b/components/bt/host/bluedroid/btc/profile/std/spp/btc_spp.c index 41afac4a9d39..025500407f00 100644 --- a/components/bt/host/bluedroid/btc/profile/std/spp/btc_spp.c +++ b/components/bt/host/bluedroid/btc/profile/std/spp/btc_spp.c @@ -519,6 +519,7 @@ static void btc_spp_init(btc_spp_args_t *arg) } if ((spp_local_param.tx_event_group = xEventGroupCreate()) == NULL) { BTC_TRACE_ERROR("%s create tx_event_group failed\n", __func__); + osi_mutex_free(&spp_local_param.spp_slot_mutex); ret = ESP_SPP_NO_RESOURCE; break; } @@ -582,11 +583,6 @@ static void btc_spp_uninit(void) osi_mutex_unlock(&spp_local_param.spp_slot_mutex); } while(0); - if (spp_local_param.tx_event_group) { - vEventGroupDelete(spp_local_param.tx_event_group); - spp_local_param.tx_event_group = NULL; - } - if (ret != ESP_SPP_SUCCESS) { esp_spp_cb_param_t param; param.uninit.status = ret; @@ -1256,6 +1252,10 @@ void btc_spp_cb_handler(btc_msg_t *msg) param.uninit.status = ESP_SPP_SUCCESS; BTA_JvFree(); osi_mutex_free(&spp_local_param.spp_slot_mutex); + if (spp_local_param.tx_event_group) { + vEventGroupDelete(spp_local_param.tx_event_group); + spp_local_param.tx_event_group = NULL; + } #if SPP_DYNAMIC_MEMORY == TRUE osi_free(spp_local_param_ptr); spp_local_param_ptr = NULL; diff --git a/components/bt/host/bluedroid/stack/btu/btu_hcif.c b/components/bt/host/bluedroid/stack/btu/btu_hcif.c index 6abbdedb7b4b..a64d5da0f818 100644 --- a/components/bt/host/bluedroid/stack/btu/btu_hcif.c +++ b/components/bt/host/bluedroid/stack/btu/btu_hcif.c @@ -1598,6 +1598,11 @@ static void btu_hcif_ssr_evt_dump (UINT8 *p, UINT16 evt_len) STREAM_TO_UINT16 (max_tx_lat, p); STREAM_TO_UINT16 (max_rx_lat, p); + UNUSED(status); + UNUSED(handle); + UNUSED(max_tx_lat); + UNUSED(max_rx_lat); + HCI_TRACE_WARNING("hcif ssr evt: st 0x%x, hdl 0x%x, tx_lat %d rx_lat %d", status, handle, max_tx_lat, max_rx_lat); } #endif @@ -1962,6 +1967,9 @@ static void btu_hcif_link_supv_to_changed_evt (UINT8 *p) STREAM_TO_UINT16(handle, p); STREAM_TO_UINT16(supv_to, p); + UNUSED(handle); + UNUSED(supv_to); + HCI_TRACE_WARNING("hcif link supv_to changed: hdl 0x%x, supv_to %d", handle, supv_to); } diff --git a/components/driver/include/driver/gpio.h b/components/driver/include/driver/gpio.h index eeb63f74f8e9..089b500ce204 100644 --- a/components/driver/include/driver/gpio.h +++ b/components/driver/include/driver/gpio.h @@ -498,7 +498,8 @@ esp_err_t gpio_sleep_set_pull_mode(gpio_num_t gpio_num, gpio_pull_mode_t pull); #if SOC_GPIO_SUPPORT_DEEPSLEEP_WAKEUP -#define GPIO_IS_DEEP_SLEEP_WAKEUP_VALID_GPIO(gpio_num) ((gpio_num & ~SOC_GPIO_DEEP_SLEEP_WAKEUP_VALID_GPIO_MASK) == 0) +#define GPIO_IS_DEEP_SLEEP_WAKEUP_VALID_GPIO(gpio_num) ((gpio_num >= 0) && \ + (((1ULL << (gpio_num)) & SOC_GPIO_DEEP_SLEEP_WAKEUP_VALID_GPIO_MASK) != 0)) /** * @brief Enable GPIO deep-sleep wake-up function. diff --git a/components/esp_phy/esp32c3/include/phy_init_data.h b/components/esp_phy/esp32c3/include/phy_init_data.h index 7e458c43117e..212cd582de81 100644 --- a/components/esp_phy/esp32c3/include/phy_init_data.h +++ b/components/esp_phy/esp32c3/include/phy_init_data.h @@ -20,8 +20,8 @@ extern "C" { // define the lowest tx power as LOWEST_PHY_TX_POWER #define PHY_TX_POWER_LOWEST LIMIT(CONFIG_ESP_PHY_MAX_TX_POWER * 4, 0, 52) -#define PHY_TX_POWER_OFFSET 44 -#define PHY_TX_POWER_NUM 5 +#define PHY_TX_POWER_OFFSET 2 +#define PHY_TX_POWER_NUM 14 #if CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN #define PHY_CRC_ALGORITHM 1 diff --git a/components/esp_phy/esp32s2/include/phy_init_data.h b/components/esp_phy/esp32s2/include/phy_init_data.h index e1aa8d461381..5128a8656926 100644 --- a/components/esp_phy/esp32s2/include/phy_init_data.h +++ b/components/esp_phy/esp32s2/include/phy_init_data.h @@ -20,8 +20,8 @@ extern "C" { // define the lowest tx power as LOWEST_PHY_TX_POWER #define PHY_TX_POWER_LOWEST LIMIT(CONFIG_ESP_PHY_MAX_TX_POWER * 4, 0, 52) -#define PHY_TX_POWER_OFFSET 44 -#define PHY_TX_POWER_NUM 5 +#define PHY_TX_POWER_OFFSET 2 +#define PHY_TX_POWER_NUM 14 #if CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN #define PHY_CRC_ALGORITHM 1 diff --git a/components/esp_phy/esp32s3/include/phy_init_data.h b/components/esp_phy/esp32s3/include/phy_init_data.h index 88f56282d580..4f2b6694502b 100644 --- a/components/esp_phy/esp32s3/include/phy_init_data.h +++ b/components/esp_phy/esp32s3/include/phy_init_data.h @@ -20,8 +20,8 @@ extern "C" { // define the lowest tx power as LOWEST_PHY_TX_POWER #define PHY_TX_POWER_LOWEST LIMIT(CONFIG_ESP_PHY_MAX_TX_POWER * 4, 0, 52) -#define PHY_TX_POWER_OFFSET 44 -#define PHY_TX_POWER_NUM 5 +#define PHY_TX_POWER_OFFSET 2 +#define PHY_TX_POWER_NUM 14 #if CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN #define PHY_CRC_ALGORITHM 1 diff --git a/components/esp_phy/src/phy_init.c b/components/esp_phy/src/phy_init.c index 449160f165cb..ae9aba8b2800 100644 --- a/components/esp_phy/src/phy_init.c +++ b/components/esp_phy/src/phy_init.c @@ -349,8 +349,6 @@ IRAM_ATTR void esp_mac_bb_power_down(void) const esp_phy_init_data_t* esp_phy_get_init_data(void) { - esp_err_t err = ESP_OK; - const esp_partition_t* partition = NULL; #if CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN_EMBED size_t init_data_store_length = sizeof(phy_init_magic_pre) + sizeof(esp_phy_init_data_t) + sizeof(phy_init_magic_post); @@ -362,7 +360,7 @@ const esp_phy_init_data_t* esp_phy_get_init_data(void) memcpy(init_data_store, multi_phy_init_data_bin_start, init_data_store_length); ESP_LOGI(TAG, "loading embedded multiple PHY init data"); #else - partition = esp_partition_find_first( + const esp_partition_t* partition = esp_partition_find_first( ESP_PARTITION_TYPE_DATA, ESP_PARTITION_SUBTYPE_DATA_PHY, NULL); if (partition == NULL) { ESP_LOGE(TAG, "PHY data partition not found"); @@ -377,7 +375,7 @@ const esp_phy_init_data_t* esp_phy_get_init_data(void) return NULL; } // read phy data from flash - err = esp_partition_read(partition, 0, init_data_store, init_data_store_length); + esp_err_t err = esp_partition_read(partition, 0, init_data_store, init_data_store_length); if (err != ESP_OK) { ESP_LOGE(TAG, "failed to read PHY data partition (0x%x)", err); free(init_data_store); @@ -388,6 +386,11 @@ const esp_phy_init_data_t* esp_phy_get_init_data(void) if (memcmp(init_data_store, PHY_INIT_MAGIC, sizeof(phy_init_magic_pre)) != 0 || memcmp(init_data_store + init_data_store_length - sizeof(phy_init_magic_post), PHY_INIT_MAGIC, sizeof(phy_init_magic_post)) != 0) { +#if CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN_EMBED + ESP_LOGE(TAG, "failed to validate embedded PHY init data"); + free(init_data_store); + return NULL; +#else #ifndef CONFIG_ESP_PHY_DEFAULT_INIT_IF_INVALID ESP_LOGE(TAG, "failed to validate PHY data partition"); free(init_data_store); @@ -414,6 +417,7 @@ const esp_phy_init_data_t* esp_phy_get_init_data(void) return NULL; } #endif // CONFIG_ESP_PHY_DEFAULT_INIT_IF_INVALID +#endif // CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN_EMBED } #if CONFIG_ESP_PHY_MULTIPLE_INIT_DATA_BIN if ((*(init_data_store + (sizeof(phy_init_magic_pre) + PHY_SUPPORT_MULTIPLE_BIN_OFFSET)))) { @@ -603,7 +607,6 @@ static esp_err_t store_cal_data_to_nvs_handle(nvs_handle_t handle, } #if CONFIG_ESP_PHY_REDUCE_TX_POWER -// TODO: fix the esp_phy_reduce_tx_power unused warning for esp32s2 - IDF-759 static void __attribute((unused)) esp_phy_reduce_tx_power(esp_phy_init_data_t* init_data) { uint8_t i; diff --git a/components/esp_pm/pm_impl.c b/components/esp_pm/pm_impl.c index 55d234c370d7..239390789e6d 100644 --- a/components/esp_pm/pm_impl.c +++ b/components/esp_pm/pm_impl.c @@ -831,8 +831,8 @@ void esp_pm_impl_waiti(void) * the lock so that vApplicationSleep can attempt to enter light sleep. */ esp_pm_impl_idle_hook(); - s_skipped_light_sleep[core_id] = false; } + s_skipped_light_sleep[core_id] = true; #else cpu_hal_waiti(); #endif // CONFIG_FREERTOS_USE_TICKLESS_IDLE diff --git a/components/esp_wifi/include/esp_wifi.h b/components/esp_wifi/include/esp_wifi.h index bcd10c77a105..3d62c5c297c2 100644 --- a/components/esp_wifi/include/esp_wifi.h +++ b/components/esp_wifi/include/esp_wifi.h @@ -1295,6 +1295,19 @@ esp_err_t esp_wifi_get_country_code(char *country); */ esp_err_t esp_wifi_config_80211_tx_rate(wifi_interface_t ifx, wifi_phy_rate_t rate); +/** + * @brief Disable PMF configuration for specified interface + * + * @attention This API should be called after esp_wifi_set_config() and before esp_wifi_start(). + * + * @param ifx Interface to be configured. + * + * @return + * - ESP_OK: succeed + * - others: failed + */ +esp_err_t esp_wifi_disable_pmf_config(wifi_interface_t ifx); + #ifdef __cplusplus } #endif diff --git a/components/esp_wifi/lib b/components/esp_wifi/lib index 5a0d2aee4963..1b0fcf9eeb96 160000 --- a/components/esp_wifi/lib +++ b/components/esp_wifi/lib @@ -1 +1 @@ -Subproject commit 5a0d2aee49633b1a0c0374c2a01ed8c2a10e2fe4 +Subproject commit 1b0fcf9eeb96ddc4d72ab5850a0bf9e95e289da4 diff --git a/components/esp_wifi/src/wifi_default.c b/components/esp_wifi/src/wifi_default.c index f2adf70f3e89..4cb7a10b54e2 100644 --- a/components/esp_wifi/src/wifi_default.c +++ b/components/esp_wifi/src/wifi_default.c @@ -236,6 +236,8 @@ esp_err_t esp_wifi_clear_default_wifi_driver_and_handlers(void *esp_netif) if (s_wifi_netifs[i] == esp_netif) { s_wifi_netifs[i] = NULL; } + } + for (i = 0; i< MAX_WIFI_IFS; ++i) { // check if all netifs are cleared to delete default handlers if (s_wifi_netifs[i] != NULL) { break; diff --git a/components/mqtt/esp-mqtt b/components/mqtt/esp-mqtt index 89894bd0c611..985078affa8a 160000 --- a/components/mqtt/esp-mqtt +++ b/components/mqtt/esp-mqtt @@ -1 +1 @@ -Subproject commit 89894bd0c611b1392967fe90bb49682eba858383 +Subproject commit 985078affa8a2d2b56b87c8e6455252850f895c6 diff --git a/docs/en/api-reference/bluetooth/controller_vhci.rst b/docs/en/api-reference/bluetooth/controller_vhci.rst index 22fb3f7903a1..6fc65df49777 100644 --- a/docs/en/api-reference/bluetooth/controller_vhci.rst +++ b/docs/en/api-reference/bluetooth/controller_vhci.rst @@ -1,13 +1,6 @@ Controller && VHCI ================== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - Application Example ------------------- diff --git a/docs/en/api-reference/bluetooth/esp_a2dp.rst b/docs/en/api-reference/bluetooth/esp_a2dp.rst index 8dea862fc179..e3b5c511666e 100644 --- a/docs/en/api-reference/bluetooth/esp_a2dp.rst +++ b/docs/en/api-reference/bluetooth/esp_a2dp.rst @@ -1,13 +1,6 @@ Bluetooth A2DP API ================== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - Application Example ------------------- diff --git a/docs/en/api-reference/bluetooth/esp_avrc.rst b/docs/en/api-reference/bluetooth/esp_avrc.rst index 1c15c7b69c8f..7b8fa6f6e92a 100644 --- a/docs/en/api-reference/bluetooth/esp_avrc.rst +++ b/docs/en/api-reference/bluetooth/esp_avrc.rst @@ -6,15 +6,6 @@ Overview Bluetooth AVRCP reference APIs. -`Instructions`_ - -Application Example -------------------- - -`Instructions`_ - -.. _Instructions: ../template.html - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_bt_defs.rst b/docs/en/api-reference/bluetooth/esp_bt_defs.rst index 85e73d0688fb..58400242ce8a 100644 --- a/docs/en/api-reference/bluetooth/esp_bt_defs.rst +++ b/docs/en/api-reference/bluetooth/esp_bt_defs.rst @@ -1,19 +1,6 @@ BT GENERIC DEFINES ================== -Overview --------- - -`Instructions`_ - -Application Example -------------------- - -`Instructions`_ - -.. _Instructions: ../template.html - - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_bt_device.rst b/docs/en/api-reference/bluetooth/esp_bt_device.rst index b234cea14c30..d135e21340df 100644 --- a/docs/en/api-reference/bluetooth/esp_bt_device.rst +++ b/docs/en/api-reference/bluetooth/esp_bt_device.rst @@ -6,15 +6,6 @@ Overview Bluetooth device reference APIs. -`Instructions`_ - -Application Example -------------------- - -`Instructions`_ - -.. _Instructions: ../template.html - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_bt_main.rst b/docs/en/api-reference/bluetooth/esp_bt_main.rst index 321f9331e2ec..2955ee57d083 100644 --- a/docs/en/api-reference/bluetooth/esp_bt_main.rst +++ b/docs/en/api-reference/bluetooth/esp_bt_main.rst @@ -1,19 +1,6 @@ BT MAIN API =========== -Overview --------- - -`Instructions`_ - -Application Example -------------------- - -`Instructions`_ - -.. _Instructions: ../template.html - - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_gap_ble.rst b/docs/en/api-reference/bluetooth/esp_gap_ble.rst index 8f95906853b6..8d539dfdccc4 100644 --- a/docs/en/api-reference/bluetooth/esp_gap_ble.rst +++ b/docs/en/api-reference/bluetooth/esp_gap_ble.rst @@ -1,13 +1,6 @@ GAP API ======= -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - Application Example ------------------- @@ -18,7 +11,7 @@ Check :example:`bluetooth/bluedroid/ble` folder in ESP-IDF examples, which conta - :example:`bluetooth/bluedroid/ble/gatt_security_client` - :example_file:`GATT Security Client Example Walkthrough ` -* This is a SMP security server demo and its tutorial. This demo initiates its security parameters and acts as a GATT server, which can send a pair request to the peer device and then complete the encryption procedure. +* This is a SMP security server demo and its tutorial. This demo initiates its security parameters and acts as a GATT server, which can send a pair request to the peer device and then complete the encryption procedure. - :example:`bluetooth/bluedroid/ble/gatt_security_server` - :example_file:`GATT Security Server Example Walkthrough ` diff --git a/docs/en/api-reference/bluetooth/esp_gap_bt.rst b/docs/en/api-reference/bluetooth/esp_gap_bt.rst index 346f7ec90a16..1466f6b766a3 100644 --- a/docs/en/api-reference/bluetooth/esp_gap_bt.rst +++ b/docs/en/api-reference/bluetooth/esp_gap_bt.rst @@ -1,18 +1,6 @@ CLASSIC BLUETOOTH GAP API ========================= -Overview --------- - -`Instructions`_ - -Application Example -------------------- - -`Instructions`_ - -.. _Instructions: ../template.html - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_gatt_defs.rst b/docs/en/api-reference/bluetooth/esp_gatt_defs.rst index 931802126fd1..8b6a31ba57ed 100644 --- a/docs/en/api-reference/bluetooth/esp_gatt_defs.rst +++ b/docs/en/api-reference/bluetooth/esp_gatt_defs.rst @@ -1,18 +1,6 @@ GATT DEFINES ============ -Overview --------- - -`Instructions`_ - -Application Example -------------------- - -`Instructions`_ - -.. _Instructions: ../template.html - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_gattc.rst b/docs/en/api-reference/bluetooth/esp_gattc.rst index 708888d2b5d2..bb511d196f4a 100644 --- a/docs/en/api-reference/bluetooth/esp_gattc.rst +++ b/docs/en/api-reference/bluetooth/esp_gattc.rst @@ -1,24 +1,17 @@ GATT CLIENT API =============== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - Application Example ------------------- Check :example:`bluetooth/bluedroid/ble` folder in ESP-IDF examples, which contains the following demos and their tutorials: -* This is a GATT client demo and its tutorial. This demo can scan for devices, connect to the GATT server and discover its services. +* This is a GATT client demo and its tutorial. This demo can scan for devices, connect to the GATT server and discover its services. - :example:`bluetooth/bluedroid/ble/gatt_client` - :example_file:`GATT Client Example Walkthrough ` -* This is a multiple connection demo and its tutorial. This demo can connect to multiple GATT server devices and discover their services. +* This is a multiple connection demo and its tutorial. This demo can connect to multiple GATT server devices and discover their services. - :example:`bluetooth/bluedroid/ble/gattc_multi_connect` - :example_file:`GATT Client Multi-connection Example Walkthrough ` diff --git a/docs/en/api-reference/bluetooth/esp_gatts.rst b/docs/en/api-reference/bluetooth/esp_gatts.rst index 1b48fccc8955..eb58060cbf48 100644 --- a/docs/en/api-reference/bluetooth/esp_gatts.rst +++ b/docs/en/api-reference/bluetooth/esp_gatts.rst @@ -1,19 +1,12 @@ GATT SERVER API =============== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - Application Example ------------------- Check :example:`bluetooth/bluedroid/ble` folder in ESP-IDF examples, which contains the following demos and their tutorials: -* This is a GATT sever demo and its tutorial. This demo creates a GATT service with an attribute table, which releases the user from adding attributes one by one. This is the recommended method of adding attributes. +* This is a GATT sever demo and its tutorial. This demo creates a GATT service with an attribute table, which releases the user from adding attributes one by one. This is the recommended method of adding attributes. - :example:`bluetooth/bluedroid/ble/gatt_server_service_table` - :example_file:`GATT Server Service Table Example Walkthrough ` diff --git a/docs/en/api-reference/bluetooth/esp_hf_client.rst b/docs/en/api-reference/bluetooth/esp_hf_client.rst index b79eb743f770..2a3f6d57a9a5 100644 --- a/docs/en/api-reference/bluetooth/esp_hf_client.rst +++ b/docs/en/api-reference/bluetooth/esp_hf_client.rst @@ -1,13 +1,6 @@ HFP CLIENT API ============== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_hf_defs.rst b/docs/en/api-reference/bluetooth/esp_hf_defs.rst index 4633a81f67e5..09152f3df604 100644 --- a/docs/en/api-reference/bluetooth/esp_hf_defs.rst +++ b/docs/en/api-reference/bluetooth/esp_hf_defs.rst @@ -1,13 +1,6 @@ HFP DEFINES =========== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - API Reference ------------- diff --git a/docs/en/api-reference/bluetooth/esp_spp.rst b/docs/en/api-reference/bluetooth/esp_spp.rst index ced53408990f..51ceadd50785 100644 --- a/docs/en/api-reference/bluetooth/esp_spp.rst +++ b/docs/en/api-reference/bluetooth/esp_spp.rst @@ -1,13 +1,6 @@ SPP API =============== -Overview --------- - -`Instructions`_ - -.. _Instructions: ../template.html - Application Example ------------------- diff --git a/tools/idf_tools.py b/tools/idf_tools.py index 69851be55df5..86e96e938582 100755 --- a/tools/idf_tools.py +++ b/tools/idf_tools.py @@ -96,6 +96,7 @@ class WindowsError(OSError): # type: ignore PLATFORM_WIN32 = 'win32' PLATFORM_WIN64 = 'win64' PLATFORM_MACOS = 'macos' +PLATFORM_MACOS_ARM64 = 'macos-arm64' PLATFORM_LINUX32 = 'linux-i686' PLATFORM_LINUX64 = 'linux-amd64' PLATFORM_LINUX_ARM32 = 'linux-armel' @@ -120,8 +121,8 @@ class WindowsError(OSError): # type: ignore 'osx': PLATFORM_MACOS, 'darwin': PLATFORM_MACOS, 'Darwin-x86_64': PLATFORM_MACOS, - # pretend it is x86_64 until Darwin-arm64 tool builds are available: - 'Darwin-arm64': PLATFORM_MACOS, + PLATFORM_MACOS_ARM64: PLATFORM_MACOS_ARM64, + 'Darwin-arm64': PLATFORM_MACOS_ARM64, # Linux PLATFORM_LINUX64: PLATFORM_LINUX64, 'linux64': PLATFORM_LINUX64, @@ -1416,10 +1417,11 @@ def action_install(args): # type: ignore tools_info = load_tools_info() tools_spec = args.tools # type: ignore targets = [] # type: list[str] + info('Current system platform: {}'.format(CURRENT_PLATFORM)) # Installing only single tools, no targets are specified. if 'required' in tools_spec: targets = clean_targets(args.targets) - info('Selected targets are: {}' .format(', '.join(get_user_defined_targets()))) + info('Selected targets are: {}'.format(', '.join(get_user_defined_targets()))) if not tools_spec or 'required' in tools_spec: # Installing tools for all ESP_targets required by the operating system. diff --git a/tools/tools.json b/tools/tools.json index a61ef727af41..62115bfc08ce 100644 --- a/tools/tools.json +++ b/tools/tools.json @@ -54,6 +54,11 @@ "size": 97807647, "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/xtensa-esp32-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" }, + "macos-arm64": { + "sha256": "dda3d7a43efd995d9a51d5a5741626dbf915df46078aef0b5aea7163ac82398b", + "size": 97807647, + "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/xtensa-esp32-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" + }, "name": "esp-2021r2-patch3-8.4.0", "status": "recommended", "win32": { @@ -123,6 +128,11 @@ "size": 98224709, "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/xtensa-esp32s2-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" }, + "macos-arm64": { + "sha256": "de9af641678c93775e932ee5ec4f478f8925cfc1ebc22e41adc4fb85430a0c35", + "size": 98224709, + "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/xtensa-esp32s2-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" + }, "name": "esp-2021r2-patch3-8.4.0", "status": "recommended", "win32": { @@ -192,6 +202,11 @@ "size": 98553473, "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/xtensa-esp32s3-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" }, + "macos-arm64": { + "sha256": "e5af78f05d3af07617805d06ebb45ff2fe9b6aed6970a84c35eea28a5d8d5e53", + "size": 98553473, + "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/xtensa-esp32s3-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" + }, "name": "esp-2021r2-patch3-8.4.0", "status": "recommended", "win32": { @@ -242,6 +257,11 @@ "size": 89888488, "url": "https://github.com/espressif/llvm-project/releases/download/esp-12.0.1-20210914/xtensa-esp32-elf-llvm12_0_1-esp-12.0.1-20210914-macos.tar.xz" }, + "macos-arm64": { + "sha256": "6e7413e5fa515e403859ecf5301bdcdc3f8bf12c5de9aecaa11e9f17f32b05db", + "size": 89888488, + "url": "https://github.com/espressif/llvm-project/releases/download/esp-12.0.1-20210914/xtensa-esp32-elf-llvm12_0_1-esp-12.0.1-20210914-macos.tar.xz" + }, "name": "12.0.1-d9341b81fc", "status": "recommended", "win64": { @@ -309,6 +329,11 @@ "size": 113703959, "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/riscv32-esp-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" }, + "macos-arm64": { + "sha256": "4aacc1742a76349d790b1ac8e9e9d963daefda5346dbd6741cfe8e7a35a44e4e", + "size": 113703959, + "url": "https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/riscv32-esp-elf-gcc8_4_0-esp-2021r2-patch3-macos.tar.gz" + }, "name": "esp-2021r2-patch3-8.4.0", "status": "recommended", "win32": { @@ -371,6 +396,11 @@ "size": 8872874, "url": "https://github.com/espressif/binutils-esp32ulp/releases/download/v2.28.51-esp-20191205/binutils-esp32ulp-macos-2.28.51-esp-20191205.tar.gz" }, + "macos-arm64": { + "sha256": "a35d9e7a0445247c7fc9dccd3fbc35682f0fafc28beeb10c94b59466317190c4", + "size": 8872874, + "url": "https://github.com/espressif/binutils-esp32ulp/releases/download/v2.28.51-esp-20191205/binutils-esp32ulp-macos-2.28.51-esp-20191205.tar.gz" + }, "name": "2.28.51-esp-20191205", "status": "recommended", "win32": { @@ -434,6 +464,11 @@ "size": 8876194, "url": "https://github.com/espressif/binutils-esp32ulp/releases/download/v2.28.51-esp-20191205/binutils-esp32s2ulp-macos-2.28.51-esp-20191205.tar.gz" }, + "macos-arm64": { + "sha256": "5a9bb678a5246638cbda303f523d9bb8121a9a24dc01ecb22c21c46c41184155", + "size": 8876194, + "url": "https://github.com/espressif/binutils-esp32ulp/releases/download/v2.28.51-esp-20191205/binutils-esp32s2ulp-macos-2.28.51-esp-20191205.tar.gz" + }, "name": "2.28.51-esp-20191205", "status": "recommended", "win32": { @@ -478,7 +513,8 @@ ] ], "platforms": [ - "macos" + "macos", + "macos-arm64" ] } ], @@ -513,6 +549,11 @@ "size": 66311879, "url": "https://github.com/Kitware/CMake/releases/download/v3.20.3/cmake-3.20.3-macos-universal.tar.gz" }, + "macos-arm64": { + "sha256": "5f72dba3aa5f3800fb29ab6115ae0b31f10bdb2aad66204e14c98f6ac7e6b6ed", + "size": 66311879, + "url": "https://github.com/Kitware/CMake/releases/download/v3.20.3/cmake-3.20.3-macos-universal.tar.gz" + }, "name": "3.20.3", "status": "recommended", "win32": { @@ -562,41 +603,46 @@ "versions": [ { "linux-amd64": { - "sha256": "3460945f3560ef673264a0259a33dcbf0dd18ac6b7b4862e89318655c62215c7", - "size": 1901040, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-linux-amd64-0.11.0-esp32-20211220.tar.gz" + "sha256": "8d49845d7f0f2f9178e72c694a76e39a6ef3dd219cfccbfc2b8e09fc8d8f1c6e", + "size": 2058842, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-linux-amd64-0.11.0-esp32-20220411.tar.gz" }, "linux-arm64": { - "sha256": "65d4de147d37c04e1c65d020e9c38e90db5a71e9e0bc602f5c8e0f44e46cd098", - "size": 1792274, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-linux-arm64-0.11.0-esp32-20211220.tar.gz" + "sha256": "584e4d10d6efb9985f4212542cfa2a92f89c747b54035bac8aa75b5f5e768e28", + "size": 1902060, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-linux-arm64-0.11.0-esp32-20220411.tar.gz" }, "linux-armel": { - "sha256": "4c03c5fdf73d9a4357cb5e2918c8e3d99900c7a1bb6d50e8712a8d38477398a0", - "size": 1943340, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-linux-armel-0.11.0-esp32-20211220.tar.gz" + "sha256": "49189d645d8c482b81d1870766a5795da30a79b352d98803f0054f200174fc5a", + "size": 2128366, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-linux-armel-0.11.0-esp32-20220411.tar.gz" }, "linux-armhf": { - "sha256": "acbb2bf74454ad2e45bab690538082cd6538a687ba2ba3d233309eb985702aba", - "size": 1803024, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-linux-armhf-0.11.0-esp32-20211220.tar.gz" + "sha256": "a538a2b98fd09fb548a9dbfa0b5155364273e1ae37e944d1abfa04cc4e6e0ba2", + "size": 2009408, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-linux-armhf-0.11.0-esp32-20220411.tar.gz" }, "macos": { - "sha256": "689149120965a8c36c78c1852035b72f500f2a5b406f53624ed4c0a85c4e9a60", - "size": 1959080, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-macos-0.11.0-esp32-20211220.tar.gz" + "sha256": "d718bc24087f796ff06f49fb9052183b302402ab775460b1ebdfc4b5e1768463", + "size": 2125935, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-macos-0.11.0-esp32-20220411.tar.gz" + }, + "macos-arm64": { + "sha256": "19448f0d4aaafa85c93c86e363ca879e5ccdcfdda42ba5ce4ac3817e9d8eecdb", + "size": 2165892, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-macos-arm64-0.11.0-esp32-20220411.tar.gz" }, - "name": "v0.11.0-esp32-20211220", + "name": "v0.11.0-esp32-20220411", "status": "recommended", "win32": { - "sha256": "18f5515c4cecce5866e2f7cc7ff536f1a21a624e40a61d24c9dea4a910657cbb", - "size": 2441430, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-win32-0.11.0-esp32-20211220.zip" + "sha256": "167e9299fa1d022b493c76332f507f6a6735c7bfec3cf91c54a598b331c78b5f", + "size": 2570094, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-win32-0.11.0-esp32-20220411.zip" }, "win64": { - "sha256": "18f5515c4cecce5866e2f7cc7ff536f1a21a624e40a61d24c9dea4a910657cbb", - "size": 2441430, - "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20211220/openocd-esp32-win32-0.11.0-esp32-20211220.zip" + "sha256": "167e9299fa1d022b493c76332f507f6a6735c7bfec3cf91c54a598b331c78b5f", + "size": 2570094, + "url": "https://github.com/espressif/openocd-esp32/releases/download/v0.11.0-esp32-20220411/openocd-esp32-win32-0.11.0-esp32-20220411.zip" } } ] @@ -642,6 +688,11 @@ "size": 240112, "url": "https://dl.espressif.com/dl/ninja-1.10.2-osx.tar.gz" }, + "macos-arm64": { + "sha256": "847bb1ca4bc16d8dba6aeed3ecb5055498b86bc68c364c37583eb5738bb440f1", + "size": 240112, + "url": "https://dl.espressif.com/dl/ninja-1.10.2-osx.tar.gz" + }, "name": "1.10.2", "status": "recommended", "win64": { diff --git a/tools/tools_schema.json b/tools/tools_schema.json index cd6be7dd4d52..f09044d62219 100644 --- a/tools/tools_schema.json +++ b/tools/tools_schema.json @@ -200,7 +200,7 @@ "type": "array", "items": { "type": "string", - "enum": ["linux-i686", "linux-amd64", "linux-armel", "linux-arm64", "macos", "win32", "win64"] + "enum": ["linux-i686", "linux-amd64", "linux-armel", "linux-arm64", "macos", "macos-arm64", "win32", "win64"] } }, "export_paths": {