Neo Neo - 2 months ago 9
Android Question

Is there any AdMob dummy id?

Is there any AdMob dummy ids for testing purpose?
Do I need to register app & get MY_AD_UNIT_ID?

Answer

There is are dummy id's per se. You need to setup the XML or the JAVA code to get test ads. To get Test Ads during testing, add the following to your XML where you have the AdView declared.

NOTE: I use just the XML code to display Ads in my app.

<LinearLayout
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:gravity="bottom|center"
    android:orientation="horizontal" >

    <com.google.ads.AdView
        android:id="@+id/adView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        ads:adSize="BANNER"
        ads:adUnitId="YOUR_AD_UNIT_ID"
        ads:loadAdOnCreate="true"
        ads:testDevices="TEST_EMULATOR, YOUR_DEVICE_ID" >
    </com.google.ads.AdView>
</LinearLayout>

To set the Test Unit (Both the emulator and your devices) from JAVA:

AdRequest adRequest = new AdRequest();
adRequest.addTestDevice(AdRequest.TEST_EMULATOR);            
adRequest.addTestDevice("test");

To get your Device ID, you can use this:

final TelephonyManager tm = (TelephonyManager)getBaseContext().getSystemService(Context.TELEPHONY_SERVICE);
String deviceid = tm.getDeviceId();

From: http://stackoverflow.com/a/9681517/450534

EDIT: Missed your second question.

Yes. You will need to register your app in your Ad-Mob account. Without that being registered, you won't be getting your Ad Unit ID and therefore, no Ads in your app either.