GATTS_SetPreferredMtu
C
uint16_t GATTS_SetPreferredMtu(uint16_t preferredMtuPeriph, uint16_t preferredMtuCentral);
Description
GATT Server configures preferred ATT MTU. By default, BLE_ATT_MAX_MTU_LEN will be used to respond exchange MTU request from remote client. User specified ATT MTU will be used if the preferred MTU is configured.
Note
The API is optional. BLE_ATT_MAX_MTU_LEN will be used to respond if no configuration.
Parameters
Parameter | Description |
---|---|
[in] preferredMtuPeriph | Preferred ATT MTU when GAP role is peripheral. |
[in] preferredMtuCentral | Preferred ATT MTU when GAP role is central. |
Return values
Return value | Description |
---|---|
MBA_RES_SUCCESS | Successfully configured preferred MTU in GATT Server role. |
MBA_RES_INVALID_PARA | Invalid MTU value usage. |