我正在尝试编写一个连接到蓝牙低功耗设备的 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