apidocs / com.nimmsta.core.android.device / BLEConnectFactory / createConnectionAsync

createConnectionAsync

fun createConnectionAsync(scannedDevice: SearchScanResult, cancellationToken: CancellationToken?): Task<UARTServiceInterface>

Established the connection to the device and returns an UARTServiceInterface. Does error handling if something fails.

Parameters

scannedDevice - ScanRecord to connect to

cancellationToken - cancellationToken to handle cancellations

Return
Task of generic type UARTServiceInterface