1 /* 2 * Copyright (C) 2016 BlueKitchen GmbH 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 8 * 1. Redistributions of source code must retain the above copyright 9 * notice, this list of conditions and the following disclaimer. 10 * 2. Redistributions in binary form must reproduce the above copyright 11 * notice, this list of conditions and the following disclaimer in the 12 * documentation and/or other materials provided with the distribution. 13 * 3. Neither the name of the copyright holders nor the names of 14 * contributors may be used to endorse or promote products derived 15 * from this software without specific prior written permission. 16 * 4. Any redistribution, use, or modification is done solely for 17 * personal benefit and not for any commercial purpose or for 18 * monetary gain. 19 * 20 * THIS SOFTWARE IS PROVIDED BY BLUEKITCHEN GMBH AND CONTRIBUTORS 21 * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 23 * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL MATTHIAS 24 * RINGWALD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 25 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 26 * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS 27 * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 28 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 29 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF 30 * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31 * SUCH DAMAGE. 32 * 33 * Please inquire about commercial licensing options at 34 * [email protected] 35 * 36 */ 37 38 /* 39 * avdtp.h 40 * 41 * Audio/Video Distribution Transport Protocol 42 * 43 * This protocol defines A/V stream negotiation, establishment, and transmission 44 * procedures. Also specified are the message formats that are exchanged between 45 * such devices to transport their A/V streams in A/V distribution applications. 46 * 47 * Media packets are unidirectional, they travel downstream from AVDTP Source to AVDTP Sink. 48 */ 49 50 #ifndef __AVDTP_H 51 #define __AVDTP_H 52 53 #include <stdint.h> 54 #include "hci.h" 55 #include "classic/btstack_sbc.h" 56 #include "btstack_ring_buffer.h" 57 58 #if defined __cplusplus 59 extern "C" { 60 #endif 61 62 #define MAX_NUM_SEPS 10 63 64 // protocols 65 #define PSM_AVCTP 0x0017 66 #define PSM_AVDTP 0x0019 67 68 // service classes 69 #define AUDIO_SOURCE_GROUP 0x110A 70 #define AUDIO_SINK_GROUP 0x110B 71 #define ADVANCED_AUDIO_DISTRIBUTION 0X110D 72 73 #define MAX_CSRC_NUM 15 74 75 // Supported Features 76 #define AVDTP_SOURCE_SF_Player 0x0001 77 #define AVDTP_SOURCE_SF_Microphone 0x0002 78 #define AVDTP_SOURCE_SF_Tuner 0x0004 79 #define AVDTP_SOURCE_SF_Mixer 0x0008 80 81 #define AVDTP_SINK_SF_Headphone 0x0001 82 #define AVDTP_SINK_SF_Speaker 0x0002 83 #define AVDTP_SINK_SF_Recorder 0x0004 84 #define AVDTP_SINK_SF_Amplifier 0x0008 85 86 // ACP to INT, Signal Response Header Error Codes 87 #define BAD_HEADER_FORMAT 0x01 88 89 // ACP to INT, Signal Response Payload Format Error Codes 90 #define BAD_LENGTH 0x11 91 #define BAD_ACP_SEID 0x12 92 #define SEP_IN_USE 0x13 93 #define SEP_NOT_IN_USE 0x14 94 #define BAD_SERV_CATEGORY 0x17 95 #define BAD_PAYLOAD_FORMAT 0x18 96 #define NOT_SUPPORTED_COMMAND 0x19 97 #define INVALID_CAPABILITIES 0x1A 98 99 // ACP to INT, Signal Response Transport Service Capabilities Error Codes 100 #define BAD_RECOVERY_TYPE 0x22 101 #define BAD_MEDIA_TRANSPORT_FORMAT 0x23 102 #define BAD_RECOVERY_FORMAT 0x25 103 #define BAD_ROHC_FORMAT 0x26 104 #define BAD_CP_FORMAT 0x27 105 #define BAD_MULTIPLEXING_FORMAT 0x28 106 #define UNSUPPORTED_CONFIGURATION 0x29 107 108 // ACP to INT, Procedure Error Codes 109 #define BAD_STATE 0x31 110 // Signal Identifier fields 111 typedef enum { 112 AVDTP_SI_DISCOVER = 0x01, 113 AVDTP_SI_GET_CAPABILITIES, 114 AVDTP_SI_SET_CONFIGURATION, 115 AVDTP_SI_GET_CONFIGURATION, 116 AVDTP_SI_RECONFIGURE, //5 117 AVDTP_SI_OPEN, //6 118 AVDTP_SI_START, //7 119 AVDTP_SI_CLOSE, 120 AVDTP_SI_SUSPEND, 121 AVDTP_SI_ABORT, //10 122 AVDTP_SI_SECURITY_CONTROL, 123 AVDTP_SI_GET_ALL_CAPABILITIES, //12 124 AVDTP_SI_DELAYREPORT 125 } avdtp_signal_identifier_t; 126 127 typedef enum { 128 AVDTP_SINGLE_PACKET= 0, 129 AVDTP_START_PACKET , 130 AVDTP_CONTINUE_PACKET , 131 AVDTP_END_PACKET 132 } avdtp_packet_type_t; 133 134 typedef enum { 135 AVDTP_CMD_MSG = 0, 136 AVDTP_GENERAL_REJECT_MSG , 137 AVDTP_RESPONSE_ACCEPT_MSG , 138 AVDTP_RESPONSE_REJECT_MSG 139 } avdtp_message_type_t; 140 141 typedef enum{ 142 AVDTP_AUDIO = 0, 143 AVDTP_VIDEO, 144 AVDTP_MULTIMEDIA 145 } avdtp_media_type_t; 146 147 typedef enum{ 148 AVDTP_CODEC_SBC = 0x00, 149 AVDTP_CODEC_MPEG_1_2_AUDIO = 0x01, 150 AVDTP_CODEC_MPEG_2_4_AAC = 0x02, 151 AVDTP_CODEC_ATRAC_FAMILY = 0x04, 152 AVDTP_CODEC_NON_A2DP = 0xFF 153 } avdtp_media_codec_type_t; 154 155 typedef enum{ 156 AVDTP_CONTENT_PROTECTION_DTCP = 0x0001, 157 AVDTP_CONTENT_PROTECTION_SCMS_T = 0x0002 158 } avdtp_content_protection_type_t; 159 160 typedef enum{ 161 AVDTP_SOURCE = 0, 162 AVDTP_SINK 163 } avdtp_sep_type_t; 164 165 typedef enum { 166 AVDTP_SERVICE_CATEGORY_INVALID_0 = 0x00, 167 AVDTP_MEDIA_TRANSPORT = 0X01, 168 AVDTP_REPORTING, 169 AVDTP_RECOVERY, 170 AVDTP_CONTENT_PROTECTION, //4 171 AVDTP_HEADER_COMPRESSION, //5 172 AVDTP_MULTIPLEXING, //6 173 AVDTP_MEDIA_CODEC, //7 174 AVDTP_DELAY_REPORTING, //8 175 AVDTP_SERVICE_CATEGORY_INVALID_FF = 0xFF 176 } avdtp_service_category_t; 177 178 typedef struct { 179 uint8_t recovery_type; // 0x01 = RFC2733 180 uint8_t maximum_recovery_window_size; // 0x01 to 0x18, for a Transport Packet 181 uint8_t maximum_number_media_packets; // 0x01 to 0x18, The maximum number of media packets a specific parity code covers 182 } avdtp_recovery_capabilities_t; 183 184 typedef struct { 185 avdtp_media_type_t media_type; 186 avdtp_media_codec_type_t media_codec_type; 187 uint16_t media_codec_information_len; 188 const uint8_t * media_codec_information; 189 } adtvp_media_codec_capabilities_t; 190 191 typedef struct { 192 uint16_t cp_type; 193 uint16_t cp_type_value_len; 194 const uint8_t * cp_type_value; 195 } adtvp_content_protection_t; 196 197 typedef struct{ 198 uint8_t back_ch; // byte0 - bit 8; 0=Not Available/Not Used; 1=Available/In Use 199 uint8_t media; // byte0 - bit 7 200 uint8_t recovery; // byte0 - bit 6 201 } avdtp_header_compression_capabilities_t; 202 203 typedef struct{ 204 uint8_t fragmentation; // byte0 - bit 8, Allow Adaptation Layer Fragmentation, 0 no, 1 yes 205 // Request/indicate value of the Transport Session Identifier for a media, reporting, or recovery transport sessions, respectively 206 uint8_t transport_identifiers_num; 207 uint8_t transport_session_identifiers[3]; // byte1, upper 5bits, 0x01 to 0x1E 208 // Request/indicate value for TCID for a media, reporting, or transport session 209 uint8_t tcid[3]; // byte2 0x01 to 0x1E 210 } avdtp_multiplexing_mode_capabilities_t; 211 212 typedef struct{ 213 avdtp_recovery_capabilities_t recovery; 214 adtvp_media_codec_capabilities_t media_codec; 215 adtvp_content_protection_t content_protection; 216 avdtp_header_compression_capabilities_t header_compression; 217 avdtp_multiplexing_mode_capabilities_t multiplexing_mode; 218 } avdtp_capabilities_t; 219 220 typedef enum{ 221 AVDTP_SBC_48000 = 1, 222 AVDTP_SBC_44100 = 2, 223 AVDTP_SBC_32000 = 4, 224 AVDTP_SBC_16000 = 8 225 } avdtp_sbc_sampling_frequency_t; 226 227 typedef enum{ 228 AVDTP_SBC_JOINT_STEREO = 1, 229 AVDTP_SBC_STEREO = 2, 230 AVDTP_SBC_DUAL_CHANNEL = 4, 231 AVDTP_SBC_MONO = 8 232 } avdtp_sbc_channel_mode_t; 233 234 typedef enum{ 235 AVDTP_SBC_BLOCK_LENGTH_16 = 1, 236 AVDTP_SBC_BLOCK_LENGTH_12 = 2, 237 AVDTP_SBC_BLOCK_LENGTH_8 = 4, 238 AVDTP_SBC_BLOCK_LENGTH_4 = 8 239 } avdtp_sbc_block_length_t; 240 241 typedef enum{ 242 AVDTP_SBC_SUBBANDS_8 = 1, 243 AVDTP_SBC_SUBBANDS_4 = 2 244 } avdtp_sbc_subbands_t; 245 246 typedef enum{ 247 AVDTP_SBC_ALLOCATION_METHOD_LOUDNESS = 1, 248 AVDTP_SBC_ALLOCATION_METHOD_SNR = 2 249 } avdtp_sbc_allocation_method_t; 250 251 typedef struct { 252 uint8_t fragmentation; 253 uint8_t starting_packet; // of fragmented SBC frame 254 uint8_t last_packet; // of fragmented SBC frame 255 uint8_t num_frames; 256 } avdtp_sbc_codec_header_t; 257 258 // typedef struct { 259 // uint8_t transaction_label; 260 // avdtp_packet_type_t packet_type; 261 // avdtp_message_type_t message_type; 262 // uint8_t signal_identifier; 263 // } avdtp_signaling_packet_header_t; 264 265 typedef struct { 266 uint8_t version; 267 uint8_t padding; 268 uint8_t extension; 269 uint8_t csrc_count; 270 uint8_t marker; 271 uint8_t payload_type; 272 273 uint16_t sequence_number; 274 uint32_t timestamp; 275 uint32_t synchronization_source; 276 277 uint32_t csrc_list[MAX_CSRC_NUM]; 278 } avdtp_media_packet_header_t; 279 280 typedef enum { 281 AVDTP_BASIC_SERVICE_MODE, 282 AVDTP_MULTIPLEXING_SERVICE_MODE 283 } avdtp_service_mode_t; 284 285 typedef enum { 286 AVDTP_STREAM_ENDPOINT_IDLE, 287 AVDTP_STREAM_ENDPOINT_CONFIGURATION_SUBSTATEMACHINE, 288 AVDTP_STREAM_ENDPOINT_CONFIGURED, 289 290 AVDTP_STREAM_ENDPOINT_W2_REQUEST_OPEN_STREAM, 291 AVDTP_STREAM_ENDPOINT_W4_L2CAP_FOR_MEDIA_CONNECTED, 292 293 AVDTP_STREAM_ENDPOINT_OPENED, 294 AVDTP_STREAM_ENDPOINT_STREAMING, 295 AVDTP_STREAM_ENDPOINT_STREAMING_W2_SEND, 296 297 AVDTP_STREAM_ENDPOINT_CLOSING, 298 AVDTP_STREAM_ENDPOINT_ABORTING, 299 AVDTP_STREAM_ENDPOINT_W4_L2CAP_FOR_MEDIA_DISCONNECTED 300 } avdtp_stream_endpoint_state_t; 301 302 typedef enum { 303 AVDTP_INITIATOR_STREAM_CONFIG_IDLE, 304 AVDTP_INITIATOR_W2_SET_CONFIGURATION, 305 AVDTP_INITIATOR_W2_SUSPEND_STREAM_WITH_SEID, 306 AVDTP_INITIATOR_W2_RECONFIGURE_STREAM_WITH_SEID, 307 308 AVDTP_INITIATOR_W2_OPEN_STREAM, 309 310 AVDTP_INITIATOR_W2_STREAMING_START, 311 AVDTP_INITIATOR_W2_STREAMING_STOP, 312 AVDTP_INITIATOR_W2_STREAMING_ABORT, 313 AVDTP_INITIATOR_FRAGMENTATED_COMMAND, 314 AVDTP_INITIATOR_W4_ANSWER 315 } avdtp_initiator_stream_endpoint_state_t; 316 317 typedef enum { 318 AVDTP_ACCEPTOR_STREAM_CONFIG_IDLE, 319 AVDTP_ACCEPTOR_W2_ANSWER_GET_CAPABILITIES, 320 AVDTP_ACCEPTOR_W2_ANSWER_GET_ALL_CAPABILITIES, 321 AVDTP_ACCEPTOR_W2_ANSWER_SET_CONFIGURATION, 322 AVDTP_ACCEPTOR_W2_ANSWER_RECONFIGURE, 323 AVDTP_ACCEPTOR_W2_ANSWER_GET_CONFIGURATION, 324 AVDTP_ACCEPTOR_W2_ANSWER_OPEN_STREAM, 325 AVDTP_ACCEPTOR_W2_ANSWER_START_STREAM, 326 AVDTP_ACCEPTOR_W2_ANSWER_CLOSE_STREAM, 327 AVDTP_ACCEPTOR_W2_ANSWER_ABORT_STREAM, 328 AVDTP_ACCEPTOR_W2_SUSPEND_STREAM_WITH_SEID, 329 AVDTP_ACCEPTOR_W2_ANSWER_SUSPEND_STREAM, 330 AVDTP_ACCEPTOR_W2_REJECT_WITH_ERROR_CODE, 331 AVDTP_ACCEPTOR_W2_REJECT_CATEGORY_WITH_ERROR_CODE, 332 AVDTP_ACCEPTOR_W2_REJECT_UNKNOWN_CMD, 333 AVDTP_ACCEPTOR_STREAMING 334 } avdtp_acceptor_stream_endpoint_state_t; 335 336 typedef struct { 337 uint8_t seid; // 0x01 – 0x3E, 6bit 338 uint8_t in_use; // 1 bit, 0 - not in use, 1 - in use 339 avdtp_media_type_t media_type; // 4 bit 340 avdtp_sep_type_t type; // 1 bit, 0 - SRC, 1 - SNK 341 342 uint16_t registered_service_categories; 343 avdtp_capabilities_t capabilities; 344 345 uint16_t configured_service_categories; 346 avdtp_capabilities_t configuration; 347 } avdtp_sep_t; 348 349 350 typedef enum { 351 AVDTP_SIGNALING_CONNECTION_IDLE, 352 AVDTP_SIGNALING_CONNECTION_W4_L2CAP_CONNECTED, 353 AVDTP_SIGNALING_CONNECTION_OPENED, 354 AVDTP_SIGNALING_CONNECTION_W4_L2CAP_DISCONNECTED 355 } avdtp_connection_state_t; 356 357 typedef enum { 358 AVDTP_SIGNALING_CONNECTION_ACCEPTOR_IDLE, 359 AVDTP_SIGNALING_CONNECTION_ACCEPTOR_W2_ANSWER_DISCOVER_SEPS, 360 AVDTP_SIGNALING_CONNECTION_ACCEPTOR_W2_REJECT_WITH_ERROR_CODE, 361 AVDTP_SIGNALING_CONNECTION_ACCEPTOR_W2_REJECT_CATEGORY_WITH_ERROR_CODE, 362 AVDTP_SIGNALING_CONNECTION_ACCEPTOR_W2_GENERAL_REJECT_WITH_ERROR_CODE 363 } avdtp_acceptor_connection_state_t; 364 365 typedef enum { 366 AVDTP_SIGNALING_CONNECTION_INITIATOR_IDLE, 367 AVDTP_SIGNALING_CONNECTION_INITIATOR_W2_DISCOVER_SEPS, 368 AVDTP_SIGNALING_CONNECTION_INITIATOR_W2_GET_CAPABILITIES, 369 AVDTP_SIGNALING_CONNECTION_INITIATOR_W2_GET_ALL_CAPABILITIES, 370 AVDTP_SIGNALING_CONNECTION_INITIATOR_W2_GET_CONFIGURATION, 371 AVDTP_SIGNALING_CONNECTION_INITIATOR_W4_ANSWER 372 } avdtp_initiator_connection_state_t; 373 374 typedef struct { 375 uint8_t command[200]; 376 uint16_t size; 377 uint16_t offset; 378 avdtp_signal_identifier_t signal_identifier; 379 avdtp_message_type_t message_type; 380 avdtp_packet_type_t packet_type; 381 uint8_t acp_seid; 382 uint8_t int_seid; 383 uint16_t transaction_label; 384 uint16_t num_packets; 385 } avdtp_signaling_packet_t; 386 387 typedef struct { 388 btstack_linked_item_t item; 389 390 bd_addr_t remote_addr; 391 hci_con_handle_t con_handle; 392 uint16_t l2cap_signaling_cid; 393 avdtp_service_mode_t service_mode; 394 395 avdtp_connection_state_t state; 396 avdtp_acceptor_connection_state_t acceptor_connection_state; 397 avdtp_initiator_connection_state_t initiator_connection_state; 398 399 // used for fragmentation 400 // avdtp_signaling_packet_header_t signaling_header; 401 avdtp_signaling_packet_t signaling_packet; 402 403 uint8_t disconnect; 404 405 uint8_t initiator_transaction_label; 406 uint8_t acceptor_transaction_label; 407 uint8_t query_seid; 408 uint8_t int_seid; 409 uint8_t acp_seid; 410 411 avdtp_capabilities_t remote_capabilities; 412 uint16_t remote_capabilities_bitmap; 413 414 uint8_t wait_to_send_acceptor; 415 uint8_t wait_to_send_initiator; 416 uint8_t wait_to_send_self; 417 418 uint8_t suspended_seids[MAX_NUM_SEPS]; 419 uint8_t num_suspended_seids; 420 421 uint8_t reject_service_category; 422 avdtp_signal_identifier_t reject_signal_identifier; 423 uint8_t error_code; 424 } avdtp_connection_t; 425 426 427 typedef struct avdtp_stream_endpoint { 428 btstack_linked_item_t item; 429 430 // original capabilities 431 avdtp_sep_t sep; 432 uint16_t l2cap_media_cid; 433 uint16_t l2cap_reporting_cid; 434 uint16_t l2cap_recovery_cid; 435 436 avdtp_stream_endpoint_state_t state; 437 avdtp_acceptor_stream_endpoint_state_t acceptor_config_state; 438 avdtp_initiator_stream_endpoint_state_t initiator_config_state; 439 440 // active connection 441 avdtp_connection_t * connection; 442 // store configurations with remote seps 443 avdtp_sep_t remote_seps[MAX_NUM_SEPS]; 444 uint8_t remote_seps_num; 445 446 // currently active remote seid 447 uint8_t remote_sep_index; 448 // register request for media L2cap connection release 449 uint8_t media_disconnect; 450 uint8_t media_connect; 451 452 btstack_timer_source_t fill_audio_ring_buffer_timer; 453 uint32_t time_audio_data_sent; // ms 454 uint32_t acc_num_missed_samples; 455 btstack_sbc_encoder_state_t sbc_encoder_state; 456 uint16_t sequence_number; 457 458 btstack_ring_buffer_t audio_ring_buffer; 459 btstack_ring_buffer_t sbc_ring_buffer; 460 } avdtp_stream_endpoint_t; 461 462 typedef struct { 463 btstack_linked_list_t connections; 464 btstack_linked_list_t stream_endpoints; 465 uint16_t stream_endpoints_id_counter; 466 btstack_packet_handler_t avdtp_callback; 467 void (*handle_media_data)(avdtp_stream_endpoint_t * stream_endpoint, uint8_t *packet, uint16_t size); 468 btstack_packet_handler_t packet_handler; 469 } avdtp_context_t; 470 471 void avdtp_register_media_transport_category(avdtp_stream_endpoint_t * stream_endpoint); 472 void avdtp_register_reporting_category(avdtp_stream_endpoint_t * stream_endpoint); 473 void avdtp_register_delay_reporting_category(avdtp_stream_endpoint_t * stream_endpoint); 474 void avdtp_register_recovery_category(avdtp_stream_endpoint_t * stream_endpoint, uint8_t maximum_recovery_window_size, uint8_t maximum_number_media_packets); 475 void avdtp_register_content_protection_category(avdtp_stream_endpoint_t * stream_endpoint, uint16_t cp_type, const uint8_t * cp_type_value, uint8_t cp_type_value_len); 476 void avdtp_register_header_compression_category(avdtp_stream_endpoint_t * stream_endpoint, uint8_t back_ch, uint8_t media, uint8_t recovery); 477 void avdtp_register_media_codec_category(avdtp_stream_endpoint_t * stream_endpoint, avdtp_media_type_t media_type, avdtp_media_codec_type_t media_codec_type, const uint8_t * media_codec_info, uint16_t media_codec_info_len); 478 void avdtp_register_multiplexing_category(avdtp_stream_endpoint_t * stream_endpoint, uint8_t fragmentation); 479 void avdtp_handle_can_send_now(avdtp_connection_t * connection, uint16_t l2cap_cid, avdtp_context_t * context); 480 481 void avdtp_packet_handler(uint8_t packet_type, uint16_t channel, uint8_t *packet, uint16_t size, avdtp_context_t * context); 482 avdtp_connection_t * avdtp_create_connection(bd_addr_t remote_addr, avdtp_context_t * context); 483 avdtp_stream_endpoint_t * avdtp_create_stream_endpoint(avdtp_sep_type_t sep_type, avdtp_media_type_t media_type, avdtp_context_t * context); 484 485 void avdtp_disconnect(uint16_t con_handle, avdtp_context_t * context); 486 void avdtp_open_stream(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 487 void avdtp_start_stream(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 488 void avdtp_stop_stream(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 489 void avdtp_abort_stream(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 490 void avdtp_discover_stream_endpoints(uint16_t con_handle, avdtp_context_t * context); 491 void avdtp_get_capabilities(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 492 void avdtp_get_all_capabilities(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 493 void avdtp_get_configuration(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 494 void avdtp_set_configuration(uint16_t con_handle, uint8_t int_seid, uint8_t acp_seid, uint16_t configured_services_bitmap, avdtp_capabilities_t configuration, avdtp_context_t * context); 495 void avdtp_reconfigure(uint16_t con_handle, uint8_t acp_seid, uint16_t configured_services_bitmap, avdtp_capabilities_t configuration, avdtp_context_t * context); 496 void avdtp_suspend(uint16_t con_handle, uint8_t acp_seid, avdtp_context_t * context); 497 498 void avdtp_source_stream_data_start(uint16_t con_handle); 499 void avdtp_source_stream_data_stop(uint16_t con_handle); 500 501 #if defined __cplusplus 502 } 503 #endif 504 505 #endif // __AVDTP_H