This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

GATTS table size - inconsistant RAM start

Hello,

I am developing a profile which includes 39 characteristics spread over 4 services on nRF52840/SD140/SDK13. When I add one too many, sd_ble_gatts_characteristic_add() returns NRF_ERROR_NO_MEM. Reading upon this issue led me to believe that I could simply tweak the GATTS table size until all my data fits in.

By default, I don't specify the table size and my RAM starts at 0x20002128. If I then specify the size to be BLE_GATTS_ATTR_TAB_SIZE_DEFAULT (1408), I am advised by a NRF_LOG warning to start at 0x20002888. Doubling that size (2816), I am advised to start at 0x20002088 which is much lower. Increasing then to 3000, I am advised to start at 0x20002c08. 5000 will advice me to start at 0x20002908 which weirdly is lower again.

In any case, the same error always occurs on the same characteristic (except on the case of the much reduced start size when it fails much earlier), and I am unable to allocate enough space for my profile data.

Increasing vs_uuid_count from BLE_UUID_VS_COUNT_DEFAULT to BLE_UUID_VS_COUNT_MAX does not change the behaviour, except in the case where the table size is unspecified where I am advised to start at 0x20003068 instead.

Is this behaviour expected? How can I configure the SoftDevice to be able to include all my characteristics?

Thank you in advance.

Parents Reply Children
No Data
Related