NewInstructionEventListener跳过一些停止操作 [英] NewInstructionEventListener skipping some stop over maneuvers

查看:76
本文介绍了NewInstructionEventListener跳过一些停止操作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用sdk编写应用程序,并且我的路线有很多停靠点(> 100),并且我需要确保驱动程序能够通过所有这些停靠点.

I'm writing an application with the here sdk and I have routes with a lot of stop overs (> 100) and I need to make sure that the driver goes through all of them.

为此,我:

  1. 计划后从MapRoute#getRoute()#getManeuvers()方法获取中途停留列表.
  2. 收听NewInstructionEventListener#onNewInstructionEvent()以了解驱动程序何时到达中途停留地点.

问题是有时候,即使驱动程序到达了事件,我也没有收到事件.

Problem is that sometimes, I don't receive the event even if the driver has reached it.

我能够在模拟模式下重现此问题,并且我相信它与行驶速度有关.我的信念是,当车辆快速行驶时,不会为中途停留操作发出指令.

I was able to reproduce this issue in simulation mode and I believe it is linked to the driving speed. My belief is that when the vehicle goes to fast, no instruction is generated for the stopover maneuver.

我不知道如何解决此问题.是否有办法获得中途停留"事件. (我宁愿避免使用positionmanager并计算到中途停留的距离)

I don't know how to work around this problem. Is there a way to get a "stopover reached" event. (I would prefer to avoid using the positionmanager and compute the distance to the stopovers)

谢谢.

推荐答案

不幸的是,在这种情况下,不能依赖onNewInstructionEvent回调.根据速度和其他因素,您的评估是正确的,您可能无法在所有情况下都获得回调.

Unfortunately the onNewInstructionEventcallback cannot be relied on for this use case. Your assessment is correct, based on speed and other factors you may not get the callback in all cases.

调整参数以触发onNewInstructionEvent回调的功能未作为SDK的一部分公开.您将必须研究实现您的用例的其他方法,例如您提到的距离解决方案.

The ability to tune the parameters for triggering onNewInstructionEventcallback are not exposed as part of the SDK. You will have to investigate other approaches for achieving your use case such as distance solution you mentioned.

这篇关于NewInstructionEventListener跳过一些停止操作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆