mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-26 21:35:16 +00:00
avdtp: introduce avdtp_configuration_state
This commit is contained in:
parent
62430644b6
commit
e57d740485
@ -345,6 +345,7 @@ avdtp_connection_t * avdtp_create_connection(bd_addr_t remote_addr, avdtp_contex
|
||||
connection->state = AVDTP_SIGNALING_CONNECTION_IDLE;
|
||||
connection->initiator_transaction_label = avdtp_get_next_initiator_transaction_label(context);
|
||||
connection->avdtp_cid = avdtp_get_next_avdtp_cid(context);
|
||||
connection->configuration_state = AVDTP_CONFIGURATION_STATE_IDLE;
|
||||
context->avdtp_cid = connection->avdtp_cid;
|
||||
(void)memcpy(connection->remote_addr, remote_addr, 6);
|
||||
btstack_linked_list_add(&context->connections, (btstack_linked_item_t *) connection);
|
||||
|
@ -379,6 +379,13 @@ typedef struct {
|
||||
avdtp_packet_type_t packet_type;
|
||||
} avdtp_signaling_packet_t;
|
||||
|
||||
typedef enum {
|
||||
AVDTP_CONFIGURATION_STATE_IDLE,
|
||||
AVDTP_CONFIGURATION_STATE_LOCAL_INITIATED,
|
||||
AVDTP_CONFIGURATION_STATE_LOCAL_CONFIGURED,
|
||||
AVDTP_CONFIGURATION_STATE_REMOTE_INITIATED,
|
||||
AVDTP_CONFIGURATION_STATE_REMOTE_CONFIGURED,
|
||||
} avtdp_configuration_state_t;
|
||||
|
||||
typedef struct {
|
||||
btstack_linked_item_t item;
|
||||
@ -423,6 +430,9 @@ typedef struct {
|
||||
// avdtp_sep_t remote_seps[AVDTP_MAX_NUM_SEPS];
|
||||
// uint8_t remote_seps_num;
|
||||
|
||||
// configuration state machine
|
||||
avtdp_configuration_state_t configuration_state;
|
||||
|
||||
// store current role
|
||||
uint8_t is_initiator;
|
||||
uint8_t is_configuration_initiated_locally;
|
||||
|
Loading…
x
Reference in New Issue
Block a user