fix ble adv tx power map

This commit is contained in:
chenjianhua 2022-09-19 11:23:05 +08:00
parent 38d1250788
commit bec6de98c4
2 changed files with 13 additions and 1 deletions

View File

@ -1188,15 +1188,27 @@
#endif
#ifndef BTM_BLE_ADV_TX_POWER
#ifdef CONFIG_IDF_TARGET_ESP32
#define BTM_BLE_ADV_TX_POWER {-12, -9, -6, -3, 0, 3, 6, 9}
#else
#define BTM_BLE_ADV_TX_POWER {-24, -21, -18, -15, -12, -9, -6, -3, 0, 3, 6, 9, 12, 15, 18, 21}
#endif
#endif
#ifndef BTM_TX_POWER
#ifdef CONFIG_IDF_TARGET_ESP32
#define BTM_TX_POWER {-12, -9, -6, -3, 0, 3, 6, 9}
#else
#define BTM_TX_POWER {-24, -21, -18, -15, -12, -9, -6, -3, 0, 3, 6, 9, 12, 15, 18, 21}
#endif
#endif
#ifndef BTM_TX_POWER_LEVEL_MAX
#ifdef CONFIG_IDF_TARGET_ESP32
#define BTM_TX_POWER_LEVEL_MAX 7
#else
#define BTM_TX_POWER_LEVEL_MAX 15
#endif
#endif

View File

@ -385,7 +385,7 @@ typedef UINT8 tBTM_BLE_AD_TYPE;
/* adv tx power level */
#define BTM_BLE_ADV_TX_POWER_MIN 0 /* minimum tx power */
#define BTM_BLE_ADV_TX_POWER_MAX 7 /* maximum tx power */
#define BTM_BLE_ADV_TX_POWER_MAX BTM_TX_POWER_LEVEL_MAX /* maximum tx power */
typedef UINT8 tBTM_BLE_ADV_TX_POWER;
/* adv tx power in dBm */