Hi, this is Josh from Greystripe. I replied to Anthoni via our support
email, but I also wanted to post the solution here, for those playing
along at home ;)
The fix here is pretty simple. Anthoni was missing our Activity
declaration in his Android manifest. Just add these lines to the xml
and everything should launch fine:
<activity android:name="com.greystripe.android.sdk.AdView"
android:configChanges="keyboard|keyboardHidden|orientation" >
<intent-filter>
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
If you have any other issues, you can always send any questions to our
support (*at*) greystripe (*dot*) com address. We're here to help!
On Apr 24, 5:36 pm, Anthoni <[email protected]> wrote:
> Hello,
>
> I am trying to get the Greystripe SDK to work in my application, but
> am having some serious trouble with it and not sure why.
> I have followed the instructions and done what it says to set it up,
> but my application is just not displaying at all. The DDMS says
> something about a timeout, but I don't have a clue what's going on.
>
> The application works perfectly without adding Greystripe in, so I
> know it's the actual SDK that's at fault or how I am setting it up.
> Below is both my DDMS output and the manifest of my application. Could
> someone enlighten me please ?
>
> < DDMS >
> 04-25 00:26:25.127: DEBUG/AndroidRuntime(1561): >>>>>>>>>>>>>>
> AndroidRuntime START <<<<<<<<<<<<<<
> 04-25 00:26:25.137: DEBUG/AndroidRuntime(1561): CheckJNI is ON
> 04-25 00:26:25.447: DEBUG/AndroidRuntime(1561): --- registering native
> functions ---
> 04-25 00:26:25.457: INFO/jdwp(1561): received file descriptor 20 from
> ADB
> 04-25 00:26:26.517: DEBUG/PackageParser(586): Scanning package: /data/
> app/vmdl25923.tmp
> 04-25 00:26:26.927: INFO/PackageManager(586): Removing non-system
> package:com.abulba.moviedb
> 04-25 00:26:26.939: DEBUG/PackageManager(586): Removing package
> com.abulba.moviedb
> 04-25 00:26:26.946: DEBUG/PackageManager(586): Unregistered content
> provider: com.abulba.AdContentProvider, className =
> com.greystripe.android.sdk.AdContentProvider, isSyncable = false
> 04-25 00:26:26.946: DEBUG/PackageManager(586): Providers:
> com.greystripe.android.sdk.AdContentProvider
> 04-25 00:26:26.956: DEBUG/PackageManager(586): Activities:
> com.abulba.moviedb.main com.abulba.moviedb.DetailsActivity
> com.abulba.moviedb.ActorActivity com.abulba.moviedb.QuotesActivity
> com.abulba.moviedb.DirectorActivity com.abulba.moviedb.Actorography
> com.greystripe.android.sdk.AdView
> com.abulba.moviedb.AdditionalActivity
> 04-25 00:26:27.077: DEBUG/PackageManager(586): Scanning package
> com.abulba.moviedb
> 04-25 00:26:27.087: INFO/PackageManager(586): /data/app/vmdl25923.tmp
> changed; unpacking
> 04-25 00:26:27.116: DEBUG/installd(555): DexInv: --- BEGIN '/data/app/
> vmdl25923.tmp' ---
> 04-25 00:26:28.207: DEBUG/dalvikvm(1567): DexOpt: load 405ms, verify
> 427ms, opt 9ms
> 04-25 00:26:28.227: DEBUG/installd(555): DexInv: --- END '/data/app/
> vmdl25923.tmp' (success) ---
> 04-25 00:26:28.236: DEBUG/PackageManager(586): Registered content
> provider: com.abulba.AdContentProvider, className =
> com.greystripe.android.sdk.AdContentProvider, isSyncable = false
> 04-25 00:26:28.236: DEBUG/PackageManager(586): Providers:
> com.greystripe.android.sdk.AdContentProvider
> 04-25 00:26:28.236: DEBUG/PackageManager(586): Activities:
> com.abulba.moviedb.main com.abulba.moviedb.DetailsActivity
> com.abulba.moviedb.ActorActivity com.abulba.moviedb.QuotesActivity
> com.abulba.moviedb.DirectorActivity com.abulba.moviedb.Actorography
> com.greystripe.android.sdk.AdView
> com.abulba.moviedb.AdditionalActivity
> 04-25 00:26:28.387: INFO/installd(555): move /data/dalvik-cache/
> d...@a...@[email protected] -> /data/dalvik-cache/
> d...@[email protected][email protected]
> 04-25 00:26:28.397: DEBUG/PackageManager(586): New package installed
> in /data/app/com.abulba.moviedb.apk
> 04-25 00:26:28.576: DEBUG/AndroidRuntime(1561): Shutting down VM
> 04-25 00:26:28.576: DEBUG/dalvikvm(1561): DestroyJavaVM waiting for
> non-daemon threads to exit
> 04-25 00:26:28.586: DEBUG/ActivityManager(586): Uninstalling process
> com.abulba.moviedb
> 04-25 00:26:28.607: DEBUG/dalvikvm(1561): DestroyJavaVM shutting VM
> down
> 04-25 00:26:28.617: DEBUG/dalvikvm(1561): HeapWorker thread shutting
> down
> 04-25 00:26:28.617: DEBUG/dalvikvm(1561): HeapWorker thread has shut
> down
> 04-25 00:26:28.617: DEBUG/jdwp(1561): JDWP shutting down net...
> 04-25 00:26:28.617: DEBUG/jdwp(1561): +++ peer disconnected
> 04-25 00:26:28.617: INFO/dalvikvm(1561): Debugger has detached; object
> registry had 1 entries
> 04-25 00:26:28.627: DEBUG/dalvikvm(1561): VM cleaning up
> 04-25 00:26:28.666: DEBUG/ActivityManager(586): Force removing process
> ProcessRecord{436a5098 1526:com.abulba.moviedb/10021}
> (com.abulba.moviedb/10021)
> 04-25 00:26:28.688: WARN/dalvikvm(1561): LinearAlloc 0x0 not freed:
> 0x410caa08 len=20
> 04-25 00:26:28.706: WARN/dalvikvm(1561): LinearAlloc 0x0 not freed:
> 0x410caa20 len=340
> 04-25 00:26:28.706: WARN/dalvikvm(1561): LinearAlloc 0x0 not freed:
> 0x410cab78 len=2244
> 04-25 00:26:28.720: DEBUG/dalvikvm(1561): LinearAlloc 0x0 used 632188
> of 4194304 (15%)
> 04-25 00:26:28.756: INFO/Process(586): Sending signal. PID: 1526 SIG:
> 9
> 04-25 00:26:28.858: INFO/WindowManager(586): WIN DEATH:
> Window{436f6c48 com.abulba.moviedb/com.abulba.moviedb.main
> paused=false}
> 04-25 00:26:28.916: DEBUG/ActivityManager(586): Received spurious
> death notification for thread android.os.binderpr...@4374ffd8
> 04-25 00:26:29.056: WARN/ResourceType(586): No package identifier when
> getting value for resource number 0x7f060000
> 04-25 00:26:29.086: WARN/ResourceType(586): No package identifier when
> getting value for resource number 0x7f060001
> 04-25 00:26:29.297: DEBUG/dalvikvm(685): GC freed 82 objects / 3976
> bytes in 335ms
> 04-25 00:26:29.307: DEBUG/HomeLoaders(685): application intent
> received: android.intent.action.PACKAGE_REMOVED, replacing=true
> 04-25 00:26:29.326: DEBUG/HomeLoaders(685): -->
> package:com.abulba.moviedb
> 04-25 00:26:29.326: DEBUG/HomeLoaders(685): application intent
> received: android.intent.action.PACKAGE_ADDED, replacing=true
> 04-25 00:26:29.336: DEBUG/HomeLoaders(685): -->
> package:com.abulba.moviedb
> 04-25 00:26:29.336: DEBUG/HomeLoaders(685): --> update package
> com.abulba.moviedb
> 04-25 00:26:29.547: DEBUG/dalvikvm(586): GC freed 8088 objects /
> 411264 bytes in 374ms
> 04-25 00:26:29.837: WARN/ResourceType(586): No package identifier when
> getting value for resource number 0x7f060000
> 04-25 00:26:29.887: WARN/ResourceType(586): No package identifier when
> getting value for resource number 0x7f060001
> 04-25 00:26:30.126: DEBUG/AndroidRuntime(1572): >>>>>>>>>>>>>>
> AndroidRuntime START <<<<<<<<<<<<<<
> 04-25 00:26:30.126: DEBUG/AndroidRuntime(1572): CheckJNI is ON
> 04-25 00:26:30.446: INFO/jdwp(1572): received file descriptor 20 from
> ADB
> 04-25 00:26:30.476: DEBUG/AndroidRuntime(1572): --- registering native
> functions ---
> 04-25 00:26:31.527: INFO/ActivityManager(586): Starting activity:
> Intent { flags=0x10000000 comp={com.abulba.moviedb/
> com.abulba.moviedb.main} }
> 04-25 00:26:31.617: DEBUG/AndroidRuntime(1572): Shutting down VM
> 04-25 00:26:31.627: DEBUG/dalvikvm(1572): DestroyJavaVM waiting for
> non-daemon threads to exit
> 04-25 00:26:31.657: DEBUG/dalvikvm(1572): DestroyJavaVM shutting VM
> down
> 04-25 00:26:31.657: DEBUG/dalvikvm(1572): HeapWorker thread shutting
> down
> 04-25 00:26:31.667: DEBUG/dalvikvm(1572): HeapWorker thread has shut
> down
> 04-25 00:26:31.667: DEBUG/jdwp(1572): JDWP shutting down net...
> 04-25 00:26:31.667: DEBUG/jdwp(1572): +++ peer disconnected
> 04-25 00:26:31.667: INFO/dalvikvm(1572): Debugger has detached; object
> registry had 2 entries
> 04-25 00:26:31.677: INFO/ActivityManager(586): Start proc
> com.abulba.moviedb for activity com.abulba.moviedb/.main: pid=1579
> uid=10021 gids={3003}
> 04-25 00:26:31.687: DEBUG/dalvikvm(1572): VM cleaning up
> 04-25 00:26:31.806: WARN/dalvikvm(1572): LinearAlloc 0x0 not freed:
> 0x410caa08 len=20
> 04-25 00:26:31.867: WARN/dalvikvm(1572): LinearAlloc 0x0 not freed:
> 0x410caa20 len=340
> 04-25 00:26:31.867: WARN/dalvikvm(1572): LinearAlloc 0x0 not freed:
> 0x410cab78 len=2244
> 04-25 00:26:31.877: DEBUG/dalvikvm(1572): LinearAlloc 0x0 used 641844
> of 4194304 (15%)
> 04-25 00:26:31.996: INFO/jdwp(1579): received file descriptor 20 from
> ADB
> 04-25 00:26:32.127: WARN/System.err(1579): Can't dispatch DDM chunk
> 4d505251: no handler defined
> 04-25 00:26:32.156: DEBUG/dalvikvm(669): GC freed 9289 objects /
> 524248 bytes in 600ms
> 04-25 00:26:32.416: INFO/ActivityThread(1579): Publishing provider
> com.abulba.AdContentProvider:
> com.greystripe.android.sdk.AdContentProvider
> 04-25 00:26:32.766: INFO/com.greystripe.android.sdk.GSSDKImpl(1579):
> initialize(myappid)
> 04-25 00:26:32.867: INFO/ActivityManager(586): Starting activity:
> Intent { flags=0x10000000 comp={com.abulba.moviedb/
> com.greystripe.android.sdk.AdView} (has extras) }
> 04-25 00:26:33.667: INFO/global(1579): Default buffer size used in
> BufferedReader constructor. It would be better to be explicit if an 8k-
> char buffer is required.
> 04-25 00:26:33.847: INFO/com.greystripe.android.sdk.GSSDKImpl(1579):
> initialize(myappid)
> 04-25 00:26:34.027: DEBUG/dalvikvm(1579): GC freed 2412 objects /
> 299208 bytes in 163ms
> 04-25 00:26:34.087: INFO/com.greystripe.android.sdk.GSSDKImpl(1579):
> boot initialization attempt #0
> 04-25 00:26:34.327: DEBUG/InetAddress(1579): ads2.greystripe.com:
> 174.143.230.35 (family 2, proto 6)
> 04-25 00:26:34.756: INFO/com.greystripe.android.sdk.GSSDKImpl(1579):
> client version is current
> 04-25 00:26:35.266: DEBUG/dalvikvm(1579): GC freed 4571 objects /
> 332704 bytes in 94ms
> 04-25 00:26:36.858: DEBUG/dalvikvm(1579): GC freed 3227 objects /
> 446104 bytes in 93ms
> 04-25 00:26:41.596: WARN/ActivityManager(586): Launch timeout has
> expired, giving up wake lock!
> 04-25 00:26:42.256: WARN/ActivityManager(586): Activity idle timeout
> for HistoryRecord{435a4ab8 {com.abulba.moviedb/
> com.abulba.moviedb.main}}
> 04-25 00:26:47.367: DEBUG/dalvikvm(685): GC freed 605 objects / 32592
> bytes in 104ms
> 04-25 00:26:52.266: WARN/ActivityManager(586): Activity destroy
> timeout for HistoryRecord{435b4db0 {com.abulba.moviedb/
> com.greystripe.android.sdk.AdView}}
> 04-25 00:27:11.266: INFO/ActivityManager(586): Starting activity:
> Intent { action=android.intent.action.MAIN
> categories={android.intent.category.HOME} flags=0x10200000
> comp={com.android.launcher/com.android.launcher.Launcher} }
> 04-25 00:27:11.801: WARN/ActivityManager(586): Activity pause timeout
> for HistoryRecord{435a4ab8 {com.abulba.moviedb/
> com.abulba.moviedb.main}}
> 04-25 00:27:11.867: WARN/InputManagerService(586): Window already
> focused, ignoring focus gain of:
> com.android.internal.view.iinputmethodclient$stub$pr...@43762230
> </DDMS >
>
> <?xml version="1.0" encoding="utf-8"?>
> <manifest xmlns:android="http://schemas.android.com/apk/res/android"
> package="com.abulba.moviedb"
> android:versionCode="1"
> android:versionName="1.0">
> <application android:icon="@drawable/icon" android:label="@string/
> app_name" android:description="@string/app_desc">
> <activity android:name=".main" android:label="@string/
> app_name">
> <intent-filter>
> <action android:name="android.intent.action.MAIN" />
> <category
> android:name="android.intent.category.LAUNCHER" />
> </intent-filter>
> </activity>
>
> <activity android:name=".DetailsActivity" android:label="@string/
> detail_title"></activity>
> <activity android:name=".ActorActivity" android:label="@string/
> actor_title"></activity>
> <activity android:name=".QuotesActivity" android:label="@string/
> quotes_title"></activity>
> <activity android:name=".DirectorActivity" android:label="@string/
> director_title"></activity>
> <activity android:name=".Actorography" android:label="@string/
> actorography_title"></activity>
> <activity android:name="com.greystripe.android.sdk.AdView"></
> activity>
>
> <!--
> Used to add adverts in, remove when ready to deploy
> -->
> <provider
> android:name="com.greystripe.android.sdk.AdContentProvider"
> android:authorities="com.abulba.AdContentProvider"
> android:multiprocess="true"
> android:exported="false"
> />
>
> <activity android:name=".AdditionalActivity"></activity>
> </application>
> <uses-sdk android:minSdkVersion="3" />
>
> <uses-permission android:name="android.permission.INTERNET"></uses-
> permission>
> <uses-permission android:name="android.permission.READ_PHONE_STATE"></
> uses-permission>
> <uses-permission
> android:name="android.permission.ACCESS_NETWORK_STATE"></uses-
> permission>
> </manifest>
>
> Regards
> Anthoni
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group
> athttp://groups.google.com/group/android-developers?hl=en
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en