Guys, help ... I have been fighting this problem for 2 weeks already. on emulators of different versions of the bucket and different resolutions of the screen, the test banner is shown as it should, but it is worth pouring the apk-shku on a real device, as it does not want to show any banner. Letters from admob did not come, they could not ban akk. such a logkat falls in the emulator:

05-03 08:07:44.032 798-798/ru.xxx.xxx I/Ads: Starting ad request. 05-03 08:07:45.572 798-798/ru.xxx.xxx W/Ads: Loading already in progress, saving this object for future refreshes. 05-03 08:07:58.812 798-798/ru.xxx.xxx I/Ads: Scheduling ad refresh 60000 milliseconds from now. 05-03 08:07:58.922 798-798/ru.xxx.xxx I/Ads: Ad finished loading. 

but such a real device

 05-03 13:17:23.388 28142-28142/ru.xxx.xxx I/Ads: Starting ad request. 05-03 13:17:23.983 28142-28142/ru.xxx.xxx W/Ads: Loading already in progress, saving this object for future refreshes. 05-03 13:17:34.748 28142-28247/ru.xxx.xxx W/Ads: There was a problem getting an ad response. ErrorCode: 0 05-03 13:17:34.749 28142-28142/ru.xxx.xxx W/Ads: Failed to load ad: 0 

I tried different connections to the Internet - Wi-Fi, 3G, but the outcome is the same. I repeat once again that I go quietly on the account of admob, there were no letters from them, I tried to create other banners.

activity code

 public class AndroidLauncher extends AndroidApplication implements AdsController { private static final String BANNER_AD_UNIT_ID = "xxx"; AdView bannerAd; InterstitialAd interstitialAd; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); // Create a gameView and a bannerAd AdView View gameView = initializeForView(new RunawayCat(this), config); setupAds(); // Define the layout RelativeLayout layout = new RelativeLayout(this); layout.addView(gameView, ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT); RelativeLayout.LayoutParams params = new RelativeLayout.LayoutParams( ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT); params.addRule(RelativeLayout.ALIGN_PARENT_TOP); params.addRule(RelativeLayout.ALIGN_PARENT_LEFT); layout.addView(bannerAd, params); setContentView(layout); } public void setupAds() { bannerAd = new AdView(this); bannerAd.setVisibility(View.INVISIBLE); bannerAd.setAdUnitId(BANNER_AD_UNIT_ID); bannerAd.setAdSize(AdSize.SMART_BANNER); AdRequest.Builder builder = new AdRequest.Builder(); AdRequest ad = builder.build(); builder.addTestDevice("xxxx"); bannerAd.loadAd(ad); } @Override public void showBannerAd() { runOnUiThread(new Runnable() { @Override public void run() { bannerAd.setVisibility(View.VISIBLE); AdRequest.Builder builder = new AdRequest.Builder(); AdRequest ad = builder.build(); bannerAd.loadAd(ad); } }); } 

}

  • one
    Create another Ads Unit Id and try with it. Check the manifest, check the services, check the correctness of the Ads Unit Id - VAndrJ
  • Well, I wrote that I had already created several banners with different IDs, this does not help ... even the package was renamed for everyone - baralgin1003
  • Have you tried other devices? - VAndrJ
  • one
    Add the activation code and the layout, maybe an error. Plus, the question is, did they just test it on their device or on others too? - qwerty123
  • The code added, I have 3 devices, I tested it for everyone. And not only under your Google account. Can there be such an option that advertising will be shown only after publication in the market? Should there be any advertising at all during debugging? I tried to add devices through addTestDevice (), but also in vain. - baralgin1003

0