zephyrproject-rtos/zephyr

Bluetooth: VOCS: Client: Use CCC auto discover

已关闭

#81,132 创建于 2024年11月8日

 (1 条评论) (0 个反应) (2 位负责人)C (9,144 个派生)batch import
EnhancementGood first issuearea: Bluetootharea: Bluetooth Audio

仓库指标

星标
 (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

贡献者指南