This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Read Long Characteristics from Android

Other Parts Discussed in Thread: CC2650STK

Hi

I have a SensorTag CC2650STK.

I want to read long characteristics from Android. I've already modified the MAX_PDU_SIZE and can successfully request a larger MTU from Android. But in the readAttrCB function the maxLen parameter is always 22. Android only offers the readCharacteristic method where you can't manually pass an offset or the number of bytes to be read. Is the offset parameter in the readAttrCB something that can also be set != null by the BLE stack on the peripheral when a larger GATT packet is aggregated? As I understand it the client is never notified of the actual size of the characteristics and just gets whatever number of bytes is packaged in the readAttrCB function? So how exactly can this bottleneck of 22 bytes be circumvented?

Cheers

  • Hello Andreas,

    The offset parameter will only be non-zero if the ATT read blob request procedure is used and a non-zero offset is supplied by the client.

    Also, how is your peripheral (GATT server) requesting a larger MTU? Only the GATT client may request a MTU change. Do you have a sniffer trace that shows the MTU size being set to a larger value?

    Best wishes
  • Hi
    The MTU is requested by the client. I finally got it to work by returning blePending and using ATT_ReadRsp later.
    Cheers