0

我已将 AdWhirl 集成到我的应用程序中,但我得到的只是蓝屏,我的问题是什么?这是我的 LogCat

 07-18 10:19:16.342: INFO/AdWhirl SDK(536): Creating adWhirlManager...
    07-18 10:19:16.342: DEBUG/AdWhirl SDK(536): Locale is: en_US

07-18 10:19:16.392: DEBUG/AdWhirl SDK(536): Hashed device ID is: 7d1dd13a2fa91c0ad174cb69a11549a3
07-18 10:19:16.392: INFO/AdWhirl SDK(536): Finished creating adWhirlManager
07-18 10:19:16.482: DEBUG/AdWhirl SDK(536): Prefs{8ebb402972284c059c3c29290c148c1f}: {"config": "{"extra":{"location_on":0,"background_color_rgb":{"red":255,"green":255,"blue":255,"alpha":1},"text_color_rgb":{"red":0,"green":0,"blue":0,"alpha":1},"cycle_time":30,"transition":8},"rations":[{"nid":"eca2504eac0b4c7c92d10eb9f5d6cc55","type":17,"nname":"event","weight":100,"priority":1,"key":"adfonic|;|requestAds"}]}
07-18 10:19:16.482: DEBUG/AdWhirl SDK(536): ", "timestamp": 1310983984384}
07-18 10:19:16.532: INFO/AdWhirl SDK(536): Stored config info not present or expired, fetching fresh data
07-18 10:19:16.762: INFO/ActivityManager(37): Displayed activity somon.sattori/.AdwhirlActivity: 1606 ms (total 1606 ms)
07-18 10:19:17.232: DEBUG/AdWhirl SDK(536): HTTP/1.1 200 OK
07-18 10:19:17.272: DEBUG/AdWhirl SDK(536): Received jsonString: {"extra":{"location_on":0,"background_color_rgb":{"red":255,"green":255,"blue":255,"alpha":1},"text_color_rgb":{"red":0,"green":0,"blue":0,"alpha":1},"cycle_time":30,"transition":8},"rations":[{"nid":"eca2504eac0b4c7c92d10eb9f5d6cc55","type":17,"nname":"event","weight":100,"priority":1,"key":"adfonic|;|requestAds"}]}
07-18 10:19:17.302: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:19:17.302: DEBUG/AdWhirl SDK(536): Dart is <49.10743447084954> of <100.0>
07-18 10:19:17.312: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:19:17.312: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:19:17.312: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:19:17.312: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:19:17.312: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:19:17.312: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:19:17.322: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:19:17.332: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:19:17.332: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:19:17.342: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:19:17.352: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:19:17.352: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:19:17.352: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:19:17.352: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds
07-18 10:19:22.072: DEBUG/dalvikvm(115): GC_EXPLICIT freed 690 objects / 39048 bytes in 237ms
07-18 10:19:27.041: DEBUG/dalvikvm(229): GC_EXPLICIT freed 179 objects / 12552 bytes in 163ms
07-18 10:19:32.041: DEBUG/dalvikvm(260): GC_EXPLICIT freed 65 objects / 3032 bytes in 139ms
07-18 10:19:47.363: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:19:47.363: DEBUG/AdWhirl SDK(536): Dart is <81.05320880409683> of <100.0>
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:19:47.381: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:19:47.381: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:19:47.381: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds
07-18 10:20:17.403: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:20:17.403: DEBUG/AdWhirl SDK(536): Dart is <62.64999120883845> of <100.0>
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:20:17.421: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:20:17.421: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:20:17.421: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds
07-18 10:20:47.452: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:20:47.452: DEBUG/AdWhirl SDK(536): Dart is <99.30774291820936> of <100.0>
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:20:47.472: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:20:47.472: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:20:47.472: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds
07-18 10:21:17.502: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:21:17.502: DEBUG/AdWhirl SDK(536): Dart is <80.51932668270184> of <100.0>
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:21:17.512: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:21:17.512: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:21:17.512: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:21:17.531: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds
07-18 10:21:47.568: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:21:47.571: DEBUG/AdWhirl SDK(536): Dart is <80.618935969158> of <100.0>
07-18 10:21:47.581: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:21:47.581: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:21:47.581: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:21:47.581: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:21:47.581: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:21:47.581: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:21:47.591: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:21:47.591: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:21:47.591: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:21:47.591: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:21:47.591: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds
07-18 10:22:17.633: INFO/AdWhirl SDK(536): Rotating Ad
07-18 10:22:17.633: DEBUG/AdWhirl SDK(536): Dart is <62.376967053984686> of <100.0>
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536): Showing ad:
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536):     nid: eca2504eac0b4c7c92d10eb9f5d6cc55
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536):     name: event
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536):     type: 17
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536):     key: adfonic|;|requestAds
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536):     key2: 
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536): Valid adapter, calling handle()
07-18 10:22:17.652: DEBUG/AdWhirl SDK(536): Event notification request initiated
07-18 10:22:17.652: WARN/AdWhirl SDK(536): Event notification would be sent, but no interface is listening
07-18 10:22:17.652: ERROR/AdWhirl SDK(536): nextRation is null!
07-18 10:22:17.671: DEBUG/AdWhirl SDK(536): Will call rotateAd() in 30 seconds

07-18 10:22:17.671: DEBUG/AdWhirl SDK(536): 将在 30 秒内调用 rotateAd()

这是我的java代码

 AdWhirlManager.setConfigExpireTimeout(1000 * 60 * 5);
    AdWhirlTargeting.setAge(18);
    AdWhirlTargeting.setGender(AdWhirlTargeting.Gender.MALE);
    AdWhirlTargeting.setKeywords("banking, credit, interest");
    AdWhirlTargeting.setTestMode(false);
    AdWhirlLayout  adWhirlLayout = new AdWhirlLayout(this, "8ebb402972284c059c3c29290c148c1f");
    RelativeLayout.LayoutParams adWhirlLayoutParams = new RelativeLayout.LayoutParams( LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT);
    LinearLayout layout = (LinearLayout) findViewById(R.id.layout_adwhirl);
    layout.addView(adWhirlLayout, adWhirlLayoutParams);
    layout.invalidate();

最后是 xml

        <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
   xmlns:android="http://schemas.android.com/apk/res/android"
   android:layout_width="fill_parent"
   android:layout_height="fill_parent"
   android:background="#283562">

   <LinearLayout
       android:id="@+id/layout_adwhirl"
       android:orientation="vertical"
       android:layout_width="fill_parent"
       android:layout_height="wrap_content"
       android:layout_alignParentBottom="true"
       android:layout_centerHorizontal="true"
       android:background="@android:color/black"/>

</RelativeLayout>

最后,现在只有 Admob 在 Adwhirl 的网络设置中,我也将 admob 的 sdk 导入到我的项目中

4

1 回答 1

0

更改AdWhirlTargeting.setTestMode(false)为 TRUE 以在模拟器中获取结果。

于 2011-08-15T21:18:49.590 回答