Bluetooth: Audio: Add CONFIG_BT_AUDIO_DEBUG_STREAM_DATA

Add the CONFIG_BT_AUDIO_DEBUG_STREAM_DATA Kconfig option
to better debug bt_audio_stream without drowning the log
in the data being sent.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
This commit is contained in:
Emil Gydesen 2022-07-07 16:40:36 +02:00 committed by Fabio Baltieri
commit 1b9c2e22b2
4 changed files with 20 additions and 3 deletions

View file

@ -193,6 +193,14 @@ config BT_AUDIO_DEBUG_STREAM
Use this option to enable Bluetooth Audio Stream debug logs for the Use this option to enable Bluetooth Audio Stream debug logs for the
Bluetooth Audio functionality. Bluetooth Audio functionality.
config BT_AUDIO_DEBUG_STREAM_DATA
bool "Bluetooth Audio Stream data debug"
depends on BT_AUDIO_DEBUG_STREAM
help
Use this option to enable Bluetooth Audio Stream data debug logs for
the Bluetooth Audio functionality. This will enable debug logs for all
audio data received and sent.
config BT_AUDIO_DEBUG_CAPABILITIES config BT_AUDIO_DEBUG_CAPABILITIES
bool "Bluetooth Audio Capabilities debug" bool "Bluetooth Audio Capabilities debug"
depends on BT_AUDIO_CAPABILITY depends on BT_AUDIO_CAPABILITY

View file

@ -332,7 +332,10 @@ static void ascs_iso_recv(struct bt_iso_chan *chan,
ops = ep->stream->ops; ops = ep->stream->ops;
BT_DBG("stream %p ep %p len %zu", chan, ep, net_buf_frags_len(buf)); if (IS_ENABLED(CONFIG_BT_AUDIO_DEBUG_STREAM_DATA)) {
BT_DBG("stream %p ep %p len %zu",
chan, ep, net_buf_frags_len(buf));
}
if (ops != NULL && ops->recv != NULL) { if (ops != NULL && ops->recv != NULL) {
ops->recv(ep->stream, info, buf); ops->recv(ep->stream, info, buf);

View file

@ -128,7 +128,10 @@ static void broadcast_sink_iso_recv(struct bt_iso_chan *chan,
ops = ep->stream->ops; ops = ep->stream->ops;
BT_DBG("stream %p ep %p len %zu", chan, ep, net_buf_frags_len(buf)); if (IS_ENABLED(CONFIG_BT_AUDIO_DEBUG_STREAM_DATA)) {
BT_DBG("stream %p ep %p len %zu",
chan, ep, net_buf_frags_len(buf));
}
if (ops != NULL && ops->recv != NULL) { if (ops != NULL && ops->recv != NULL) {
ops->recv(ep->stream, info, buf); ops->recv(ep->stream, info, buf);

View file

@ -80,7 +80,10 @@ static void unicast_client_ep_iso_recv(struct bt_iso_chan *chan,
ops = ep->stream->ops; ops = ep->stream->ops;
BT_DBG("stream %p ep %p len %zu", chan, ep, net_buf_frags_len(buf)); if (IS_ENABLED(CONFIG_BT_AUDIO_DEBUG_STREAM_DATA)) {
BT_DBG("stream %p ep %p len %zu",
chan, ep, net_buf_frags_len(buf));
}
if (ops != NULL && ops->recv != NULL) { if (ops != NULL && ops->recv != NULL) {
ops->recv(ep->stream, info, buf); ops->recv(ep->stream, info, buf);