Ir para o conteúdo
  • Revista PROGRAMAR: Já está disponível a edição #60 da revista programar. Faz já o download aqui!

Rick45

Android Google maps não carrega

Mensagens Recomendadas

Rick45

Boas pessoal, estou com um pequeno problema, tenho uma palicação com api v2 do google maps, quando instalo instalo a aplicaçºoa no tlm via eclipse o mapa carrega certinho, mas caso instale a aplicação via ficheiro apk funciona tudo na mesma so que o maps nao carrega.

qual será o problema?

tenho a API_KEY, tenho tmbm a keystore.

Partilhar esta mensagem


Ligação para a mensagem
Partilhar noutros sites
KTachyon

Espreita o logcat para ver o output que te dá quando utilizas a aplicação instalada. Podes ter que filtrar o output do teu telemóvel, mas os logs da tua app vão estar lá bem explícitos.


“There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult.”

-- Tony Hoare

Partilhar esta mensagem


Ligação para a mensagem
Partilhar noutros sites
Rick45

o log cat é o seguinte:

08-28 14:11:23.800: I/ActivityManager(523): START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.example.easylocalizer/.MainActivity} from pid 716
08-28 14:11:24.020: I/ActivityManager(523): Start proc com.example.easylocalizer for activity com.example.easylocalizer/.MainActivity: pid=17762 uid=10010 gids={50010, 1015, 3003, 1028}
08-28 14:11:24.170: W/Trace(17762): error opening trace file: No such file or directory (2)
08-28 14:11:24.210: W/ActivityThread(17762): Application com.example.easylocalizer is waiting for the debugger on port 8100...
08-28 14:11:24.210: I/System.out(17762): Sending WAIT chunk
08-28 14:11:24.240: I/dalvikvm(17762): Debugger is active
08-28 14:11:24.430: I/System.out(17762): Debugger has connected
08-28 14:11:24.430: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:24.630: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:24.830: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:25.030: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:25.230: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:25.430: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:25.630: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:25.830: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:26.030: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:26.230: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:26.440: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:26.640: I/System.out(17762): waiting for debugger to settle...
08-28 14:11:26.840: I/System.out(17762): debugger has settled (1385)
08-28 14:11:30.560: W/System.err(17762): java.io.FileNotFoundException: /mnt/sdcard/download/data.txt: open failed: ENOENT (No such file or directory)
08-28 14:11:30.560: W/System.err(17762):  at libcore.io.IoBridge.open(IoBridge.java:416)
08-28 14:11:30.560: W/System.err(17762):  at java.io.FileOutputStream.<init>(FileOutputStream.java:88)
08-28 14:11:30.570: W/System.err(17762):  at java.io.FileOutputStream.<init>(FileOutputStream.java:73)
08-28 14:11:30.570: W/System.err(17762):  at java.io.FileWriter.<init>(FileWriter.java:80)
08-28 14:11:30.580: W/System.err(17762):  at com.example.easylocalizer.MainActivity.onCreate(MainActivity.java:125)
08-28 14:11:30.580: W/System.err(17762):  at android.app.Activity.performCreate(Activity.java:5104)
08-28 14:11:30.590: W/System.err(17762):  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1080)
08-28 14:11:30.590: W/System.err(17762):  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2262)
08-28 14:11:30.590: W/System.err(17762):  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2358)
08-28 14:11:30.600: W/System.err(17762):  at android.app.ActivityThread.access$600(ActivityThread.java:153)
08-28 14:11:30.600: W/System.err(17762):  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1247)
08-28 14:11:30.600: W/System.err(17762):  at android.os.Handler.dispatchMessage(Handler.java:99)
08-28 14:11:30.600: W/System.err(17762):  at android.os.Looper.loop(Looper.java:137)
08-28 14:11:30.610: W/System.err(17762):  at android.app.ActivityThread.main(ActivityThread.java:5227)
08-28 14:11:30.610: W/System.err(17762):  at java.lang.reflect.Method.invokeNative(Native Method)
08-28 14:11:30.610: W/System.err(17762):  at java.lang.reflect.Method.invoke(Method.java:511)
08-28 14:11:30.610: W/System.err(17762):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:795)
08-28 14:11:30.620: W/System.err(17762):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:562)
08-28 14:11:30.640: W/System.err(17762):  at dalvik.system.NativeStart.main(Native Method)
08-28 14:11:30.650: W/System.err(17762): Caused by: libcore.io.ErrnoException: open failed: ENOENT (No such file or directory)
08-28 14:11:30.670: W/System.err(17762):  at libcore.io.Posix.open(Native Method)
08-28 14:11:30.670: W/System.err(17762):  at libcore.io.BlockGuardOs.open(BlockGuardOs.java:110)
08-28 14:11:30.680: W/System.err(17762):  at libcore.io.IoBridge.open(IoBridge.java:400)
08-28 14:11:30.680: W/System.err(17762):  ... 18 more
08-28 14:11:30.870: I/ActivityManager(523): START u0 {cmp=com.example.easylocalizer/.Preferences} from pid 17762
08-28 14:11:31.170: W/ResourceType(17762): getEntry failing because entryIndex 906 is beyond type entryCount 2
08-28 14:11:31.190: W/ResourceType(17762): Failure getting entry for 0x7f0b038a (t=10 e=906) in package 0 (error -2147483647)
08-28 14:11:31.190: E/GooglePlayServicesUtil(17762): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
08-28 14:11:31.390: W/ActivityManager(523): Activity pause timeout for ActivityRecord{40d7b818 u0 com.example.easylocalizer/.MainActivity}
08-28 14:11:32.410: W/Resources(17762): Converting to string: TypedValue{t=0x10/d=0x5 a=-1}
08-28 14:11:32.600: I/Google Maps Android API(17762): Failed to contact Google servers. Another attempt will be made when connectivity is established.
08-28 14:11:32.760: I/Choreographer(17762): Skipped 57 frames!  The application may be doing too much work on its main thread.
08-28 14:11:33.590: D/libEGL(17762): loaded /system/lib/egl/libEGL_adreno200.so
08-28 14:11:33.610: D/libEGL(17762): loaded /system/lib/egl/libGLESv1_CM_adreno200.so
08-28 14:11:33.620: D/libEGL(17762): loaded /system/lib/egl/libGLESv2_adreno200.so
08-28 14:11:33.730: D/OpenGLRenderer(17762): Enabling debug mode 0
08-28 14:11:33.820: I/Choreographer(17762): Skipped 40 frames!  The application may be doing too much work on its main thread.
08-28 14:11:33.860: W/ActivityManager(523): Launch timeout has expired, giving up wake lock!
08-28 14:11:34.110: W/ActivityManager(523): Activity idle timeout for ActivityRecord{40d7b818 u0 com.example.easylocalizer/.MainActivity}
08-28 14:11:34.110: I/ActivityManager(523): No longer want com.bel.android.dspmanager (pid 16115): empty for 1800s
08-28 14:11:34.370: W/ActivityManager(523): Scheduling restart of crashed service com.bel.android.dspmanager/.service.HeadsetService in 5000ms
08-28 14:11:35.780: I/ActivityManager(523): Displayed com.example.easylocalizer/.Preferences: +4s397ms (total +11s783ms)
08-28 14:11:38.800: W/ResourceType(17762): getEntry failing because entryIndex 906 is beyond type entryCount 2
08-28 14:11:38.800: W/ResourceType(17762): Failure getting entry for 0x7f0b038a (t=10 e=906) in package 0 (error -2147483647)
08-28 14:11:38.800: E/GooglePlayServicesUtil(17762): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
08-28 14:11:39.400: I/ActivityManager(523): Start proc com.bel.android.dspmanager for service com.bel.android.dspmanager/.service.HeadsetService: pid=17803 uid=10028 gids={50028, 3002, 1028}
08-28 14:11:39.640: W/Trace(17803): error opening trace file: No such file or directory (2)
08-28 14:11:39.810: I/HeadsetService(17803): Starting service.
08-28 14:11:40.210: I/ActivityManager(523): Displayed com.example.easylocalizer/.MainActivity: +16s210ms
08-28 14:11:40.870: D/libloc(523): loc_eng_set_position mode, client = 0, interval = 1 sec, mode = 1 (SA=0/MSB=1/MSA=2)
08-28 14:11:40.920: D/libloc(523): loc_eng_ioctl called: client = 0, ioctl_type = RPC_LOC_IOCTL_SET_FIX_CRITERIA
08-28 14:11:40.920: D/RPC(523): 3000008c:00040000 sending call (XID 75).
08-28 14:11:40.930: D/RPC(523): 3000008c:00040000 received REPLY (XID 75), grabbing mutex to wake up client.

penso que o problema deve estar aquit:

08-28 14:11:38.800: E/GooglePlayServicesUtil(17762): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.

o que poderá ser?

Partilhar esta mensagem


Ligação para a mensagem
Partilhar noutros sites
KTachyon

Estás a utilizar o API Key de testes no APK assinado?


“There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult.”

-- Tony Hoare

Partilhar esta mensagem


Ligação para a mensagem
Partilhar noutros sites

Crie uma conta ou ligue-se para comentar

Só membros podem comentar

Criar nova conta

Registe para ter uma conta na nossa comunidade. É fácil!

Registar nova conta

Entra

Já tem conta? Inicie sessão aqui.

Entrar Agora

×

Aviso Sobre Cookies

Ao usar este site você aceita os nossos Termos de Uso e Política de Privacidade. Este site usa cookies para disponibilizar funcionalidades personalizadas. Para mais informações visite esta página.