The HIDs sample is currently setup with a passkey callback and requires authenticated write and read access. Add a sample option to disable the passkey callbacks, and automatically set the GATT attributes as encryption required. This is a useful sample setup as real world HID devices (mice, keyboards...) usually don't have a passkey mechanism, and removing the callback to reproduce that setup while not changing the GATT permission leads to automatic disconnections for encryption failures that can be fairly hard to troubleshoot. Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
14 lines
351 B
Plaintext
14 lines
351 B
Plaintext
# Copyright 2023 Google LLC
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
mainmenu "Bluetooth: Peripheral HIDs"
|
|
|
|
config SAMPLE_BT_USE_AUTHENTICATION
|
|
bool "Enable passkey authentication"
|
|
default y
|
|
help
|
|
Enable the passkey authentication callback and register the GATT
|
|
read and and write attributes as authentication required.
|
|
|
|
source "Kconfig.zephyr"
|