yashsingh1/xdaforums huggingface dataset:
[Nexus 7 3G Android Development] Xentar712:
Cool, I'll give it a go once you get TWRP up and running. Maybe Tassadar, over in the MultiROM forum, can tweak it for MultiRom as well. I'm really liking MultiRom - IMHO it's less risky when toying with unknowns. It's probably more risky in reality though, and I'm just crazy :)
[Nexus 7 3G Android Development] superc0w:
I've flashed this recovery to get 4.2.1 on my Nexus 7 3G, but it seems that I can't go into recovery mode anymore. The screen shows me picture of an android lying down with its front open.

The only way I'm able to go into recovery is to reflash, or do a

fastboot boot recovery recovery-CWM-tilapia-regular.img

This works for that 1 boot, after which I get the same issue.
[Nexus 7 3G Android Development] mateorod:
Okay. After I flashed the OTA, CWM asked me if I wanted to make it permanent, but maybe that by itself us not enough. I had already done the following step.

flash recovery and boot into it. Mount system, and then:

adb shell
mv system/recovery-from-boot.p system/recovery-from-boot.bak
exit

CWM asked me if i wanted to prevent the updates from flashing stock recovery and if I wanted to secure the root (su binary). But maybe that doesn't work right out of the box.
[Nexus 7 3G Android Development] superc0w:
Yup, I renamed recovery-from-boot.p to recovery-from-boot.p.bak using ES File Explorer and it's all good now. I'm now able to use CWM. However, CWM always asks me if I want to prevent updates from flashing stock recovery and I always chose no (since it warns that this is irreversible).

Strange though. I assumed that even if CWM doesn't stick without renaming recovery-from-boot.p, the N7 3G would flash stock recovery and it would still be functional.
[Nexus 7 3G Android Development] Ather:
installed last night, works great..frankly i prefer the non-touch, dunnow why but its much better...i tried to rename the files, but there werent any files in the /system , flashed the CWM package, took a nandroid..all works great :)
[Nexus 7 3G Android Development] gwisch:
Somehow this still does not seem to work for me:

After I reflashed the tilapia recovery (CWM 6.0.1.9), I executed the nakasig file and get:

Finding update package...
Opening update package...
Installing update...
Verifying current system...assert failed: apply_patch_check("/system/framework/framework-res.apk". "212e537985a59a7d40ff8b450a3de597ade4251c". "521503fb2a63dc6d80c4a1ecf72770c3745c4178")
E:Error in /sdcard/0/65880f45b1c0.signed-nakasig-JOP40D-from-JOP40C.65880f56.zip
(Status 7)
Installation aborted.

:confused:
[Nexus 7 3G Android Development] phonic:
That error message has absolutely nothing to do with the recovery image.

This special talapia version of CWM isn't some magic pill that will make every other problem go away. It's simply designed to accurately reflect the hardware for the tablet you own (talapia vs grouper) so you don't run into as many problems down the road installing OTA updates and custom ROMs that check.

However, you still need to meet ALL the other requirements of the updates. So if you made changes to your /system files, kernel (not in this case, but in general), build.prop, etc., the OTA update will still abort and explain why.

Did you even read the error message?

Verifying current system...assert failed: apply_patch_check("/system/framework/framework-res.apk".

It's pretty clear that you modified the framework file. You will need to revert that back to stock and flash the OTA again afterwards. Any other tweaks/modifications/freezes/removals/etc. of system apps will most likely result in the same thing.
[Nexus 7 3G Android Development] mateorod:
TWRP is up...

I compiled a TWRP image for tilapia as well.

This actually took a little doing...my intention here was to simply compile some images, but since tilapia is only Android 4.2, and we don't have CM10.1 (officially), I actually endied up having to port TWRP whole cloth. This is compiled from TWRP source code, with a few tweaks.

There are a couple things about the port I would like to eventually tweak, I had to copy the sbin folder over by hand, and due to the intertwined nature of grouper/tilapia, settings derived from common files in the source code are named grouper still, (i.e. ueventd.grouper.rc instead of ueventd.tilapia.rc) but that is quibble stuff and may end up staying that way regardless, since many of the tilapia make files are merely pointers to the grouper files. It certainly doesn't hurt anything.

The TWRP image has been confirmed working with the OTAs.

I thought long and hard about possibly modifying these recovery images to allow users to flash grouper roms as well. I know it is unlikely that everything will be made available in two versions, even though it should be.

Any thoughts on this? It is a demonstrably better idea than having people use the grouper images, but I still think the developers/modders should be the ones handling this problem. People are going to NEED this recovery image once the nightlies of AOKP/CM10.1 and whatever start coming down, but I know that grouper zips will still be tempting to many.
[Nexus 7 3G Android Development] manekineko:
Under the instructions in the first post, it says:

So without flashing anything, I should be able to just point fastboot towards the clockworkmod file on my computer and it should reboot into clockworkmod right?

When I try to do this, it doesn't work, and I just get this:

C:\Program Files\Droid Explorer\SDK\tools>fastboot boot recovery D:\Downloads\recovery-CWM-tilapia-regular.img
cannot load 'recovery'

I also tried to follow the main instructions and it fails on step 2 with:

C:\Program Files\Droid Explorer\SDK\tools>fastboot flash recovery D:\Downloads\recovery-CWM-tilapia-regular.img
sending 'recovery' (6568 KB)... FAILED (remote: Bootloader is locked.) finished. total time: 0.021s

I looked at other threads and found out that normally flashing a custom recovery requires issuing a fastboot oem unlock command that wipes all data. Am I missing anything or is this actually required before either of these?
[Nexus 7 3G Android Development] mateorod:
Yep. My bad.

I originally just posted the images as an alternative to the recoveries for the regular Nexus 7 (non-3g) images people were using. I later realized that some new people would come by so I threw rooting instructions as well. I didn't go back far enough, sorry. I will fix it now.

What you need to do is easy though, just like you mentioned you need to unlock your bootloader. So once you boot into the bootloader,

fastboot oem unlock

This will wipe all of your data, and there is no way around this, sorry. It is a security measure of some sort. There will be a screen where you acknowledge this and then the bootloader will unlock. You can then follow the rest of the instructions. Sorry for the confusion.

Update: Fixed and streamlined OP. Glad you got me to do this, I think it is better now.
[Nexus 7 3G Android Development] manekineko:
In the rooting instructions, this line wasn't working for me, as /sdcard/ was for some reason a directory containing 3 folders (0, odb, legacy), where 0 had the normal contents of /sdcard/:

Instead, I had to do:

adb push CWM-SuperSU-v0.98.zip /sdcard/0/

After that change, I was able to flash the zip and root successfully.
[Nexus 7 3G Android Development] justin0108:
Hi OP,

I followed your instructions and managed to root my nexus 7 3G running stock Android 4.2.1. Thanks.

However there are some extra "incidents" which is not captured in your instructions and somehow it happen on my side, so I just detailed down what happen in case it can be of help to others:

Below is the full OP's original instruction and some extra "incidents" during rooting

Instructions

1. Boot into the bootloader (2 choices)

Turn the device on while pressing volume down; or

Code:

adb reboot bootloader

2. Unlock your bootloader

THIS WILL WIPE ALL OF YOUR DATA! No way around it...

Code:

fastboot oem unlock

My Nexus rebooted after this step and all the ADB drivers on my Windows 7 pc is gone. With my Nexus 7 still connected and booted up, when I do "adb device", I cannot see my device. I open the Device Manager and notice that the "ADB Composite Interface" driver is gone!

I got to re-install all my drivers for my Nexus 7 manually. I downloaded WugFresh Toolkit and follow the first step to re-install all the drivers. (I just wana try manual rooting, that's why I didn't use WugFresh Toolkit)

After making sure my device can be listed after "adb device", I proceed to

2a. Reboot into bootloader

adb reboot bootloader

3. With your Nexus 7 3G in the bootloader and connected to your computer through the usb cable:

replace recovery-CWM-tilapia-regular with the name of the recovery image you chose to download.

Code:

fastboot flash recovery recovery-CWM-tilapia-regular.img

4. To make CWM your permanent recovery: (this can, despite the warnings, be undone. Do it.)

Boot into recovery mode by pressing 'vol up' and when the menu says 'recovery mode' press the power button.

Mount system in the 'mounts' menu

Code:

adb shell
mv system/recovery-from-boot.p system/recovery-from-boot.bak
exit

5. To Root (With /system still mounted):

There is no error when pushing the zip file to /sdcard/ but the file just didn't appear. The windows command prompt also indicate that the push was successful. I notice that the my /sdcard/ directory is softlink to /data/media/, so I push to /data/media/ instead and it works! The zip file now appear in /sdcard/. I am not sure why is this so.

Code:

adb push CWM-SuperSU-v0.98.zip /data/media/

Flash the SuperSU zip in recovery ('Install' menu with TWRP or 'choose zip from sdcard' in CWM)

Reboot System

5a. CWM will give a warning message stating overwriting of flash recovery. I cannot recall what is that exact message. But you will be presented with a llist of options with one "Yes" and all "No". I choose "Yes" to retain CWM as my recovery.
[Nexus 7 3G Android Development] mateorod:
I can't speak as to how Windows works exactly, but I can tell you that fastboot code does nothing to the 'host' PC. Not saying it didn't happen, but it wasn't fast boot.

The person above you reported that they had to push to /sdcard/0. I checked my original instructions and they work for me. I haven't decided what to put yet. They have been playing around with the standard nomenclature for emulated storage, but I have yet to see anything that explains the varied experiences. I haven't looked yet really, either

I originally told people to follow the CWM directions on having permanent recovery. But some user experience taught me that some people are going to skip this step due to confusion over the warnings. So I decided to put in the manual method.

Thanks for your feedback.
[Nexus 7 3G Android Development] justin0108:
Hi,

In fact I am also confused about the warning. Not sure does choosing "Yes" means retain CWM or not. So I just choose "Yes" and saw that CWM is still the recovery after reboot.

So do you mean after this step:

adb shell
mv system/recovery-from-boot.p system/recovery-from-boot.bak
exit

It does not matter whether I choose "Yes" or "No" in the final phase, and I will still have CWM as my recovery?
[Nexus 7 3G Android Development] mateorod:
Well, what answering 'yes' does is a decidedly more elebant solution, it just removes the execute permission from system/etc/install-recovery.sh. But the effect is the same, and since the above is what people have been recommending...
[Nexus 7 3G Android Development] cmstlist:
Could these be made available in flashable zip format, for easy changing between one and the other?
[Nexus 7 3G Android Development] mouse100:
Is CWM Touch not available for N7 3G?
[Nexus 7 3G Android Development] FReaKRaNT:
That is what this thread is about.:what:

Cheers, FReaKRaNT
[Nexus 7 3G Android Development] mouse100:
At the end of OP there are only links to download cwm no-touch and twrp

------------------------

Nexus 7 3G - Tapatalk 2
[Nexus 7 3G Android Development] mateorod:
At the top of the OP I explain that CWM Touch has closed source elements. The only way I know how to build Touch is on koush's web builder. But as of last week, it was still producing non-working images of both touch and regular CWM for tilapia.

I ported and compiled TWRP and CWM regular because the source was available to me. I did port the CWM touch by hand but it was too buggy to release.

I will be posting a Twrp update in the next day or so.

Edit: I just saw that PA finally went public with their builds. As the roms start coming out you will need tilapia recovery if you want to have working 3g roms. CM10.1 builds are starting to role out, so as they fix up the source, the automatic web builder will finally have access to working source. Then CWM Touch will go up.
[Nexus 7 3G Android Development] shinji257:
I look forward to it. I'm running TWRP on mine but I assume at this point it is a grouper build since It is 2.3.2.1 and this thread only has a 2.3.1.2 build. I'll await your update then flash it replacing the old recovery. It seems the toolkits only install the grouper recoveries?
[Nexus 7 3G Android Development] mateorod:
Well, I know that sparksco committed my patches to get TWRP to compile, so there is the possibility that there is another working tilapia build out there. The TWRP guys just added a bunch of stuff over the last week. I was kind of waiting until they finished getting it close to stable, just so I wasn't pumping out updates daily.

Even with my patches to fix the compile, I don't have TWRP working completely out of the box...the busybox in the recovery.img isn't working for some reason so I have to port over a working sbin folder by hand. But that is a very minor thing and doesn't impact how the images behave.

I also updated the CWM based on your report the other day, so thanks for that. I hadn't noticed any problems myself, but since koush had updated it seemed the thing to do.

The web builder for CWM Touch is based on the github source for CM. And since they hadn't added all the makefiles yet, it was producing a non-booting image, likely with the same binary issues. But now that tilapia roms are coming out, all those tool kits will need to add recovery. And it doesn't just build out of the box yet, so they will probably be these recoveries.

If you want to check your recovery, you can unpack it with the unpackbootimg binary in your SDK.
[Nexus 7 3G Android Development] p0izn:
What is the path for cwm-made backups? Where i can find them? Because in cwm backup is located in sdcard/clockworkmod/backup , but in Android (via TC) this path doesnt exist.
[Nexus 7 3G Android Development] gatebil:
try /mnt/shell/emulated/clockworkmod
[Nexus 7 3G Android Development] mouse100:
Will it be possible to make in a future a tilapia recovery with this multi boot feature?

http://xdaforums.com/showthread.php?t=2011403

------------------------

Nexus 7 3G - Tapatalk 2
[Nexus 7 3G Android Development] Flagellant:
Thank you very much! I was searching for it.:good:
[Nexus 7 3G Android Development] mateorod:
I don't use back ups, is that the only place? It isn't in sdcard? I may change that for the next update. Should really be on TWRP to fix, but since I am the only person messing with the recoery right now...I will look into it.

I don't really know what you are asking. That is a rom that needs a modded recovery to flash itself, right? Does it not work with your device and if not what does it say?

If the dev is only building for grouper, than you can use grouper recovery (not the best idea) or change the assert in the update zip (still not the best idea) to read tilapia.

Or preferably, you can ask the dev to build for tilapia too, since if it is only for grouper, the 3g stuff won't work anyway.
[Nexus 7 3G Android Development] manekineko:
It's an Android 4.2 thing. Because of multi-user support, the location of backups shifted off of the sdcard, as I believe each user has their own virtual sdcard.
[Nexus 7 3G Android Development] mouse100:
No it's a modded twrp recovery that supports multi-ROM installation and so multi boot. But since it's in grouper section I think it's not for tilapia so I ask you if it's possible to port this recovery also on nexus 7 3g. I didn't try that modified recovery yet.

------------------------

Nexus 7 3G - Tapatalk 2
[Nexus 7 3G Android Development] mateorod:
But why? If the ROM is for tilapia, then you need tilapia recovery. If the ROM is only for grouper, then take your chances and change the ROM's updater script or use grouper recovery. It isn't that it is specifically a bad idea to use grouper's recovery, just generally a bad practice. You won't have working 3g, but if the ROM isn't built for tilapia you won't have that anyway.

Like I said, the best thing is to ask the developer to build for tilapia too. It won't be that hard for him since the process is so similar.
[Nexus 7 3G Android Development] kEvinErd:
Hey guys.. Thanks for the awesome guide. Very helpful for a newbie like me.

Just got a few questions as I come from Samsung phones previously:

1) In the OP, the steps are to first flash CWM, then root whereas for Samsung phones, it's usually root, and then flash CWM. Does the sequence matter?

2) In the OP, to root, we use the CWM installable zip. But I also notice that Chainfire has released a CF-auto-root specifically for Nexus 7 models (found here: http://xdaforums.com/showthread.php?t=2025272). Are there any differences in the two versions?
[Nexus 7 3G Android Development] mateorod:
Well, sequence matters in that you need to flash recovery to flash the SuperSu zip. Basically, you will need to do it as written. Unlocking the bootloader allows you to flash recovery, then you root from there. The difference is that we are not dealing with exploits here, the Nexus devices come ready to be rooted and flashed.

As for CF-auto-root, I am sure it works just like intended, But I wouldn't say it is necessary for Nexus devices. He likely added Nexus support to that program simply because it was easy to do and to give the program wider support.

I am not slagging CF-auto-root, Chainfire is the man. But rooting the Nexus devices is easy. If you have already read this guide, you are basically already there.

Good luck!
[Nexus 7 3G Android Development] cmstlist:
Explanation: You were probably using Samsung non-Nexus devices which are always released with an initial OS version older than the most recent. As a result, there is often a root exploit which has been discovered by that time, that does not require you to first modify the bootloader or recovery partitions. If Google has patched that exploit in the source code, it takes a while for the patch upgrade to percolate through Samsung and the carriers before it hits your phone, if it ever does.

Typically on Nexus devices, the first root method is to go through bootloader to flash an insecure boot.img or custom recovery to then get it rooted, because on devices with an easy unlocked bootloader this is always the most straightforward method. Any root exploits in the OS rarely last very long, because the fix comes along straight from Google in short order.
[Nexus 7 3G Android Development] Sean09:
Any idea why TWRP recovery is asking for a password?
[Nexus 7 3G Android Development] Coolman4now:
Can we get a touch CWM, please ?
[Nexus 7 3G Android Development] cmstlist:
Assuming you didn't encrypt it or add a password yourself -

If you just unlocked your bootloader or wiped your userdata partition, there is in fact no partition there at all. TWRP seems to get confused by the absence of a partition and assumes it must be encrypted, so it asks for a password.

If this is your situation (happened to me too), you need to boot into the OS (any functioning ROM should work) once, let it boot completely, and once it's done that you should be able to get into recovery again.

If you did encrypt your data partition in Android, then the password it is asking for is the one it needs to decrypt your data partition.
[Nexus 7 3G Android Development] Sean09:
Thanks, that did it. I flashed to CWM, sideloaded to flash the rom and gapps, reflashed after booting once, and it worked fine.
[Nexus 7 3G Android Development] mateorod:
It is not up to me. If it was open source, I would port it. But it isn't.

Sometime soon, the CM repos will be made buildable, and then compiling Touch will be trivial.

update: as soon as I open my mouth, Cyanogen releases 10.1 for tilapia. Now that they have added tilapia to the Jenkins menu I can most likely make Touch. I will update TWRP and try and release CWM Touch tonight.
[Nexus 7 3G Android Development] mateorod:
TWRP has been updated to 2.3.1.2. It is strongly recommended that you update to the newest version, as they have commited a bunch of 4.2 related fixes.

Even with the recent Cyanogen 10.1 build for tilapia, the CWM Touch Builder's output still doesn't boot. I have again ported it by hand, but it is buggy to the point of being unusable.

There isn't anything I know how to do except wait until Koush fixes it. Sorry.
[Nexus 7 3G Android Development] cmstlist:
The file still says 2.3.1. Has it not been updated yet?
[Nexus 7 3G Android Development] mateorod:
Shoot, I just have the old link up. You can just navigate up a level to techerrata/browse/mateorod/recovery and I will fix the OP.

Thanks.
[Nexus 7 3G Android Development] cmstlist:
Also I can't seem to get ADB devices to recognize TWRP in recovery. ADB works fine when booted into the system. Are there drivers I should be looking for? Win7 32-bit here.
[Nexus 7 3G Android Development] mateorod:
I use linux, but am having no issues. Have you mounted system?

This is not 100% compiled from source, I am still porting the sbin folder. But everything seems to working fine from here. I have pushed a couple patches upstream to TWRP in the hopes of official support, but no traction yet. I think sparksco may review them, though. We'll see.
[Nexus 7 3G Android Development] kenkiller:
Maybe u need more sleep. :D It's 2.3.2.1, isn't it? :D
[Nexus 7 3G Android Development] sparksco:
Disregard wrong thread.
[Nexus 7 3G Android Development] cmstlist:
I don't see how mounting anything within TWRP would help Windows recognize it. FWIW I have the same issue with TWRP on my GNex, but if I wait long enough it suddenly kicks in and recognizes. That doesn't happen with the N73G.
[Nexus 7 3G Android Development] cybercool10:
@mateorod or anyone who has Download the latest updated TWRP for Tilapia , kindly provide a Mirror , dunno why but Downloading has been failing for me from Techerrata Since two days :-/ Sorry for bothering
[Nexus 7 3G Android Development] denzel09:
Is it possibile to have a touch versione of cwm for tilapia ?

Sent from my Asus Nexus 7 3g 32GB
[Nexus 7 3G Android Development] kEvinErd:
Many thanks for your explanations and confirmations!

I will stick exactly to the OP's guide then! :o So much to learn going from an android-based OS to a full android OS!
[Nexus 7 3G Android Development] Sib64:
Download Links for Tilapia Recovery

For those who are interested, I give a another link for download the different versions of Tilapia recovery:

- recovery-CWM-regular-6.0.2.1-tilapia.img - md5: c6819cc1ffa3b849476b5e69854d3aaf

- recovery-twrp-tilapia-2.3.2.1.img - md5: 1f7085b4e7dd1f7741e9521cfd6501cf
[Nexus 7 3G Android Development] denzel09:
Different in what buddy?

Sent from my Asus Nexus 7 3g 32GB
[Nexus 7 3G Android Development] PVL_93_RU:
Obviously, one is from ClockWorkMod and the other is from Team Win
[Nexus 7 3G Android Development] denzel09:
OK buddy, i thinked a different thing LOL

Sent from my Asus Nexus 7 3g 32GB
[Nexus 7 3G Android Development] Shinj1EVA:
CWM 6.0.2.3 for Tilapia (Touch and non-touch)

Just built these from the last CM nightly. The touch build server seems to compile fine now as well.

Regular: https://www.dropbox.com/s/qaqjy9rtkb94sm2/recovery-cwm-tilapia-6.0.2.3.img

Touch: https://www.dropbox.com/s/tjbysidf5y2ndzv/recovery-cwm-tilapia-6.0.2.3-touch.img
[Nexus 7 3G Android Development] denzel09:
Both work flawlessy, thank you so much.. please keep update the thread, i hope in you:good::good::good::good::good::good: