BLE_GAP_SetPhy
C
uint16_t BLE_GAP_SetPhy(uint16_t connHandle, uint8_t txPhys, uint8_t rxPhys, uint8_t phyOptions);
Description
Sets the PHY preferences for the specified connection.
Note
The BLE Stack might not be able to make the change immediately. An event will be generated if one or both PHYs change.
Events generated
BLE_GAP_EVT_PHY_UPDATE is generated when the PHY is updated.
Parameters
Parameter | Description |
---|---|
[in] connHandle | Connection handle associated with this connection. |
[in] txPhys | Transmitter PHYs. A bit field that indicates the preferred transmitter PHYs. Refer to PHY options for transmission and reception for possible values.. |
[in] rxPhys | Receiver PHYs. A bit field that indicates the preferred receiver PHYs. Refer to PHY options for transmission and reception for possible values.. |
[in] phyOptions | PHY options. Refer to Preferred PHY preference for possible values.. |
Return values
Return value | Description |
---|---|
MBA_RES_SUCCESS | Successfully sets the PHY preferences for the specified connection. |
MBA_RES_OOM | Internal memory allocation failure occurred. |
MBA_RES_INVALID_PARA | The parameters provided are invalid. |
MBA_RES_UNKNOWN_CONN_ID | Unknown connection identifier. |
MBA_RES_COMMAND_DISALLOWED | Command disallowed due to a conflicting operation or state. |