Serial Number

by New Developer » Wed, 11 May 2011 09:19:59 GMT


Sponsored Links
 When I start or connect my Xoom  I get  in Console

[2011-05-10 21:15:29 - eeds] Automatic Target Mode: Unable to detect device 
compatibility. Please select a target device.
[2011-05-10 21:16:20 - eeds] Uploading new.apk onto device '0288...b397'
[2011-05-10 21:16:22 - eeds] Installing new.apk...

I assumed 0288...b397  is the serial number yet when I execute

SERIAL_NUMBER  = Secure.getString(getBaseContext().getContentResolver() ,  
Secure.ANDROID_ID);
Log.i("Activity" , "Serial Number     =   '" + SERIAL_NUMBER               + "' 
 ");            
I get the following in LogCat

05-10 21:16:26.400: INFO/Activity(1354): Serial Number     =   '7299...b099'  

Not the same Number.
So which is the correct serial Number and how do I find the serial number on 
the Xoom itself ??

Thanks in advance

-- 



Other Threads

1. Side effect of normal activity stack behaviour causes bug when used with Intent.FLAG_ACTIVITY_REORDER_TO_FRONT

This took me awhile to understand and I will report it as a bug if I'm
not corrected.

You only need a basic new project (sdk 1.5r3) with two activty
classes. A root/launcher activity with a button to start a second
activity (of a different class). Everything else on default. Use the
following line to start the second activity:

this.startActivity(new Intent(this, SecondActivity.class).setFlags
(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT));

That's it for setup.

Now launch the app on to a device or emulator, launch from any state,
fresh boot, Run command, it's irrelevant. Follow these steps:

1. Press button to start second activity.
2. Press the physical Back key.
3. Press button to start second activity.
4. ActivityManager will print: Starting activity: Intent
{ flags=0x20000 comp={yourproject/yourproject.SecondActivity} }
5. Second activity will NOT display.

I did a lot of debugging and I think I've found the reason, though I
do not know the underlying cause, this would be something deeper in
the OS.

Between step 2 & 3, the normal behaviour seems to that the
SecondActivity only reaches the onPause() method, even though
isFinishing() returns true. Now if you do not have the reorder flag,
what normally happens is a new instance of the activity is created and
the old continues destroying from onPause(). But if you do, the old
activity is still at onPause() and it also has isFinishing() true, so
it is not brought back forward as I assume it is marked dead but also,
a new instance is not created (which I believe is a bug/mistake).

It will be forever stuck in this state UNTIL you make any other action
on the activity stack (press back again, launch a 3rd activity if you
set it up etc), then it will get the message to continue with the
destroy cycle. But this is not really a viable solution, it's a hack
and not always an option, also to a user, the app just looks broken.
It's also possible to continually get back in this state, requiring
the hack each and every time.

I'm not really sure why the SecondActivity is not fully destroyed when
the Back key is pressed? What is the purpose of holding it at onPause
()? If there is some purpose, can we also have a flag that overrides
that decision and always *instantly* performs the destroy cycle on
Back key.



--~--~---------~--~----~------------~-------~--~----~

2. Can i display Gif animation on home screen?

HI

Is it possible to display the Gif animation on the home screen or any
screen where we presently opened.....

how can i show the Gif animation image playing in the Home scree.....

plz any body suggest me how to show the gif image on the screen
instead out our layout....

thanks a lot in advance......
--~--~---------~--~----~------------~-------~--~----~

3. access to guser credentials

4. About SurfaceView

5. return result of activity

6. Automatic permanently display the virtual keyboard

7. omap3 rev.c3 boot up problem(android)