Skip to content

Commit 9204e64

Browse files
samples: bluetooth: llpm: Enable sample to run without security protocol
On devices where security manager has not yet been implemented, it is useful to still be able to test bluetooth functionality through llpm sample. Signed-off-by: Robert Robinson <[email protected]>
1 parent b987a8b commit 9204e64

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Disabled Bluetooth Security Manager while crypto is not supported
2+
CONFIG_BT_SMP=n

samples/bluetooth/llpm/src/main.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,13 @@ static void connected(struct bt_conn *conn, uint8_t err)
200200
if (err) {
201201
printk("Failed to set security: %d\n", err);
202202
}
203+
#else
204+
/*Start service discovery*/
205+
err = bt_gatt_dm_start(default_conn, BT_UUID_LATENCY, &discovery_cb,
206+
&latency_client);
207+
if (err) {
208+
printk("Discover failed (err %d)\n", err);
209+
}
203210
#endif /* CONFIG_BT_SMP */
204211
}
205212

0 commit comments

Comments
 (0)