PDA

View Full Version : onDestinationReached” has not occured in SKNavigationListener



pchad
08.03.2016, 16:06
Hi Guys,

While driving(simulation mode), sometimes in front of destination, I got the result in “40 meters you will reach your destination” and when I stop the driving then "onDestinationReached" method is not occurring in SKNavigationListener. Is it how it is supposed to work?


SKNavigationState [adviceID=0, currentSpeed=4.60116423119374E-46, currentSpeedLimit=0.0, countryCode=CN, lastAdvice=false, showSignPost=true, currentAdviceCurrentStreetName=, currentAdviceNextStreetName=, currentAdviceCurrentOsmStreetType=RESIDENTIAL, currentAdviceNextOsmStreetType=UNDEFINED, currentAdviceDistanceToAdvice=174, currentAdviceTimeToDestination=-50, currentAdviceDistanceToDestination=-212, currentAdviceVisualAdviceFile=/storage/emulated/0/BakbakMaps/Maps/Advisor/Visual/954958/0.png, currentAdviceAudioAdvices=[in_open, 100_open, 70_closed, meters, you_will_reach_your_destination], currentAdviceExitNumber=, nextAdviceCurrentStreetName=, nextAdviceNextStreetName=, nextAdviceDistanceToAdvice=275, nextAdviceVisualAdviceFile=, nextAdviceCurrentOsmStreetType=RESIDENTIAL, nextAdviceNextOsmStreetType=UNDEFINED, distanceToDestination=28.0, firstCrossingDescriptor=SKCrossingDescriptor [crossingType=0, routeAngle=90.0, turnToRight=false, directionUK=false, allowedRoutesAngles=null, forbiddenRoutesAngles=null], secondCrossingDescriptor=SKCrossingDescriptor [crossingType=0, routeAngle=180.0, turnToRight=false, directionUK=false, allowedRoutesAngles=[90.0], forbiddenRoutesAngles=null], adviceInstruction=in 100 70 meters you will reach your destination, viaPointsInfo=null, isLastVisualAdvice=true, currentStreetDirection=DIRECTION_LEFT, nextStreetDirection=DIRECTION_LEFT]”

Techknow
09.03.2016, 08:01
Hi, from my understanding, onDestinationReached() is called when a distance threshold is met depending on the type of road you are traveling in and specified values in a advice file in SKMaps.zip. See this topic (http://forum.skobbler.com/showthread.php/7454-routingServiceDidReachDestination-called-too-early). When the distanceToDestination value is close enough to the threshold the method will be called. If the waypoint is too far away from the road it is possible it won't be called.

pchad
09.03.2016, 15:53
Thanks for the pointer. That really helps.




Hi, from my understanding, onDestinationReached() is called when a distance threshold is met depending on the type of road you are traveling in and specified values in a advice file in SKMaps.zip. See this topic (http://forum.skobbler.com/showthread.php/7454-routingServiceDidReachDestination-called-too-early). When the distanceToDestination value is close enough to the threshold the method will be called. If the waypoint is too far away from the road it is possible it won't be called.