mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-28 16:11:24 +00:00
added l2cap_can_send_packet_now
This commit is contained in:
parent
a22f364722
commit
6b1fde377c
@ -196,6 +196,13 @@ l2cap_channel_t * l2cap_get_channel_for_local_cid(uint16_t local_cid){
|
||||
return NULL;
|
||||
}
|
||||
|
||||
int l2cap_can_send_packet_now(uint16_t local_cid){
|
||||
l2cap_channel_t *channel = l2cap_get_channel_for_local_cid(local_cid);
|
||||
if (!channel) return 0;
|
||||
if (!channel->packets_granted) return 0;
|
||||
return hci_can_send_packet_now(HCI_ACL_DATA_PACKET);
|
||||
}
|
||||
|
||||
uint16_t l2cap_get_remote_mtu_for_local_cid(uint16_t local_cid){
|
||||
l2cap_channel_t * channel = l2cap_get_channel_for_local_cid(local_cid);
|
||||
if (channel) {
|
||||
|
@ -136,6 +136,7 @@ int l2cap_send_internal(uint16_t local_cid, uint8_t *data, uint16_t len);
|
||||
uint16_t l2cap_get_remote_mtu_for_local_cid(uint16_t local_cid);
|
||||
|
||||
void l2cap_block_new_credits(uint8_t blocked);
|
||||
int l2cap_can_send_packet_now(uint16_t local_cid); // non-blocking UART write
|
||||
|
||||
void l2cap_finialize_channel_close(l2cap_channel_t *channel);
|
||||
void l2cap_close_connection(void *connection);
|
||||
|
Loading…
x
Reference in New Issue
Block a user