Skip to content

Commit

Permalink
Fixed bluetooth SC samples
Browse files Browse the repository at this point in the history
Fixed bluetooth SC samples to build in modern zephyr.

Signed-off-by: Jared Baumann <jared.baumann8@t-mobile.com>
  • Loading branch information
jtbaumann committed Feb 16, 2023
1 parent 166f661 commit 438dcf9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
5 changes: 5 additions & 0 deletions samples/bluetooth/peripheral_sc_only/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,9 @@ static struct bt_conn_auth_cb auth_cb_display = {
.passkey_display = auth_passkey_display,
.passkey_entry = NULL,
.cancel = auth_cancel,
};

static struct bt_conn_auth_info_cb auth_info_cb = {
.pairing_complete = pairing_complete,
.pairing_failed = pairing_failed,
};
Expand All @@ -137,7 +140,9 @@ void main(void)


bt_conn_auth_cb_register(&auth_cb_display);
bt_conn_auth_info_cb_register(&auth_info_cb);
bt_conn_cb_register(&conn_callbacks);


err = bt_le_adv_start(BT_LE_ADV_CONN_NAME, ad, ARRAY_SIZE(ad), NULL, 0);
if (err) {
Expand Down
7 changes: 6 additions & 1 deletion samples/bluetooth/sc_extensive_test/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,10 @@ static struct bt_conn_auth_cb auth_cb_display = {
.passkey_entry = NULL,
.cancel = auth_cancel,
.passkey_confirm = NULL,

};

static struct bt_conn_auth_info_cb auth_info_cb = {
.pairing_complete = pairing_complete,
.pairing_failed = pairing_failed,
};
Expand All @@ -168,6 +172,7 @@ void main(void)


bt_conn_auth_cb_register(&auth_cb_display);
bt_conn_auth_info_cb_register(&auth_info_cb);
bt_conn_cb_register(&conn_callbacks);

err = bt_le_adv_start(BT_LE_ADV_CONN_NAME, ad, ARRAY_SIZE(ad), NULL, 0);
Expand Down Expand Up @@ -276,4 +281,4 @@ SHELL_STATIC_SUBCMD_SET_CREATE(ble_smp_9116_sub,
SHELL_SUBCMD_SET_END
);
// static int ble_list_connected(const struct shell *shell, int argc, char **argv)
SHELL_CMD_REGISTER(testapp, &ble_smp_9116_sub, "RS9116 SMP test commands", NULL);
SHELL_CMD_REGISTER(testapp, &ble_smp_9116_sub, "RS9116 SMP test commands", NULL);

0 comments on commit 438dcf9

Please sign in to comment.