仓库指标
- 星标
- (15,249 个星标)
- PR 合并指标
- (PR 指标待抓取)
描述
Is your enhancement proposal related to a problem? Please describe. The VOCS client subscribes to the VOCS state, location and description, but it assumes that the CCC is the next characteristic by hard-coding the handle offset:
/*
* TODO: Don't assume that CCC is at handle + 2;
* do proper discovery;
*/
sub_params->ccc_handle = attr->handle + 2;
Describe the solution you'd like
The VOCS client should perform a proper discovery of the CCC characteristic and subscribe to it, even if it is not at handle + 2. For this the CONFIG_BT_GATT_AUTO_DISCOVER_CCC feature can be used, which is already used in most parts of LE Audio.
Ideally the use of CONFIG_BT_GATT_AUTO_DISCOVER_CCC should re-use the initial discovery parameter struct, so as not to increase memory usage.
Describe alternatives you've considered N/A
Additional context N/A