l2cap.h (62f901df9794b0d1b972cdf6aeebec4b6f6ed719) l2cap.h (df3354fc67b724e12e38312f95d99fe997e0d46e)
1/*
2 * Copyright (C) 2009-2012 by Matthias Ringwald
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

--- 79 unchanged lines hidden (view full) ---

88// Extended Response Timeout eXpired
89#define L2CAP_ERTX_TIMEOUT_MS 120000
90
91// private structs
92typedef enum {
93 L2CAP_STATE_CLOSED = 1, // no baseband
94 L2CAP_STATE_WILL_SEND_CREATE_CONNECTION,
95 L2CAP_STATE_WAIT_CONNECTION_COMPLETE,
1/*
2 * Copyright (C) 2009-2012 by Matthias Ringwald
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

--- 79 unchanged lines hidden (view full) ---

88// Extended Response Timeout eXpired
89#define L2CAP_ERTX_TIMEOUT_MS 120000
90
91// private structs
92typedef enum {
93 L2CAP_STATE_CLOSED = 1, // no baseband
94 L2CAP_STATE_WILL_SEND_CREATE_CONNECTION,
95 L2CAP_STATE_WAIT_CONNECTION_COMPLETE,
96 L2CAP_STATE_WAIT_SECURITY_LEVEL_UPDATE,
96 L2CAP_STATE_WAIT_REMOTE_SUPPORTED_FEATURES,
97 L2CAP_STATE_WAIT_INCOMING_SECURITY_LEVEL_UPDATE,
98 L2CAP_STATE_WAIT_OUTGOING_SECURITY_LEVEL_UPDATE,
97 L2CAP_STATE_WAIT_CLIENT_ACCEPT_OR_REJECT,
98 L2CAP_STATE_WAIT_CONNECT_RSP, // from peer
99 L2CAP_STATE_CONFIG,
100 L2CAP_STATE_OPEN,
101 L2CAP_STATE_WAIT_DISCONNECT, // from application
102 L2CAP_STATE_WILL_SEND_CONNECTION_REQUEST,
103 L2CAP_STATE_WILL_SEND_CONNECTION_RESPONSE_INSUFFICIENT_SECURITY,
104 L2CAP_STATE_WILL_SEND_CONNECTION_RESPONSE_DECLINE,

--- 70 unchanged lines hidden (view full) ---

175
176 // client connection
177 void *connection;
178
179 // internal connection
180 btstack_packet_handler_t packet_handler;
181
182 // required security level
99 L2CAP_STATE_WAIT_CLIENT_ACCEPT_OR_REJECT,
100 L2CAP_STATE_WAIT_CONNECT_RSP, // from peer
101 L2CAP_STATE_CONFIG,
102 L2CAP_STATE_OPEN,
103 L2CAP_STATE_WAIT_DISCONNECT, // from application
104 L2CAP_STATE_WILL_SEND_CONNECTION_REQUEST,
105 L2CAP_STATE_WILL_SEND_CONNECTION_RESPONSE_INSUFFICIENT_SECURITY,
106 L2CAP_STATE_WILL_SEND_CONNECTION_RESPONSE_DECLINE,

--- 70 unchanged lines hidden (view full) ---

177
178 // client connection
179 void *connection;
180
181 // internal connection
182 btstack_packet_handler_t packet_handler;
183
184 // required security level
183 gap_security_level_t security_level;
185 gap_security_level_t required_security_level;
184} l2cap_service_t;
185
186
187typedef struct l2cap_signaling_response {
188 hci_con_handle_t handle;
189 uint8_t sig_id;
190 uint8_t code;
191 uint16_t data; // infoType for INFORMATION REQUEST, result for CONNECTION request and command unknown

--- 59 unchanged lines hidden ---
186} l2cap_service_t;
187
188
189typedef struct l2cap_signaling_response {
190 hci_con_handle_t handle;
191 uint8_t sig_id;
192 uint8_t code;
193 uint16_t data; // infoType for INFORMATION REQUEST, result for CONNECTION request and command unknown

--- 59 unchanged lines hidden ---