[INFO]What is EpicMTD, and what you need to know. - Epic 4G Android Development

Getting started
Before I get into the thick of this, I've been for a little over a week or maybe even more taking as much time as I can to explain to people what MTD is and the risks of it. And unfortunately most people just by natural human tendencies have an issue comprehending it which believe me is perfectly fine haha, it's a lot to take at once. So I'm going to layout the basic need to knows, and if any more information is needed feel free to pm me and I'll add it into this main post.
I'm going to try to make this as simplistic as I can.:x
What is a partition?
A partition is an area of allocated space, a division of the whole overall area of space. In this case our partitions on the Epic 4G are /System, /Data, as well as /Cache. All with set permanent sizes.
What is a partition map?
A partition map is the configuration of our partitions, it's what in a vagueness sets our required sizes for the divisions of our nand also known as flash memory. A partition or partition map should not be confused with a file system. An example would be BML and MTD.
What is a file system?
A file system resides on the partition map and governs the data being read/wrote/moved/etc by the Operating System, in this case Android. Changing a file system is less complex than an overall change in partition mapping. They again, are not the same thing.
What is MTD?
MTD is an Open Source Partition map. It allows those who are using it control over how their partitions are sized and how much space is allocated here and how much space is taken away from there. Currently on MTD we have 689 megabytes of space allocated to our /data partition allowing more to be downloaded from the market as an example. MTD as a partition config has YAFFS2 as a file system residing on it governing how data is transferred and the speed of which it is done. EXT2 through 4 aren't possible on the MTD platform, just as YAFFS2 may not be possible on the BML proprietary platform.
What is BML?
BML like MTD is a partition map, however it is proprietary in nature, Close Source if you will. The size for /System /Data /Cache is set and permanent and makes opening up space more of a task for Developers. Stock the Epic 4G comes on BML, and is running RFS as it's file system, once rooted you can leave RFS for EXT4 (Journaled or Un-Journaled) as long as the kernel you use allows for EXT4. But in the end, changing a file system on BML does not lessen or enhance the control you have over your partitions.
What do I need to know before flashing a rom with this?
Currently there are two distributions which have moved over to the MTD platform.
One of which and the first inital one being:
[ROM] Epicmtd CM7 SELFKANG (12/10) - 2.3.7
And the second which is a basis of the first:
[ACS] [MTD] [YAFFS2] MIUI 1.12.2 Beta 6 MTD (Updated 12/10/2011)
Within the flashable zips for these two roms there are scripts which completely format your device and move you to MTD. It is required to back up the things you wish to keep with Titanium backup if you have it. Nandroids from RFS/EXT4/BML do not work on MTD/YAFFS2. Alternatively if you have purchased appextractor or titanium back up pro licensing from the Android market you can make a nandroid before your move and then extract the data apps or system apps you want from that backup while on MTD/YAFFS2 without going into recovery.
When flashing one of these ROMS in CWM5 your phone shall reboot during the installation if it finds you're on BML, don't panic it is a natural process of this move.
When booting into recovery on MTD it reacts to how long you hold the 3 button combination. Being Volume down, Camera, and Power. Don't panic if it doesn't pop up, you must let go to let it know which path it goes to. If your phone looks like it's booting again don't do the combination. It's switching from the init to the recovery.
CWM 5 is not broken, on MTD our kernel now has a 2 stage init. And it's part of the process.
How do I go about flashing other roms if they're not MTD?
Flashing a Stock TouchWiz rom can be very problematic, mainly due to the nature of and differences between MTD and BML. Currently there isn't a stock MTD kernel. To return to BML, you have a choice of either using Heimdall or Odin. To do so you require the victory.pit as well as a stock tar of your choice which includes our bootloader so that when you repartition your device all goes well without problem. There is no method to return without using Odin/Heimdall because BML is a proprietary configuration. We lack the tools to replicate Samsung's methods and mannerisms.
What does it mean for me as an end user?
As an End User, MTD is an opening to a new life for the Epic 4G. Things like ICS, more space in data or system, are more within our reach and grasp due to the nature of Open Source MTD is immersed in. We're closer to the Captivate, Fascinate, Vibrant, and Galaxy S international by being on MTD, we've that new freedom they've had for a long time. Not to say things like ICS aren't possible on BML but with this we're at a better standing point.
Stock EI22 on MTD
noobnl as well as Tortel have worked together to put a stock EI22 rom for the MTD platform which can be found here.
[EI22] Stock-ish MTD Build
This is for a stock experience and for those want to use MTD as well as make use of the stock features our phone has, nothing out of the ordinary or custom, just as a basic point. Rom Developers can go on towards moving their roms over to this platform now with the use of the boot.img but for now kernel developers will still have an issue nonetheless.
Those responsible for this in no specific order: Decad3nce, noobnl, jt1134, mkasick, nullghost, nubecoder, DRockstar, UberPinguin, Rodderik, wtogami, as well as countless others.
All things within this thread are subject to change if a need for correction is to be met.

First. Good post. Sticky request.
Sent from my SPH-D700 using XDA App

Too bad this wasn't up before I flashed the MIUI update.... It looks like MTD=FML for me. I now have no choice on if i want 4g or not because the only 2 ROMs with MTD are CM7 and MIUI which dont support 4g. Grrrr. I hope someone can make something to get back to EXT4 or RFS W/O odin or heimdall. Last time I used odin to go to a stock ROM it ended up hard bricking my phone and i had to pay $600 for a new one.
I hope other users read this post before making the ssame mistake I did. Thank you AproSamurai.

No. Those are proprietary. You need to use Odin because it has the Samsung code that we don't have.
Edit: make sure you use a pit and make sure you check repartition and auto reboot. Nothing else.
Sent from my SPH-D700 using XDA App

roddygonzo17 said:
Too bad this wasn't up before I flashed the MIUI update.... It looks like MTD=FML for me. I now have no choice on if i want 4g or not because the only 2 ROMs with MTD are CM7 and MIUI which dont support 4g. Grrrr. I hope someone can make something to get back to EXT4 or RFS W/O odin or heimdall. Last time I used odin to go to a stock ROM it ended up hard bricking my phone and i had to pay $600 for a new one.
I hope other users read this post before making the ssame mistake I did. Thank you AproSamurai.
Click to expand...
Click to collapse
I apologize I couldn't have gotten it out sooner. Been a bit busy as of late, my apologies. Things are being worked on now regarding overlay and 911 by the CM team. And then CM will be official and we'll begin to see work on ICS and beyond, if that's of any consolation.:x

roddygonzo17 said:
Too bad this wasn't up before I flashed the MIUI update.... It looks like MTD=FML for me. I now have no choice on if i want 4g or not because the only 2 ROMs with MTD are CM7 and MIUI which dont support 4g. Grrrr. I hope someone can make something to get back to EXT4 or RFS W/O odin or heimdall. Last time I used odin to go to a stock ROM it ended up hard bricking my phone and i had to pay $600 for a new one.
I hope other users read this post before making the ssame mistake I did. Thank you AproSamurai.
Click to expand...
Click to collapse
You're gonna have to Odin, sorry. There's absolutely no way and there most likely will never be a way without it.
By the way, $600? I've bricked my phone a few times, and when I went to sprint I got a replacement for $35. Not sure what you did there.
Sent from my Samsung Epic using CM7!

Great post. This was very needed
Sent from my SPH-D700 using xda premium

Thanks for a quick reply marcusant. If its not too much of a hassle would you mind making a video and possibly post links for the .tar and .pit to use unless the .pit is the same as for froyo. I just really need my phone and dont want to have to buy another one.
---------- Post added at 07:31 PM ---------- Previous post was at 07:22 PM ----------
|| Acer || said:
You're gonna have to Odin, sorry. There's absolutely no way and there most likely will never be a way without it.
By the way, $600? I've bricked my phone a few times, and when I went to sprint I got a replacement for $35. Not sure what you did there.
Sent from my Samsung Epic using CM7!
Click to expand...
Click to collapse
The representative from sprint told me that the only way i would have been able to brick it like that (would not turn on, no recovery mode, and no download mode and when plugged the charger in it wouldnt charge or be recognized by the computer) is if i rooted it which voided my warranty and wouldnt be covered by insurance.

roddygonzo17 said:
The representative from sprint told me that the only way i would have been able to brick it like that (would not turn on, no recovery mode, and no download mode and when plugged the charger in it wouldnt charge or be recognized by the computer) is if i rooted it which voided my warranty and wouldnt be covered by insurance.
Click to expand...
Click to collapse
I would have fought that by playing stupid and asking what he was talking about. Sprint also came out last year stating rooting does not void warranty but did require being noted on your account IIRC. I can give at least 1 scenario where that could have happened without rooting ... go drop your phone in the bathtub.
Memory modules and other ICs can easily go bad as well so sprint employee was playing a jumping to conclusion game and a manager would have been called over quickly.

onilink67 said:
I would have fought that by playing stupid and asking what he was talking about. Sprint also came out last year stating rooting does not void warranty but did require being noted on your account IIRC. I can give at least 1 scenario where that could have happened without rooting ... go drop your phone in the bathtub.
Memory modules and other ICs can easily go bad as well so sprint employee was playing a jumping to conclusion game and a manager would have been called over quickly.
Click to expand...
Click to collapse
You know I wasn't really thinking of that at that point, i was just worried about getting my phone back but that would have been a great idea. That way the little stickers that turn red when they get wet would have changed colors since water damage is covered.

"Wouldn't naturally do this but needs to keep this relevant until it can be stickied."
BUMP

I need to make a tutorial to restore... I'm really busy right now but will try to put up a simple guide without pictures. When I have time I will do pictures or a video. *qbking77 may beat me.
Sent from my SPH-D700 using XDA App

Its old but still relevant.

roddygonzo17 said:
Thanks for a quick reply marcusant. If its not too much of a hassle would you mind making a video and possibly post links for the .tar and .pit to use unless the .pit is the same as for froyo. I just really need my phone and dont want to have to buy another one.
Click to expand...
Click to collapse
http://db.tt/Pf4qPUIV
This is the tar and pit file.

very usefull info, im allready on one before this was posted, but i knew most of what i needed, you should ask qbking to put his video in the op. it has alot of good info in it for those people who dont read anything.....

If I,
1.) make a nand backup in CWM5 of MTD CM7, would I be able to Odin back to stock, then restore the nand backup?
Or,
2.) would I have to reflash the ROM then advanced restore data?
Im leaning toward option 2 since CWM5 wont preserve the partition map, only the filesystem. I just want to be sure.
Thank you Apro
vvvvvvvvvvvvvvvvvv

theduce102 said:
If I,
1.) make a nand backup in CWM5 of MTD CM7, would I be able to Odin back to stock, then restore the nand backup?
Or,
2.) would I have to reflash the ROM then advanced restore data?
Im leaning toward option 2 since CWM5 wont preserve the partition map, only the filesystem. I just want to be sure.
Click to expand...
Click to collapse
2 would be the correct answer to your question.

I installed the miui and didn't realize that I would have oden back to stock but I just followed qbking's video and I after that I was able to restore my nandroid backup. I got freaked out because i couldnt restore my backup at 1st but in the end it was my fault for not reading before l did it.
Sent from my SPH-D700 using XDA App

Thanks for the info Apro. Knowing is half the battle.
Born from an Epic Rebirth.

|| Acer || said:
You're gonna have to Odin, sorry. There's absolutely no way and there most likely will never be a way without it.
By the way, $600? I've bricked my phone a few times, and when I went to sprint I got a replacement for $35. Not sure what you did there.
Sent from my Samsung Epic using CM7!
Click to expand...
Click to collapse
only $35? I haven't had to send my Epic in for replacement yet but every phone i've sent to Asurion in the past is always $100 per incident... are you on a different insurance plan or something?

Related

SK4G Development

Some of you may know me and some not. I was asked to help out on the SK4G development, so here I am.
I have some questions first.
1. You are using CWM?
2. Amend or Edify?
3. Do you have the drivers and adb set up yet?
Depending on the answers I can put out a couple of tests and then get to work on this.
I will need your newest deodexed framework-res.apk, twframework-res.apk, settings.apk, services.jar - and others as needed.
If you do not have a deodexed rom yet then I need a copy of your systemfs.rfs or a full odin to deodex it myself. I have the system dump, is this your newest rom? If so then I have already deodexed it - just let me know.
1. Yes, the epic 4g version which is buggy
2 don know
3.yes
Sent from my SGH-T839 using Tapatalk
1) No. It doesn't sound like the currently available CWM firmwares work well on the SK4G. I am waiting for one designed for this hardware. I have run CWM on other handsets, of course.
2) No. Had not heard of those until you'd mentioned them.
3) Yes. Working well. We're all set here, at least.
System dump: There only seems to be one ROM/firmware version for this phone so far. The one you have should be current. I pulled mine in this thread:
http://forum.xda-developers.com/showthread.php?t=1037403&page=5
Specifically here:
http://forum.xda-developers.com/showpost.php?p=13210149&postcount=59
I'm happy to help further. Please simply let me know what you need.
And thanks for taking this on! This could be a solid phone without some of the bloatware trash foisted on it.
1. They are using the one click root for the epic by noobnl which installs CWM 2.5.1.0
2. Amend though can't you just use update-binary and make it compatible with both
blu9987 said:
1. They are using the one click root for the epic by noobnl which installs CWM 2.5.1.0
2. Amend though can't you just use update-binary and make it compatible with both
Click to expand...
Click to collapse
Yes, but I am old school and still use amend most of the time and needed to make sure it was going to be compatible.
Once I see some feedback on the theme I posted I will move forward - I just need to know how it turns out so I will have a better understanding of the phones layout.
Might need to send Koush a message and see if we can get a proper recovery going.
I really would love it if this phone got some custom roms. I don't want to get rid of it. But I put a ad up on craigslist to trade for a mytouch 4g.
Sent from my SGH-T839 using XDA App
Also as far a getting a proper working recovery, i think we may need a recovery that supports the ext-SD card. our internal memory isnt used by us because its so small. its used for things like installing apps i believe. if you use a file manager you'll see the only available SD card is the external one and same when mounting the phone. i think the epic and vibrant recovery would work just fine except we'd need one that supports the external SD card.
there is a kernel called dead horse that i used on my vibrant that had this support for ext SD but i dont think theres a way to get just the recovery out of it. hopefully someone might know a way to direct CWM to our ext SD then we might be on to something ..
ayoteddy said:
Also as far a getting a proper working recovery, i think we may need a recovery that supports the ext-SD card. our internal memory isnt used by us because its so small. its used for things like installing apps i believe. if you use a file manager you'll see the only available SD card is the external one and same when mounting the phone. i think the epic and vibrant recovery would work just fine except we'd need one that supports the external SD card.
there is a kernel called dead horse that i used on my vibrant that had this support for ext SD but i dont think theres a way to get just the recovery out of it. hopefully someone might know a way to direct CWM to our ext SD then we might be on to something ..
Click to expand...
Click to collapse
Its just a driver issue. We need to know exactly which SD card reader is in the phone and see if we can contact the manufacturer for the source.
I do not know how to decompile things like drivers, but I would like to know so I could get the ball rolling on this.
I'd love to see development pickup on this phone.
I've had my G1 since Dec 08 and happily rooted and did whatever I wanted to do it with the huge support from the developer community that the G1 received.
I'm keeping myself stock until someone gets Clockwork working with nandroid and there's an unroot method.
d4n137_91 said:
I'd love to see development pickup on this phone.
I've had my G1 since Dec 08 and happily rooted and did whatever I wanted to do it with the huge support from the developer community that the G1 received.
I'm keeping myself stock until someone gets Clockwork working with nandroid and there's an unroot method.
Click to expand...
Click to collapse
I feel the exact same way. I just picked mine up today and I really want to dive into it.
Yeah man, id like to see some development for this phone. I'm willing to help with whatever. This forum seems very dead though. Let's hope it picks up.
Sent from my Sidekick 4G using XDA app
what is the sdcard mounted as? mmcblk0p1? mmcblk1p1? This is key to getting recovery set up.
Where do I find that? I just rooted the phone but I haven't flashed the buggy recovery image
Sent from my little sidekick
gearhead27 said:
Where do I find that? I just rooted the phone but I haven't flashed the buggy recovery image
Sent from my little sidekick
Click to expand...
Click to collapse
adb shell
cd sys
cd block
ls
pastebin that info
that should tell me what I need to know
ive got it. it's mmcblk0p1
Same as the Vibrant, but theirs is mounted to internal sd. I would just need to switch up some stuff.
1st and foremost.... I need your guy's initramfs from your kernel
Idk too much about the initramfs nor how to extract it.
If I'm right the zImage is the kernel maybe this could help you so I've uploaded it to dropbox aswell.
http://db.tt/hhJIGXn
If it needs to be done from our phone could you point us in the right direction on how to get the initramfs.
Sent from my SGH-T839 using XDA App
So exciting seeing the development picking up
so happy to have someone look in this 4rum......im willing to help,,,,,if you guys need someone to be a tester.....just let me know....
ayoteddy said:
Idk too much about the initramfs nor how to extract it.
If I'm right the zImage is the kernel maybe this could help you so I've uploaded it to dropbox aswell.
http://db.tt/hhJIGXn
If it needs to be done from our phone could you point us in the right direction on how to get the initramfs.
Sent from my SGH-T839 using XDA App
Click to expand...
Click to collapse
Thanks, I'll get you guys something to test with tomorrow night when I get to work.
krylon360 said:
Thanks, I'll get you guys something to test with tomorrow night when I get to work.
Click to expand...
Click to collapse
can't wait to test it.....thanks a lot

[Q] creating backups

just got my GS4g yesterday, and it's my 1st SP (yay), rooted it with SOC - and I'd like to make a full backup of it's 'out of box' condition ..so I found this Froyo CMW thread and would like to utilize it
http://forum.xda-developers.com/showthread.php?t=1099374
however, it assumes the reader has previous knowledge of wtf they're talkn about..
I read further in the post "I have sent this to Koush as well to have it added to Rom Manager" - so I ran over to market and DL'd Rom Manager, but now I can't find the file ..hell I even googled "I downloaded from android market, where's my file" and no useful results come up ffs xD - so then I find this thread (yay) - but I can't afford to buy an app, here an app, there an app, everywhere an app app - so are there any free root explorer type applications? -ALSO- how do we mount our device as R/W? ..as it seems every single tutorial I come across is ambiguous
anywayz, I'd be really grateful if someone could help me out here..
I'd like to make a full backup of my 'out of box' Froyo, update it to stock 236, make another backup, flash it to Valhalla black 236, make another backup, ect - thanks for the read
KotsChopShop said:
just got my GS4g yesterday, and it's my 1st SP (yay) - and I'd like to make a full backup of it's 'out of box' condition ..so I found this Froyo CMW thread and would like to utilize it
http://forum.xda-developers.com/showthread.php?t=1099374
however, it assumes the reader has previous knowledge of wtf they're talkn about..
I read further in the post "I have sent this to Koush as well to have it added to Rom Manager" - so I ran over to market and DL'd Rom Manager, but now I can't find the file ..hell I even googled "I downloaded from android market, where's my file" and no useful results come up ffs xD ..anywayz, I'd be really grateful if someone could help me out here - I'd like to make a full backup of my 'out of box' Froyo, update it to stock 236, make another backup, flash it to Valhalla black 236, make another backup, ect - thanks for the read
Click to expand...
Click to collapse
1. Never use Rom Manager! ever!
2. Root your phone and then make a nandroid backup through recovery then flash whatever you want and make another nandroid backup and so on. There are enough Roms here that you really do not need to worry about a stock back-up but, as always it is good to back up everything. Trust in the THE BIBLE as it is your friend.
thanks for actually reading my post :rollseyes: lol
1] ok.. but I DL'd it, where is it so I can delete it? lol
2] already did, and I already found the bible (thx tho)
the problem is these tutorials and guides are ambiguous, and all of them assume you have prior knowledge of what their talkn about.. pretty much , no, exactly like the last
few statements of your own post "then make a nandroid backup through recovery then flash whatever you want and make another nandroid backup and so on" = lolwut? :/
I can't make a backup because.. well, read my 1st post again lol
KotsChopShop said:
thanks for actually reading my post :rollseyes: lol
1] ok.. but I DL'd it, where is it so I can delete it? lol
2] already did, and I already found the bible (thx tho)
the problem is these tutorials and guides are ambiguous, and all of them assume you have prior knowledge of what their talkn about.. pretty much , no, exactly like the last
few statements of your own post "then make a nandroid backup through recovery then flash whatever you want and make another nandroid backup and so on" = lolwut? :/
I can't make a backup because.. well, read my 1st post again lol
Click to expand...
Click to collapse
1. setting/applications/ROM manager/ uninstall
The rest would take a full page post. If I were you I would just go straight to GingerBread and do not worry about trying anything with Froyo. For that go here GB starter pack and follow the well detailed directions and if still confused I will do a step by step for you for GB. The aforementioned guide tells you what to get and where to put it and what to press. The technical knowledge will come in time after dealing with Roms, kernals, flashing, etc. You don't really need to know anything other than what files to use, where to put said files, and what buttons to press and that will get you rooted and Rom'd. Before your rooted and Rom'd you should learn what does what and why and that will take a lot of reading and time but, if your impatient like a lot around here you can always learn after you've rooted and Rom'd your phone.
thanks for your replies swann, underneath my amagad, I do appreciate it lol
ok so.. I DL'd RM last night, but apparently it didn't install because it's nowhere to be found...
it's not in my apps, and idk where DL'd files are stored so I can delete it (it's not on my SD either)
anywayz, before I do anything else, I want to make a backup of my out of box Froyo
(and idgaf if anyone thinks I should skip this part, I still want to do it =)
and in order to do this, I went here --> http://forum.xda-developers.com/showthread.php?t=1099374
but since it doesn't fully explain the how to's, I went here --> http://forum.xda-developers.com/showthread.php?t=1122508
but then I don't have root explorer, and can't afford to pay for a bunch of different apps, therefore, I need to know of a trusted/stable/free alternative - and I also don't know how to "mount my system as R/W"
...and when I google it, nothing helpful comes up.. or is that something indigenous to root explorer? (which wasn't explained, because as I stated, all these so called tutorials are ambiguous)
wait.. is it me or do I seem to be repeating myself? *scratches head* lol
I have all kinds of patience swann, I can do all the research and studying that's needed without qualms - as I know exactly how it is.. I own and operate a forum which specializes in teaching kats how to mod the gta series and how to model in 3d applications.. and we home grow some of the most talented kats the gta modding scene has ever been blessed with ...but that's because all of my tutorials are concise and clear and leave nothing to guess - as are my answers to everyone's questions - so when I ask a question and nobody answers it, but thinks for some reason that they did, I tend to get a little uh.. how should we say.. urhrhr towards them because they're obviously wetoded or some shyt lol
anywayz, assistance would be greatly appreciated..
1. Are you rooted? If not, you will need to do this first.
2. ES file explorer is a good free alternative to root explorer, you will have to go into setting to allow for system files.
3. You would be better off just downloading a stock Froyo Rom and using that as your back-up but...if your wanting to do it your way you will need to be rooted and for that you will have to read because I took my phone out of the box, plugged in USB to the computer and installd GB before even setting the phone up so I am not sure of the process of flashing Froyo or if it even differs from GB. After that I will be happy to help you when you get to point of wanting GB.
KotsChopShop said:
rooted it with SOC
Click to expand...
Click to collapse
yes, I am rooted
thank you, I'll have a look for it asap
my plans are this; backup out of box Froyo, install stock/factory 236 update, backup that version of GB, then flash to Valhalla 236 black w/FBis's debloater
the reason I didn't automatically update to Tmo/Kies 236 is because I've read about the bad KJ6 modem causing text send errors as well as gps failures..
Dude fyi, Samsung doesn't make android. All new people see to credit Samsung for android. Google makes Android
Sent from my SGH-T959V using xda premium
uhh weally? lol ..yes, I understand that
but exactly what relevance does that hold with anything I've said thus far? ..was it because I mentioned Kies? - and if so, soeffnwhat.. your post effectively does nothing in it's frivolous existence lol
KotsChopShop said:
yes, I am rooted
thank you, I'll have a look for it asap
my plans are this; backup out of box Froyo, install stock/factory 236 update, backup that version of GB, then flash to Valhalla 236 black w/FBis's debloater
the reason I didn't automatically update to Tmo/Kies 236 is because I've read about the bad KJ6 modem causing text send errors as well as gps failures..
Click to expand...
Click to collapse
I believe the problems arose from using the leaked KJ6 items. I have not had any problems using anything related to KJ6 items built from the source. When you get to the GB flashing/Roms and such and have any problems just let me know.
for real? ..ok, I'll back this ish up tonight and [email protected] if need be
edit; welp, I decided to just roll with it and install stock 236 w/o backn up Froyo.. and it's exactly as everyone says, longer text messages and/or messages with images will not send :mutherF*$*ingSuicide:

[TOOL] G2X Cleanup Batch *** WARNING *** WILL FORMAT INTERNAL SD

If you are going to flash and ICS ROM after this tool please make sure to first install a GB then ICS otherwise your SD card will not be accessible. I am trying to find a fix but it has been illusive. This statement will be removed once a fix has been found and OP updated.
Now with CWM Touch!
This method uses NVFLASH to recreate all partitions and formats them, thereby getting rid of the file allocation pointers and hence renders data inaccessible without effort.
Note: I have never seen a file come back to life or its data affect other files without effort on the users part or a temporary glitch once the partitions and pointers have been overwritten. Please post a reply with evidence if you have seen it.
Benefits:
The contents of the zip file can be used to super clean G2X before a new ROM flash. This tool recreates all the partitions in the phone so wipes the pointers to all files (everything). The method it employes has existed from before. The files here will stop short of pushing a ROM, so that you can push your favorite ROM.
Prerequisites:
G2X (Will not work on O2X due to different partition table)
Desire to have a clean install of your favorite ROM
Backup your data
*** WARNING ***​
This tool will wipe both phone internal memory and internal SD card. External SD card content is safe.
Don't say you haven't been warned!
What to do:
Download the attached Zip file.
Take out the battery (assuming you have backed up your data on external SD card, computer or elsewhere), connect the device via USB while holding VOL+ and VOL- together. Don't let go of the volume buttons until the device is recognized.
(I typically leave Device Manager open to see when it shows up in the list under "USB Controllers").
Launch flash.bat, sit back and wait until the process finishes (generally a good idea to open a command prompt, CD to the directory and then run the file).
Unplug, put battery in, reboot into CWM recovery (pushed by this tool) by holding VOL- first, then pressing and holding POWER).
Flash your favorite ROM.
Enjoy!
I made this package because I could not get the bluetooth to work with G2x GB 2.3.3 (and below). The issue was a disconnect problem where both the phone and headset would still think they were connected but in audio would not be routed for a call or media. After this procedure my phone has not had an issue for almost 3 weeks now. I have tried it with two ROMs and 3 different headsets without any issues.
I guess I will not toss this phone after all .
Putting it out there in the hope that it may help others solve some of their issues as well. I suspect bad data stays in places not touched by other methods.
Your comments are most welcome.
[Update]
Klathmon has made an newer version with CWM 5.0.2.8. RP by Klathmon can be found here:
http://forum.xda-developers.com/showpost.php?p=24768294&postcount=66
I have tested the windows version but linux one is untested. Use at your own risk.
[Update]
Now with CWM Touch!
Thanks to everyone who has contributed on this thread with a drive to positive change! You work/comments/suggestions are very much appreciated.
References:
http://forum.xda-developers.com/showthread.php?t=1248644. This link was the inspiration for the current work.
Link to CWM Touch development thread. I took the image posted there: http://rootzwiki.com/topic/22984-recovery-touch-enabled-cwm-5813/
[EDIT] The zip file should be fixed now. Darn work machine does something to the upload.
was just about to flash the new hellfire rom and saw this tool! will try it out and see how things go
edit: yeah corrupt zip on my end too.
The zip file seems to be corrupt. Could you re-upload plz
worked great on my end, no problems.
khanggle said:
worked great on my end, no problems.
Click to expand...
Click to collapse
The real test is how stable your ROM would stay with this method to wipe than any of the other methods.
I guess only time will tell .
wow this method really blaze hellfire much thanks to your( you) & (rom dev)
Ohh I like this. Thank you for sharing .
This thing is faster than nullifier, and I especially like how you don't need to be in CWM to use it. It just seems like doing it in "update mode" would allow better manipulation of the phone's internals.
so this tool DOES format and nullify in addition to recreating the partitions?
deleting and recreating partitions does not remove data. only by writing over existing data can you get rid of it (like nullifier does)
dodgefan67 said:
so this tool DOES format and nullify in addition to recreating the partitions?
deleting and recreating partitions does not remove data. only by writing over existing data can you get rid of it (like nullifier does)
Click to expand...
Click to collapse
He states in OP that it doesn't write anything, therefor doesn't "nullify". It formats and partitions.
dodgefan67 said:
so this tool DOES format and nullify in addition to recreating the partitions?
deleting and recreating partitions does not remove data. only by writing over existing data can you get rid of it (like nullifier does)
Click to expand...
Click to collapse
Actually you are right. Deleting, recreating and formatting partitions does not get did of the 1s and 0s, so in that sense the data is still there. However the pointers are gone, and hence even though the data is still there it can't be accessed without effort.
What do you think the nand has on it when the device is shipped... I can assure you its not ask zeroes!
Sent from my LG-P999 using XDA
mansa_noob said:
Actually you are right. Deleting, recreating and formatting partitions does not get did of the 1s and 0s, so in that sense the data is still there. However the pointers are gone, and hence even though the data is still there it can't be accessed without effort.
What do you think the nand has on it when the device is shipped... I can assure you its not ask zeroes!
Sent from my LG-P999 using XDA
Click to expand...
Click to collapse
Well no, it has a next to worthless version of android Also, the point he was trying to get across is that it would be better for you to present the script for what it is and not try to compare it to other scripts that do something entirely different. You do kind of imply that you accomplish the same thing as the Nullifier script and more, when in fact you simply do something different.
Some may and probably will prefer your script, at least for specific purposes, while others will prefer the Nullifier script.
MWBehr said:
Well no, it has a next to worthless version of android Also, the point he was trying to get across is that it would be better for you to present the script for what it is and not try to compare it to other scripts that do something entirely different. You do kind of imply that you accomplish the same thing as the Nullifier script and more, when in fact you simply do something different.
Some may and probably will prefer your script, at least for specific purposes, while others will prefer the Nullifier script.
Click to expand...
Click to collapse
Done. OP updated to reflect. Thanks for clarifying that. It was not my intention to state that this tool does anything any other does, or does not.
I think we are all trying to do the same thing... get rid of the issues when swapping ROMs like _____. I can't seem to think of a good analogy here .
thanks for clarifying the OP, that makes much more sense
and no i wasnt trying to say you were reinenting the wheel, just trying to understand what your tool is actually doing
and also i do understand that it would take effort to get data off any type of storage device once the partition has been erased. i deal with wiping hard drives in a data center all the time. we use a DOD wipe tool that writes 1s and 0s over a drive a minimum of three full times to eradicate the data
but with this tool doing it outside of CWM, it sounds like it may do a better job of it
but i must ask, why do you need to push CWM? what if i have a newer version of it already on my phone?
dodgefan67 said:
but i must ask, why do you need to push CWM? what if i have a newer version of it already on my phone?
Click to expand...
Click to collapse
There is no need to push CWM 5.02. As I said in the OP it is a mod of the script found in the reference. In that script it was pushing default recovery. Since the recovery partition is being overwritten as well you will loose existing one and you need a recovery to be able to push a new ROM. Hence the need to push recovery (instead of using super one click).
As long as the recovery is not bigger than the partition that holds it we should be able to push a newer version. However I can't leave it empty or people will look for me with a shotgun (myself included ).
dodgefan67 said:
but i must ask, why do you need to push CWM? what if i have a newer version of it already on my phone?
Click to expand...
Click to collapse
I was thinking the same thing but seems easy enough .. add the cwm img to the dir and edit the .cfg file. Hopefully that should get the new CWM flashed
So would it be benefitial or pointless to nullify to clear the data then run this script for a... super clean?
Sent from my LG-P999 using XDA
mansa_noob said:
There is no need to push CWM 5.02. As I said in the OP it is a mod of the script found in the reference. In that script it was pushing default recovery. Since the recovery partition is being overwritten as well you will loose existing one and you need a recovery to be able to push a new ROM. Hence the need to push recovery (instead of using super one click).
As long as the recovery is not bigger than the partition that holds it we should be able to push a newer version. However I can't leave it empty or people will look for me with a shotgun (myself included ).
Click to expand...
Click to collapse
ahhhhhh now i understand. my eyes have been opened LOL
---------- Post added at 07:36 PM ---------- Previous post was at 07:35 PM ----------
PL0X_Kleiner said:
So would it be benefitial or pointless to nullify to clear the data then run this script for a... super clean?
Sent from my LG-P999 using XDA
Click to expand...
Click to collapse
i think it would be pointless unless you are super paranoid
dodgefan67 said:
ahhhhhh now i understand. my eyes have been opened LOL
---------- Post added at 07:36 PM ---------- Previous post was at 07:35 PM ----------
i think it would be pointless unless you are super paranoid
Click to expand...
Click to collapse
Nobody is twisting any arms here... Use it if you want to, don't if you don't want to.
I saw benefit so posted so that others may benefit as well.
Sent from my LG-P999 using XDA
Ok so question, why are you killing all the data on your internal SD card? Why not just the individual partitions that the phone uses? Your destroying data that don't need to be destroyed before flashing a rom...
Sent from my LG-P999 using xda premium
It does not have to be destroyed. I just haven't had a chance to test without recreating emmc yet.
Next step. Likely tomorrow. Would like to test before release.
Sent from my LG-P999 using XDA
[edit] BTW, I do want to restate that there is some data that needs to be destroyed which is not being taken care of by other methods. I don't believe it is in the emmc, but rather it resides in one of the other partitions. Most methods out there are only working in the /data, /system and /cache domain.
My original problem (bluetooth disconnect) which happens to be a problem for some in the community even now was only completely fixed by this method.

[RDU][CWM] BML to MTD Conversion Utility v0.1| [5/17]

The Goal: To create a CWM flash-able .zip that will convert a BML formatted phone to MTD without the need to be included in a rom, creating a standard and simplicity for end-users.
RDU
ROM DEVELOPERS UNITED
AS ONE
CWM BML to MTD Conversion Utility​Supported ROMs:
- Any BML Setup
So here's how it works:
This file will convert your phone's kernel and boot recovery to MTD. Afterwards, you will be able to flash an MTD rom.
ALWAYS make a backup of your data before flashing anything.
If you flash this over an already MTD rom, it will simply abort.
The Latest Version Here. After it finishes, your phone will be stuck in a loop. Pull the battery and 3-finger back into recovery to flash an MTD rom.
UPDATE: (--/--)
Further ideas or customizations from fellow rom developers welcome.
First
This sounds vary usefull on my firends Epics. I think it will speed thing up for me at times depending what they want
Sent from the Drivers Seat of my Suby txting and Driving doing 100MPH+ in a school zone! Ha.
zman519 said:
First
This sounds vary usefull on my firends Epics. I think it will speed thing up for me at times depending what they want
Sent from the Drivers Seat of my Suby txting and Driving doing 100MPH+ in a school zone! Ha.
Click to expand...
Click to collapse
Please note, this is a test version.
It's based on a version I used myself, but being on MTD, I can't test it easily.
There are 3 current scenarios it could yield:
1. Nothing happens.
2. It works perfectly.
3. It works, but puts the phone into a bootloop. This is what the old version did to me... Pop the battery. Boot into recovery. Profit.
So this would theoretically convert a BML ROM to MTD on a person's phone. Sounds great.
As a note to all remember as always to back up before flashing ANYTHING.
Sent from my SPH-D700 using xda premium
kennyglass123 said:
So this would theoretically convert a BML ROM to MTD on a person's phone. Sounds great.
As a note to all remember as always to back up before flashing ANYTHING.
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
Right now it should format your phone and prep it for a Rom. If it works properly, I'd like to rewrite it to convert and PRESERVE a BML Rom into an MTD Rom.
RandomKing said:
Please note, this is a test version.
It's based on a version I used myself, but being on MTD, I can't test it easily.
There are 3 current scenarios it could yield:
1. Nothing happens.
2. It works perfectly.
3. It works, but puts the phone into a bootloop. This is what the old version did to me... Pop the battery. Boot into recovery. Profit.
Click to expand...
Click to collapse
I understand ;-)
If my budy ever gets a new sdcard, I'll use his phone as a test dumey. The worst that could happen is I have to bust out the usb cable & fire up ODIN
Sent from the Drivers Seat of my Suby txting and Driving doing 100MPH+ in a school zone! Ha.
Ok so currently no data or apps are preserved. It is mostly a blank MTD slate?
Sent from my SPH-D700 using xda premium
kennyglass123 said:
Ok so currently no data or apps are preserved. It is mostly a blank MTD slate?
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
Yup. I need someone to confirm that it works properly. As I mentioned, I previously used a simpler version to convert myself to MTD and it worked, but it put me in a bootloop. I'm hoping to solve the bootloop so I can create a version to preserve a setup.
RandomKing said:
Yup. I need someone to confirm that it works properly. As I mentioned, I previously used a simpler version to convert myself to MTD and it worked, but it put me in a bootloop. I'm hoping to solve the bootloop so I can create a version to preserve a setup.
Click to expand...
Click to collapse
Well if you ran this and it put you in a boot loop, then it most likely worked properly since this would have formatted/converted your partition map to MTD. The BML rom would have either been erased or just unable to run due to the conversion.
Just a curious question here:
What would you need to do to actually convert an existing BML install to work on the MTD partition map?
nikon120 said:
Well if you ran this and it put you in a boot loop, then it most likely worked properly since this would have formatted/converted your partition map to MTD. The BML rom would have either been erased or just unable to run due to the conversion.
Just a curious question here:
What would you need to do to actually convert an existing BML install to work on the MTD partition map?
Click to expand...
Click to collapse
He said that it worked right in the post you quoted... lol
And I have no diea about the question... I'm kinda curious about this too...
nikon120 said:
Well if you ran this and it put you in a boot loop, then it most likely worked properly since this would have formatted/converted your partition map to MTD. The BML rom would have either been erased or just unable to run due to the conversion.
Just a curious question here:
What would you need to do to actually convert an existing BML install to work on the MTD partition map?
Click to expand...
Click to collapse
Because formatting destroys the existing file structure (it doesn't actually erase files, just overwrites the data that maps out the locations of those files), everything would need to be copied to a temporary location before converting the original location to the new partition type. Then the temp data (backup) would need to be copied back to the original location using the new format.
It is not possible to just change the format while leaving the data in place - those warnings on every format command (in every computerized device - windows, mac, etc) were not a design decision, but a result of a design limitation. The backup/format/restore method is the only way.
flastnoles11 said:
He said that it worked right in the post you quoted... lol
And I have no diea about the question... I'm kinda curious about this too...
Click to expand...
Click to collapse
He also said he was trying to solve the boot-loop problem, not a formatting problem. The clarification was not to assert that the formatting worked - the focus was on explaining the cause of the boot loop, to point out that there is no problem to be solved there because a BML kernel should boot loop when the rest of the partitions are freshly formatted MTD partitions.
The standard BML kernel can't read MTD, so the fact that those partitions are empty is irrelevant. Even if the partitions were converted without data loss (via a backup/convert/restore), the kernel would still need to be MTD-capable (so this by itself will not convert a BML rom to MTD)
Hopefully this clears up some of the confusion...
Sent from my SPH-D700 using XDA
nikon120 said:
Well if you ran this and it put you in a boot loop, then it most likely worked properly since this would have formatted/converted your partition map to MTD. The BML rom would have either been erased or just unable to run due to the conversion.
Just a curious question here:
What would you need to do to actually convert an existing BML install to work on the MTD partition map?
Click to expand...
Click to collapse
A kernel that supports MTD and copy all system, data and cache folder then paste it back after the conversion with the new kernel.
Sent from my SPH-D700 using xda premium
flastnoles11 said:
He said that it worked right in the post you quoted... lol
And I have no diea about the question... I'm kinda curious about this too...
Click to expand...
Click to collapse
Yes he did. I too read his reply.
My response to Random was that since he's put in the bootloop, then it worked for him due to the lack of converting the rom over. Therefore my reply implied that testing more won't hurt anything at all and would be good protocol, but may not be needed since it worked for him given his output.
styles420 said:
Because formatting destroys the existing file structure (it doesn't actually erase files, just overwrites the data that maps out the locations of those files), everything would need to be copied to a temporary location before converting the original location to the new partition type. Then the temp data (backup) would need to be copied back to the original location using the new format.
It is not possible to just change the format while leaving the data in place - those warnings on every format command (in every computerized device - windows, mac, etc) were not a design decision, but a result of a design limitation. The backup/format/restore method is the only way.
Click to expand...
Click to collapse
Ahh yea, I wasn't 100% sure if this was the case. Good breakdown though.
Doesn't seem to be working, I'll be uploading the version I use later on with directions.
I understand the theory, prepping a 100% BML setup for it's MTD future; just out of curiosity, Q: would there be a way to reverse this process so that if you arrive at your destination MTD ROM + change your mind, would it be possible to choose to convert an MTD ROM back to BML w/out having to ODIN (md5.tar + pit...........the way we do currently)?
BTW, am looking forward to testing your proposed conversion utility, just wondering.
nikon120 said:
Well if you ran this and it put you in a boot loop, then it most likely worked properly since this would have formatted/converted your partition map to MTD. The BML rom would have either been erased or just unable to run due to the conversion.
Just a curious question here:
What would you need to do to actually convert an existing BML install to work on the MTD partition map?
Click to expand...
Click to collapse
All I know is that it'd need an mtd kernel. Also, maybe it could work like rfs to ext4 where it backs everything up then restores and flashes an mtd compatible kernel. Theoretically, that should work on samsung tw based roms.
Sent from my SPH-D700 using XDA
Randomking, to fix the bootloop issue, try having it reboot recovery like the cm/miui mtd install scripts do (I think).
Sent from my SPH-D700 using XDA
sonarchist said:
I understand the theory, prepping a 100% BML setup for it's MTD future; just out of curiosity, Q: would there be a way to reverse this process so that if you arrive at your destination MTD ROM + change your mind, would it be possible to choose to convert an MTD ROM back to BML w/out having to ODIN (md5.tar + pit...........the way we do currently)?
BTW, am looking forward to testing your proposed conversion utility, just wondering.
Click to expand...
Click to collapse
Not possible since BML is proprietary. Odin is the only way to get this top secret partition information on our phone.
Sent from my SPH-D700 using xda premium
Thank You!
Edit
NVRMIND

Recovery Twrp vs CWR

Any advantage over one from the other
Sent from my GT-N8013 using xda app-developers app
I Rio Wonder about that
Sent from my GT-I9100 using xda premium
this will be interesting hearing everyone's imput ... tho its all based on personal preferenceim sure .. i like cwr
I have used both in the past and still prefer CWM....no reason other than its what I learned to use when i was a noob....now Im a noob veteran.
droidstyle said:
I have used both in the past and still prefer CWM....no reason other than its what I learned to use when i was a noob....now Im a noob veteran.
Click to expand...
Click to collapse
I will second this, I like them both, in fact I still use TWRP on my Nook Tablet, but I've been using Koush's stuff for so long, over 3 or 4 phones now, that it just seems natural for me to use CWM.
TWRP for me. Its much faster and has nice features.
I use to be a CWM fan, that was until I started using TWRP on my Rezound. From then on I use TWRP, but I don't mind good ole CWM every once in a while.
TWRP because it's faster and the UI is easier to use simply because the tiles are large.
I like Amon Ra best of all. Oopps...wrong thread LOL!. I use TWRP on my Bionic and CWM on the Galaxy. Like mentioned above, CWM is what I learned on and for some reason it feels like more hands on.
Let me say this. My friend was running CM10 all the way from like september. I tried updating it in CWM but it gave me assert errors. Reflash TWRP on it, and flash latest nightlies no problem. Dirty flash too, just wipe dalvik and cache.
There isn't an objective answer that I can give. I'm biased towards pretty much anything that is alternative to what everyone else is using. Also, I have no data that would indicate one recovery is better than another. So here's my purely subjective answer.
I prefer TWRP over CWMR for several subjective reasons:
Coming from the original Moto Droid on vzw, I ran RZrecovery (a moded version of SPrecovery, which had an OC'd kernel and lots of options as well as charging while in recovery way before I had seen it anywhere else). Basically, I'm not accustomed to CWMR.
I'm not a fan of the differential backups that CWMR defaults to. I know it takes up more space to have an IMG or TAR for each partition I choose, but I'm a crack flasher and go back and forth between TouchWiz and AOSP based roms all the time. I need to be able to keep my backups completely seperate. No blobs. I need a golden master for each ROM I flash. With a 64GB externeal SD card and a 32GB internal card, I rarely run out of space.
I can name backups while booted into TWRP before you create the backup. The whole date being wrong in every recovery thing is indeed annoying.
I like the terminal. I prefer to root, flash, hack, etc etc on my own without help from apps and or pre-built tools (except for dsixda's android kitchen, which is so bloody easy to use it blow my friggin mind). So I don't need or want ROM Manager to do much of anything for me. I even flash TWRP via the terminal. GooManager always runs in the background, and hasn't really ever had the most up to date versions of TWRP, so I ditched it pretty fast. I hate apps that run in the background when I'm not using them.
I like the look and feel of TWRP. Its feels like a teeny version of android with a small but very functional UI. Only thing missing is a terminal emulator that I could use from within TWRP itself. (Choosing a command file to run just isn't the same, but it has come in handy)
I also like having backups go to a folder that is labeled with the device's SN. Seems like a really fantastical feature in the making, like a cloud based storage for TWRP could be somewhere off in the future, where you could backup multiple devices to one online storage space.
Its the only "alternative" in town. I like "alternative" aka not so main stream stuff, which is odd cause I'm not a fan of Alt Rock. More of a Hendrix, Zepplin "classic rock" (aka blues based rock n roll with lots of riffs on the minor pentatonic scale) kind of person.
Um, I don't really have an 8th reason. But I would like an OC'd kernel in TWRP to help speed up backups, but I dunno how viable that is.
Ta,
ALQI
alquimista said:
Um, I don't really have an 8th reason. But I would like an OC'd kernel in TWRP to help speed up backups, but I dunno how viable that is.
Click to expand...
Click to collapse
Tempting, but with backups/flashing/recovery, I think slow and steady wins the race.
I used to use cwm, but with the change to blobs all of my backups stopped working. Even ones I just made.
so I stopped trusting it.
I switched to twrp. The backups are larger I think, but I trust them more.
Sent from my SCH-I535 using xda app-developers app
Haven't had any problems with TWRP, and it was the first I used. So pretty much just became acquainted with it and haven't seen a reason to switch.
I use CRW on my phone and TWP on the Kindle Fire. The best advice I can give is use what ever method the dev tells you to use, if he goes out of his way to mention it there is probably a good reason behind it.
One thing about CRW I wish would get fixed is the file name date being wrong (When it saves a file it gives the file a name based on the date but all current versions save it with an incorrect date (it thinks its 1970 lol) If i dont change it right away I end up with a bunch of mystery backups.
Another thing to remember about the latest CRW's is the blob. To save space during the saving of a backup a file (blob) is created that has any redundant info shared by backups in it. So all the info for your latest backup file isn't all in the file with that backups name some or most of it is in the blob file. So if you want two or three backups from your phone saved to your home computer make sure you take the entire clockworkmod file because if you take just the individual CRW backup file (1970 -blah-blah-blah) you will be missing all the info on the blob. CRW will let you restore with the partial file and that can get ugly fast.
I've always used cwr but I will give twrp a shot, love trying new stuff. And the date issue with cwr is really annoying. I'm sure it could be renamed but I don't want to change anything and get an md5 mismatch.
Sent from my SCH-I535 using xda app-developers app

Categories

Resources