forked from Jasonchenlijian/FastBle
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from githubwwj/master
- Loading branch information
Showing
17 changed files
with
478 additions
and
463 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,42 @@ | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
package="com.clj.fastble"> | ||
|
||
<uses-permission android:name="android.permission.BLUETOOTH" /> | ||
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" /> | ||
|
||
<!-- Android 12以下配置的三个蓝牙权限 --> | ||
<!-- 这个权限允许程序连接到已配对的蓝牙设备, 请求连接/接收连接/传输数据需要改权限, 主要用于对配对后进行操作 --> | ||
<uses-permission | ||
android:name="android.permission.BLUETOOTH" | ||
android:maxSdkVersion="30" /> | ||
|
||
<!-- 这个权限允许程序发现和配对蓝牙设备, 该权限用来管理蓝牙设备, 有了这个权限, 应用才能使用本机的蓝牙设备, 主要用于对配对前的操作 --> | ||
<uses-permission | ||
android:name="android.permission.BLUETOOTH_ADMIN" | ||
android:maxSdkVersion="30" /> | ||
|
||
<!-- Android 6.0以后,12.0以下,这两个权限是必须的,蓝牙扫描周围的设备需要获取模糊的位置信息。 | ||
这两个权限属于同一组危险权限,在清单文件中声明之后,还需要再运行时动态获取。 --> | ||
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" /> | ||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /> | ||
<!-- Android 12以下配置的两个蓝牙权限 --> | ||
|
||
|
||
|
||
|
||
<!-- Android 12 及以上版本配置的三个权限 --> | ||
<!-- 您的应用查找蓝牙设备(如蓝牙低功耗 (BLE) 外围设备)--> | ||
<uses-permission | ||
android:name="android.permission.BLUETOOTH_SCAN" | ||
android:usesPermissionFlags="neverForLocation" | ||
tools:targetApi="s" /> | ||
|
||
<!-- 应用程序使手机蓝牙可被其它蓝牙设备发现时才需要--> | ||
<uses-permission android:name="android.permission.BLUETOOTH_ADVERTISE" /> | ||
|
||
<!-- 仅应用程序与已配对的蓝牙设备通信时才需要 --> | ||
<uses-permission | ||
android:name="android.permission.BLUETOOTH_CONNECT" | ||
tools:targetApi="s" /> | ||
<!-- Android 12 及以上版本配置的三个权限 --> | ||
|
||
</manifest> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.