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.

GATT notification sent succesfully but not received

Hi,

I am trying to notify a GATT client when a characteristic value has changed. The GAP connection is established correctly, the GATT service is dicovered and the characteristic value is found. The charv has read, write and notify permissions, and when it is changed on the server side, I call explicitly GATT_Notification which returns SUCCESS. However, the client doesn't get the notification.

I performed another test in which the client tries to read the same charv, but no responses come.

The two projects are based on SimpleBLEPeripheral and Central, and only the things described above were changed regarding to GATT. 

 

And another question: is there any way to let the server know when a notification was received on the other side? 

 

Do you have any ideas?

 

Thanks,

Gergo

  • Hello,

    Sounds like you are on right track. Can you get Btool to see the notification?  That way we can isolate the issue to peripheral or central.

     

    I would look at indications.  They require an ack when received, and the GATT server will not send out another indication until the ACK is received (or timeout).

    BR,

    -Greg

     

  • Hi Greg,

     

    Thanks for your reply.I have Btool, but I use our own debug method instead. I simply connect the two devices to the PC via USB, and the debug messages are sent to a virtual serial port (using UART).

    Depending on these messages I can see that the notification is sent properly (SUCCESS) on the server side, however, the client doesn't get any notification GATT messages in this phase (of course there are some while the services and charvalues are being found). It is also holds for write responses, but doesn't for read responses. This would suggest me that the flag haven't been set properly, but I've added READ and NOTIFY flag to the charvalue.

    I'll read about indications, thanks.

     

    BR,

    Gergo

     

  • Any ideas?

     

    Thanks,

    Gergo

  • Hi All,

    We've successfully solved the problem. The bug wasn't in the notification sending, but in the connection. There's a parameter called supervisor timeout which was set to the same value as originally in the sample project. However, setting this to a higher value solved the problem, now all notifications are received correctly.

    Best regards,

    Gergo