【发布时间】:2019-07-03 15:01:40
【问题描述】:
我正在尝试编写一个连接到蓝牙低功耗设备的 chrome 应用程序。我在清单中添加了"bluetooth": { "low_energy": true }:
{
"name": "DE1",
"version": "1",
"manifest_version": 2,
"icons": {
"128": "de1icon.png"
},
"permissions": [],
"bluetooth": {
"uuids": ["A000"],
"low_energy": true
},
"app": {
"background": {
"scripts": ["chrome.js"]
}
}
}
但是当我打电话时
chrome.bluetoothLowEnergy.connect
我得到了错误
Error handling response: TypeError: Cannot read property 'connect' of undefined
文档说这是我应该做的
https://developer.chrome.com/apps/manifest/bluetooth#reference
【问题讨论】:
标签: bluetooth bluetooth-lowenergy google-chrome-app web-bluetooth