Zephyr API Documentation 4.0.0-rc3
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
tmap.h
Go to the documentation of this file.
1
11#ifndef ZEPHYR_INCLUDE_BLUETOOTH_AUDIO_TMAP_
12#define ZEPHYR_INCLUDE_BLUETOOTH_AUDIO_TMAP_
13
29#include <zephyr/autoconf.h>
31#include <zephyr/sys/util.h>
33
35#define BT_TMAP_CG_SUPPORTED \
36 (IS_ENABLED(CONFIG_BT_CAP_INITIATOR) && IS_ENABLED(CONFIG_BT_BAP_UNICAST_CLIENT) && \
37 IS_ENABLED(CONFIG_BT_TBS) && IS_ENABLED(CONFIG_BT_VCP_VOL_CTLR))
38
40#define BT_TMAP_CT_SUPPORTED \
41 (IS_ENABLED(CONFIG_BT_CAP_ACCEPTOR) && IS_ENABLED(CONFIG_BT_BAP_UNICAST_SERVER) && \
42 IS_ENABLED(CONFIG_BT_TBS_CLIENT) && \
43 (IS_ENABLED(CONFIG_BT_ASCS_ASE_SNK) && \
44 IS_ENABLED(CONFIG_BT_VCP_VOL_REND) == IS_ENABLED(CONFIG_BT_ASCS_ASE_SNK)))
45
47#define BT_TMAP_UMS_SUPPORTED \
48 (IS_ENABLED(CONFIG_BT_CAP_INITIATOR) && \
49 IS_ENABLED(CONFIG_BT_BAP_UNICAST_CLIENT_ASE_SNK) && IS_ENABLED(CONFIG_BT_VCP_VOL_CTLR) && \
50 IS_ENABLED(CONFIG_BT_MCS))
51
53#define BT_TMAP_UMR_SUPPORTED \
54 (IS_ENABLED(CONFIG_BT_CAP_ACCEPTOR) && IS_ENABLED(CONFIG_BT_ASCS_ASE_SNK) && \
55 IS_ENABLED(CONFIG_BT_VCP_VOL_REND))
56
58#define BT_TMAP_BMS_SUPPORTED \
59 (IS_ENABLED(CONFIG_BT_CAP_INITIATOR) && IS_ENABLED(CONFIG_BT_BAP_BROADCAST_SOURCE))
60
62#define BT_TMAP_BMR_SUPPORTED \
63 (IS_ENABLED(CONFIG_BT_CAP_ACCEPTOR) && IS_ENABLED(CONFIG_BT_BAP_BROADCAST_SINK))
64
112
125 void (*discovery_complete)(enum bt_tmap_role role, struct bt_conn *conn, int err);
126};
127
136
145int bt_tmap_discover(struct bt_conn *conn, const struct bt_tmap_cb *tmap_cb);
146
155
160#endif /* ZEPHYR_INCLUDE_BLUETOOTH_AUDIO_TMAP_ */
Bluetooth connection handling.
void bt_tmap_set_role(enum bt_tmap_role role)
Set one or multiple TMAP roles dynamically.
int bt_tmap_register(enum bt_tmap_role role)
Adds TMAS instance to database and sets the received TMAP role(s).
bt_tmap_role
TMAP Role characteristic.
Definition tmap.h:66
int bt_tmap_discover(struct bt_conn *conn, const struct bt_tmap_cb *tmap_cb)
Perform service discovery as TMAP Client.
@ BT_TMAP_ROLE_UMR
TMAP Unicast Media Receiver role.
Definition tmap.h:96
@ BT_TMAP_ROLE_UMS
TMAP Unicast Media Sender role.
Definition tmap.h:89
@ BT_TMAP_ROLE_CG
TMAP Call Gateway role.
Definition tmap.h:74
@ BT_TMAP_ROLE_BMS
TMAP Broadcast Media Sender role.
Definition tmap.h:103
@ BT_TMAP_ROLE_CT
TMAP Call Terminal role.
Definition tmap.h:82
@ BT_TMAP_ROLE_BMR
TMAP Broadcast Media Receiver role.
Definition tmap.h:110
#define BIT(n)
Unsigned integer with bit position n set (signed in assembly language).
Definition util_macro.h:44
TMAP callback structure.
Definition tmap.h:114
void(* discovery_complete)(enum bt_tmap_role role, struct bt_conn *conn, int err)
TMAP discovery complete callback.
Definition tmap.h:125
Misc utilities.
Macro utilities.