New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
applications: nrf5340_audio: Enable bidirectional CIS #8915
applications: nrf5340_audio: Enable bidirectional CIS #8915
Conversation
a0e582a
to
4468f96
Compare
Integration test specification
Detailed information of selected test modules Note: This message is automatically posted and updated by the CI |
You can find the documentation preview for this PR at this link. It will be updated about 10 minutes after the documentation build succeeds. Note: This comment is automatically posted by the Documentation Publishing GitHub Action. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general it feels overly hardcoded, at least on the gateway. But I guess it has to be this way because of the current limitations.
Also, remember documentation change
applications/nrf5340_audio/src/bluetooth/le_audio_cis_gateway.c
Outdated
Show resolved
Hide resolved
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
4468f96
to
d2ea0c9
Compare
@@ -91,10 +86,12 @@ Connected Isochronous Stream (CIS) | |||
In this configuration, you can use the nRF5340 Audio development kit in the role of the gateway, the left headset, or the right headset. | |||
|
|||
.. note:: | |||
In the current version of the nRF5340 Audio application, the CIS mode offers only monodirectional communication. | |||
In the current version of the nRF5340 Audio application, the CIS mode offers both unidirectional and bidirectional communication. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to add a section under Configuration -- "Selecting the CIS bidirectional communication" -- and describe there how to enable the bidirectional stream.
Also, we need to mention that Testing covers the unidirectional mode.
@erikrobstad , does this PR require changes in the figures? I gave a cursory look, but I'm unable to verify.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@greg-fer It does not look like we need to change the figures
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alexsven It does not look like you have added that (CIS) Testing covers the unidirectional mode.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Testing as in the CI-system? The tests for bidirectional are done, just waiting for this PR to be merged
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cd72a49
to
869fe3d
Compare
Also, I would suggest adding a changelog entry, but it is your call :) |
869fe3d
to
d5c9098
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving, but please add those periods. Period.
d5c9098
to
81a3efc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the discussion, understood that this is the first step for bidirection feature. And will keep improve for supporting TWS in the later.
81a3efc
to
4427168
Compare
4427168
to
0087d15
Compare
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
applications/nrf5340_audio/src/bluetooth/le_audio_cis_headset.c
Outdated
Show resolved
Hide resolved
0087d15
to
b1656e2
Compare
@@ -91,10 +86,12 @@ Connected Isochronous Stream (CIS) | |||
In this configuration, you can use the nRF5340 Audio development kit in the role of the gateway, the left headset, or the right headset. | |||
|
|||
.. note:: | |||
In the current version of the nRF5340 Audio application, the CIS mode offers only monodirectional communication. | |||
In the current version of the nRF5340 Audio application, the CIS mode offers both unidirectional and bidirectional communication. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@greg-fer It does not look like we need to change the figures
@@ -91,10 +86,12 @@ Connected Isochronous Stream (CIS) | |||
In this configuration, you can use the nRF5340 Audio development kit in the role of the gateway, the left headset, or the right headset. | |||
|
|||
.. note:: | |||
In the current version of the nRF5340 Audio application, the CIS mode offers only monodirectional communication. | |||
In the current version of the nRF5340 Audio application, the CIS mode offers both unidirectional and bidirectional communication. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alexsven It does not look like you have added that (CIS) Testing covers the unidirectional mode.
b1656e2
to
4cb2cd2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remember the part in the documentation Testing section, ref. previous comment
@@ -34,6 +34,7 @@ Overview | |||
The application can work as a gateway or a headset. | |||
The gateway receives the audio data from external sources (USB or I2S) and forwards it to one or more headsets. | |||
The headset is a receiver device that plays back the audio it gets from the gateway. | |||
There is also the bidirectional mode where both gateway and headset can receive and send at the same time. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is also the bidirectional mode where both gateway and headset can receive and send at the same time. | |
It is also possible to enable a bidirectional mode where one gateway and one headset can send and receive audio to and from each other at the same time. |
|
||
Play and pause emulated by disabling and enabling stream, respectively. | ||
- The following limitations apply: | ||
|
||
* BAP unicast, one CIG with two CIS. | ||
* Audio input: USB or I2S (Line in or using Pulse Density Modulation). | ||
* Audio output: USB or I2S/Analog headset output. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isnt it a limitation that only one headset can be used for bidirectional stream?
4cb2cd2
to
fdb05bf
Compare
@@ -196,10 +196,11 @@ config BUF_BLE_RX_PACKET_NUM | |||
gaps due to BLE retransmits. | |||
|
|||
config STREAM_BIDIRECTIONAL | |||
bool "Enable bi-directional stream - Currently not supported" | |||
depends on TRANSPORT_CIS | |||
bool "Enable bidirectional stream" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove enable
as per guide lines:
https://docs.zephyrproject.org/latest/build/kconfig/tips.html#prompt-strings
For a Kconfig symbol that enables a driver/subsystem FOO, consider having just “Foo” as the prompt, instead of “Enable Foo support” or the like.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
@@ -143,8 +142,13 @@ config BT_AUDIO_UNICAST_CLIENT | |||
bool | |||
default y | |||
|
|||
config BT_ISO_TX_BUF_COUNT | |||
int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this is just changing the default then there is no need for the int
type.
int |
https://docs.zephyrproject.org/latest/build/kconfig/tips.html#common-kconfig-shorthands
For a symbol defined in multiple locations (e.g., in a Kconfig.defconfig file in Zephyr), it is best to only give the symbol type for the “base” definition of the symbol
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, I removed all int, bool, string etc from this file. But the rest of the Kconfig.default files we should do as a separate PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But the rest of the Kconfig.default files we should do as a separate PR
agreed.
config BT_ISO_TX_BUF_COUNT | ||
int | ||
default 2 | ||
|
||
config BT_MAX_CONN | ||
int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know this is existing code, but when update the default then please remove the int
type.
int |
default 2 | ||
|
||
config BT_AUDIO_UNICAST_CLIENT_ASE_SRC_COUNT | ||
int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
int |
int | ||
default 1 if STREAM_BIDIRECTIONAL | ||
default 0 | ||
|
||
config BT_VCS_CLIENT | ||
bool |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bool |
@@ -159,6 +163,16 @@ config BT_AUDIO_UNICAST_CLIENT_GROUP_STREAM_COUNT | |||
int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
int |
Implement a microphone return stream from left headset to gateway Signed-off-by: Erik Robstad <erik.robstad@nordicsemi.no> Signed-off-by: Alexander Svensen <alexander.svensen@nordicsemi.no>
fdb05bf
to
d016088
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Implement a microphone return stream from
left headset to gateway
Signed-off-by: Erik Robstad erik.robstad@nordicsemi.no