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

Ram Memory of Attribute Size question

Hi, 

I have some question below: note: the project_uuid belong uuid-16bit by my define uuid of product myself.

1. My project uses project_uuid and DFU_btn_less services. I figure out If my definition is wrong. I set "#define NRF_SDH_BLE_VS_UUID_COUNT 1", but my project still running OK. Is the setting right?

2. Receives writes, How many NRF_SDH_BLE_VS_UUID_COUNT if following I call how many time sd_ble_uuid_vs_add in services_init()?

3. My project includes many services(project_uuid, HID, TMP, and DFU), and then I addition ATT_MTU = 247 from 23. Now my service_init happen error message "NRF_ERROR_NO_MEM = sd_ble_gatts_characteristic_add", but execute nrf_sdh_ble_enable(&ram_start) is OK, what's the problem?

4. Receives writes, I try to fix NRF_SDH_BLE_GATTS_ATTR_TAB_SIZE = 2048 from 1408, and then this "NRF_SUCCESS= sd_ble_gatts_characteristic_add". Really fix the problem in this way?

5. Could you explain "NRF_SDH_BLE_SERVICE_CHANGED"? I just follow some example to turn on, but I think to occupy Ram size when I turn on NRF_SDH_BLE_SERVICE_CHANGED.

Parents
  • Hi Ken

    Q3: Yes, this was my mistake, the userspace solution was something used in older SoftDevices that had more limited storage, please use NRF_SDH_BLE_GATTS_ATTR_TAB_SIZE in order to increase the size of the GATT table.

    Q5: To include the Service Changed characteristic in the Attribute Table set NRF_SDH_BLE_SERVICE_CHANGED in your sdk_config.h file. The ble_app_hrs example does this for example.

    Q6: Increasing the size of your GATT table should solve the NRF_ERROR_NO_MEM = sd_ble_gatts_characteristic_add error.

    Best regards,

    Simon

Reply
  • Hi Ken

    Q3: Yes, this was my mistake, the userspace solution was something used in older SoftDevices that had more limited storage, please use NRF_SDH_BLE_GATTS_ATTR_TAB_SIZE in order to increase the size of the GATT table.

    Q5: To include the Service Changed characteristic in the Attribute Table set NRF_SDH_BLE_SERVICE_CHANGED in your sdk_config.h file. The ble_app_hrs example does this for example.

    Q6: Increasing the size of your GATT table should solve the NRF_ERROR_NO_MEM = sd_ble_gatts_characteristic_add error.

    Best regards,

    Simon

Children
Related