Test Rom in emulator? - Android

Anyone able to describe in detail how I can test rom's I cook in an android emulator? I have the emulator working, but can't figure out how to throw a rom in there. I have windows 7 and an evo, btw....any help much appreciated!
Sent from my PC36100 using XDA App

adeyo said:
Anyone able to describe in detail how I can test rom's I cook in an android emulator? I have the emulator working, but can't figure out how to throw a rom in there. I have windows 7 and an evo, btw....any help much appreciated!
Sent from my PC36100 using XDA App
Click to expand...
Click to collapse
what I just did was backup the *.img files from /android-sdk-linux_86/platforms/android-8/images/
and copied the *.img files from /out/target/product/vogue/
then I ran AVD from eclipse and created a new virtual device for 'android2.2'
works great.

... genius. Thank you

thanks...one question remains
thanks for the tips!! ...ok, i still have one question. i don't have a vogue, i have an evo... our rom's (img's) appear to be different or in a different location. can i extract the necessary img's from a rom??

I would also like to know this except for an eris?

I am also trying to do this. I have tried to use mkfs.yaffs2 in ubuntu to turn the system folder in to system.img, then replace it with the one in the SDK folder but then the AVDs don't boot at all.

one5 said:
I am also trying to do this. I have tried to use mkfs.yaffs2 in ubuntu to turn the system folder in to system.img, then replace it with the one in the SDK folder but then the AVDs don't boot at all.
Click to expand...
Click to collapse
I learned you don't replace anything in the sdk folder, but look in the .android/ "evo".avd folder ("whatever the name is off the emulator you created").avd ...that is where you place the system.img file.
Sent from my PC36100 using XDA App

adeyo said:
Anyone able to describe in detail how I can test rom's I cook in an android emulator? I have the emulator working, but can't figure out how to throw a rom in there. I have windows 7 and an evo, btw....any help much appreciated!
Sent from my PC36100 using XDA App
Click to expand...
Click to collapse
The easiest way to test a rom in the emulator after you build it is to simply type "emulator" in your terminal window. I am assuming you have your paths set up correctly.

Related

[Q] Learning to Create ROMs: How Do I Port a ROM from One Device to Another?

So I'm trying my luck at ROM creation and am learning as much as I can. One thing I haven't been able to find through Googling etc is how to port a ROM from one device to another, or more specifically what folders/files need to be replaced in a ROM to make it work on another device?
Appreciate any guidance, thanks guys!
PS I'm using DsiXDa's Kitchen, but it "doesn't support any devices besides HTC devices" and I want to port a ROM to a Dell Streak from an HTC Nexus One. Is it even possible and what files can I manually replace to get it to run?
dcogen said:
So I'm trying my luck at ROM creation and am learning as much as I can. One thing I haven't been able to find through Googling etc is how to port a ROM from one device to another, or more specifically what folders/files need to be replaced in a ROM to make it work on another device?
Appreciate any guidance, thanks guys!
PS I'm using DsiXDa's Kitchen, but it "doesn't support any devices besides HTC devices" and I want to port a ROM to a Dell Streak from an HTC Nexus One. Is it even possible and what files can I manually replace to get it to run?
Click to expand...
Click to collapse
I'm looking at a Streak ROM right now, and it looks fairly standard for Android. I would search for 'vendor tree' and/or 'extract-files.sh' to get an idea about what files and settings you might need. That will get you started. You have to swap kernels, that's a given. You'll probably need a few additional things from a stock Streak ROM, like:
files in:
/system/usr/keychars
/system/usr/keylayout
/system/lib/hw
/system/lib/modules
/system/etc
some libs in /system/lib
Probably a few things from /system/bin and /system/xbin
Look at the *.rc files in both the N1 ROM and the stock Streak ROM. They will call binaries and make changes. It's all tied together and is quite complex for such a 'small' thing... Get ready to do some research and testing and don't expect it to just work right away. If it does, your lucky.
I use WinMerge to compare ROMs all of the time. It will give you clues as to what is needed for the ROM to work on your device. And logcat will also point you in the right direction on occasion
Thanks a bunch gnarlyc!
Least I have a starting point now, going to get to Googling and see what I can figure out. And WinMerge is an awesome tool, thanks for that. I'll post back here if anything. Thanks again!
Anyone else have some information to share as well that could help?
EDIT: How do I get WinMerge to work? I installed it and tried to compare the two .zip files and it just shows jibberish in each window?
dcogen said:
EDIT: How do I get WinMerge to work? I installed it and tried to compare the two .zip files and it just shows jibberish in each window?
Click to expand...
Click to collapse
Well, it shouldn't show gibberish. I have it up right now with two init.desirec.rc files from two different ROMs. It's not going to be able to compare .zips though. Only text files and folders. You'll have to unzip those.
There are other programs that do the same thing, like 'N-way folder compare' and 'Beyond Compare' and plain old 'diff' in Linux or cygwin. Find what works best for you.
gnarlyc said:
It's not going to be able to compare .zips though. Only text files and folders. You'll have to unzip those.
Click to expand...
Click to collapse
I actually found that they have a .zip plugin to allow you to compare .zips and I tried to install it but it just isn't working. When I try to unzip them and just select the unzipped folder it opens it in the selector window instead of just using the folder.
I'll keep messing with it, thanks again for the starting point at least

[HOW TO] CRT-Effect only

This is just the plain CRT effect. No custom roms, no pre-made files or anything. (You need root)
I've searched for this on XDA, Google, other forums etc. but I couldn't find it.
It always showed up ROMs including this feature, not the actual feature itself
DO A BACKUP BEFORE EDITING ANY FILES!
Also, you need root
1. Pull framework-res.apk from the /system/framework/ folder via ADB (Alternate way below*)
2. Decompile framework-res.apk with APKTool/APK Manager (Whatever you prefer..)
3. Navigate to /res/values/ and open the bools.xml file with Notepad++ (Notepad works too )
4. Search for "config_animateScreenLights" and change the "true" to "false".
5. Save, and compile the file. Open the fresh-compiled file and copy resources.arsc to the original apk. (Overwrite the existing one)
Click to expand...
Click to collapse
Transfer the framework-res.apk file back to your phone, and then switch it with the original one
You must reboot to make it work!
*If you don't know how to push/pull files via adb, you can use Root Explorer and copy it to the /sdcard/ folder, then transfer it to your PC.
If you switch it back with root explorer, programs will start to force close. Just reboot and you'll be fine
Click to expand...
Click to collapse
CWM Flashable template
Use the attachment below as a template for flashing with CWM.
Open the .zip file, and place your framework-res.apk in system/framework/
Then extract it to your phone and flash it
Click to expand...
Click to collapse
Thank you very much, Worked
tried it on KF2
Don't forget to share what you make mentioning what fw it is from
Sent from my GT-I9100 using XDA App
Rawat said:
Don't forget to share what you make mentioning what fw it is from
Sent from my GT-I9100 using XDA App
Click to expand...
Click to collapse
Doesn't matter, it's integrated in every Android 2.3 devices.
Sent from my GT-I9100 using XDA App
thanks for this, could you possibly make a similar "how to" for the overscroll glow effect?? Been searching everywhere and can't find a simple guide
viva.fidel said:
thanks for this, could you possibly make a similar "how to" for the overscroll glow effect?? Been searching everywhere and can't find a simple guide
Click to expand...
Click to collapse
I'll see what I can do
Edit: Looks like there's something wrong with my firmware.. I don't have a classes.dex files within framework.jar
And it's hell of a process to do it, so I might have to re-concider this :/
Edit 2: I dont have a deodexed rom, and when I try to deodex it, it fails
Is the Pixelbug still there?
Sent from my GT-I9100 using XDA App
i think metamorph app supports editing system files... can u make a compatible zip?
DooMLoRD said:
can u make a compatible zip?
Click to expand...
Click to collapse
Sorry, I'm waaaaay to lazy to create a zip compatible for every single firmware out there. I can't take a framework file from KE2 and think it works on a phone with KF3..
fuzzl said:
Is the Pixelbug still there?
Sent from my GT-I9100 using XDA App
Click to expand...
Click to collapse
Pixelbug?
No idea what that is, but I can't see any pixels being stuck or anything.
Thanks, but...
Would you like to explain step 5 a bit further? I'm a bit confused. I'm using apk manager and it asks me a bunch of things and you don't tell me where to overwrite the arsc-file, etc.
sackynuts said:
Thanks, but...
Would you like to explain step 5 a bit further? I'm a bit confused. I'm using apk manager and it asks me a bunch of things and you don't tell me where to overwrite the arsc-file, etc.
Click to expand...
Click to collapse
Ah, so sorry.
Open the original framework-res with WinRar. And do the same with the modified. In there you'll see the resources.arsc file
If you don't know how to use APK Manager, use google.
Not trying to be rude, I'm just in a little hurry
I'll ask a mod later if he can move on of my posts up, and then I can perhaps create a more user friendly guide
Sent from my GT-I9100 using XDA App
bruflot said:
I'll see what I can do
Edit: Looks like there's something wrong with my firmware.. I don't have a classes.dex files within framework.jar
And it's hell of a process to do it, so I might have to re-concider this :/
Click to expand...
Click to collapse
No worries, thanks for having a look though
Sent from my GT-I9100 using XDA App
viva.fidel said:
No worries, thanks for having a look though
Sent from my GT-I9100 using XDA App
Click to expand...
Click to collapse
Well, I can take a further look, but only if you upload your framework.jar file and then send it to me.
Sent from my GT-I9100 using XDA App
bruflot said:
Doesn't matter, it's integrated in every Android 2.3 devices.
Sent from my GT-I9100 using XDA App
Click to expand...
Click to collapse
I read your thread, and know what you posted.
What I'm saying is that if someone makes the anim for example KF3, it would only take a few seconds to upload so other people could use, while diy CRT anim takes at least 5 mins even if you know what you're doing.
bruflot said:
I have always liked the CRT effect, but it got kinda annoying to always have a custom ROM installed to have it (I prefer stock ROMs )
I've searched for this on XDA, Google, other forums etc. but I couldn't find it.
It always showed up ROMs including this feature, not the actual feature itself
DO A BACKUP BEFORE EDITING ANY FILES!
Transfer the framework-res.apk file back to your phone, and then switch it with the original one
You must reboot to make it work!
I don't know the adb commands for switching the system files, so if anyone could tell them to me?
Sent from my GT-I9100 using XDA App
Click to expand...
Click to collapse
So to send a file to system in adb I used
Code:
abd push (new apk with mods) /sdcard // used to temp move it
adb shell
su
mount -o remount,rw /system
mv /sdcard/framework-res.apk /system/framework/framework-res.apk
Is that what you were asking?
bruflot said:
Well, I can take a further look, but only if you upload your framework.jar file and then send it to me.
Sent from my GT-I9100 using XDA App
Click to expand...
Click to collapse
That I can do no problem, appreciate you willing to look into this, used to have CM7 on my old HTC Desire and missing the overscroll effect! The only how-to thread on this I could find was [MOD][PORT][04-16] Android 2.3 Overscroll Glow MOD for Galaxy S I9000 (Gingerbread) but it's only for specific SGS firmwares, might be of some help to you still
Hmm...I don't have a res/values folder (just res, there is no values). There is also no Books.xml anywhere in the apk. I'm on stock rooted KE7...Is the value somewhere else on my version? Am I doing something wrong?
TheSopranos16 said:
Hmm...I don't have a res/values folder (just res, there is no values). There is also no Books.xml anywhere in the apk. I'm on stock rooted KE7...Is the value somewhere else on my version? Am I doing something wrong?
Click to expand...
Click to collapse
And you decompiled it right? I know i you were to just open the apk it would have a res but not res/values.
I followed the instructions ... and used APK Manager, I complied, signed, and before i quit it asked me to delete a file...resources.arsc
do i have to do that?
also, i noticed the APK Manager made signed apk of less size as compared to original file
original apk file size = 8.05 mb
complied, signed apk = 5.16 mb
is that normal?
infra4800 said:
I followed the instructions ... and used APK Manager, I complied, signed, and before i quit it asked me to delete a file...resources.arsc
do i have to do that?
also, i noticed the APK Manager made signed apk of less size as compared to original file
original apk file size = 8.05 mb
complied, signed apk = 5.16 mb
is that normal?
Click to expand...
Click to collapse
yeh same thing happend to mine, works fine though also use LCD Density to change the DPI to 240 to get rid of the pixelated crt animation

[Q] Copy all files from Android device?

What I'd like to do is to pull off all the files (keeping the structures intact) and either create an image file (.bin/.img) or something along those lines.
I know of DDMS and Android Commander, but I don't think they have the full power to get everything and I also understand the phone has to be rooted (which is not a big deal). Has anyone had any luck/expertise in this area?
If I can get this to work it then it would help out with some of the research that I am doing since it'll be easier to mount the image file in linux and go from there.
Alternate idea, does anyone know if when making a backup of the rom with CWM or BM does it hold the same type of data? If so where is the boot.img located?
Thanks for the help in advance!
I think there're a couple of threads in the development section regarding the images dumped from this phone.
sspa said:
I think there're a couple of threads in the development section regarding the images dumped from this phone.
Click to expand...
Click to collapse
Thanks I'll keep digging around to see what I can find.
Climber Ty said:
What I'd like to do is to pull off all the files (keeping the structures intact) and either create an image file (.bin/.img) or something along those lines.
I know of DDMS and Android Commander, but I don't think they have the full power to get everything and I also understand the phone has to be rooted (which is not a big deal). Has anyone had any luck/expertise in this area?
If I can get this to work it then it would help out with some of the research that I am doing since it'll be easier to mount the image file in linux and go from there.
Alternate idea, does anyone know if when making a backup of the rom with CWM or BM does it hold the same type of data? If so where is the boot.img located?
Thanks for the help in advance!
Click to expand...
Click to collapse
You can use an app called App2card at below for your need. It has the data tools for backing up any file/folder on any kind of storage (internal flash, fat32, ext2/3/4...) and ability to restore them in original structure as they were when backing up
http://205.196.123.32/fgqe9rc69leg/iln88jii0g81e05/App2Card_2.9.85_30Oct2011.apk
Sent from my MB860 using xda premium
Look for samcripps fruit cake maker it takes your /system folder and creates an. Img out of it.
Sounds like exactly what your after. Thank samcripp if it works for you too.
Sent from my MB860 using XDA App
I use android commander to pull system folder from phone.
Sent from my MB860 using XDA Premium App
stevendeb25 said:
I use android commander to pull system folder from phone.
Sent from my MB860 using XDA Premium App
Click to expand...
Click to collapse
Thanks, I tried that last night but the init.rc and other imortant files cannot be copied due to permissions access.
I eventually used CWM to make a backup of the phone and pulled the files that way. I just wonder if it has all the files on the phone (haven't had time to root through it yet)?
Climber Ty said:
Thanks, I tried that last night but the init.rc and other imortant files cannot be copied due to permissions access.
I eventually used CWM to make a backup of the phone and pulled the files that way. I just wonder if it has all the files on the phone (haven't had time to root through it yet)?
Click to expand...
Click to collapse
I think you can post your question in RomRacer's recovery thread; it's in dev section

[Q] Zip to APK issue

I just download MMOJ game, and wanted to make some changes for fun. I changed file extension from .APK to .Zip, unzip the file, modfied a .lua file, zip the files, and changed the extension back to .apk. Then, I tried to install the game, and then I receive "Parsing Error". What did I do wrong? As you can tell, I don't have a good programming skill, so when providing answers, please be as detail as possible, so any new comers can understand the explanation and solutions.
Thank you.
You need to find a program to properly de/recompile for you, search out apktool as one of many options, there will surely be instructions as well in you searches
Sent from my Nexus 4 using Tapatalk 2
demkantor said:
You need to find a program to properly de/recompile for you, search out apktool as one of many options, there will surely be instructions as well in you searches
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
Thanks for the reply. Because many people said that I can change .apk to zip and back to .apk, I thought de/recompile program was unnecessary. I will try a program. Any recommendation? Preferably free?
Depending on what you do yes you can unzip do somethings then rezip, but for most changes it needs to be decompiled, I usually use apktool, initially made by brut.all but has been updated by others, right now I believe version 3 is the latest
Sent from my Nexus 4 using Tapatalk 2
demkantor said:
Depending on what you do yes you can unzip do somethings then rezip, but for most changes it needs to be decompiled, I usually use apktool, initially made by brut.all but has been updated by others, right now I believe version 3 is the latest
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
I tried apktool, but after extracting the folder AndroidApktool in C:\ and put the .apk file I want to modify along with framework-res.apk, AndroidApktool.exe does not start. It gives an error. Is my PC language setting as Korean a problem, do you think?
Once changed from a zip to an apk after being modified.the apk usually needs to be resigned before attempting to reinstall again.
Sent from my SGH-T889 using Tapatalk 4
Um, did you open cmd/terminal and tell it to decompile?
apktool d xxx.apk
Or what do you mean by it doesn't start?
Sent from my Nexus 4 using Tapatalk 2
hasbrobot said:
Once changed from a zip to an apk after being modified.the apk usually needs to be resigned before attempting to reinstall again.
Sent from my SGH-T889 using Tapatalk 4
Click to expand...
Click to collapse
Does that mean if I can get a program that re-signs the .apk, I can install the modified .apk?
demkantor said:
Um, did you open cmd/terminal and tell it to decompile?
apktool d xxx.apk
Or what do you mean by it doesn't start?
Sent from my Nexus 4 using Tapatalk 2
Click to expand...
Click to collapse
No, I did not use the command line apktool d xxx.apk. I may have to read how-to.txt to understand how to execute the file. Because apktool was an executable file, I thought double clicking would start the program with graphical user interface waiting for further input from the user.
u can unzip apk to .zip, but not rebuild file .zip to apk if you're not use tool. It'll not compiler.

De Bloating

OK so I have taken the leap with this phone. For the first time I have installed a custom ROM, I have the rooted, Deoxed and xposed version from Paul. I managed to get a reboot loop when playing with xposed but fixed it but it has made me a bit wary.
I want to get rid of a few stock apps like the file manager (I like ES file explorer), music player (both Google and the stock player), backup, and a few others.
Research has led me to believe I can use ES to delete the .APK's but this is getting outside my comfort zone a bit and I don't want to delete anything that I actually need. Do other APPs rely on the honor file manager for example?
Advice and pointers too real idiot noob guides would be handy.
Thanks
SaulBee said:
I want to get rid of a few stock apps.....................
Click to expand...
Click to collapse
@SaulBee ... Go to the topic "honor 5X ROMS, Kernels, Recoveries & Other Development". Then scroll down to the thread "(SCRIPT)(TWRP) Stock ROM Debloat for KIW L24, L22, L21 (kiwi)" by @deadman96385 ..... There you will find all the information you need.
Cheers, I will take a closer look. I wasn't sure about just running the script as there was stuff in that I wanted to keep. I'll admit I didn't read the whole thread, so will do that now.
Ok read the thread, unpacked the zip, edited the file to leave a few things and rezipped. Backed up then ran the script all in twrp and it didn't work. Can't remember what the error message was. If android is based on linux and I now have busybox installed can I uninstall stuff in a terminal emulator using the commands in that script one at a time?
Sent from my KIW-L21 using Tapatalk
Just use titanium backup or system app uninstaller from play store to delete system apps you dont want...
Sent from my KIW-L21 using Tapatalk
Faheemarif252 said:
Just use titanium backup or system app uninstaller from play store to delete system apps you dont want...
Sent from my KIW-L21 using Tapatalk
Click to expand...
Click to collapse
Cheers will give that a go.
Sent from my KIW-L21 using Tapatalk
SaulBee said:
.....unpacked the zip, edited the file to leave a few things and rezipped......
Click to expand...
Click to collapse
@SaulBee ....You obviously know what you are doing ....... so yes I would download a Terminal Emulator from the store and try that. I would also re-check the Meta-Inf file before you re-zipped just in case you missed something.
SaulBee said:
Cheers will give that a go.
Sent from my KIW-L21 using Tapatalk
Click to expand...
Click to collapse
metpolds said:
@SaulBee ....You obviously know what you are doing ....... so yes I would download a Terminal Emulator from the store and try that. I would also re-check the Meta-Inf file before you re-zipped just in case you missed something.
Click to expand...
Click to collapse
you also have to be sure you use the correct text editor like notepad ++ as windows notepad will screw it up
clsA said:
you also have to be sure you use the correct text editor like notepad ++ as windows notepad will screw it up
Click to expand...
Click to collapse
Cheers I am linux boy really so use a gedit variant. I had a go with titanium backup and got rid of a few things. What I may have a go at is stripping the file down to take out all the nfc files as a little experiment.
Sent from my KIW-L21 using Tapatalk

Categories

Resources