# getBlueStatus ^6.8
获取蓝牙状态
# 请求参数
N/A
# 接口调用示例
this.$bridge
.getBlueStatus()
.then(res => {
this.$alert(res)
})
.catch(err => {
this.$toast(err)
})
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
# 返回参数
- 成功时返回
Prop | Type | Default | Description |
---|---|---|---|
messageBody | Object | N/A | |
messageType | String | N/A | singleBlueStatus |
- messageBody 对象属性
Prop | Type | Default | Description |
---|---|---|---|
status | Number | N/A | 1表示蓝牙已打开,0:蓝牙关闭状态,2::蓝牙正在重置,3:设备不支持蓝牙,4:蓝牙未授权 |
- 失败时返回
Prop | Type | Default | Description |
---|---|---|---|
errorMessage | String | N/A | 错误消息 |
errorCode | Number | N/A | 错误码 |