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

Largest allowed setting for variable length characteristic?

I'm using the nRF51822 with the S110 soft device. When specifying the maximum size of a variable length characteristic notify property (the max_len field of the ble_gatts_attr_t structure), what is the maximum value that can be used? Looking at other questions on the Nordic Developer Zone it seems as if this field should be set to no higher than 20 bytes, but it would be more efficient for me to deal with larger packet sizes. Can the constant BLE_GATTS_VAR_ATTR_LEN_MAX (which is 512) be used as the maximum size for this field?

What are the implications of using packets larger than 20 bytes, if it is possible?

Thanks.

Parents
  • What are the implications of using packets larger than 20 bytes, if it is possible?

    It is not possible today with the current SoftDevice.

    However, it does make sense to have attribute values that are longer than 20 bytes, and certain use cases actually require this.

    Remember that the GATT procedures: "Read Long Characteristic Values" and "Write Long Characteristic Values", both supported by the SoftDevice, allow you to access attribute values that are longer than 20 bytes by using multiple packets.

Reply
  • What are the implications of using packets larger than 20 bytes, if it is possible?

    It is not possible today with the current SoftDevice.

    However, it does make sense to have attribute values that are longer than 20 bytes, and certain use cases actually require this.

    Remember that the GATT procedures: "Read Long Characteristic Values" and "Write Long Characteristic Values", both supported by the SoftDevice, allow you to access attribute values that are longer than 20 bytes by using multiple packets.

Children
No Data
Related