autoConnectIf

fun autoConnectIf(predicate: () -> Boolean)

Whether to automatically connect as soon as the remote device becomes available (predicate returns trueconnection attempts will wait indefinitely unless wrapped in a withTimeout), or to directly connect to the remote device (predicate returns false — connection attempts timeout after ~30 seconds).

predicate is called once per connection attempt, not per call to connect.