- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What is the difference between CYBLE_EVT_GAP_DEVICE_CONNECTED
and CYBLE_EVT_GATT_CONNECT_IND
(and their disconnect's)?
For me it seems natural to use the GAP event to see if an connection is created (or not) since the Generic Access Profile is about connections. But I've seen that some of the example projects from Cypress uses the GATT variant.
Solved! Go to Solution.
- Labels:
-
BLE
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
CYBLE_EVT_GAP_DEVICE_CONNECTED: This event is received when device is connected over GAP layer.
CYBLE_EVT_GATT_CONNECT_IND: This event is received when device is connected over GATT level
Actually, once successful connection happens after calling CyBle_GapcConnectDevice, both these events will be generated in the following order:
CYBLE_EVT_GATT_CONNECT_IND
CYBLE_EVT_GAP_DEVICE_CONNECTED
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
CYBLE_EVT_GAP_DEVICE_CONNECTED: This event is received when device is connected over GAP layer.
CYBLE_EVT_GATT_CONNECT_IND: This event is received when device is connected over GATT level
Actually, once successful connection happens after calling CyBle_GapcConnectDevice, both these events will be generated in the following order:
CYBLE_EVT_GATT_CONNECT_IND
CYBLE_EVT_GAP_DEVICE_CONNECTED
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi! Is that order correct? As far as I understand, GAP is just a fancy acronym/name for how a peripheral device should connect to others (i.e. central). The device's GAP is just the device's behavior for connections, so calling it "layer" is misleading. (I may have misunderstood what GAP is).
Since GAP is about connections, shouldn't the event CYBLE_EVT_GAP_DEVICE_CONNECTED
come first then?
Or can a device be connected to GATT without being (for example) authenticated, and therefore not be fully connected as required by the device's GAP? (Please refer to this other post: http://www.cypress.com/forum/psoc-4-ble/pairingbondingauthentification-procedure)