The API are used for enable user to use 2Mbps feature of BLE Stack.
◆ Cy_BLE_SetPhy()
This function allows application to set the PHY for the current connection.
This is a non-blocking function and successful operation is informed through 'CY_BLE_EVT_SET_PHY_COMPLETE'. Actual PHY used by controller will be informed through the 'CY_BLE_EVT_PHY_UPDATE_COMPLETE' event.
- Parameters
-
- Returns
- cy_en_ble_api_result_t : Return value indicates whether the function succeeded or failed. Following are the possible error codes.
Errors codes | Description |
CY_BLE_SUCCESS | On successful operation. |
CY_BLE_ERROR_NO_DEVICE_ENTITY | Device identified by bdHandle is not present |
CY_BLE_ERROR_INVALID_PARAMETER | Null pointer passed. |
CY_BLE_ERROR_MEMORY_ALLOCATION_FAILED | If Memory allocation failed. |
CY_BLE_ERROR_INSUFFICIENT_RESOURCES | If BLE Stack resources are unavailable. |
◆ Cy_BLE_GetPhy()
This function allows the application to read the current PHY setting for the specified connection.
This is a non-blocking function. Current PHY setting (TxPhy, RxPhy) is informed through 'CY_BLE_EVT_GET_PHY_COMPLETE' event.
- Parameters
-
- Returns
- cy_en_ble_api_result_t : Return value indicates whether the function succeeded or failed. Following are the possible error codes.
Errors codes | Description |
CY_BLE_SUCCESS | On successful operation. |
CY_BLE_ERROR_NO_DEVICE_ENTITY | Device identified by bdHandle is not present. |
CY_BLE_ERROR_MEMORY_ALLOCATION_FAILED | If Memory allocation failed. |
CY_BLE_ERROR_INSUFFICIENT_RESOURCES | If BLE Stack resources are unavailable. |