Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

I am getting a SOFTDEVICE: ASSERTION FAILED after some time when advertising with whitelist.

I am getting a SOFTDEVICE: ASSERTION FAILED after some time when advertising with whitelist.  I am using NRF5_SDK 14.2.0 and have tried both softdevice s132 5.0.0 and 5.1.0.  I modified the code to giv ethe PC and it is pc = 15F94.  addr2linegives me ??:0. How can I find out why the assert is happening?

The problem does not happen when I am connected.

Parents
  • Hi,

    It looks like you have stumbled upon a known (but not documented) bug that occurs if you are using whitelisting and identity keys. The assert happens when you are advertising and you receive a malformed scan or connection request from a central. In the real world (if you don't try to provoke the issue yourself) this only happens when you receive packets with the wrong CRC value. So how often this will occur depends on how noisy the user's environment is. 

    The Softdevice team propose two solutions based on the fact that the assert only happens if you are using identity lists and only when you are advertising:

    1. Stop using identity lists. Unless you really need this feature this would be the best option. 
    2. If you need identity lists, the other option is to reset your device on the assert, but whether this is a viable solution obviously depends on your use case? If you need to maintain other BLE links or do any other time critical things when the assert happens, then naturally a reset isn't feasible. If you are indeed able to reset, the downside should be minor. The device should be able to reset within a couple of milliseconds and the users won't notice. 

    If you are able to wait, the bug is fixed in S132 v6.0.0 which is just around the corner (please talk to your sales rep for specific release dates). As usual between major Softdevice release versions, there is going to be some API changes and some porting required. 

  • I followed some example code when adding whitelist functionality to my app.  The few examples always used identity lists.  What does using identity lists do specifically?  I think I will be able to just not use identity list but I would like to know what functionality I will be loosing.

  • jlarsen said:
    I followed some example code when adding whitelist functionality to my app.

    You are not alone. There have been identical reports from customers who have done the same. Unfortunately we just recently figured out the reason for the bug and that is why it isn't documented anywhere yet. 

    Identity keys are a security feature in BLE. From BLE Specification v5:

    Vol 1, Part A, 5.4.5 Privacy Feature
    Bluetooth LE supports a feature that reduces the ability to track a LE device
    over a period of time by changing the Bluetooth device address on a frequent
    basis. In order for a device using the privacy feature to reconnect to known devices,
    the device address, referred to as the private address, must be resolvable by
    the other device. The private address is generated using the device’s resolving
    identity key (IRK) exchanged during the bonding procedure.

  • Thank you MartinBL.  We do not need identity list functionality. I removed the use of identity lists in our code and the problem went away.

Reply Children
No Data
Related