• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[RECOVERY][ariel] TWRP 2.8.6.0 touch recovery [2015-06-07]

Search This thread

jmz

Inactive Recognized Developer
Sep 17, 2008
3,623
4,804
Lawton, OK
www.jmzsoft.com
Google Pixel 4a 5G
Team Win Recovery Project 2.x, or twrp2 for short, is a custom recovery built with ease of use and customization in mind. It’s a fully touch driven user interface – no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.

Phone look:


Tablet look:


CHANGELOG for 2.8.6.0:

  1. Fix daylight savings time rules for USA and Europe (_that)
  2. Allow mulitple overlays for popup boxes (Dees_Troy)
  3. Add pattern style password entry for decrypt (Tassadar)
  4. Keyboard improvements (_that)
  5. Update AOSP base to 5.1 (Dees_Troy)
  6. Reduce theme count to 5 and rely on scaling (Dees_Troy)
  7. Various scaling improvements (Dees_Troy)
  8. Improved handling of resources in the GUI (_that)
  9. Make scroll bar size proportional to list size (_that)
  10. Allow scoll lists to render without a header (_that)
  11. Make console scroll per pixel with kinetic scrolling (_that)
  12. Support styles in XML to reduce XML size and improve consistentcy (Dees_Troy)
  13. Various other fixes and improvements (mdmower, bigbiff, codelover, etc)

CHANGELOG for 2.8.5.0:

  1. Scale the GUI - TWRP can read the theme's resolution and scale it up or down to fit the theme to your screen's resolution
  2. Backups can now be cancelled while the backup is in progress (does not include restore because we don't want to leave your device in a bad state)
  3. Improve thread handling and move input handling into the main rendering thread to improve stability
  4. Make MTP work even if unplugged and plugged back in
  5. Unify scrollable list code and make kinetic scrolling feel more natural
  6. Fix handling of mapped zip files for OTA updates (CM12 updater)
  7. USB keyboards should now work on all devices that support USB host mode via a USB OTG cable
  8. Other small fixes and improvements

CHANGELOG for 2.8.4.0:

  1. Add flashing of boot and recovery images via the TWRP GUI (Find the Images button on the Install page)
  2. Fix some MTP related crashes and bugs
  3. Eliminate TWRP toggling USB IDs during boot if MTP is enabled
  4. Fix various adb sideload issues
  5. Improve threading of actions
  6. Eliminate separate thread for screen timeout
  7. Update libblkid to 2.25.0
  8. Use power button as back button on watch themes for easier navigation
  9. Add mutex locking to data manager
  10. Improve custom theme handling on encrypted devices
  11. Allow the stock theme to be offset by build flags so we can center a lower res theme on a higher res screen especially for watches with round screens

CHANGELOG for 2.8.3.0:

  1. MTP will now tell the host PC that storage is removed instead of disabling MTP completely
  2. MTP will now report the correct max file size based on the file system in use to the host PC (may fix transfer of large files)
  3. Update and improve fix permissions and make fixing contexts optional
  4. Update SuperSU in TWRP to 2.40 and update install process
  5. Make TWRP work properly on AArch64 (Nexus 9 is now built in true 64-bit binaries and libraries)
  6. Attempt to set correct permissions and contexts on all files placed in storage so backups will show in Android
  7. Fix kernel panic during MTP start on some devices
  8. Support unicode fonts on devices with True Type Font support
  9. Fix slider value not showing sometimes (vibration settings page)
  10. Toggle MTP off during adb sideload to set correct USB IDs
  11. Reduce library requirements for 5.0 L decrypt
  12. Other minor fixes and improvements

Note: Starting with TWRP 2.8.2.0 and higher, adb sideload uses a new sideload method originally implemented in AOSP recovery. You will need the latest adb binaries to use sideload in these newer versions of TWRP. The version required is 1.0.32. You can find the version by running "adb version" on your computer. The new sideload feature no longer stores the zip on your device. Instead, a fuse file system is created in RAM and the zip is streamed from your computer. This puts less wear and tear on storage and ensures that large zips will not fill up all of your RAM. The sideload may spit an error on your PC side, but the zip should install just fine on your device.
 
Last edited:

jmz

Inactive Recognized Developer
Sep 17, 2008
3,623
4,804
Lawton, OK
www.jmzsoft.com
Google Pixel 4a 5G
Everything seems to be working. No known issues. USB-OTG works also

Downloadhttps://www.androidfilehost.com/?fid=24052804347756852

or use our TWRP Manager software to install it automatically for you



Install either by DD or maybe flashify will work for you.

Code:
dd if=recovery.img of=/dev/block/mmcblk0p7

Thanks goes to @Dees_Troy as this was my first MediaTek based device to build recovery for

This will also be taken official this week.
 
Last edited:

bibikalka

Senior Member
May 14, 2015
1,370
1,090
So for us the slow ones, can you explain this in detail?
You've replaced the stock recovery with TWRP, so we can flash images from USB drives ? But you need root to do the first flash to recovery, correct?
Will Amazon update re-write the recovery partition so you are back to stock ?
 

jmz

Inactive Recognized Developer
Sep 17, 2008
3,623
4,804
Lawton, OK
www.jmzsoft.com
Google Pixel 4a 5G
So for us the slow ones, can you explain this in detail?
You've replaced the stock recovery with TWRP, so we can flash images from USB drives ? But you need root to do the first flash to recovery, correct?
Will Amazon update re-write the recovery partition so you are back to stock ?

yes. and future custom roms if they come. You should be disabling OTAs anyways. OTAs im pretty sure will fail anyways with a custom recovery
 

bibikalka

Senior Member
May 14, 2015
1,370
1,090
yes. and future custom roms if they come. You should be disabling OTAs anyways. OTAs im pretty sure will fail anyways with a custom recovery

Man, that's pretty awesome! It sounds like one just needs one good TWRP flash, and then it's not that hard to recover after a screw up via OTG.

And it seems like with this TWRP we should be able to flash Amazon updates onto the device (such as 4.5.4), and install root on top after that ? Root 4ever ? :D How hard is it to make TWRP flash stock Amazon updates ? I want 4.5.4 , with root !!! :D

You could also change the size of /cache, and add it to /data, or move dalvik cache from /data to /cache, see these allocations (there is 1 Gb of space in /cache !!!):
http://forum.xda-developers.com/fire-hd/help/internal-memory-structure-hidden-t3122246

So even without a custom ROM there are tons of easy tweaks that one could do.

I actually got to like the Fire OS, it is super stable for me. With custom recoveries things are often quite rocky for a while. I'd like to get some sort of Android Setup app, in order to change things above and beyond what Amazon allows (such as that Cyrillic AOSP keyboard!).

Once you figure out how to put stock Amazon update files onto the device plus root, you can pretty much play with Xposed and get into risky stuff (not being afraid of bootloop.) Just make sure to keep the trusty TWRP handy!!!
 

jmz

Inactive Recognized Developer
Sep 17, 2008
3,623
4,804
Lawton, OK
www.jmzsoft.com
Google Pixel 4a 5G
Man, that's pretty awesome! It sounds like one just needs one good TWRP flash, and then it's not that hard to recover after a screw up via OTG.

And it seems like with this TWRP we should be able to flash Amazon updates onto the device (such as 4.5.4), and install root on top after that ? Root 4ever ? :D How hard is it to make TWRP flash stock Amazon updates ? I want 4.5.4 , with root !!! :D

You could also change the size of /cache, and add it to /data, or move dalvik cache from /data to /cache, see these allocations (there is 1 Gb of space in /cache !!!):
http://forum.xda-developers.com/fire-hd/help/internal-memory-structure-hidden-t3122246

So even without a custom ROM there are tons of easy tweaks that one could do.

I actually got to like the Fire OS, it is super stable for me. With custom recoveries things are often quite rocky for a while. I'd like to get some sort of Android Setup app, in order to change things above and beyond what Amazon allows (such as that Cyrillic AOSP keyboard!).

Once you figure out how to put stock Amazon update files onto the device plus root, you can pretty much play with Xposed and get into risky stuff (not being afraid of bootloop.) Just make sure to keep the trusty TWRP handy!!!

Yeah, I am going to be working on the update this week. Starting a new job tomorrow.

Also, I added a link to our software TWRP Manager so it is even easier to install TWRP.
 

bibikalka

Senior Member
May 14, 2015
1,370
1,090
Yeah, I am going to be working on the update this week. Starting a new job tomorrow.

Also, I added a link to our software TWRP Manager so it is even easier to install TWRP.

I just saw your boot unlocker thread, you should better manage your cross-references :D Congrats for getting us this far!

But I wonder if one could just flash 4.5.4 first, and then unlock the bootloader, and install TWRP, then root. Which bootloader versions can be unlocked? All so far? So people who were force updated to 4.5.4 are not SOL ?

Of course, it's easier to just have TWRP flash Amazon updates, then root is always available. That would be an enabling step, with the ability to flash Amazon stock ROMs, one can mess things up totally, and still recover back.

Exciting times, man !!!!
 

jmz

Inactive Recognized Developer
Sep 17, 2008
3,623
4,804
Lawton, OK
www.jmzsoft.com
Google Pixel 4a 5G
I just saw your boot unlocker thread, you should better manage your cross-references :D Congrats for getting us this far!

But I wonder if one could just flash 4.5.4 first, and then unlock the bootloader, and install TWRP, then root. Which bootloader versions can be unlocked? All so far? So people who were force updated to 4.5.4 are not SOL ?

Of course, it's easier to just have TWRP flash Amazon updates, then root is always available. That would be an enabling step, with the ability to flash Amazon stock ROMs, one can mess things up totally, and still recover back.

Exciting times, man !!!!

Messing with things more and more I don't think that is a fully working bootloader unlock. For example, I can't boot an unsigned boot.img after flashing. But I can boot it if I flash to recovery partition then issue adb reboot recovery.

Or that may just be a MTK/Amazon/LK thing. Not too sure at this point. But it seems right now, custom kernels are out of the question.
 

bibikalka

Senior Member
May 14, 2015
1,370
1,090
Messing with things more and more I don't think that is a fully working bootloader unlock. For example, I can't boot an unsigned boot.img after flashing. But I can boot it if I flash to recovery partition then issue adb reboot recovery.

Or that may just be a MTK/Amazon/LK thing. Not too sure at this point. But it seems right now, custom kernels are out of the question.

I see what you mean ... Even a partial unlock is huge step forward in terms of customization options, and the biggest deal is that now it's not too scary to screw up! Btw, in Amazon update files there is recovery-from-boot.p, is that the image we need for recovery? Or should we make a proper one via dd?


In Amazon update they seem to update recovery, but I wonder who checks for signed boot.img ? Is this part of the chipset ?
(from /recovery/etc ):
#!/system/bin/sh
if ! applypatch -c EMMC:/dev/block/platform/mtk-msdc.0/by-name/recovery:5888256:6d9d1bbc4172c107db3228ed8d9f97111219c617; then
log -t recovery "Installing new recovery image"
applypatch -b /system/etc/recovery-resource.dat EMMC:/dev/block/platform/mtk-msdc.0/by-name/boot:5370112:c2c686ada1b194050a3c8f05e2102345df48e9ce EMMC:/dev/block/platform/mtk-msdc.0/by-name/recovery 6d9d1bbc4172c107db3228ed8d9f97111219c617 5888256 c2c686ada1b194050a3c8f05e2102345df48e9ce:/system/recovery-from-boot.p
else
log -t recovery "Recovery image already installed"
fi
 

jmz

Inactive Recognized Developer
Sep 17, 2008
3,623
4,804
Lawton, OK
www.jmzsoft.com
Google Pixel 4a 5G
I see what you mean ... Even a partial unlock is huge step forward in terms of customization options, and the biggest deal is that now it's not too scary to screw up! Btw, in Amazon update files there is recovery-from-boot.p, is that the image we need for recovery? Or should we make a proper one via dd?


In Amazon update they seem to update recovery, but I wonder who checks for signed boot.img ? Is this part of the chipset ?
(from /recovery/etc ):
#!/system/bin/sh
if ! applypatch -c EMMC:/dev/block/platform/mtk-msdc.0/by-name/recovery:5888256:6d9d1bbc4172c107db3228ed8d9f97111219c617; then
log -t recovery "Installing new recovery image"
applypatch -b /system/etc/recovery-resource.dat EMMC:/dev/block/platform/mtk-msdc.0/by-name/boot:5370112:c2c686ada1b194050a3c8f05e2102345df48e9ce EMMC:/dev/block/platform/mtk-msdc.0/by-name/recovery 6d9d1bbc4172c107db3228ed8d9f97111219c617 5888256 c2c686ada1b194050a3c8f05e2102345df48e9ce:/system/recovery-from-boot.p
else
log -t recovery "Recovery image already installed"
fi

all devices have that in some form or another.

I would make a dd backup of the stock one before flashing.
 

bibikalka

Senior Member
May 14, 2015
1,370
1,090
just dump your current recovery.img.

dd if=/dev/block/mmcblk0p7 of=/sdcard/stockrecovery.img

Then as soon as you boot into recovery make a backup.

Is there an option in TWRP Manager to save stock recovery without any reboots? This sounds like an easy feature to add. Or is this part of "live backup" ?
 

Top Liked Posts

  • There are no posts matching your filters.
  • 9
    Team Win Recovery Project 2.x, or twrp2 for short, is a custom recovery built with ease of use and customization in mind. It’s a fully touch driven user interface – no more volume rocker or power buttons to mash. The GUI is also fully XML driven and completely theme-able. You can change just about every aspect of the look and feel.

    Phone look:


    Tablet look:


    CHANGELOG for 2.8.6.0:

    1. Fix daylight savings time rules for USA and Europe (_that)
    2. Allow mulitple overlays for popup boxes (Dees_Troy)
    3. Add pattern style password entry for decrypt (Tassadar)
    4. Keyboard improvements (_that)
    5. Update AOSP base to 5.1 (Dees_Troy)
    6. Reduce theme count to 5 and rely on scaling (Dees_Troy)
    7. Various scaling improvements (Dees_Troy)
    8. Improved handling of resources in the GUI (_that)
    9. Make scroll bar size proportional to list size (_that)
    10. Allow scoll lists to render without a header (_that)
    11. Make console scroll per pixel with kinetic scrolling (_that)
    12. Support styles in XML to reduce XML size and improve consistentcy (Dees_Troy)
    13. Various other fixes and improvements (mdmower, bigbiff, codelover, etc)

    CHANGELOG for 2.8.5.0:

    1. Scale the GUI - TWRP can read the theme's resolution and scale it up or down to fit the theme to your screen's resolution
    2. Backups can now be cancelled while the backup is in progress (does not include restore because we don't want to leave your device in a bad state)
    3. Improve thread handling and move input handling into the main rendering thread to improve stability
    4. Make MTP work even if unplugged and plugged back in
    5. Unify scrollable list code and make kinetic scrolling feel more natural
    6. Fix handling of mapped zip files for OTA updates (CM12 updater)
    7. USB keyboards should now work on all devices that support USB host mode via a USB OTG cable
    8. Other small fixes and improvements

    CHANGELOG for 2.8.4.0:

    1. Add flashing of boot and recovery images via the TWRP GUI (Find the Images button on the Install page)
    2. Fix some MTP related crashes and bugs
    3. Eliminate TWRP toggling USB IDs during boot if MTP is enabled
    4. Fix various adb sideload issues
    5. Improve threading of actions
    6. Eliminate separate thread for screen timeout
    7. Update libblkid to 2.25.0
    8. Use power button as back button on watch themes for easier navigation
    9. Add mutex locking to data manager
    10. Improve custom theme handling on encrypted devices
    11. Allow the stock theme to be offset by build flags so we can center a lower res theme on a higher res screen especially for watches with round screens

    CHANGELOG for 2.8.3.0:

    1. MTP will now tell the host PC that storage is removed instead of disabling MTP completely
    2. MTP will now report the correct max file size based on the file system in use to the host PC (may fix transfer of large files)
    3. Update and improve fix permissions and make fixing contexts optional
    4. Update SuperSU in TWRP to 2.40 and update install process
    5. Make TWRP work properly on AArch64 (Nexus 9 is now built in true 64-bit binaries and libraries)
    6. Attempt to set correct permissions and contexts on all files placed in storage so backups will show in Android
    7. Fix kernel panic during MTP start on some devices
    8. Support unicode fonts on devices with True Type Font support
    9. Fix slider value not showing sometimes (vibration settings page)
    10. Toggle MTP off during adb sideload to set correct USB IDs
    11. Reduce library requirements for 5.0 L decrypt
    12. Other minor fixes and improvements

    Note: Starting with TWRP 2.8.2.0 and higher, adb sideload uses a new sideload method originally implemented in AOSP recovery. You will need the latest adb binaries to use sideload in these newer versions of TWRP. The version required is 1.0.32. You can find the version by running "adb version" on your computer. The new sideload feature no longer stores the zip on your device. Instead, a fuse file system is created in RAM and the zip is streamed from your computer. This puts less wear and tear on storage and ensures that large zips will not fill up all of your RAM. The sideload may spit an error on your PC side, but the zip should install just fine on your device.
    5
    Everything seems to be working. No known issues. USB-OTG works also

    Downloadhttps://www.androidfilehost.com/?fid=24052804347756852

    or use our TWRP Manager software to install it automatically for you



    Install either by DD or maybe flashify will work for you.

    Code:
    dd if=recovery.img of=/dev/block/mmcblk0p7

    Thanks goes to @Dees_Troy as this was my first MediaTek based device to build recovery for

    This will also be taken official this week.
    1
    Pulled download temporarily
    1
    Will flashing the SuperSU package in recovery root, or cause a bootloop?

    Dont need to flash anything with TWRP. If you boot twrp then choose reboot to system option it will ask if you want to install SuperSU.
    1
    I made some progress on how to modify the update files from Amazon in order not to ruin the TWRP, will try to get a few clarifications from the HDX thread:
    http://forum.xda-developers.com/showpost.php?p=61244948&postcount=51

    But I am thinking that we can get a slightly stripped down Amazon update, and then apply GAPPS via TWRP, and other good things.

    While working on this, I found some tasty lines in tz.img (TEE1) and lk.bin (UBOOT) from the update bin:

    $strings tz.img
    ...
    [%s] This is a production device.
    [%s] Device Unlocked!!! Skip LK verification.
    [%s] Verifying LK...
    [%s] fail to verify Second Bootloader.
    [%s] This is an Engineering device.
    [%s] User build Unlocked!!! Skip LK verification.
    ...

    $strings lk.bin
    ...
    Device or user build unlocked, or non user build on engineering device! Skip kernel verification.
    %s androidboot.unlocked_kernel=true
    Verifying kernel with engineering key...
    Verifying kernel...
    %s androidboot.unlocked_kernel=false
    ...

    Anyway, I have no idea if such info can be of any use.

    With 20.4.5.1 update out there, we can go back in time to the buggiest versions of UBOOT and TEE1, which should hopefully increase options for successfully booting a custom kernel.