Skip to content

Commit 2c0381d

Browse files
committed
Merge branch 'feat/improve_bt_log_spi_output_interface' into 'master'
Feat/improve bt log spi output interface See merge request espressif/esp-idf!36912
2 parents 7a5684d + e41f619 commit 2c0381d

File tree

10 files changed

+351
-224
lines changed

10 files changed

+351
-224
lines changed

components/bt/CMakeLists.txt

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,12 +131,9 @@ if(CONFIG_BT_ENABLED)
131131
"common/osi/osi.c"
132132
"common/osi/semaphore.c"
133133
"porting/mem/bt_osi_mem.c"
134+
"common/ble_log/ble_log_spi_out.c"
134135
)
135136

136-
if(CONFIG_BT_LE_CONTROLLER_LOG_SPI_OUT_ENABLED)
137-
list(APPEND srcs "common/ble_log/ble_log_spi_out.c")
138-
endif()
139-
140137
# Host Bluedroid
141138
if(CONFIG_BT_BLUEDROID_ENABLED)
142139

@@ -877,7 +874,7 @@ idf_component_register(SRCS "${srcs}"
877874
PRIV_INCLUDE_DIRS "${priv_include_dirs}"
878875
REQUIRES esp_timer esp_wifi
879876
PRIV_REQUIRES nvs_flash soc esp_pm esp_phy esp_coex mbedtls esp_driver_uart vfs esp_ringbuf
880-
esp_driver_spi
877+
esp_driver_spi esp_driver_gpio
881878
LDFRAGMENTS "${ldscripts}")
882879

883880
if(CONFIG_BT_ENABLED)

components/bt/common/Kconfig.in

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,58 @@ config BT_ALARM_MAX_NUM
44
help
55
This option decides the maximum number of alarms which
66
could be used by Bluetooth host.
7+
8+
config BT_BLE_LOG_SPI_OUT_ENABLED
9+
bool "Output ble logs to SPI bus (Experimental)"
10+
default n
11+
help
12+
Output ble logs to SPI bus
13+
14+
config BT_BLE_LOG_SPI_OUT_QUEUE_SIZE
15+
int "Number of ble log async SPI output queues"
16+
depends on BT_BLE_LOG_SPI_OUT_ENABLED
17+
default 4
18+
help
19+
The number of ble log async SPI output queues
20+
21+
config BT_BLE_LOG_SPI_OUT_TRANS_BUF_SIZE
22+
int "Size of ble log async SPI output transaction buffer size"
23+
depends on BT_BLE_LOG_SPI_OUT_ENABLED
24+
default 2048
25+
help
26+
The size of ble log async SPI output transaction buffer size
27+
28+
config BT_BLE_LOG_SPI_OUT_MOSI_IO_NUM
29+
int "GPIO number of SPI MOSI"
30+
depends on BT_BLE_LOG_SPI_OUT_ENABLED
31+
default 0
32+
help
33+
GPIO number of SPI MOSI
34+
35+
config BT_BLE_LOG_SPI_OUT_SCLK_IO_NUM
36+
int "GPIO number of SPI SCLK"
37+
depends on BT_BLE_LOG_SPI_OUT_ENABLED
38+
default 1
39+
help
40+
GPIO number of SPI SCLK
41+
42+
config BT_BLE_LOG_SPI_OUT_CS_IO_NUM
43+
int "GPIO number of SPI CS"
44+
depends on BT_BLE_LOG_SPI_OUT_ENABLED
45+
default 2
46+
help
47+
GPIO number of SPI CS
48+
49+
config BT_BLE_LOG_SPI_OUT_TS_SYNC_ENABLED
50+
bool "Enable ble log & logic analyzer log time sync"
51+
depends on BT_BLE_LOG_SPI_OUT_ENABLED
52+
default y
53+
help
54+
Enable ble log & logic analyzer log time sync
55+
56+
config BT_BLE_LOG_SPI_OUT_SYNC_IO_NUM
57+
int "GPIO number of SYNC IO"
58+
depends on BT_BLE_LOG_SPI_OUT_TS_SYNC_ENABLED
59+
default 3
60+
help
61+
GPIO number of SYNC IO

0 commit comments

Comments
 (0)