Devices are unlikely to change appearance over time which is the reason
why we cache then on the storage so this skips reading it on every
reconnection.
Signed-off-by: Manika Shrivastava <manika.sh@samsung.com>
Signed-off-by: Ayush Garg <ayush.garg@samsung.com>
static void handle_appearance(struct gas *gas, uint16_t value_handle)
{
+ uint16_t value;
+
+ if (!device_get_appearance(gas->device, &value))
+ return;
+
if (!bt_gatt_client_read_value(gas->client, value_handle,
read_appearance_cb, gas, NULL))
DBG("Failed to send request to read appearance");