Jump to content


Photo

[Testing] Getting an emulator up and running a full ROM with the Market etc.

- - - - -

  • Please log in to reply
39 replies to this topic

#1
PaulOBrien

PaulOBrien

    It's My Party

  • Founder
  • PipPipPipPipPipPip
  • 36,349 posts
  • Gender:Male
  • Location:Norwich, UK
  • Devices:All the Nexus!
  • Twitter:@paulobrien
Posted Image
I am currently using the Android emulator on my machine with a copy of the excellent Cyanogen 3.6.5 ROM I am running on my device.

If you'd like to do the same, here's how (it's a great way to play with things like the Android Market that aren't in the real emulator!)

Windows PC

1. Download the Android SDK (which includes the emulator) from here.
2. Extract the downloaded zip.
3. Run a command prompt, and change to the 'tools' directory of the SDK (or add the tools directory to your path).
4. Type 'android list target'
5. Note the 'id' number of the '1.5' target (in my case it's '2')
6. Type 'android create avd -n enhanced -t 2' (substitute 2 with the target number determined above if required)
7. You will be prompted to create a hardware profile. This is optional, but I selected 'yes' and accepted the defaults for everything except RAM, where I gave it 256MB. ;)
8. Download and unzip this image file.
9. Copy the above file to the location of the enhanced.avd directory ('C:\Documents and Settings\<user>\.android\enhanced.avd' on Windows XP, and 'C:\Users\<user>\.android\enhanced.avd' on Windows Vista).
10. You're ready! Type 'emulator -avd enhanced' to run! Note: inital boot may take a few minutes!

If you get Java errors, you need to download the JDK for your system from here!

Mac OSX

1. Download the Android SDK (which includes the emulator) from here.
2. Extract the downloaded zip.
3. Run Terminal, and change to the 'tools' directory of the SDK (or add the tools directory to the path settings in ~/.profile).
4. Type './android list target'
5. Note the 'id' number of the '1.5' target (in my case it's '2')
6. Type './android create avd -n enhanced -t 2' (substitute 2 with the target number determined above if required)
7. You will be prompted to create a hardware profile. This is optional, but I selected 'yes' and accepted the defaults for everything except RAM, where I gave it 256MB. :D
8. Download and unzip this image file.
9. Copy the above file to ~/.android/avd/enhanced.avd/system.img (e.g. if you saved it to and unzipped it to downloads enter 'cp ~/Downloads/system.img ~/.android/avd/enhanced.avd/system.img')
10. You're ready! Type './emulator -avd enhanced' to run! Note: inital boot may take a few minutes!

If you get Java errors, you need to download the JDK for your system from here!

:)

P

  • 0

You can follow me on Twitter - http://twitter.com/paulobrien / Follow MoDaCo on Twitter - http://twitter.com/modaco

Want to donate? MoDaCo is raising money for the Multiple Sclerosis society.

Posted Image


#2
zombiefly

zombiefly

    Enthusiast

  • Members
  • PipPipPip
  • 160 posts
hi,
followed the instructions, had problems with java so installed from the link provided, however i'm still getting this:

D:\android-sdk-windows-1.5_r2\tools>android list target
Exception in thread "main" java.lang.UnsupportedClassVersionError: com/android/s
dkmanager/Main (Unsupported major.minor version 49.0)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)

Tools dir is added to system path variable. I'm using windows xp.

Thanks

ZF

Edited by zombiefly, 08 July 2009 - 02:57 PM.

  • 0
---------------------------------------------------------------------
HTC One X
Android ICS
---------------------------------------------------------------------

#3
Russ-ST24

Russ-ST24

    Newbie

  • Members
  • Pip
  • 42 posts
  • Devices:Samsung Galaxy S
Hi Paul,
Thank you for putting together this quick tutorial.
I am very tempted by an Android device as I have various WinMo devices with custom ROMs and an iPhone 3Gs but am never satified.
Did you by chance know how I can run a HERO ROM in the emulator? I am very interested in the Hero and would like to play in the emulator.
I can find the ROM just need to know if I need any special settings to get it to work.

Many thanks

Russ

  • 0
Samsung Galaxy S
Motorola Milestone
HTC Hero (White)
SE Xperia X1 (Jacks V3.x)

#4
PaulOBrien

PaulOBrien

    It's My Party

  • Founder
  • PipPipPipPipPipPip
  • 36,349 posts
  • Gender:Male
  • Location:Norwich, UK
  • Devices:All the Nexus!
  • Twitter:@paulobrien
I haven't managed to get a Hero ROM running, and I don't actually think it's possible because of the Kernel in use (but I could be wrong)...

P

  • 0

You can follow me on Twitter - http://twitter.com/paulobrien / Follow MoDaCo on Twitter - http://twitter.com/modaco

Want to donate? MoDaCo is raising money for the Multiple Sclerosis society.

Posted Image


#5
PaulOBrien

PaulOBrien

    It's My Party

  • Founder
  • PipPipPipPipPipPip
  • 36,349 posts
  • Gender:Male
  • Location:Norwich, UK
  • Devices:All the Nexus!
  • Twitter:@paulobrien
Zombiefly, did you install the JDK from above, not just the JRE?

P

  • 0

You can follow me on Twitter - http://twitter.com/paulobrien / Follow MoDaCo on Twitter - http://twitter.com/modaco

Want to donate? MoDaCo is raising money for the Multiple Sclerosis society.

Posted Image


#6
zombiefly

zombiefly

    Enthusiast

  • Members
  • PipPipPip
  • 160 posts

Zombiefly, did you install the JDK from above, not just the JRE?

P


I installed the file that I downloaded from the link... which was : jdk-6u14-windows-i586.exe
Do i need to update the JRE too? i'll give that a go now...

edit: nope, that made no difference. Will try this on my home pc this evening ;)

Edited by zombiefly, 08 July 2009 - 03:31 PM.

  • 0
---------------------------------------------------------------------
HTC One X
Android ICS
---------------------------------------------------------------------

#7
PaulOBrien

PaulOBrien

    It's My Party

  • Founder
  • PipPipPipPipPipPip
  • 36,349 posts
  • Gender:Male
  • Location:Norwich, UK
  • Devices:All the Nexus!
  • Twitter:@paulobrien
No, you should be sorted I would have thought - odd!

P

  • 0

You can follow me on Twitter - http://twitter.com/paulobrien / Follow MoDaCo on Twitter - http://twitter.com/modaco

Want to donate? MoDaCo is raising money for the Multiple Sclerosis society.

Posted Image


#8
Russ-ST24

Russ-ST24

    Newbie

  • Members
  • Pip
  • 42 posts
  • Devices:Samsung Galaxy S

I haven't managed to get a Hero ROM running, and I don't actually think it's possible because of the Kernel in use (but I could be wrong)...

P


Thats a shame, I will play this rom in the emulator.
Having trouble finding the Calendar on this ROM? I am being thick?

Thanks

Russ

  • 0
Samsung Galaxy S
Motorola Milestone
HTC Hero (White)
SE Xperia X1 (Jacks V3.x)

#9
PaulOBrien

PaulOBrien

    It's My Party

  • Founder
  • PipPipPipPipPipPip
  • 36,349 posts
  • Gender:Male
  • Location:Norwich, UK
  • Devices:All the Nexus!
  • Twitter:@paulobrien
You're right! Where the hell has the Calendar gone!

;)

Investigating!

P

  • 0

You can follow me on Twitter - http://twitter.com/paulobrien / Follow MoDaCo on Twitter - http://twitter.com/modaco

Want to donate? MoDaCo is raising money for the Multiple Sclerosis society.

Posted Image


#10
Russ-ST24

Russ-ST24

    Newbie

  • Members
  • Pip
  • 42 posts
  • Devices:Samsung Galaxy S

You're right! Where the hell has the Calendar gone!

;)

Investigating!

P


Web browsers seems to have done a runner too!
When I use the google search bar it just crashes with acore.

Russ

  • 0
Samsung Galaxy S
Motorola Milestone
HTC Hero (White)
SE Xperia X1 (Jacks V3.x)

#11
PaulOBrien

PaulOBrien

    It's My Party

  • Founder
  • PipPipPipPipPipPip
  • 36,349 posts
  • Gender:Male
  • Location:Norwich, UK
  • Devices:All the Nexus!
  • Twitter:@paulobrien
Oops, needs some work methinks! ;)

P

  • 0

You can follow me on Twitter - http://twitter.com/paulobrien / Follow MoDaCo on Twitter - http://twitter.com/modaco

Want to donate? MoDaCo is raising money for the Multiple Sclerosis society.

Posted Image


#12
Blinkerz

Blinkerz

    Newbie

  • Members
  • Pip
  • 17 posts
  • Location:Seattle
  • Devices:HTC Himalaya, Acer Liquid
I think you can try out several Hero roms that has been "Cyanogenized" (they have the Cyanogen Kernel)

  • 0

#13
l3v5y

l3v5y

    Diehard

  • MoDaCo Gold
  • PipPipPipPip
  • 312 posts
  • Gender:Male
  • Location:Bristol!
  • Devices:HTC Prophet, Diamond, HD2
  • Twitter:@l3v5y

Oops, needs some work methinks! ;)

P


Is it due to the Apps2SD thing used in quite a lot of android ROMs?

  • 0

Posted Image
HTC Prophet - WM6.5.1 23081
HTC Touch Diamond - WM6.5.3 Light (28014)
HTC Leo - Getting repaired - WM6.5.3 (28014)

Cooking is easier with devices ;)

Twitter


#14
Russ-ST24

Russ-ST24

    Newbie

  • Members
  • Pip
  • 42 posts
  • Devices:Samsung Galaxy S
Ok, So have anyone got a fully working ROM for this emulator? I just want to test out IMAP Secure mail etc before I buy a Hero.

Thanks

Russ

  • 0
Samsung Galaxy S
Motorola Milestone
HTC Hero (White)
SE Xperia X1 (Jacks V3.x)

#15
Russ-ST24

Russ-ST24

    Newbie

  • Members
  • Pip
  • 42 posts
  • Devices:Samsung Galaxy S
Hi,
I am using this for some testing and I need to connect to an IMAP server on port 993 for SSL IMAP but with a self signed cert.
The OS is too protective and says security issue! and wont let me past.
Anyone know how to add your own trusted certs into android?
Also I guess as the brower is missing it wont download anything from the marketplace :-(

Thanks

Russ

Dont care about the emulator just want to know if its possible on the real deal.

  • 0
Samsung Galaxy S
Motorola Milestone
HTC Hero (White)
SE Xperia X1 (Jacks V3.x)

#16
baka_neko

baka_neko

    Newbie

  • Members
  • Pip
  • 1 posts
i tried this but i got stuck at boot loop. it brought me up to the page where it says click on android to continue setup of google account. i try to click on the android, nothing happens. the hardware buttons work but the touch screen does not. After 1min or so it reboots.

FYI it works perfectly without the cyanogen's image

  • 0

#17
zencloud

zencloud

    Newbie

  • Members
  • Pip
  • 4 posts
Paul,

Many thanks for this very usefull guide :-)

Is there a way to create an update-cm-3.9.1-signed.system.img.zip for current cyanogen version ?
http://forum.xda-dev...ad.php?t=539744

It would be great to find a way to test cyanogen versions on the emulator

Edited by zencloud, 28 July 2009 - 06:17 AM.

  • 0

#18
zencloud

zencloud

    Newbie

  • Members
  • Pip
  • 4 posts
Here you have 3.9.1 thanks to Bavilo:
http://sharebee.com/7b5ff589

it works fine in the emulator :-)

  • 0

#19
zencloud

zencloud

    Newbie

  • Members
  • Pip
  • 4 posts
JacxHero 1.1 working on the emulator:
http://www.4shared.c...4e6/system.html

big thanks to MikeIzFresh

Posted Image

Edited by zencloud, 08 August 2009 - 09:10 AM.

  • 0

#20
reesd

reesd

    Newbie

  • Members
  • Pip
  • 3 posts
  • Devices:ADP1, Fuze, Magic

Here you have 3.9.1 thanks to Bavilo:
http://sharebee.com/7b5ff589

it works fine in the emulator :-)


Can someone point me to the steps for how to create a system.img from a custom ROM like cyanogen? I've been surfing around and am obviously missing some key understanding about how the system.img relates to the updates.zip these guys are now distributing their ROMs as.

Thanks,
d

  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users