onPhyUpdate

open override fun onPhyUpdate(gatt: BluetoothGatt, txPhy: Int, rxPhy: Int, status: Int)

Called when the PHY (Physical Layer) for a connection has been updated.

PHY updates can change the data rate and range characteristics of the BLE connection. This callback is invoked after BluetoothGatt.setPreferredPhy completes or when the remote device initiates a PHY change.

Parameters

gatt

The BluetoothGatt instance for the connection.

rxPhy

The receiver PHY in use (same constants as txPhy).

status

BluetoothGatt.GATT_SUCCESS if the PHY was updated successfully, or an error code if the update failed.

See also

ConnectionStateMachine.handlePhyUpdate