feat(ble): add priority level config on ESP32-C5
(cherry picked from commit 96bdca38a11f8385757d43ed9fe0f3d9ac91c2be) Co-authored-by: zhaoweiliang <zhaoweiliang@espressif.com>
This commit is contained in:
@@ -881,3 +881,65 @@ endmenu
|
||||
config BT_LE_DTM_ENABLED
|
||||
bool "Enable Direct Test Mode (DTM) feature"
|
||||
default n
|
||||
|
||||
menu "Scheduling Priority Level Config"
|
||||
choice BT_LE_ADV_SCHED_PRIO_LEVEL
|
||||
prompt "The Adv scheduling priority level"
|
||||
default BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
|
||||
help
|
||||
The Adv scheduling priority level is used for arbitration when internal scheduling conflicts.
|
||||
config BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
|
||||
bool "low priority level"
|
||||
config BT_LE_ADV_SCHED_PRIO_MID_LEVEL
|
||||
bool "medium priority level"
|
||||
config BT_LE_ADV_SCHED_PRIO_HIGH_LEVEL
|
||||
bool "high priority level"
|
||||
endchoice
|
||||
|
||||
config BT_LE_DFT_ADV_SCHED_PRIO_LEVEL
|
||||
int
|
||||
default 0 if BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
|
||||
default 1 if BT_LE_ADV_SCHED_PRIO_MID_LEVEL
|
||||
default 2 if BT_LE_ADV_SCHED_PRIO_HIGH_LEVEL
|
||||
default 0
|
||||
|
||||
choice BT_LE_PERIODIC_ADV_SCHED_PRIO_LEVEL
|
||||
prompt "The Periodic Adv scheduling priority level"
|
||||
default BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
|
||||
help
|
||||
The Periodic Adv scheduling priority level is used for arbitration when internal scheduling conflicts.
|
||||
config BT_LE_PERIODIC_ADV_SCHED_PRIO_LOW_LEVEL
|
||||
bool "low priority level"
|
||||
config BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
|
||||
bool "medium priority level"
|
||||
config BT_LE_PERIODIC_ADV_SCHED_PRIO_HIGH_LEVEL
|
||||
bool "high priority level"
|
||||
endchoice
|
||||
|
||||
config BT_LE_DFT_PERIODIC_ADV_SCHED_PRIO_LEVEL
|
||||
int
|
||||
default 0 if BT_LE_PERIODIC_ADV_SCHED_PRIO_LOW_LEVEL
|
||||
default 1 if BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
|
||||
default 2 if BT_LE_PERIODIC_ADV_SCHED_PRIO_HIGH_LEVEL
|
||||
default 1
|
||||
|
||||
choice BT_LE_SYNC_SCHED_PRIO_LEVEL
|
||||
prompt "The Sync scheduling priority level"
|
||||
default BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
|
||||
help
|
||||
The SYNC scheduling priority level is used for arbitration when internal scheduling conflicts.
|
||||
config BT_LE_SYNC_SCHED_PRIO_LOW_LEVEL
|
||||
bool "low priority level"
|
||||
config BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
|
||||
bool "medium priority level"
|
||||
config BT_LE_SYNC_SCHED_PRIO_HIGH_LEVEL
|
||||
bool "high priority level"
|
||||
endchoice
|
||||
|
||||
config BT_LE_DFT_SYNC_SCHED_PRIO_LEVEL
|
||||
int
|
||||
default 0 if BT_LE_SYNC_SCHED_PRIO_LOW_LEVEL
|
||||
default 1 if BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
|
||||
default 2 if BT_LE_SYNC_SCHED_PRIO_HIGH_LEVEL
|
||||
default 1
|
||||
endmenu
|
||||
|
||||
@@ -297,7 +297,7 @@ extern "C" {
|
||||
#define RUN_BQB_TEST (0)
|
||||
#define RUN_QA_TEST (0)
|
||||
#define NIMBLE_DISABLE_SCAN_BACKOFF (0)
|
||||
|
||||
#define BT_LL_CTRL_PRIO_LVL_CFG ((CONFIG_BT_LE_DFT_SYNC_SCHED_PRIO_LEVEL << 4) | (CONFIG_BT_LE_DFT_PERIODIC_ADV_SCHED_PRIO_LEVEL << 2) | CONFIG_BT_LE_DFT_ADV_SCHED_PRIO_LEVEL)
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user