feat(bt/bqb): Add setting local di record function for bt classic hid device bqb test

This commit is contained in:
wanglai@espressif.com 2023-08-01 11:45:50 +08:00 committed by BOT
parent 25b1e6fe36
commit f9fd217020
2 changed files with 23 additions and 0 deletions

View File

@ -317,4 +317,21 @@ static const char *bta_hd_state_code(tBTA_HD_STATE state_code)
return "<unknown>";
}
}
#if BT_HID_DEVICE_BQB_INCLUDED
tBTA_STATUS bta_hd_bqb_set_local_di_record(void)
{
tBTA_STATUS status = BTA_FAILURE;
tBTA_DI_RECORD bqb_device_info;
bqb_device_info.vendor = 0;
bqb_device_info.vendor_id_source = 0xff; // BTA_HH_VENDOR_ID_INVALID
bqb_device_info.product = 1;
bqb_device_info.version = 0;
bqb_device_info.primary_record = TRUE;
return BTA_DmSetLocalDiRecord(&bqb_device_info, &bta_hd_cb.sdp_handle);
}
#endif /* BT_HID_DEVICE_BQB_INCLUDED */
#endif /* BTA_HD_INCLUDED */

View File

@ -2045,6 +2045,12 @@
#define HID_DEV_FLUSH_TO 0xffff
#endif
#if (BTA_HD_INCLUDED == TRUE) && (HID_DEV_INCLUDED == TRUE) && (BT_CLASSIC_BQB_INCLUDED == TRUE)
#define BT_HID_DEVICE_BQB_INCLUDED TRUE
#else
#define BT_HID_DEVICE_BQB_INCLUDED FALSE
#endif
/*************************************************************************
** Definitions for Both HID-Host & Device
*/