SmartSnippets DA1459x SDK
Data Structures | Enumerations | Functions
ble_l2cap.h File Reference

LE L2CAP connection oriented channels API. More...

#include <stdint.h>
#include "ble_common.h"
#include "ble_gap.h"

Go to the source code of this file.

Data Structures

struct  ble_evt_l2cap_connected_t
 
struct  ble_evt_l2cap_connection_failed_t
 
struct  ble_evt_l2cap_connection_req_t
 
struct  ble_evt_l2cap_disconnected_t
 
struct  ble_evt_l2cap_credit_changed_t
 
struct  ble_evt_l2cap_data_ind_t
 
struct  ble_evt_l2cap_sent_t
 

Enumerations

enum  ble_evt_l2cap {
  BLE_EVT_L2CAP_CONNECTED = BLE_EVT_CAT_FIRST(BLE_EVT_CAT_L2CAP), BLE_EVT_L2CAP_CONNECTION_FAILED, BLE_EVT_L2CAP_CONNECTION_REQ, BLE_EVT_L2CAP_DISCONNECTED,
  BLE_EVT_L2CAP_REMOTE_CREDITS_CHANGED, BLE_EVT_L2CAP_DATA_IND, BLE_EVT_L2CAP_SENT
}
 
enum  ble_l2cap_connection_status {
  BLE_L2CAP_CONNECTION_SUCCESSFUL, BLE_L2CAP_CONNECTION_REFUSED_LE_PSM_NOT_SUPPORTED, BLE_L2CAP_CONNECTION_REFUSED_NO_RESOURCES_AVAILABLE, BLE_L2CAP_CONNECTION_REFUSED_INSUFFICIENT_AUTHENTICATION,
  BLE_L2CAP_CONNECTION_REFUSED_INSUFFICIENT_AUTHORIZATION, BLE_L2CAP_CONNECTION_REFUSED_INSUFFICIENT_ENCRYPTION_KEY_SIZE, BLE_L2CAP_CONNECTION_REFUSED_INSUFFICIENT_ENCRYPTION
}
 

Functions

ble_error_t ble_l2cap_listen (uint16_t conn_idx, uint16_t psm, gap_sec_level_t sec_level, uint16_t initial_credits, uint16_t *scid)
 Create a connection oriented channel listening for incoming connections. More...
 
ble_error_t ble_l2cap_listen_defer_setup (uint16_t conn_idx, uint16_t psm, gap_sec_level_t sec_level, uint16_t initial_credits, uint16_t *scid)
 Create a connection oriented channel listening for incoming connections. More...
 
ble_error_t ble_l2cap_connection_cfm (uint16_t conn_idx, uint16_t scid, enum ble_l2cap_connection_status status)
 Accept or reject incoming connection. More...
 
ble_error_t ble_l2cap_stop_listen (uint16_t conn_idx, uint16_t scid)
 Stop listening for incoming connections. More...
 
ble_error_t ble_l2cap_connect (uint16_t conn_idx, uint16_t psm, uint16_t initial_credits, uint16_t *scid)
 Connect a connection oriented channel to remote peer. More...
 
ble_error_t ble_l2cap_disconnect (uint16_t conn_idx, uint16_t scid)
 Disconnect channel. More...
 
ble_error_t ble_l2cap_add_credits (uint16_t conn_idx, uint16_t scid, uint16_t credits)
 Add local credits on channel. More...
 
ble_error_t ble_l2cap_send (uint16_t conn_idx, uint16_t scid, uint16_t length, const void *data)
 Send data on channel. More...
 
ble_error_t ble_l2cap_conn_param_update (uint16_t conn_idx, const gap_conn_params_t *conn_params)
 Initiate a connection parameter update over L2CAP. More...
 

Detailed Description

LE L2CAP connection oriented channels API.

Copyright (C) 2015-2018 Renesas Electronics Corporation and/or its affiliates. All rights reserved. Confidential Information.

This software ("Software") is supplied by Renesas Electronics Corporation and/or its affiliates ("Renesas"). Renesas grants you a personal, non-exclusive, non-transferable, revocable, non-sub-licensable right and license to use the Software, solely if used in or together with Renesas products. You may make copies of this Software, provided this copyright notice and disclaimer ("Notice") is included in all such copies. Renesas reserves the right to change or discontinue the Software at any time without notice.

THE SOFTWARE IS PROVIDED "AS IS". RENESAS DISCLAIMS ALL WARRANTIES OF ANY KIND, WHETHER EXPRESS, IMPLIED, OR STATUTORY, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. TO THE MAXIMUM EXTENT PERMITTED UNDER LAW, IN NO EVENT SHALL RENESAS BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE, EVEN IF RENESAS HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. USE OF THIS SOFTWARE MAY BE SUBJECT TO TERMS AND CONDITIONS CONTAINED IN AN ADDITIONAL AGREEMENT BETWEEN YOU AND RENESAS. IN CASE OF CONFLICT BETWEEN THE TERMS OF THIS NOTICE AND ANY SUCH ADDITIONAL LICENSE AGREEMENT, THE TERMS OF THE AGREEMENT SHALL TAKE PRECEDENCE. BY CONTINUING TO USE THIS SOFTWARE, YOU AGREE TO THE TERMS OF THIS NOTICE.IF YOU DO NOT AGREE TO THESE TERMS, YOU ARE NOT PERMITTED TO USE THIS SOFTWARE.