xref: /btstack/src/l2cap.h (revision fd7ed8d4e236eb1f58278017103446dc94df24f3)
143625864Smatthias.ringwald /*
243625864Smatthias.ringwald  *  l2cap.h
343625864Smatthias.ringwald  *
443625864Smatthias.ringwald  *  Logical Link Control and Adaption Protocl (L2CAP)
543625864Smatthias.ringwald  *
643625864Smatthias.ringwald  *  Created by Matthias Ringwald on 5/16/09.
743625864Smatthias.ringwald  */
843625864Smatthias.ringwald 
9*fd7ed8d4Smatthias.ringwald #pragma once
10*fd7ed8d4Smatthias.ringwald 
1143625864Smatthias.ringwald #include "hci.h"
1243625864Smatthias.ringwald 
1343625864Smatthias.ringwald typedef enum {
1443625864Smatthias.ringwald     COMMAND_REJECT = 1,
1543625864Smatthias.ringwald     CONNECTION_REQUEST,
1643625864Smatthias.ringwald     CONNECTION_RESPONSE,
1743625864Smatthias.ringwald     CONFIGURE_REQUEST,
1843625864Smatthias.ringwald     CONFIGURE_RESPONSE,
1943625864Smatthias.ringwald     DISCONNECTION_REQUEST,
2043625864Smatthias.ringwald     DISCONNECTION_RESPONSE,
2143625864Smatthias.ringwald     ECHO_REQUEST,
2243625864Smatthias.ringwald     ECHO_RESPONSE,
2343625864Smatthias.ringwald     INFORMATIONAL_REQUEST,
2443625864Smatthias.ringwald     INFORMATIONAL_RESPONSE
2543625864Smatthias.ringwald } L2CAP_SIGNALING_COMMANDS;
2643625864Smatthias.ringwald 
2716833f0aSmatthias.ringwald typedef struct {
2816833f0aSmatthias.ringwald 
2916833f0aSmatthias.ringwald } l2cap_channel_t;
3016833f0aSmatthias.ringwald 
3116833f0aSmatthias.ringwald typedef struct {
3216833f0aSmatthias.ringwald 
3316833f0aSmatthias.ringwald } l2cap_service_t;
3416833f0aSmatthias.ringwald 
3543625864Smatthias.ringwald void l2cap_init();
3643625864Smatthias.ringwald int l2cap_send_signaling_packet(hci_con_handle_t handle, L2CAP_SIGNALING_COMMANDS cmd, uint8_t identifier, ...);
3743625864Smatthias.ringwald 
3843625864Smatthias.ringwald extern uint16_t  local_cid;
3943625864Smatthias.ringwald extern uint8_t   sig_seq_nr;
40