QT QBluetoothDeviceDiscoveryAgent require turn on GPS Module
-
I dont need use BLE in my app, but without GPS on my android classic bluetooth device scan does not work.
How to be? Is this a bug or expected behavior?In log: * qt.bluetooth.android: Search not possible due to turned off Location service *
I use:
QT 5.15
Android 8.0
Android SDK 30 -
I found a solution to my problem. The topic can be closed.
-
I dont need use BLE in my app, but without GPS on my android classic bluetooth device scan does not work.
How to be? Is this a bug or expected behavior?In log: * qt.bluetooth.android: Search not possible due to turned off Location service *
I use:
QT 5.15
Android 8.0
Android SDK 30@RSmirnov said in QT QBluetoothDeviceDiscoveryAgent require turn on GPS Module:
How to be? Is this a bug or expected behavior?
This is expected behaviour. Android requires GPS for BLE discovery. This is true not only for Qt app, but for all Android apps.
-
I dont need use BLE in my app, but without GPS on my android classic bluetooth device scan does not work.
How to be? Is this a bug or expected behavior?In log: * qt.bluetooth.android: Search not possible due to turned off Location service *
I use:
QT 5.15
Android 8.0
Android SDK 30@RSmirnov its no bug, its a stipulation from the OS due to security
You can potentially derive the physical location of a device when using Bluetooth without the User being aware of that. For that reason you have to enable GPS/Location service to use Bluetooth, that way the user is aware of that
-
@RSmirnov said in QT QBluetoothDeviceDiscoveryAgent require turn on GPS Module:
How to be? Is this a bug or expected behavior?
This is expected behaviour. Android requires GPS for BLE discovery. This is true not only for Qt app, but for all Android apps.
-
If I recall correctly, GPS is not needed for BT classic.
It turns out that to scan devices, I will force the user to turn on GPS every time and it will be ok?
You don't need to force anything. Get the Android permission and system will do it automatically for you.
-
If I recall correctly, GPS is not needed for BT classic.
It turns out that to scan devices, I will force the user to turn on GPS every time and it will be ok?
You don't need to force anything. Get the Android permission and system will do it automatically for you.
-
@sierdzio Ok, I will understand why I do not observe such (system will do it automatically) behavior. Thanks!
@RSmirnov if your issue is solved, please don't forget to mark your post as such! Thanks
-
I found a solution to my problem. The topic can be closed.