ANEAdMob is a native extension for Android to show ads. Among the supported functionality are the ability to show ad, cache interstitial ad, show interstitial ad, hide ad and listen to tap, close, leave, etc. events. When showing an ad, it’s possible to choose its size and location on the screen.

The position of an ad can be customized based on pre-defined constants. A developer can control the vertical and horizontal position of an ad, for instance centralizing it horizontally and pushing it to the bottom of the screen vertically.

Sample

_admob = new AdMob();
_admob.addEventListener(AdEvent.INIT_OK, onEvent);
_admob.addEventListener(AdEvent.INIT_FAIL, onEvent);
_admob.addEventListener(AdEvent.AD_SHOW_OK, onEvent);
_admob.addEventListener(AdEvent.AD_SHOW_FAIL, onEvent);
_admob.addEventListener(AdEvent.PRESENT_SCREEN, onEvent);
_admob.addEventListener(AdEvent.DISMISS_SCREEN, onEvent);
_admob.addEventListener(AdEvent.LEAVE_APPLICATION, onEvent);
_admob.addEventListener(AdEvent.INTERSTITIAL_CACHE_OK, onEvent);
_admob.addEventListener(AdEvent.INTERSTITIAL_CACHE_OK, onEvent);
_admob.addEventListener(AdEvent.INTERSTITIAL_CLOSED, onEvent);
_admob.init("YOUR_PUBLISHER_ID");

protected function onEvent(ae:AdEvent):void {
    trace(ae.type+" "+ae._data);
}

//showing 468x60 ad at the bottom center side of the screen
_admob.show(AdParams.SIZE_IAB_BANNER, AdParams.HALIGN_CENTER, AdParams.VALIGN_BOTTOM);

//caching and showing interstitial ad
_admob.cacheInterstitial();
...
_admob.showInterstitial();
Air Native Extension, Android . URL.