Commit Graph

23 Commits

Author SHA1 Message Date
Zhou Xiao
490acad912 feat(bt/ble_log): implement UART redirection stream write
Introduce stream write API with deferred frame encapsulation for UART
redirection on port 0. Redirected data is now properly framed (header +
payload + checksum) instead of being sent as raw ASCII, preventing frame
parser sync oscillation on the receiver.

- Add stream_seal/stream_write/stream_flush in ble_log_lbm.c
- Add BLE_LOG_SRC_REDIR source and BLE_LOG_UART_REDIR_ENABLED gate
- Simplify redir_uart_tx_chars and timer callback to use stream API
- Flush pending stream data in ble_log_prph_deinit
- Make get_trans static (no external callers after refactor)
- Move UART wrap linker flags outside CONFIG_BT_ENABLED guard
- Default UART DMA peripheral when SOC_UHCI_SUPPORTED
- Default baud rate 921600 -> 3000000
2026-04-07 11:44:38 +08:00
Zhou Xiao
54a5fe04e6 change(bt/ble_log): deprecate legacy SPI log output module
Move ble_log_spi_out.c and ble_log_spi_out.h into a deprecated/
subdirectory under components/bt/common/ble_log/. Extract all
BT_BLE_LOG_SPI_OUT_* Kconfig options into deprecated/Kconfig.in
with an if-block to reduce depends-on repetition, sourced from
ble_log/Kconfig.in inside a "Legacy SPI Log Output (Deprecated)"
menu. Add mutual exclusion with BLE_LOG_ENABLED so that the legacy
SPI Out and the new BLE Log Module cannot be enabled simultaneously.
Update CMakeLists.txt source path and add deprecated/include to
include dirs so existing callers are unaffected. The BLE Log
Module's SPI Master DMA peripheral transport is the replacement.
2026-04-07 11:44:14 +08:00
Zhou Xiao
1fee2c3a0f change(bt/ble_log): remove BLE Log UHCI Out module
Delete ble_log_uhci_out.c and its header. Remove the UHCI Out source
from CMakeLists.txt and all BT_BLE_LOG_UHCI_OUT_* Kconfig options.
Remove per-chip BT_LE_CONTROLLER_LOG_UHCI_OUT_ENABLED Kconfig and
all UHCI Out caller references in esp32c5/c6/h2 controller bt.c.
Update ble_log_console README to reference the new BLE Log Module
UART DMA config. The functionality is superseded by the BLE Log
Module's UART DMA peripheral transport.
2026-04-07 11:43:22 +08:00
Zhou Xiao
cace3f1da0 feat(ble_log): encode HCI direction in ble_log pipeline
Add ble_log_write_hci macro that encodes upstream/downstream direction
in MSB of HCI type byte. Update all 4 callsites (NimBLE + Bluedroid)
to use the new macro. Parser reads MSB to determine direction;
backward compatible (old firmware MSB=0 defaults to "sent").


(cherry picked from commit 8fd5dbb730)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2026-03-10 14:59:56 +08:00
luoxu
cf3e21e600 feat(ble): Support ble log compression(draft) 2025-10-14 16:49:04 +08:00
Zhou Xiao
2da8ba640d feat(ble): support ble log uart dma out
(cherry picked from commit 534b43e85a)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-10-09 11:20:45 +08:00
Zhou Xiao
e429ec36f8 feat(ble): refactored ble log module with layered design
(cherry picked from commit 797a0c4e6eafaf6164e0f9c34f3867a46733924c)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-09-01 13:13:32 +08:00
Zhou Xiao
74b00c1ea5 feat(ble): ble log spi out dev phase 5
* supported ts sync for light sleep
* removed controller event queue dependency
* supported get lc ts for ESP32-C3/S3
* optimized ble log spi out code size


(cherry picked from commit f99389e00d)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-07-30 13:13:54 +08:00
Zhou Xiao
a3243068b9 change(ble): removed esp log to save code size
(cherry picked from commit 0088541f54)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-07-08 13:14:05 +08:00
Zhou Xiao
26847c0f80 feat(ble): support ble mesh log module
(cherry picked from commit 066e1d3f1b)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-07-08 13:13:57 +08:00
Zhou Xiao
215220c6af feat(ble): support host & hci log module
(cherry picked from commit dd4cbe5e00)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-07-08 13:13:55 +08:00
Zhou Xiao
e13ec6c442 fix(ble): ensure internal malloc in ble log spi out 2025-06-30 10:31:37 +08:00
Zhou Xiao
0bdf6c956d feat(ble): support le audio log buffer separation
(cherry picked from commit cd3aa6527c)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-05-22 16:54:01 +08:00
Zhou Xiao
f1e3a8e106 feat(ble): refactored flush module and provided public flush api
(cherry picked from commit 70792443c7)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-05-22 16:53:56 +08:00
Zhou Xiao
8db24f1603 feat(ble): provided dynamic spi enable/disable api
(cherry picked from commit 3568f19fef)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-05-22 16:53:51 +08:00
Zhou Xiao
3b4ed71965 feat(ble): support hci log buffer separation
(cherry picked from commit 16a3b2c71b)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-05-22 16:53:48 +08:00
Zhou Xiao
7afbc47750 feat(ble): optimized macros readability
(cherry picked from commit f8699785e9)

Co-authored-by: Zhou Xiao <zhouxiao@espressif.com>
2025-05-22 16:53:46 +08:00
Zhou Xiao
a88d47537a feat(ble): support ble log simple output via SPI interface 2025-03-24 10:58:27 +08:00
Zhou Xiao
d74bc5946a fix(ble): fix flushout and sync issues 2025-03-03 16:36:40 +08:00
zhanghaipeng
82d0e358c8 fix(ble/bluedroid): Added SPI output support for Bluedroid host log 2025-03-03 16:36:40 +08:00
Zhou Xiao
11dc85f80b feat(ble): add printf and write with timestamp interface for ble log spi out 2025-03-03 16:36:40 +08:00
Zhou Xiao
54e3f7c29c feat(ble): improved ble log spi output interface to support multisource log 2025-03-03 16:36:40 +08:00
Zhou Xiao
b47e85270d feat(ble): add spi output interface for esp ble controller log 2025-03-03 16:36:40 +08:00