0

I am updating Skobbler to version 2.5.2 to fix libpng Google Play Warning (I also tried to update to version 3+), but the navigation stops working properly after the update.

After onRouteCalculationCompleted I check the advices list using SKRouteManager.getInstance().getAdviceList() and receive valid advices.

SKRouteAdvice [adviceID=0, timeToDestination=261, distanceToDestination=1234, timeToAdvice=0, distanceToAdvice=0, streetName=Rua Barao do Abiaí, visualAdviceFile=/data/user/0/myapp/files/SKMaps//Advisor/Visual/104962/1.png, advicePosition=[-35.886744260787964,-7.215477737837522], adviceInstruction=Now turn left then turn right , audioFilePlaylist=[now, turn_left, then_open, turn_right], currentStreetType=RESIDENTIAL, currentStreetFCClass=FC3, streetDirection=DIRECTION_LEFT]

However, while navigating, the advice is a invalid one, like this:

onUpdateNavigationState SKNavigationState [adviceID=-1, currentSpeed=5.304781188371101E-58, currentSpeedLimit=0.0, countryCode=, lastAdvice=false, showSignPost=false, currentAdviceCurrentStreetName=, currentAdviceNextStreetName=, currentAdviceCurrentOsmStreetType=UNDEFINED, currentAdviceNextOsmStreetType=UNDEFINED, currentAdviceDistanceToAdvice=-738480304, currentAdviceTimeToDestination=-738962832, currentAdviceDistanceToDestination=-738480656, currentAdviceVisualAdviceFile=, currentAdviceAudioAdvices=[None], currentAdviceExitNumber=, nextAdviceCurrentStreetName=, nextAdviceNextStreetName=, nextAdviceDistanceToAdvice=-738854288, nextAdviceVisualAdviceFile=, nextAdviceCurrentOsmStreetType=UNDEFINED, nextAdviceNextOsmStreetType=UNDEFINED, distanceToDestination=0.0, firstCrossingDescriptor=SKCrossingDescriptor [crossingType=0, routeAngle=0.0, turnToRight=false, directionUK=false, allowedRoutesAngles=null, forbiddenRoutesAngles=null], secondCrossingDescriptor=SKCrossingDescriptor [crossingType=0, routeAngle=0.0, turnToRight=false, directionUK=false, allowedRoutesAngles=null, forbiddenRoutesAngles=null], adviceInstruction=, viaPointsInfo=null, isLastVisualAdvice=false, currentStreetDirection=DIRECTION_INVALID, nextStreetDirection=DIRECTION_INVALID]

To check if the advice list remains valid I added a log code before starting the navigation and the app crashes with the following error:

02-10 12:06:43.769 3236-3236/myapp A/libc: Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid 3236 (urance.myapp)
02-10 12:06:43.994 4166-4166/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
02-10 12:06:43.995 4166-4166/? A/DEBUG: Build fingerprint: 'google/bullhead/bullhead:7.1.1/N4F26O/3582057:user/release-keys'
02-10 12:06:43.995 4166-4166/? A/DEBUG: Revision: 'rev_1.0'
02-10 12:06:43.995 4166-4166/? A/DEBUG: ABI: 'arm'
02-10 12:06:43.995 4166-4166/? A/DEBUG: pid: 3236, tid: 3236, name: urance.myapp  >>> myapp <<<
02-10 12:06:43.995 4166-4166/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
02-10 12:06:43.995 4166-4166/? A/DEBUG:     r0 00000001  r1 d71b69dd  r2 00000002  r3 f1304a40
02-10 12:06:43.995 4166-4166/? A/DEBUG:     r4 f1323200  r5 eb614ef0  r6 00000000  r7 00000002
02-10 12:06:43.995 4166-4166/? A/DEBUG:     r8 00000001  r9 ffcd6bb4  sl c39fcd80  fp c4b7b000
02-10 12:06:43.995 4166-4166/? A/DEBUG:     ip 00000000  sp ffcd6a38  lr d72b8347  pc d72b834c  cpsr 000f0030
02-10 12:06:43.998 4166-4166/? A/DEBUG: backtrace:
02-10 12:06:44.000 4166-4166/? A/DEBUG:     #00 pc 0033734c  /data/app/myapp-2/lib/arm/libngnative.so (_ZN17SkAdviceGenerator14fillAdviceInfoEiiR16NGAdviceTypeEnumR12SkAdviceInfo+671)
02-10 12:06:44.000 4166-4166/? A/DEBUG:     #01 pc 003367ff  /data/app/myapp-2/lib/arm/libngnative.so (_ZN17SkAdviceGenerator17generateNewAdviceEibbPK6CRoute+550)
02-10 12:06:44.000 4166-4166/? A/DEBUG:     #02 pc 00332adb  /data/app/myapp-2/lib/arm/libngnative.so (_ZN9SkAdvisor22generateAllAdvicesOnceERK6CRouteb+566)
02-10 12:06:44.000 4166-4166/? A/DEBUG:     #03 pc 0011033f  /data/app/myapp-2/lib/arm/libngnative.so (NG_GetAdviceList+142)
02-10 12:06:44.000 4166-4166/? A/DEBUG:     #04 pc 000efcab  /data/app/myapp-2/lib/arm/libngnative.so (Java_com_skobbler_ngx_routing_SKRouteManager_getadvicelist+38)
02-10 12:06:44.000 4166-4166/? A/DEBUG:     #05 pc 006cb7d1  /data/app/myapp-2/oat/arm/base.odex (offset 0x658000)

P.S.: My code is very similar to Skobbler's demo project.

Does somebody else have the same problems?

Luan Barbosa
  • 462
  • 4
  • 16
  • We do, see http://stackoverflow.com/questions/41633362/skobbler-sdk-android-corrupt-inconsistent-sknavigationstate-objects – Jan Feb 15 '17 at 09:51

1 Answers1

0

The problem was caused while setting up SKAdvisorSettings. While updating Skobbler version I forgot to copy my custom advice sound file to the proper location.

Skobbler could not find the advice and configuration files for some specific languages (custom files) making the navigation not work properly.

I belive that Skobbler SDK should raise some exception or warning in this case, since the error is not really related to navigation data, like distances and time to destination. The advices should not become invalid just because the advice sound file could not be found.

So if you are having the same problem, please check if your advice files are in the correct folders.

Luan Barbosa
  • 462
  • 4
  • 16