2 Replies Latest reply on Oct 10, 2018 6:52 AM by AnKu_3769716

    Authentication failure during app upgrade in an Upgradable Stack project




      I've got a PSoC Creator workspace that follows the Upgradable BLE Stack structure and contains my app in place of the HID Keyboard example.


      My app can be successfully programmed via CySmart when the BLE Stack is running.


      However, if I try to upgrade my app with itself via CySmart when my app is running I always get an authentication failure.


      Meanwhile, the HID Keyboard app always passes authentication under the same conditions.


      All the BLE and Bootloadable component dependencies are set per the BLE Upgradable Stack documentation.


      Also, my app's BLE component Security GAP Settings match those in the HID Keyboard BLE component:


      Security mode: Mode 1

      Security level: Unauthenticated pairing with encryption

      Strict pairing: No

      I/O capabilities: No Input No Output

      Bonding requirement: Bonding

      Encryption key size: 16


      My app's main.c contains the following code (I'm using ARM GCC):


          #if !defined(__ARMCC_VERSION)






          if(CyBle_GetState() == CYBLE_STATE_CONNECTED)







      I tried modifying CySmart's Master Configuration security setting so that they correspond to BLE component ones but that didn't make any difference.


      According to debug output, CCCD and bonding data are all 0's in both my app and HID Keyboard sample app.

      Please, advise what I could be missing in terms of authentication.