mirror of
https://github.com/espressif/esp-idf.git
synced 2026-04-27 19:13:21 +00:00
259 lines
9.4 KiB
Plaintext
259 lines
9.4 KiB
Plaintext
config BLE_LOG_ENABLED
|
|
bool "Enable BT Log Async Output (Dev Only)"
|
|
default n
|
|
help
|
|
Enable BT Log Async Output
|
|
|
|
if BLE_LOG_ENABLED
|
|
config BLE_LOG_TASK_STACK_SIZE
|
|
int "Stack size for BLE Log Task"
|
|
default 1024 if IDF_TARGET_ARCH_RISCV
|
|
default 2048 if IDF_TARGET_ARCH_XTENSA
|
|
default 1024
|
|
help
|
|
Stack size for BLE Log Task
|
|
|
|
config BLE_LOG_LBM_TRANS_BUF_SIZE
|
|
int "Total buffer memory per common LBM (bytes)"
|
|
default 2048 if BT_BLUEDROID_ENABLED
|
|
default 4096 if BT_NIMBLE_ENABLED
|
|
help
|
|
Total buffer memory allocated for each common pool log buffer
|
|
manager (LBM). This memory is divided equally among internal
|
|
transport buffers. Must be a multiple of BLE_LOG_TRANS_BUF_CNT
|
|
(currently 4).
|
|
|
|
The common pool contains:
|
|
- BLE_LOG_LBM_ATOMIC_LOCK_TASK_CNT atomic LBMs (task context)
|
|
- BLE_LOG_LBM_ATOMIC_LOCK_ISR_CNT atomic LBMs (ISR context)
|
|
- 2 spinlock-protected LBMs (one for task, one for ISR fallback)
|
|
|
|
Total common pool memory:
|
|
(ATOMIC_TASK_CNT + ATOMIC_ISR_CNT + 2) * BLE_LOG_LBM_TRANS_BUF_SIZE
|
|
|
|
config BLE_LOG_LBM_ATOMIC_LOCK_TASK_CNT
|
|
int "Count of log buffer managers with atomic lock protection for task context"
|
|
default 2
|
|
help
|
|
BLE Log module will search for an LBM with atomic lock protection first; if
|
|
all LBMs with atomic lock protection are unavailable, BLE Log module will
|
|
try to use the LBM with spin lock protection. So the more LBMs with atomic
|
|
lock protection are created, the better the logging performance will be.
|
|
|
|
config BLE_LOG_LBM_ATOMIC_LOCK_ISR_CNT
|
|
int "Count of log buffer managers with atomic lock protection for ISR context"
|
|
default 1
|
|
help
|
|
BLE Log module will search for an LBM with atomic lock protection first; if
|
|
all LBMs with atomic lock protection are unavailable, BLE Log module will
|
|
try to use the LBM with spin lock protection. So the more LBMs with atomic
|
|
lock protection are created, the more ISRs can nest.
|
|
|
|
config BLE_LOG_IS_ESP_CONTROLLER
|
|
bool "Current BLE Controller is ESP BLE Controller"
|
|
depends on BT_CONTROLLER_ENABLED
|
|
depends on SOC_ESP_NIMBLE_CONTROLLER
|
|
default y
|
|
select BT_LE_CONTROLLER_LOG_ENABLED
|
|
select BLE_LOG_LL_ENABLED
|
|
help
|
|
Current BLE Controller is ESP BLE Controller
|
|
|
|
config BLE_LOG_IS_ESP_LEGACY_CONTROLLER
|
|
bool "Current BLE Controller is ESP BLE Legacy Controller"
|
|
depends on BT_CONTROLLER_ENABLED
|
|
depends on !SOC_ESP_NIMBLE_CONTROLLER
|
|
depends on BT_CTRL_RUN_IN_FLASH_ONLY
|
|
default y
|
|
select BT_CTRL_LE_LOG_EN
|
|
select BLE_LOG_LL_ENABLED
|
|
help
|
|
Current BLE Controller is ESP BLE Legacy Controller
|
|
|
|
config BLE_LOG_LL_ENABLED
|
|
bool "Enable BLE Log for Link Layer"
|
|
depends on BT_CONTROLLER_ENABLED
|
|
default n
|
|
help
|
|
Enable BLE Log for Link Layer
|
|
|
|
if BLE_LOG_LL_ENABLED
|
|
config BLE_LOG_LBM_LL_TRANS_BUF_SIZE
|
|
int "Total buffer memory per Link Layer LBM (bytes)"
|
|
default 2048
|
|
help
|
|
Total buffer memory allocated for each Link Layer dedicated
|
|
log buffer manager (LBM). This memory is divided equally among
|
|
internal transport buffers. Must be a multiple of
|
|
BLE_LOG_TRANS_BUF_CNT (currently 4).
|
|
|
|
There are 2 Link Layer LBMs without lock protection (each is
|
|
accessed from a single context only):
|
|
- LL task LBM (Link Layer task context logs)
|
|
- LL HCI LBM (Link Layer HCI context logs)
|
|
|
|
Total LL pool memory: 2 * BLE_LOG_LBM_LL_TRANS_BUF_SIZE
|
|
|
|
config BLE_LOG_LL_HCI_LOG_PAYLOAD_LEN_LIMIT_ENABLED
|
|
bool "Enable LL HCI Log Payload Length Limit"
|
|
default n
|
|
help
|
|
Enable length limit for LL HCI Log payload (addr_append).
|
|
When enabled, if len_append exceeds the configured limit,
|
|
it will be truncated to the maximum length.
|
|
|
|
config BLE_LOG_LL_HCI_LOG_PAYLOAD_LEN_LIMIT
|
|
int "LL HCI Log Payload Length Limit (bytes)"
|
|
depends on BLE_LOG_LL_HCI_LOG_PAYLOAD_LEN_LIMIT_ENABLED
|
|
default 32
|
|
help
|
|
Maximum length for LL HCI Log payload (len_append).
|
|
When the feature is enabled and len_append exceeds this value,
|
|
it will be truncated.
|
|
endif
|
|
|
|
config BLE_LOG_HOST_SIDE_HCI_LOG_ENABLED
|
|
bool "Enable BLE Host side HCI Logging"
|
|
default y
|
|
help
|
|
Enable BLE Host side HCI Logging
|
|
|
|
config BLE_LOG_TS_ENABLED
|
|
bool "Enable BLE Log Timestamp Synchronization (TS)"
|
|
default n
|
|
help
|
|
Enable BLE Log TS with external logging module
|
|
|
|
if BLE_LOG_TS_ENABLED
|
|
config BLE_LOG_SYNC_IO_NUM
|
|
int "GPIO number for Timestamp Synchronization (TS) toggle output"
|
|
depends on BLE_LOG_TS_ENABLED
|
|
default 0
|
|
help
|
|
GPIO number for TS toggle output
|
|
|
|
config BLE_LOG_TS_TRIGGER_TIMEOUT_MS
|
|
int "Timeout (ms) for Timestamp Synchronization toggle"
|
|
default 1000
|
|
help
|
|
Timeout (ms) for Timestamp Synchronization toggle
|
|
|
|
choice BLE_LOG_TS_TRIGGER_CHOICE
|
|
prompt "BLE Log Timestamp Synchronization trigger choice"
|
|
default BLE_LOG_TS_TRIGGER_TASK_EVENT
|
|
help
|
|
Choose BLE Log Timestamp Synchronization trigger
|
|
|
|
config BLE_LOG_TS_TRIGGER_ESP_TIMER
|
|
bool "BLE Log Timestamp Synchronization trigger - ESP Timer"
|
|
help
|
|
ESP Timer based periodic TS trigger
|
|
|
|
config BLE_LOG_TS_TRIGGER_TASK_EVENT
|
|
bool "BLE Log Timestamp Synchronization trigger - Task Event"
|
|
help
|
|
Task Event based TS trigger (Light Sleep Test Compatibility)
|
|
endchoice
|
|
|
|
config BLE_LOG_TS_TRIGGER_ESP_TIMER_ISR_DISPATCH_METHOD
|
|
bool "Utilize ISR dispatch method for ESP Timer as Timestamp Synchronization trigger"
|
|
default n
|
|
select ESP_TIMER_SUPPORTS_ISR_DISPATCH_METHOD
|
|
select GPIO_CTRL_FUNC_IN_IRAM
|
|
depends on BLE_LOG_TS_TRIGGER_ESP_TIMER
|
|
help
|
|
Utilize ISR dispatch method for ESP Timer as Timestamp Synchronization trigger
|
|
endif
|
|
|
|
choice BLE_LOG_PRPH_CHOICE
|
|
prompt "BLE Log peripheral choice"
|
|
default BLE_LOG_PRPH_UART_DMA if SOC_UHCI_SUPPORTED
|
|
default BLE_LOG_PRPH_DUMMY
|
|
help
|
|
Choose BLE Log peripheral
|
|
|
|
config BLE_LOG_PRPH_DUMMY
|
|
bool "Dummy transport"
|
|
help
|
|
Dummy transport (dump only)
|
|
|
|
config BLE_LOG_PRPH_SPI_MASTER_DMA
|
|
bool "Utilize SPI master DMA driver as transport"
|
|
depends on SOC_GPSPI_SUPPORTED
|
|
help
|
|
Utilize SPI master DMA driver as transport
|
|
|
|
config BLE_LOG_PRPH_UART_DMA
|
|
bool "Utilize UART DMA driver as transport"
|
|
depends on SOC_UHCI_SUPPORTED
|
|
help
|
|
Utilize UART DMA driver as transport
|
|
endchoice
|
|
|
|
if BLE_LOG_PRPH_SPI_MASTER_DMA
|
|
config BLE_LOG_PRPH_SPI_MASTER_DMA_MOSI_IO_NUM
|
|
int "GPIO number of MOSI port for SPI master DMA transport"
|
|
default 0
|
|
help
|
|
GPIO number of MOSI port for SPI master DMA transport
|
|
|
|
config BLE_LOG_PRPH_SPI_MASTER_DMA_SCLK_IO_NUM
|
|
int "GPIO number of SCLK port for SPI master DMA transport"
|
|
default 0
|
|
help
|
|
GPIO number of SCLK port for SPI master DMA transport
|
|
|
|
config BLE_LOG_PRPH_SPI_MASTER_DMA_CS_IO_NUM
|
|
int "GPIO number of CS port for SPI master DMA transport"
|
|
default 0
|
|
help
|
|
GPIO number of CS port for SPI master DMA transport
|
|
endif
|
|
|
|
if BLE_LOG_PRPH_UART_DMA
|
|
config BLE_LOG_PRPH_UART_DMA_PORT
|
|
int "UART port number for UART DMA transport"
|
|
default 0
|
|
help
|
|
UART port number for UART DMA
|
|
|
|
config BLE_LOG_PRPH_UART_DMA_BAUD_RATE
|
|
int "Baud rate of UART port for UART DMA transport"
|
|
default 3000000
|
|
help
|
|
Determine the baud rate of UART port
|
|
|
|
config BLE_LOG_PRPH_UART_DMA_TX_IO_NUM
|
|
int "GPIO number for UART TX"
|
|
default 0
|
|
help
|
|
GPIO number for UART TX
|
|
endif
|
|
|
|
menu "Settings of BLE Log Compression"
|
|
source "$IDF_PATH/components/bt/common/ble_log/extension/log_compression/Kconfig.in"
|
|
endmenu
|
|
|
|
# Deprecated options -- retained for backward sdkconfig compatibility.
|
|
# These symbols have no prompt so they never appear in menuconfig.
|
|
config BLE_LOG_LBM_TRANS_SIZE
|
|
int
|
|
default 512
|
|
|
|
config BLE_LOG_ENH_STAT_ENABLED
|
|
bool
|
|
default y
|
|
|
|
config BLE_LOG_PAYLOAD_CHECKSUM_ENABLED
|
|
bool
|
|
default y
|
|
|
|
config BLE_LOG_LBM_LL_TRANS_SIZE
|
|
int
|
|
default 512
|
|
endif
|
|
|
|
menu "Legacy SPI Log Output (Deprecated - use BT Log Async Output instead)"
|
|
source "$IDF_PATH/components/bt/common/ble_log/deprecated/Kconfig.in"
|
|
endmenu
|