Open Recovery works on 2.51 rom "How to" added

walter79

Recognized Developer
Dec 18, 2006
4,100
4,618
263
Walter how did you install the recovery? There's an app that does it, or you just copied manually to some partition? I can try to compile from source too, but I need to know that first.
i install recovery by using install instrution from modmymobile forum. first link on my first post. adb shell and install script was used. reboot to recovery via adb shell. read instruction for milestone xt720 on modmymobile. it does not overwrite tenfars recovery.

later i can write a how to.
 

Sqoerk

Senior Member
Jun 2, 2009
342
120
0
A workmate and I had a look at compiling open recovery. Right now we are not able to find a solution. My workmate found a guy who compiled the open recovery directly on his phone. But this won't work with our defy's. Somewhere I read that you have to compile it with the NDK, but my workmate tryed without success. Sorry guys, probably we have to speak to the releaser of open recovery to get it working :(
 

chaihg

Senior Member
Nov 15, 2010
497
53
0
I am sure Tenfar will be able to help us with this key mapping problem.
TENFAR are u reading this. Can you please help us with this recovery too :)

Edit: Just PMed Tenfar. Lets wish he responds.
 
Last edited:

tenfar

Retired Recognized Developer
Jul 16, 2007
299
717
0
33
Beijing
www.tenfar.com
I am sure Tenfar will be able to help us with this key mapping problem.
TENFAR are u reading this. Can you please help us with this recovery too :)

Edit: Just PMed Tenfar. Lets wish he responds.
Hi, The Power key's keycode for defy is KEY_END

Code:
int device_handle_key(int key_code, int visible) {
    if (visible) {
        switch (key_code) {
            case KEY_DOWN:
            case KEY_VOLUMEDOWN:
                return HIGHLIGHT_DOWN;

            case KEY_UP:
            case KEY_VOLUMEUP:
                return HIGHLIGHT_UP;

            case KEY_CENTER:
            case KEY_CAMERA:
            case KEY_ENTER:
            [COLOR="Red"]case KEY_END:   //just add this to here, then recompile the open recovery the power key will be functional.[/COLOR]
                return SELECT_ITEM;
        }
    }

    return NO_ACTION;
}
 
Last edited:

edition-

Senior Member
Dec 25, 2010
584
93
0
Lisbon
Hi, The keycode for defy is KEY_END

Code:
int device_handle_key(int key_code, int visible) {
    if (visible) {
        switch (key_code) {
            case KEY_DOWN:
            case KEY_VOLUMEDOWN:
                return HIGHLIGHT_DOWN;

            case KEY_UP:
            case KEY_VOLUMEUP:
                return HIGHLIGHT_UP;

            case KEY_CENTER:
            case KEY_CAMERA:
            case KEY_ENTER:
            [COLOR="Red"]case KEY_END:   //just add this to here, then recompile the open recovery the power key will be functional.[/COLOR]
                return SELECT_ITEM;
        }
    }

    return NO_ACTION;
}
Thanks mate, but which is the file that we need to change?
 

Sqoerk

Senior Member
Jun 2, 2009
342
120
0
I think the problem is NOT to find the key. The problem is to compile the whole thing... ;)

So tenfar, if you can give a hint, I'll try :D
 

chaihg

Senior Member
Nov 15, 2010
497
53
0
THANKS TENFAR. That was good response from you. I am ready to test, but will need a protocol.

Sent from my ME525 using XDA App
 

Dexter_nlb

Senior Member
Feb 12, 2009
5,459
4,549
0
Copenhagen
My biggest problem is since i update to 2.51. i can`t use system dumps to build new roms. With 2.21. and 2.34. it was no problem to build a small update.zip with system dump and it boots. But since 2.51. it doesn`t work any more.
can you explain this to me, i thought update.zip's with original recovery needed to be moto signed?

but anyways,
with the knowledge of how openrecovery worked on milestone, it might just be you guys can easily downgrade your 2.51 kernels with a simple "cat"?

the problem so far, seems no recovery utilize the dump of mmcblock's on DEFY, but it work with it on Folio100, and i think did pretty the same om my milestone sometimes..

so idea is:
extract the CG35 and CG47 partitions of your SBF files (only experienced users i guess) ..
the mmcblk1 partition table looks like this on DEFY

mmcblk1:
p1(mbmloader),
p2(mbm),
p3(mbmbackup),
p4(ebr),
p5(bploader),
p6(cdt.bin),
p7(pds),
p8(lbl),
p9(lbl_backup),
p10(logo.bin),
p11(sp),
p12(devtree),
p13(devtree_backup),
p14(bpsw),
p15(boot),
p16(recovery),
p17(cdrom),
p18(misc),
p19(cid),
p20(kpanic),
p21(system),
p22(prek),
p23(pkbackup),
p24(cache),
p25(userdata)

CG35 is equal to the /dev/block/mmcblk1p15
CG47 is equal to the /dev/block/mmcblk1p16

so a simple
cat /sdcard/CG35.img >/dev/block/mmcblk1p15
should download your kernel for root
and
cat /sdcard/CG47.img >/dev/block/mmcblk1p16
will downgrade your recovery kernel image.

and so you got a easy 2.x downgrade?
of course not tested, but it worked on milestone?
 
  • Like
Reactions: ellendel