char *desc_uuid;
bt_gatt_characteristic_property_t props;
bt_gatt_permission_t perms;
- char supp_feat[OTP_FEATURE_LENGTH] = { 0xDC, 0x00, 0x00, 0x00,
- 0x80, 0x00, 0x00, 0x00 };
+ char supp_feat[OTP_FEATURE_LENGTH] = { 0x3B, 0x00, 0x00, 0x00,
+ 0x01, 0x00, 0x00, 0x00 };
ret = bluetooth_gatt_init();
if (ret != BLUETOOTH_ERROR_NONE) {
{
int ret = BLUETOOTH_ERROR_NONE;
char value[7] = {0x00};
+ int length = OTP_INDICATION_LEN_WITHOUT_RESP;
BT_DBG("");
value[5] = (info->resp_param[4] >> 16) & 0xFF;
value[4] = (info->resp_param[5] >> 8) & 0xFF;
value[3] = info->resp_param[6] & 0xFF;
+ length = OTP_INDICATION_LEN_WITH_RESP;
}
BT_DBG("Opcode: %d", value[1]);
/* Store the status value */
- _bt_otp_set_char_value(obj_path, value, 7);
+ _bt_otp_set_char_value(obj_path, value, length);
/* Send indication */
ret = bluetooth_gatt_server_set_notification(obj_path, remote_address);
BT_ERR("_bt_otp_send_control_point_indication failed");
return;
}
- ret = bluetooth_gatt_update_characteristic(obj_path, value, 7);
+ ret = bluetooth_gatt_update_characteristic(obj_path, value, length);
if (ret != BLUETOOTH_ERROR_NONE) {
BT_ERR("_bt_otp_send_control_point_indication failed");
return;