GATTS_SetPreferredMtu
C
uint16_t GATTS_SetPreferredMtu(uint16_t preferredMtuPeriph, uint16_t preferredMtuCentral);
Description
Configures the preferred ATT MTU size for the GATT Server.
Note
By default, BLE_ATT_MAX_MTU_LEN is used to respond to MTU exchange requests from a remote client. If a preferred MTU size is configured, it will be used instead. This API is optional; if not used, BLE_ATT_MAX_MTU_LEN will be the default response.
Parameters
Parameter | Description |
---|---|
[in] preferredMtuPeriph | Preferred ATT MTU size when the GAP role is peripheral. |
[in] preferredMtuCentral | Preferred ATT MTU size when the GAP role is central. |
Return values
Return value | Description |
---|---|
MBA_RES_SUCCESS | Successfully configured the preferred MTU size for the GATT Server. |
MBA_RES_INVALID_PARA | Invalid MTU size specified. |