/// The following call might return null if the user doesn't have bluetooth access permissions
val s: BluetoothLeScanner? = bluetoothAdapter.bluetoothLeScanner
if(s == null) {
ScanUIState.errorText = "This application requires bluetooth access. Please grant access in android settings."
}