I work with the SDK 5.0.2.1. I would like to know if there is an easy way to know the current MTU size (up-to-date structure, API, etc.) while executing the application.
There is no API message returning the agreed MTU to application. However your application can read the current value of a connection index by calling the gattc_get_mtu() function. The negotiated MTU for the connection will be the minimum MTU of the the 2 devices.
I'm not sure to understand your answer. In the source code, this function is described as "Gets the negotiated MTU. This function gets the negotiated MTU.". Then, I guess that I can use it to effectively get the agreed MTU?
Hi Matthieu,
There is no API message returning the agreed MTU to application. However your application can read the current value of a connection index by calling the gattc_get_mtu() function. The negotiated MTU for the connection will be the minimum MTU of the the 2 devices.
Thanks MT_dialog
Hi,
I'm not sure to understand your answer. In the source code, this function is described as "Gets the negotiated MTU. This function gets the negotiated MTU.". Then, I guess that I can use it to effectively get the agreed MTU?
Thanks.
_Matthieu
Hi Matthieu,
是的,gattc_get_mtu() function can read the current MTU value of a connection index.
Thanks MT_dialog