Skip to content
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

Bluetooth: GMAP: Add initial implementation of GMAP #57032

Merged
merged 3 commits into from
Dec 11, 2023

Conversation

Thalley
Copy link
Collaborator

@Thalley Thalley commented Apr 19, 2023

Add initial implementation of GMAP.

This comes with the implementation of all GMAP roles, as well as BSIM and shell support.

Samples are not yet implemented, but may be added as part of this PR or a subsequent PR.

@Thalley Thalley force-pushed the gmap_iop branch 3 times, most recently from 5610d13 to 12d87d4 Compare April 19, 2023 13:18
@Thalley
Copy link
Collaborator Author

Thalley commented Apr 19, 2023

The implementation of TMAP in #56686 and this should be made similar. TBD which changes to be done by either.

@Thalley Thalley force-pushed the gmap_iop branch 23 times, most recently from dcdbe23 to cfd6e0a Compare May 10, 2023 12:53
@Thalley Thalley force-pushed the gmap_iop branch 2 times, most recently from 808659f to 3255e5d Compare May 10, 2023 19:50
Copy link
Contributor

@larsgk larsgk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't try to run it (maybe we should - it's a fairly big PR). Found a few things but otherwise looks ok to me


err = bt_bap_unicast_client_register_cb(&unicast_client_cbs);
if (err != 0) {
FAIL("Failed to register CAP callbacks (err %d)\n", err);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unicast callbacks?

}

if (src_ep_cnt != src_cnt) {
FAIL("Source endpoint and stream count mismatch: %zu != %zu\n", src_ep_cnt,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extra space

Comment on lines 787 to 788
/* Set all endpoints from multiple connections in a single array, and verify that the known
* endpoints matches the audio configuration
*/
for (size_t i = 0U; i < param->conn_cnt; i++) {
for (size_t j = 0U; j < param->snk_cnt[i]; j++) {
snk_cnt++;
}

for (size_t j = 0U; j < param->src_cnt[i]; j++) {
src_cnt++;
}
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment and code doesn't seem to match for me for this block.

subsys/bluetooth/audio/shell/gmap.c Show resolved Hide resolved
static int cmd_gmap_ac_14(const struct shell *sh, size_t argc, char **argv)
{
const struct bap_broadcast_ac_param param = {
.name = "AC_13",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AC_14?

@cvinayak
Copy link
Contributor

@Thalley rebase required.
@larsgk please re-review

larsgk
larsgk previously approved these changes Sep 28, 2023
@Thalley
Copy link
Collaborator Author

Thalley commented Sep 28, 2023

@fredrikdanebjer @kruithofa @cvinayak @MariuszSkamra @Casper-Bonde-Bose it would good to get this (experimental) feature into 3.5 if possible - If you can please review ASAP before the feature freeze tomorrow.

Add initial implementation of Gaming Audio Profile (GMAP).

This is a top layer profile in the LE Audio stack,
designed for low latency audio ideal for gaming.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add the GMAP shell module with support for running the
various audio configurations in an easy way.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Add BSIM testing of GMAP, with all spec-specified audio
configuration combinations added and tested.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
@carlescufi carlescufi merged commit cdd4bc6 into zephyrproject-rtos:main Dec 11, 2023
21 checks passed
@Thalley Thalley deleted the gmap_iop branch December 12, 2023 08:47
@@ -622,6 +622,8 @@ static void connected(struct bt_conn *conn, uint8_t err)
}
}

default_conn = bt_conn_ref(conn);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Thalley, I think this line has been inserted by mistake as it does call twice bt_conn_ref. Is this intentional?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

9 participants