【问题标题】:can't get to work ibeacon demo app无法开始工作 ibeacon 演示应用程序
【发布时间】:2015-05-21 18:29:43
【问题描述】:
【问题讨论】:
标签:
android
ibeacon
ibeacon-android
estimote
【解决方案1】:
显然存在一个仅影响 iBeacons 的错误(根据社区 [1])。所以它应该适用于真正的 estimote ibeacons。
但是,如果您不想修复它,您需要对模拟 iBeacon 的 UUID 进行硬编码。为此,请替换
app.startRangingBeacons = function()
{
// (...)
// Start ranging.
estimote.beacons.startRangingBeaconsInRegion(
{
}, // Empty region matches all beacons.
onRange,
onError);
};
与
app.startRangingBeacons = function()
{
// (...)
// Start ranging.
estimote.beacons.startRangingBeaconsInRegion(
{
"identifier": "MyRegion",
"uuid": "your-actual-uuid"
}, // Empty region matches all beacons.
onRange,
onError);
};
[1]https://github.com/evothings/phonegap-estimotebeacons/issues/78
【解决方案2】:
不幸的是,插件使用的 Estimote Android SDK 不适用于虚拟信标,只能用于物理估计。