Open andresperezmelo opened 4 years ago
me too
and created this for Android https://pub.dev/packages/print_bluetooth_thermal
I fix my project with android9. to android10 can not search bluetooth problem. All problems occur because android10 add new permission with bluetooth. Try to use this package permission_handler: ^5.0.1+1 https://pub.dev/packages/permission_handler
Before you call search bluetooth add these code Map<Permission, PermissionStatus> statuses = await [ Permission.location, Permission.locationWhenInUse, ].request(); print(statuses[Permission.location]); print(statuses[Permission.locationWhenInUse]);
Then call search ... It's work
Hope it can helps you
The module is not able to scan bluetooth when compiling a project in targetSdkVersion 30 0 29 and compileSdkVersion 30 or 29
Works fine in api 28 or lower
Let's wait if the developer updates the package.
The problem
When compiled in api 29 or 30 the application is not able to request permanent location permission, only two options of
permission denied allow only with the app in use
And it turns out that the permission of only the app in use, your module is unable to scan bluetooth
Api 28 permission Api 28 app
Api 30 o 29 permission
Doesn't scan in the app
Let's hope they update it soon, if anyone knows of a similar package that works please let us know
Att: Andres Perez