NewInstructionEventListener skipping some stop over maneuvers

 ̄綄美尐妖づ 提交于 2019-12-25 07:13:55

问题


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.

For that I :

  1. get the list of stopovers from the MapRoute#getRoute()#getManeuvers() method after planning.
  2. listen to the NewInstructionEventListener#onNewInstructionEvent() to know when the driver has reached a stopover.

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.

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)

Thank you.


回答1:


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.

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.



来源:https://stackoverflow.com/questions/37836266/newinstructioneventlistener-skipping-some-stop-over-maneuvers

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!