 Mark as New
 Bookmark
 Subscribe
 Mute
 Subscribe to RSS Feed
 Permalink
 Report Inappropriate Content
Hi, I'm building code for a CYBLE22411000 (currently sitting on a CY8CKIT042BLE) using PSoC Creator 4.4 (4.4.0.80). My BLE Component is version 3.66 from the CyComponentLibrary.
The code I'm working with is basically Day 16 Authentication from the 100 Projects in 100 Days examples (https://github.com/Infineon/PSoC4BLE/tree/master/100_Projects_in_100_Days/Day016_Authentication). The one (critical I guess) thing I changed is that I enabled bonding in the BLE component configuration, and used similar code like in the Day 15 Bonding example to store the bonding information when there's a pending flash write (https://github.com/Infineon/PSoC4BLE/blob/master/100_Projects_in_100_Days/Day015_Bonding/BLE_Bondi...)
Overall the code works, but in my StackEventHandler I get an event with event code (decimal) 260 / (hex) 0x104. This is well outside the "normal" range of event codes (0  0xFF). Any idea what this event might be? It happens after the CYBLE_EVT_PENDING_FLASH_WRITE and after the bonding data is stored. Here the output / log from a "first" connection:
Bluetooth Stack ON:<\r><\n>
Set the I/O capabilities:<\r><\n>
Updated the I/O capabilities:DISPLAY_ONLY<\r><\n>
Stack in idle state, starting advertising<\r><\n>
Started to advertise<\r><\n>
Device Connected<\r><\n>
CYBLE_EVT_GAP_CONNECTION_UPDATE_COMPLETE<\r><\n>
CYBLE_EVT_GAP_CONNECTION_UPDATE_COMPLETE<\r><\n>
CYBLE_EVT_GAP_SMP_NEGOTIATED_AUTH_INFO<\r><\n>
<\r><\n>
CYBLE_EVT_GAP_AUTH_REQ from Master:<\r><\n>
security: Authentication and Encryption<\r><\n>
Bonding:yes<\r><\n>
eKeySize: 0x10<\r><\n>
err: 0x0<\r><\n>
CYBLE_EVT_GAP_PASSKEY_DISPLAY_REQUEST. Passkey is: 639833.<\r><\n>
Please enter the passkey on peer device.<\r><\n>
<\r><\n>
Encryption ON<\r><\n>
<\r><\n>
KEYINFO_EXCHANGE_COMPLETED<\r><\n>
Long term Key: 41f6a183b5683e3887680ed7a4fb2265<\r><\n>
Encrypted Diversifier: ebcc<\r><\n>
Random Number:b403e8be6b192fdc<\r><\n>
Indentifier Resolving Key: 43f6e3ba0f0a1d4d14b995af21c71730<\r><\n>
Public device/Static Random address: 6489f1d1161c<\r><\n>
Address Type:PUBLIC<\r><\n>
<\r><\n>
Connection Signature Resolving Key: 3f1374a98709aa3e594fca4f7d03eb7d<\r><\n>
AUTHENTICATION_COMPLETED:<\r><\n>
security: Authentication and Encryption<\r><\n>
Bonding:yes<\r><\n>
eKeySize: 0x10<\r><\n>
err: 0x0<\r><\n>
CYBLE_EVT_PENDING_FLASH_WRITE<\r><\n>
Bonding data storing pending<\r><\n>
Bonding data storing pending<\r><\n>
Bonding data stored<\r><\n>
Unknown event: 260<\n>
Characteristic value updated by Client: 11<\r><\n>
Update Characteristic value to: 12<\r><\n>
CYBLE_EVT_GATTS_READ_CHAR_VAL_ACCESS_REQ<\r><\n>
CYBLE_EVT_GATT_DISCONNECT_IND<\r><\n>
And here how it looks like when reconnecting:
Device Connected<\r><\n>
AUTHENTICATION_COMPLETED:<\r><\n>
security: Authentication and Encryption<\r><\n>
Bonding:yes<\r><\n>
eKeySize: 0x10<\r><\n>
err: 0x0<\r><\n>
CYBLE_EVT_PENDING_FLASH_WRITE<\r><\n>
<\r><\n>
Encryption ON<\r><\n>
Bonding data storing pending<\r><\n>
... (repeats roughly 50 times)
Bonding data storing pending<\r><\n>
CYBLE_EVT_GAP_CONNECTION_UPDATE_COMPLETE<\r><\n>
Bonding data storing pending<\r><\n>
Bonding data storing pending<\r><\n>
Bonding data stored<\r><\n>
Unknown event: 260<\n>
CYBLE_EVT_GAP_CONNECTION_UPDATE_COMPLETE<\r><\n>
*edit* Doesn't seem to be related to storing the bonding information, here another reconnect (already bonded):
Device Connected<\r><\n>
AUTHENTICATION_COMPLETED:<\r><\n>
security: Authentication and Encryption<\r><\n>
Bonding:yes<\r><\n>
eKeySize: 0x10<\r><\n>
err: 0x0<\r><\n>
<\r><\n>
Encryption ON<\r><\n>
Unknown event: 260<\n>
Solved! Go to Solution.
 Labels:

PSoC 4 MCU
 Tags:
 ble
 Mark as New
 Bookmark
 Subscribe
 Mute
 Subscribe to RSS Feed
 Permalink
 Report Inappropriate Content
Hello,
Servicespecific Events will start from 0x00100 to 0x0E000. These events are declared in BLE_eventHandler.h.
Please refer to the below KBA for more information.
Thanks,
P Yugandhar.
 Mark as New
 Bookmark
 Subscribe
 Mute
 Subscribe to RSS Feed
 Permalink
 Report Inappropriate Content
Hello,
Servicespecific Events will start from 0x00100 to 0x0E000. These events are declared in BLE_eventHandler.h.
Please refer to the below KBA for more information.
Thanks,
P Yugandhar.