This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

BLE_ERROR_GATTS_SYS_ATTR_MISSING

Hi. I have a problem with HID keyboard example. Function sd_ble_gatts_hvx returns 0x00003401. I know that it's means BLE_ERROR_GATTS_SYS_ATTR_MISSING. But how and where I must set attributes or enable notification. I know that I must restore attributes from storage. But how? I read many posts about this but I can not to fix this problem. Please help me. Thank you in advance.

BLE_ERROR_GATTS_SYS_ATTR_MISSING does not handle

Parents
  • If you haven't bonded with the device before you need to call sd_ble_gatts_sys_attr_set(NULL) to initialize the CCCD value as shown in the description of the sd_ble_gatts_hvx() function.

    if you have bonded and stored system attribute , then you need to call sd_ble_gatts_sys_attr_set() with the attribute value you have stored.

    If you use our ble_app_hid_keyboard, you will find how we handled it in gatts_cache_manager.c

Reply
  • If you haven't bonded with the device before you need to call sd_ble_gatts_sys_attr_set(NULL) to initialize the CCCD value as shown in the description of the sd_ble_gatts_hvx() function.

    if you have bonded and stored system attribute , then you need to call sd_ble_gatts_sys_attr_set() with the attribute value you have stored.

    If you use our ble_app_hid_keyboard, you will find how we handled it in gatts_cache_manager.c

Children
Related