Skip to content

Commit a5d128b

Browse files
committed
Merge branch 'bugfix/fix_ble_max_tx_power_on_esp32c3_v5.2' into 'release/v5.2'
fix(bt/controller): Change the max TX power to +20dBm on ESP32-C3 and ESP32-S3 (v5.2) See merge request espressif/esp-idf!33616
2 parents 5dbb1cf + 3a8c97a commit a5d128b

File tree

3 files changed

+17
-16
lines changed

3 files changed

+17
-16
lines changed

components/bt/controller/esp32c3/Kconfig.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -200,8 +200,8 @@ choice BT_CTRL_DFT_TX_POWER_LEVEL
200200
bool "+15dBm"
201201
config BT_CTRL_DFT_TX_POWER_LEVEL_P18
202202
bool "+18dBm"
203-
config BT_CTRL_DFT_TX_POWER_LEVEL_P21
204-
bool "+21dBm"
203+
config BT_CTRL_DFT_TX_POWER_LEVEL_P20
204+
bool "+20dBm"
205205
endchoice
206206

207207
config BT_CTRL_DFT_TX_POWER_LEVEL_EFF
@@ -221,7 +221,7 @@ config BT_CTRL_DFT_TX_POWER_LEVEL_EFF
221221
default 12 if BT_CTRL_DFT_TX_POWER_LEVEL_P12
222222
default 13 if BT_CTRL_DFT_TX_POWER_LEVEL_P15
223223
default 14 if BT_CTRL_DFT_TX_POWER_LEVEL_P18
224-
default 15 if BT_CTRL_DFT_TX_POWER_LEVEL_P21
224+
default 15 if BT_CTRL_DFT_TX_POWER_LEVEL_P20
225225
default 0
226226

227227
config BT_CTRL_BLE_ADV_REPORT_FLOW_CTRL_SUPP

components/bt/host/bluedroid/common/include/common/bt_target.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1282,15 +1282,15 @@
12821282
#ifdef CONFIG_IDF_TARGET_ESP32
12831283
#define BTM_BLE_ADV_TX_POWER {-12, -9, -6, -3, 0, 3, 6, 9}
12841284
#else
1285-
#define BTM_BLE_ADV_TX_POWER {-24, -21, -18, -15, -12, -9, -6, -3, 0, 3, 6, 9, 12, 15, 18, 21}
1285+
#define BTM_BLE_ADV_TX_POWER {-24, -21, -18, -15, -12, -9, -6, -3, 0, 3, 6, 9, 12, 15, 18, 20}
12861286
#endif
12871287
#endif
12881288

12891289
#ifndef BTM_TX_POWER
12901290
#ifdef CONFIG_IDF_TARGET_ESP32
12911291
#define BTM_TX_POWER {-12, -9, -6, -3, 0, 3, 6, 9}
12921292
#else
1293-
#define BTM_TX_POWER {-24, -21, -18, -15, -12, -9, -6, -3, 0, 3, 6, 9, 12, 15, 18, 21}
1293+
#define BTM_TX_POWER {-24, -21, -18, -15, -12, -9, -6, -3, 0, 3, 6, 9, 12, 15, 18, 20}
12941294
#endif
12951295
#endif
12961296

components/bt/include/esp32c3/include/esp_bt.h

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -376,17 +376,18 @@ typedef enum {
376376
ESP_PWR_LVL_N18 = 2, /*!< Corresponding to -18dbm */
377377
ESP_PWR_LVL_N15 = 3, /*!< Corresponding to -15dbm */
378378
ESP_PWR_LVL_N12 = 4, /*!< Corresponding to -12dbm */
379-
ESP_PWR_LVL_N9 = 5, /*!< Corresponding to -9dbm */
380-
ESP_PWR_LVL_N6 = 6, /*!< Corresponding to -6dbm */
381-
ESP_PWR_LVL_N3 = 7, /*!< Corresponding to -3dbm */
382-
ESP_PWR_LVL_N0 = 8, /*!< Corresponding to 0dbm */
383-
ESP_PWR_LVL_P3 = 9, /*!< Corresponding to +3dbm */
384-
ESP_PWR_LVL_P6 = 10, /*!< Corresponding to +6dbm */
385-
ESP_PWR_LVL_P9 = 11, /*!< Corresponding to +9dbm */
386-
ESP_PWR_LVL_P12 = 12, /*!< Corresponding to +12dbm */
387-
ESP_PWR_LVL_P15 = 13, /*!< Corresponding to +15dbm */
388-
ESP_PWR_LVL_P18 = 14, /*!< Corresponding to +18dbm */
389-
ESP_PWR_LVL_P21 = 15, /*!< Corresponding to +21dbm */
379+
ESP_PWR_LVL_N9 = 5, /*!< Corresponding to -9dbm */
380+
ESP_PWR_LVL_N6 = 6, /*!< Corresponding to -6dbm */
381+
ESP_PWR_LVL_N3 = 7, /*!< Corresponding to -3dbm */
382+
ESP_PWR_LVL_N0 = 8, /*!< Corresponding to 0dbm */
383+
ESP_PWR_LVL_P3 = 9, /*!< Corresponding to +3dbm */
384+
ESP_PWR_LVL_P6 = 10, /*!< Corresponding to +6dbm */
385+
ESP_PWR_LVL_P9 = 11, /*!< Corresponding to +9dbm */
386+
ESP_PWR_LVL_P12 = 12, /*!< Corresponding to +12dbm */
387+
ESP_PWR_LVL_P15 = 13, /*!< Corresponding to +15dbm */
388+
ESP_PWR_LVL_P18 = 14, /*!< Corresponding to +18dbm */
389+
ESP_PWR_LVL_P20 = 15, /*!< Corresponding to +20dbm */
390+
ESP_PWR_LVL_P21 = 15, /*!< Corresponding to +20dbm, this enum variable has been deprecated */
390391
ESP_PWR_LVL_INVALID = 0xFF, /*!< Indicates an invalid value */
391392
} esp_power_level_t;
392393

0 commit comments

Comments
 (0)