1 /* @file 2 * @brief Media Control Service internal header file 3 * 4 * Copyright (c) 2020 - 2021 Nordic Semiconductor ASA 5 * 6 * SPDX-License-Identifier: Apache-2.0 7 */ 8 #ifndef ZEPHYR_SUBSYS_BLUETOOTH_HOST_AUDIO_MCS_INTERNAL_H_ 9 #define ZEPHYR_SUBSYS_BLUETOOTH_HOST_AUDIO_MCS_INTERNAL_H_ 10 11 #include <stdbool.h> 12 #include <zephyr/types.h> 13 #include <zephyr/bluetooth/gatt.h> 14 15 #ifdef __cplusplus 16 extern "C" { 17 #endif 18 19 /* This differs from BT_OTS_VALID_OBJ_ID as MCS does not use the directory list object */ 20 #define BT_MCS_VALID_OBJ_ID(id) (IN_RANGE((id), BT_OTS_OBJ_ID_MIN, BT_OTS_OBJ_ID_MAX)) 21 22 #define BT_MCS_VALID_OP(opcode) \ 23 (IN_RANGE((opcode), BT_MCS_OPC_PLAY, BT_MCS_OPC_STOP) || \ 24 (opcode == BT_MCS_OPC_MOVE_RELATIVE) || \ 25 IN_RANGE((opcode), BT_MCS_OPC_PREV_SEGMENT, BT_MCS_OPC_GOTO_SEGMENT) || \ 26 IN_RANGE((opcode), BT_MCS_OPC_PREV_TRACK, BT_MCS_OPC_GOTO_TRACK) || \ 27 IN_RANGE((opcode), BT_MCS_OPC_PREV_GROUP, BT_MCS_OPC_GOTO_GROUP)) 28 29 int bt_mcs_init(struct bt_ots_cb *ots_cbs); 30 31 #ifdef __cplusplus 32 } 33 #endif 34 35 #endif /* ZEPHYR_SUBSYS_BLUETOOTH_HOST_AUDIO_MCS_INTERNAL_H_ */ 36