Failed to load Rewarded Ads

193 views
Skip to first unread message

albert

unread,
Aug 30, 2016, 5:08:42 AM8/30/16
to Google Mobile Ads SDK Developers
log
 V/PreviewActivity: a:0
 I/Ads: Starting ad request.
 D/AppStreamingHelper: Creating delegate
 W/DynamiteLoaderImpl: Failed to load module version: module com.google.android.gms.piccard.dynamite not found
 D/GmsModuleFndr: Staging file APK's and updating chimera config...
 D/GmsModuleFndr: Staging file APKs completed
 W/DynamiteLoaderImpl: Failed to load module version after staging: module com.google.android.gms.piccard.dynamite not found
 W/DynamiteModule: Local module descriptor class for com.google.android.gms.piccard.dynamite not found.
 I/DynamiteModule: Considering local module com.google.android.gms.piccard.dynamite:0 and remote module com.google.android.gms.piccard.dynamite:0
 E/AppStreamingHelper: No acceptable module found. Local version is 0 and remote version is 0.
 V/PreviewActivity: b:0
 W/Ads: There was a problem getting an ad response. ErrorCode: 0
 W/Ads: Failed to load ad: 0

code
    private RewardedVideoAd mRewardedVideoAd;
    private boolean mIsRewardedVideoLoading;
    private final Object mLock = new Object();
    private void initRewardedVideoAd(){
        MobileAds.initialize(this, DataUtils.ADMOB_VIDEO_APP_ID);
        mRewardedVideoAd = MobileAds.getRewardedVideoAdInstance(this);
        mRewardedVideoAd.setRewardedVideoAdListener(new RewardedVideoAdListener(){
            @Override
            public void onRewarded(RewardItem reward) {
                Toast.makeText(getApplicationContext(), "onRewarded! currency: " + reward.getType() + "  amount: " +
                        reward.getAmount(), Toast.LENGTH_SHORT).show();
            }

            @Override
            public void onRewardedVideoAdLeftApplication() {
                Toast.makeText(getApplicationContext(), "onRewardedVideoAdLeftApplication",
                        Toast.LENGTH_SHORT).show();
            }

            @Override
            public void onRewardedVideoAdClosed() {
                Toast.makeText(getApplicationContext(), "onRewardedVideoAdClosed", Toast.LENGTH_SHORT).show();
            }

            @Override
            public void onRewardedVideoAdFailedToLoad(int errorCode) {
                synchronized (mLock) {
                    mIsRewardedVideoLoading = false;
                }
                Toast.makeText(getApplicationContext(), "onRewardedVideoAdFailedToLoad", Toast.LENGTH_SHORT).show();
            }

            @Override
            public void onRewardedVideoAdLoaded() {
                synchronized (mLock) {
                    mIsRewardedVideoLoading = false;
                }
                Toast.makeText(getApplicationContext(), "onRewardedVideoAdLoaded", Toast.LENGTH_SHORT).show();
            }

            @Override
            public void onRewardedVideoAdOpened() {
                Toast.makeText(getApplicationContext(), "onRewardedVideoAdOpened", Toast.LENGTH_SHORT).show();
            }

            @Override
            public void onRewardedVideoStarted() {
                Toast.makeText(getApplicationContext(), "onRewardedVideoStarted", Toast.LENGTH_SHORT).show();
            }
        });
    }

    private void loadRewardedVideoAd() {
        synchronized (mLock) {
            if (!mIsRewardedVideoLoading) {
                mIsRewardedVideoLoading = true;
                Bundle bundle = new Bundle();
                bundle.putBoolean("mute_audio", true);

                AdRequest adRequest = new AdRequest.Builder()
                        .addNetworkExtrasBundle(AdMobAdapter.class, bundle)
                        .addTestDevice("B22EE2C3BCD6A40014AA4B8088125AC0")
                        .build();
//                AdRequest adRequest = new AdRequest.Builder()
//                        .addTestDevice("B22EE2C3BCD6A40014AA4B8088125AC0")
//                        .build();
                mRewardedVideoAd.loadAd(DataUtils.ADMOB_VIDEO_UNIT_ID_FILTER, adRequest);
            }
        }
    }



Joshua Lagonera (Mobile Ads SDK Team)

unread,
Aug 30, 2016, 6:58:26 AM8/30/16
to Google Mobile Ads SDK Developers
Hi Albert,

I noticed you are adding an extra "mute_audio" parameter to your ad request. Can you try removing it as it may be interfering with the Ad Request, which may be the reason why you are not receiving any ads?  
If the above does not help, can you verify that you can receive ads using your Ad Unit ID on our sample apps?

Regards,
Joshua Lagonera
Mobile Ads SDK Team
Message has been deleted

albert

unread,
Aug 30, 2016, 9:17:49 AM8/30/16
to Google Mobile Ads SDK Developers
Thanks for your reply
             I try removing it,but still can not load Rewarded Ads,I  tried add addTestDevice("B22EE2C3BCD6A40014AA4B8088125AC0") and remove it,still can not load Rewarded Ads.

  private void loadRewardedVideoAd() {
       synchronized (mLock) {
           if (!mIsRewardedVideoLoading) {
               mIsRewardedVideoLoading = true;
               Bundle bundle = new Bundle();
               bundle.putBoolean("mute_audio", true);

               AdRequest adRequest = new AdRequest.Builder()

                     
.addTestDevice("B22EE2C3BCD6A40014AA4B8088125AC0")
                      .build();
               mRewardedVideoAd.loadAd(DataUtils.ADMOB_VIDEO_UNIT_ID_FILTER, adRequest);
           }
       }
   }


Veer Arjun Busani(Mobile Ads SDK Team)

unread,
Aug 30, 2016, 11:47:45 AM8/30/16
to Google Mobile Ads SDK Developers
Hi Albert,

Currently Reward Video ads are only served through Mediation networks, which means that there are no test ads from the AdMob network that you can use. Remove the .addTestDevice() part from your AdRequest and try again. Also, do not try to synchronize the AdRequest. Remove this bit as well. Look at the implementation in our sample apps and make sure that you follow that.

Thanks,
Arjun Busani
Mobile Ads SDK Team
Reply all
Reply to author
Forward
0 new messages