setPreferredPhy

fun setPreferredPhy(txPhy: Int, rxPhy: Int, phyOptions: Int, callback: (Int, Int, Int) -> Unit)

Requests a PHY (Physical Layer) update with timeout handling.

Parameters

txPhy

Preferred TX PHY (e.g., BluetoothDevice.PHY_LE_1M, PHY_LE_2M, PHY_LE_CODED)

rxPhy

Preferred RX PHY

phyOptions

PHY options for coded PHY (e.g., BluetoothDevice.PHY_OPTION_NO_PREFERRED)

callback

Called with (txPhy, rxPhy, status) when the operation completes or times out