标签: estimote

如何在 React Native Android 构建中包含 AAR?

我正在尝试在我的 React Native Android 应用程序中包含一个 AAR 文件,以便我可以使用本机代码访问其功能。如何捆绑 AAR 以便本机代码可以使用 React Native Android 导入它?谢谢!

我在编译时得到的错误是这样的:

~\app\android\app\src\main\java\com\grind\GrindModule.java:13: error: package com.estimote.sdk does not exist
import com.estimote.sdk.EstimoteSDK;
                        ^
Run Code Online (Sandbox Code Playgroud)

我进行了以下更改:

创建android/app/libs/estimote-sdk.aar.

创建 react native 原生模块(我以前做过几次,在我尝试使用 SDK 之前它工作正常)。

android/app/build.gradle

dependencies {
    compile(name:'estimote-sdk', ext:'aar')
    compile fileTree(dir: "libs", include: ["*.jar"])
    compile "com.android.support:appcompat-v7:23.0.1"
    compile "com.facebook.react:react-native:+"  // From node_modules
}
Run Code Online (Sandbox Code Playgroud)

android/build.gradle

...
allprojects {
    repositories {
        mavenLocal()
        jcenter()
        maven {
            // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
            url "$rootDir/../node_modules/react-native/android"
        }
        flatDir …
Run Code Online (Sandbox Code Playgroud)

android estimote react-native

11
推荐指数
2
解决办法
1万
查看次数

Estimote信标区域检测从后台服务

我最近开始测试Estimote Beacons,我正在尝试在进入信标区域时从后台服务发出通知,但不幸的是我的解决方案不起作用.它不会出错,但在发现信标时不会启动通知.我不知道它是否是一些代码错误或只是这样做的方式是错误的.我已经阅读了这个其他问题,但它看起来有点不同,因为我使用的是服务而不是活动,但也许答案是类似的(应用程序上下文相关)...

这是我的服务代码

public class BeaconsMonitoringService extends Service{

    private BeaconManager beaconManager;

    private String user;

    @Override
      public void onCreate() {
        // Configure BeaconManager.
        beaconManager = new BeaconManager(this);

      }

      @Override
      public int onStartCommand(Intent intent, int flags, int startId) {
          Toast.makeText(this, "Beacons monitoring service starting", Toast.LENGTH_SHORT).show();

          user = intent.getStringExtra("user");

            // Check if device supports Bluetooth Low Energy.
            if (!beaconManager.hasBluetooth()||!beaconManager.isBluetoothEnabled()) {
              Toast.makeText(this, "Device does not have Bluetooth Low Energy or it is not enabled", Toast.LENGTH_LONG).show();
              this.stopSelf();
            }

              connectToService();


          // If we get …
Run Code Online (Sandbox Code Playgroud)

android ibeacon ibeacon-android estimote

10
推荐指数
1
解决办法
4030
查看次数

Estimote beacon - 监听和测距听众之间的差异

我似乎并不真正理解MonitoringListener和RangingListener之间的区别.

在我的特定用例中,我希望不断了解范围内的所有信标,并且想知道何时退出与其中任何一个相关联的区域.

这是我正在谈论的片段:

    beaconManager.setRangingListener(new BeaconManager.RangingListener() {
        @Override
        public void onBeaconsDiscovered(Region region, final List<Beacon> beacons) {

        }
    });
    beaconManager.setMonitoringListener(new BeaconManager.MonitoringListener() {
        @Override
        public void onEnteredRegion(Region region, List<Beacon> beacons) {

        }

        @Override
        public void onExitedRegion(Region region) {

        }
    });
Run Code Online (Sandbox Code Playgroud)

我并没有真正理解onBeaconsDiscovered和onEnteredRegion方法之间的区别.当你开始收听其中任何一个时,你都会将Region作为参数传递给我,这让我更加困惑,因为乍一看我假设第一个只是不断搜索而另一个只是寻找一个特定的区域.

谢谢!

android estimote

8
推荐指数
1
解决办法
2806
查看次数

Apple AirLocation演示应用范围不显示信标

我有3个Estimote信标,可以在App Store Estimate App中看到.

现在我正在尝试运行Apple演示应用程序AirLocation AirLocate

我已将APLDefaults.m文件中的UUID更改为默认的Estimote UUID _supportedProximityUUIDs = @[[[NSUUID alloc] initWithUUIDString:@"B9407F30-F5F8-466E-AFF9-25556B57FE6D"]];

我已启用Region启动,startMonitoringForRegion因为此stackoverflow说.

但他们没有露面,你见过这个吗?或者我错过了一些具体的估计.

问候

ibeacon estimote

7
推荐指数
1
解决办法
4444
查看次数

如何在Android中使用Estimote SDK获取Beacon的唯一ID

我正在开发一个我正在使用Beacons的应用程序.我已经完成了相关的Estimote SDK.现在问题是我需要知道特定灯塔的唯一ID.假设我有3个信标,并且所有信标都存在于设备的范围内.现在我想根据信标的唯一ID执行不同的功能.为此,我需要知道每个灯塔的唯一ID.目前我正在为Beacon提供UUID,只是检查它是否在设备区域内.我的代码如下: -

private static final String ESTIMOTE_PROXIMITY_UUID = "XYZ";
private static final Region ALL_ESTIMOTE_BEACONS = new Region("regionId",ESTIMOTE_PROXIMITY_UUID, null, null);

beaconManager.setMonitoringListener(new MonitoringListener() {

            @Override
            public void onExitedRegion(Region region) {
            //Region Exited
            }

            @Override
            public void onEnteredRegion(Region arg0, List<Beacon> arg1) {
                // TODO Auto-generated method stub
                //Do something ...
            }
        });
Run Code Online (Sandbox Code Playgroud)

现在我需要以编程方式获取Beacon的唯一ID,以便我可以根据ID做出决定.请帮我整理一下.任何帮助都会很明显.谢谢.

android ibeacon ibeacon-android estimote android-ibeacon

7
推荐指数
1
解决办法
4580
查看次数

Android Studio - Estimote SDK - 找不到类

我正在使用Estimote Android SDK和Android Studio构建应用.我已将estimote-sdk-preview.jar添加到我的libs文件夹中,并且IDE识别它(我的任何.java文件中没有错误)但是当它上传到我的HTC One时我在logcat中得到以下错误而且我得到了我手机上的"抱歉此应用已崩溃"消息:

...
05-06 18:55:44.662  23179-23179/com.freshnode.daze E/dalvikvm? Could not find class 'com.estimote.sdk.Region', referenced from method com.freshnode.daze.MainActivity.<clinit>
05-06 18:55:44.662  23179-23179/com.freshnode.daze E/dalvikvm? Could not find class 'com.estimote.sdk.BeaconManager', referenced from method com.freshnode.daze.MainActivity.<init>
...
Run Code Online (Sandbox Code Playgroud)

我试过去项目结构并通过它添加库,在我的gradle属性中我有:

dependencies {
    compile files('libs/estimote-sdk-preview.jar')
    compile 'com.android.support:gridlayout-v7:19.0.0'
    compile 'com.android.support:appcompat-v7:19.0.0'
}
Run Code Online (Sandbox Code Playgroud)

这是我的.java文件的开头:

public class MainActivity extends ActionBarActivity {

    private static final String ESTIMOTE_PROXIMITY_UUID = "B9407F30-F5F8-466E-AFF9-25556B57FE6D";
    private static final Region ALL_ESTIMOTE_BEACONS = new Region("regionId", ESTIMOTE_PROXIMITY_UUID, null, null);

    private BeaconManager beaconManager = new BeaconManager(this);

    @Override
    protected void onCreate(Bundle …
Run Code Online (Sandbox Code Playgroud)

android ibeacon-android estimote

6
推荐指数
0
解决办法
1252
查看次数

Android Estimote sdk无法扫描其他信标而不是estimote信标

我试图在android中看到带有estimote sdk的信标,但没有运气!我可以看到所有的estimote信标,但所有其他信标都没有工作(fobo beacons等)我正在使用uuid为区域内的fobo信标构造函数,我可以在logcat中看到蓝牙可以看​​到的设备,但estimode SDK未在收集它的一盏明灯!任何想法,为什么发生这种情况?我发布以下代码:

 private static final String FOBO_PROXIMITY_UUID = "00158800-587d-2206-d52b-fb6d6e2f0001";
 private static final Region FOBOBEACONS = new Region("rid", FOBO_PROXIMITY_UUID , null, null);
 public void BeaconManager(){
    beaconManager = new com.estimote.sdk.BeaconManager(this);
    beaconManager.setBackgroundScanPeriod(5000, 30000);
    beaconManager.setForegroundScanPeriod(7000, 5000);



    beaconManager.setRangingListener(new com.estimote.sdk.BeaconManager.RangingListener() {

        @Override
        public void onBeaconsDiscovered(final Region arg0, final List<Beacon> arg1) {
            // TODO Auto-generated method stub
            runOnUiThread(new Runnable() {
                  @Override
                  public void run() {
                    // Note that beacons reported here are already sorted by estimated
                    // distance between device and beacon.
                      int test=0;
                      if(arg1.size()<=0){ …
Run Code Online (Sandbox Code Playgroud)

android android-bluetooth ibeacon-android estimote

5
推荐指数
1
解决办法
5380
查看次数

使用倍数信标(在每个不同的信标上弹出视图)

我在目标C初学者.我的应用程序与一个灯塔正常工作.我正在使用"estimote SDK".我有很多问题,我想使用2或3个信标.我想为每个信标推送一个View.

我不明白我怎么能用多个信标做到这一点.

  1. 我不知道是否必须使用多个信标管理器.(ESTBeaconManager*beaconManager)

  2. 我不知道如何将不同区域传递给didRangeBeacons :( NSArray*)beacons inRegion:(ESTBeaconRegion*)region

  3. 我可以使用一个信标仅用于通知,而另外两个用于在我们关闭时弹出2个不同视图.(每个信标的一个不同视图)

谢谢你的帮助.

最好的祝福.

码:

#import "ESTViewController.h"
#import "PresentViewController.h"
#import <ESTBeaconManager.h>
#import <AudioToolbox/AudioToolbox.h>

@interface ESTViewController () <ESTBeaconManagerDelegate>

@property (nonatomic, strong) ESTBeaconManager* beaconManager;
@property (nonatomic, strong) ESTBeaconManager* beaconManager2;
@property (nonatomic, strong) ESTBeaconManager* beaconManager3;

@property (nonatomic, strong) ESTBeacon* selectedBeacon;


@end

@implementation ESTViewController

- (void)viewDidLoad
{
    [super viewDidLoad];

    // should i create one manager instance or more ?

    self.beaconManager = [[ESTBeaconManager alloc] init];
    self.beaconManager.delegate = self;
    self.beaconManager.avoidUnknownStateBeacons = NO;

    //self.beaconManager2 = [[ESTBeaconManager alloc] init];
    //self.beaconManager2.delegate = …
Run Code Online (Sandbox Code Playgroud)

objective-c ios ibeacon estimote

5
推荐指数
1
解决办法
1714
查看次数

应用程序在区域中启动时,iBeacon - didEnterRegion未被调用

我创建了一个注册信标区域的应用程序,并使用CLLocationManager开始监视这些区域

CLLocationManager *manager = [[CLLocationManager alloc] init];
manager.delegate = self;

CLBeaconRegion *region = [[CLBeaconRegion alloc] initWithProximityUUID:estimoteUUID major:12445 identifier:@"id"];
region.notifyEntryStateOnDisplay = YES;
region.notifyOnEntry = YES;
[manager startMonitoringForRegion:region];
Run Code Online (Sandbox Code Playgroud)

当我从灯塔走得足够远并走回范围时,这种方法很有效.但是didEnterRegion,如果我已经在信标区域的范围内启动应用程序,我也希望触发委托方法,而不仅仅是当我回到边界时.有没有一种简单的方法来实现这一目标?或者让CLLocationManager认为我们离开了信标范围的方法?

另一篇文章说设置region.notifyEntryStateOnDisplay = YES;并按下保持按钮会这样做 - 但我没有这个工作(iOS 7.1,iPhone 5S).

cllocationmanager ios ibeacon estimote

5
推荐指数
1
解决办法
2871
查看次数

使用智能手表进行信标检测

我刚刚开始从事信标工作。你能告诉我一件事吗,是否可以在没有手机的情况下通过手表检测到信标?哪种智能手表可以?

estimote apple-watch beacon wear-os

5
推荐指数
1
解决办法
1663
查看次数