Bluetooth: samples: peripheral_dis: Sample requires BT_SETTINGS

The DIS service requires BT_SETTINGS otherwise it will not have a
settings handler. Instead DIS will only use Kconfig to set it's
values.

Fixes: #22478

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
This commit is contained in:
Joakim Andersson 2020-02-05 14:08:09 +01:00 committed by Johan Hedberg
commit 1e80efaa1b
2 changed files with 5 additions and 0 deletions

View file

@ -17,6 +17,7 @@ CONFIG_BT_GATT_DIS_SW_REV_STR="Zephyr Software"
CONFIG_BT_DEVICE_NAME="DIS peripheral"
# Below is setup to let DIS information be read from settings
CONFIG_BT_SETTINGS=y
CONFIG_SETTINGS_RUNTIME=y
CONFIG_SETTINGS=y
CONFIG_SETTINGS_NONE=y

View file

@ -88,6 +88,10 @@ void main(void)
return;
}
if (IS_ENABLED(CONFIG_BT_SETTINGS)) {
settings_load();
}
settings_runtime_load();
printk("Bluetooth initialized\n");