Related
alrighty, basically im lazy and want someone else to do this for me.
heres my idea:
you install rc33 or whatever you want, make a nandroid backup of it, rename the folder to OS1. this folder contains your boot.img data.img and so on
then install or place a nandroid backup of another build into a folder called OS2..
then you would be able to boot into the modified recovery mode, which would have the selection to run a script, which then asks which OS to flash, 1 or 2, you press 1 or 2 wait for it to flash and reboot, a little hacky way to get a dual boot...
now who wants to repack a recovery image for me?
good idea would be worth a try , too bad im not up to par for the job , but id like to see it done
i'll give this a shot tomorrow and see what happens, not really feeling like doing it now. and i'm not gonna do it via rebuilding the recovery.img, just gonna make a script that does it for me from the recovery terminal. i'm quite lazy as well and i already have a script that runs the fastboot commands from my computer script to flash from one build to another, in theory it shouldn't be too hard to get the script terminal reaady and do that.
tubaking182 said:
i'll give this a shot tomorrow and see what happens, not really feeling like doing it now. and i'm not gonna do it via rebuilding the recovery.img, just gonna make a script that does it for me from the recovery terminal. i'm quite lazy as well and i already have a script that runs the fastboot commands from my computer script to flash from one build to another, in theory it shouldn't be too hard to get the script terminal reaady and do that.
Click to expand...
Click to collapse
I have a .bat file that I use to flash back and forth from Windows.
To RC33
cd C:\Android\
@echo off
echo :::Instructions:::
echo You must have:
echo system.img
echo data.img
echo boot.img
echo installed in the "C:\Android" directory
echo then enable fastboot on device before proceeding
pause
fastboot flash system system.img
fastboot flash userdata data.img
fastboot flash boot boot.img
fastboot reboot
Click to expand...
Click to collapse
To 502H
cd C:\Android\502H\
@echo off
echo :::Instructions:::
echo You must have:
echo system.img
echo data.img
echo boot.img
echo installed in the "C:\Android\502H" directory
echo then enable fastboot on device before proceeding
pause
fastboot flash system system.img
fastboot flash userdata data.img
fastboot flash boot boot.img
fastboot reboot
Click to expand...
Click to collapse
Pretty simple. I have them stored to my desktop. I save my nandroid backups to the appropriate file and just double click. No problem. I just wish there was a script that I can use to reboot into HARDSPL mode (someone tell me if there is).
keatonreckard:
This is the worst idea i've heard so far...
FLASH has a limited life-time, and rewriting the whole system at every boot is a BAD idea.
If you want to dual-boot, you should look into making your own init-system, adding the ability to load another system (From SD).
Binary100100:
"adb reboot bootloader"
there might be a simpler way: change the kernel command so it mounts somewhere in sdcard as root. not sure how to do this without a computer though.
Hey binary, with your phone plugged into your comp pull up you cmd and type adb shell reboot bootloader, the phone will boot right into fastboot mode making it easy to continue the script
just to clarify...i meant a script that is store locally on the device in the recovery image... so then you dont need a computer at all... you can already do this, you just have to type in the commands from the recovery console...i just wanted an easier way to do it
Binary100100 said:
I have a .bat file that I use to flash back and forth from Windows.
To RC33
To 502H
Pretty simple. I have them stored to my desktop. I save my nandroid backups to the appropriate file and just double click. No problem. I just wish there was a script that I can use to reboot into HARDSPL mode (someone tell me if there is).
Click to expand...
Click to collapse
To flash back and forth from windows? You've been running Windows Mobile on the Dream? I must be missing something.
Joushou said:
keatonreckard:
This is the worst idea i've heard so far...
FLASH has a limited life-time, and rewriting the whole system at every boot is a BAD idea.
If you want to dual-boot, you should look into making your own init-system, adding the ability to load another system (From SD).
Binary100100:
"adb reboot bootloader"
Click to expand...
Click to collapse
not flash at every boot...just so you can text out a build and if you dont like it go back to a stable one on the go....
again, im taking the lazy way out
Disregard! - My mind ran ahead of what this post was about and I posted something regarding a slightly different idea!
I don't know about re-installing Nandroid backups...
But, if one wanted to be able to run two different installs...
Seems to me an easier way about doing this would be to have a modified SPL. It could have the option of selecting an update file...
For example, one could put two files on their sd card - update1.zip and update2.zip. The SPL could have one of the following options:
1) reboot into recovery mode - select "alt-s" - then you would have an option to select 1 or 2.
2) have an additional "Alt- " option.
"Alt-s" - runs update1.zip
"Alt-?" - runs update2.zip. (dev could pick the additional letter)
I think this would be great! No reteaching of anyone how to use the process. And, one could leave the primary use-able update.zip as "update1.zip" and use the other as the version being tried out. It wouldn't be a Nandroid back up... But, with the new "nowipe" builds it should work well.
My $.02 worth.
Joushou said:
keatonreckard:
This is the worst idea i've heard so far...
FLASH has a limited life-time, and rewriting the whole system at every boot is a BAD idea.
If you want to dual-boot, you should look into making your own init-system, adding the ability to load another system (From SD).
Binary100100:
"adb reboot bootloader"
Click to expand...
Click to collapse
To be fair, that limited life-time is something like 1,000,000 writes, which would take about... oh... a year straight of constantly rebooting your phone(assuming it takes 30 seconds per reboot)
EDIT: and that assumes re-writing the whole system every time you boot, which I don't think he means since he's saying its in the recovery image.
hmmm....
I know that from the alt+x console you can do this....
mount sdcard
echo "boot-recovery
--update_package=SDCARD:build1/update.zip" > /cache/recovery/command
reboot recovery
so if you wanted 2 builds available (I would think you would need a wipe for 2 completely different builds) but....
make 2 folders in on your sdcard
build1
build2
place a copy of the update.zip from each build you want to boot in the folder
make a script like this
Code:
echo "boot-recovery
--update_package=SDCARD:"$"/update.zip" > /cache/recovery/command
reboot recovery
save the script to the sdcard directory
then when you start your phone you could
1. type "mount sdcard" (no quotes)
2. type "sh sdcard/script.sh build1" (for build 1 located in /sdcard/build1/update.zip)
3. type "sh sdcard/script.sh build2" (for build 2 located in /sdcard/build2/update.zip)
problem would be when wipes are needed. But if you have 2 solid builds and don't need to wipe when swapping it should work.
Just need a way to make a script or bootloader that could run either one of these.
Cannot see another way around it since the OS is loaded into phone ROM/RAM
of course if your build supports the reboot command from the OS then you could just make a script to run when you want to reload the other build. Then you could skip the recovery console.
@beagz - Ha, forgot about that script. Yes, to switch between say, the DudesG build and Haykuro's H build one could write a script like that in Gscript and change back and forth when a new build comes out.
Like now... One could run Dudes G build and try out Haykuro's new ADP1.5 build.
But, I do believe your right about going back to a JF33 build - would need to wipe...
Gimpeh said:
To flash back and forth from windows? You've been running Windows Mobile on the Dream? I must be missing something.
Click to expand...
Click to collapse
Nah.. I was referring to using a bat file on my Windows computer to switch between 1.1 to 1.5 back to 1.1 by just executing the bat.
Now that i know that "adb reboot bootloader" will work it can be completely automated!
... but will it default to fastboot? Hmmm...
tubaking182 said:
Hey binary, with your phone plugged into your comp pull up you cmd and type adb shell reboot bootloader, the phone will boot right into fastboot mode making it easy to continue the script
Click to expand...
Click to collapse
Thanks! But is this going to put the phone in FASTBOOT mode? I'm trying to make this completely automatic if it's possible. Simply keep your latest and greatest backup .img's in a certain directory on your computer and EXECUTE!
Take a shower or whatever... come back and VOILA! Your previous backup.
The method that I've come up with thus far is pretty simple... but you just can't execute and walk away. You still need to enable FASTBOOT at the least on the bootloader. Although I haven't tried messing with it lately. I have my phone just like I want it.
Now that the Official ADP1.5 is out let's get to work on Mulitouch, themes, etc!
Wow this seems crazy but it just might work. Lol.
bat file to automatically restore backups using Windows!
So all you need to do is...
Open notepad, copy and paste the quoted text below, edit the top line of this bat file to the directory of your backups (I used "c:\android" for an example), save as .bat and double click. Wait and your done. Just watch it happen automatically.
Also if you decide to change that directory on the top line also use the directory on the 14th line. Your done. Easy restore to a backup.
HINT! Make a couple of these with a variety of directories on the top to change what backup your want to flash back to.
Example: c:\android\rc33; c:\android\501h; c:\android\adp15; etc
cd C:\android
color A
cls
@echo off
echo.
echo :::Instructions:::
echo.
echo You must have:
echo.
echo system.img
echo data.img
echo boot.img
echo.
echo installed in the "c:\android" directory
echo.
pause
cls
color b
echo.
echo.
echo.
echo Now restoring:
echo.
echo system.img
echo data.img
echo boot.img
echo.
echo to your device.
color c
echo.
echo DO NOT TURN OFF OR UNPLUG YOUR DEVICE DURING THIS PROCESS!!!
@adb shell reboot bootloader
@fastboot flash system system.img
@fastboot flash userdata data.img
@fastboot flash boot boot.img
@fastboot reboot
Click to expand...
Click to collapse
I've tested it and it works beautifully!
Hope it helps!
Thanks to everyone that pointed out the command "adb shell reboot bootloader"
This post is noob friendly.
OR
Use this script below for it to prompt for the location of your backups.
color A
cls
@echo off
echo.
echo :::Instructions:::
echo.
echo Enter directory of nandroid backups that you would like to restore...
set /p flash=path:
cd %flash%
cls
color b
echo.
echo.
echo.
echo Now restoring:
echo.
echo system.img
echo data.img
echo boot.img
echo.
echo to your device.
color c
echo.
echo DO NOT TURN OFF OR UNPLUG YOUR DEVICE DURING THIS PROCESS!!!
@adb shell reboot bootloader
@fastboot flash system system.img
@fastboot flash userdata data.img
@fastboot flash boot boot.img
@fastboot reboot
Click to expand...
Click to collapse
This one is even more noob friendly... but it's not as fast because it requires you to enter the location of your backups.
I hope it helps someone out there. It helps me.
[email protected]:
The average lifetime of flash is 100.000 writes, and flash isn't delivered 100% intact, they're usually delivered with faulty blocks (Depending on where you get it, blah blah blah).
That should change your numbers a bit (A month i believe?)
And, sure, he is using the update-zip, so it's not written to the same pages every time.
But still, it's a bad idea (Other than wearing stuff down, it will also be very slow ).
To dual-boot, modifying the init-system so it could choose from different android-runtimes would be way faster/cooler...
If possible, this would be pretty damn useful. Using a stable build while being able to tinker with experimental builds. Would definitly cut down on the constant flashing back and forth.
It's been a long time since the last time I made a bat file and it seems I can't remember how to exactly make one xD... I'm kind of tired of having to put the commands to change the radio, spl and recovery every time, so I've decided to make a simple bat file to be able to choose what files to install if files 1 or 2 (1 being old radio, spl, recovery, and 2 being the new)...
Here is what I got so far xD...
Code:
@echo off
cls
:start
echo.
echo 1. Press 1 to install old files
echo 2. Press 2 to install new files
set choice=
set /p choice=Press 1 or 2 to continue
<--- This section is for option 1 --->(this lines are just to show what option is each)
C:\Android\fastboot flash radio Radio1.img
C:\Android\fastboot flash hboot hboot1.img
C:\Android\fastboot flash recovery recovery1.img
C:\Android\fastboot erase system -w
C:\Android\fastboot reboot-bootloader
<--- End sextion 1 --->
<--- This section is for option 2 --->
C:\Android\fastboot flash radio Radio2.img
C:\Android\fastboot flash hboot hboot2.img
C:\Android\fastboot flash recovery recovery2.img
C:\Android\fastboot erase system -w
C:\Android\fastboot reboot-bootloader
<--- End section 2 --->
fin:
I hope anybody can give me a hand into this =P... I've forgot almost everything in creating this kind of files xD... I know I can make 2 different batch files for the diferents files, but is more commfortable to have everything in just 1 file...
Thanks in advance
YEah..... Not sure how much you want to mess with automated Radio/spl installing. those are the 2 most dangerous parts and what happens if you get an error mid way through?
Be careful
crypysmoker said:
YEah..... Not sure how much you want to mess with automated Radio/spl installing. those are the 2 most dangerous parts and what happens if you get an error mid way through?
Be careful
Click to expand...
Click to collapse
That's why I'm including a "press a key to continue" after each part ...
The only problem so far, wast test the script and forgot to make a nandroid backup xD...
I think this is what you want:
Code:
@echo off
:start
cls
echo 1. Press 1 to install old files
echo 2. Press 2 to install new files
set /p choice=Press 1 or 2 to continue:
if %choice%==1 goto choice1
if %choice%==2 goto choice2
:choice1
echo Choice1 command should go here
set /p anykey=Command complete, press any key to continue...
exit
:choice2
echo Choice2 command should go here
set /p anykey=Command complete, press any key to continue...
exit
Reference:http://en.wikipedia.org/wiki/Batch_file
Thanks, I've already got a functional batch file...
Now I'm gonna port it to C or something to get a program that works for everybody, that way it would be easier to change the radios and stuff...
okay so im creating a batch file for a little automation just mainly for rebooting the device into bootloader/recovery.. i have gotten most of the way through but at the end i would like for the batch file to stop and allow for further manual input (like i have it set to reboot the device into bootloader and then i would like the window to stop and allow me to MANUALLY input the next command such as flash/reboot/whatever) however i cant seem to find any way of doing that
HERE IS WHAT I HAVE CURRENTLY
it all works perfectly just for the issue i cant seem to work out
ECHO OFF
ECHO ============== CHANING DIRECTORY ==============
CD c:\program files (x86)\android\android-sdk\tools
TIMEOUT 2 /NOBREAK >nul
ECHO ........ Done
ECHO ============== CHECKING ADB DEVICE CONNECTION ==============
TIMEOUT 2 /NOBREAK >nul
adb devices
ECHO ........ Done
PAUSE
:MENU
ECHO.
ECHO ================== ADB MENU ==================
ECHO PRESS 1 or 2 to select your task, or 3 to EXIT.
ECHO.
ECHO 1 - Reboot Device into Bootloader [FASTBOOT]
ECHO 2 - Reboot Device into Recovery [CLOCKWORK MOD]
ECHO 3 - EXIT
ECHO.
SET /P M=Type 1, 2, or 3, then press ENTER:
IF %M%==1 GOTO BOOTLOADER
IF %M%==2 GOTO RECOVERY
IF %M%==3 GOTO EOF
:BOOTLOADER
adb reboot bootloader
GOTO FASTBOOT
:RECOVERY
adb reboot recovery
GOTO RECOVERY
:FASTBOOT
ECHO .
ECHO Waiting for device to reconnect
TIMEOUT 15 /NOBREAK >nul
ECHO ........ Done
ECHO ================== FASTBOOT ==================
ECHO manually type fastboot commands
:RECOVERY
ECHO .
ECHO Waiting for device to reconnect
TIMEOUT 15 /NOBREAK >nul
ECHO ........ Done
ECHO ================== RECOVERY ==================
ECHO Manually handle Clockwork Recovery tasks
ECHO .
ECHO .
ECHO Will automatically close in about 5 Seconds =]
TIMEOUT 5 /NOBREAK >nul
ECHO ....... bye!
I am not sur to understand exactly what you want to do, but you can do what you want in you batch file, it is what you did with for exemple :
- "Reboot Device into Bootloader [FASTBOOT]"
- "Reboot Device into Recovery [CLOCKWORK MOD]"
You have just check the choice with a number and after execute your "code".
So, if you know the "adb script" in addiction of the command you want, go to "code" it.
I remake your script and i especially add an exemple.
- "Execution" and "Code" are more clear.
- It is better for checking error.
- Now, this script is able to check if you are in "64bit" or "32bit", and check if the "ADB Tool" is in his correct way.
- Now, this script is able to check if you have connect or not your device.
- You can see the BootAnimation without "Power OFF" and then "Power ON" your phone.
- It is more beautiful, even if it is not very important.
The new "code", with your previous "started code" :
Code:
Even this topic is solved, i remove my code.
cheers for the reply.. but that was not really what i was after... i did some more googling and what i found was (in the last 2 minutes) that i needed a CMD /K at the end of the file.. which leaves the command window open and i can now enter in fastboot commands manually (for flashing etc)... i have attached the file as a.txt for anyone to use themselves if they were so inclined..
1. just make sure the directory of your adb/fastboot.exe is in the same directory as mine (CD c:\program files (x86)\android\android-sdk\tools) and change the 2 lines if necessary with note pad by opening the .txt normally as yours might be in program files or in platform-tools not tools, etc
2. change the extension to .bat and not .txt
3. chuck it in your task bar/start bar etc for quicker acess
and should be good to go =]
edit: i see the checking that the other fellow put it can do the checking for you.. but for me i knew the directory, etc
So, i did not exaclty understand your aim, but you have found it, so it is perfect.
I remake my previous script to do exactly what you want, and i always check every thing during the execution, to know the mistake when we have a problem. Because my version is for everybody, even if i think it is just for us. (Views: 45)
So if you want it, or someone else, just ask me.
ptit developer said:
So, i did not exaclty understand your aim, but you have found it, so it is perfect.
I remake my previous script to do exactly what you want, and i always check every thing during the execution, to know the mistake when we have a problem. Because my version is for everybody, even if i think it is just for us. (Views: 45)
So if you want it, or someone else, just ask me.
Click to expand...
Click to collapse
no worries mate it was my first time writing an entire script so im pretty stoked with the outcome i tried to keep it looking as real as scripts i have seen as possible.. =]
I will continue to develop this idea : "A easy way to use ADB Menu".
When i will have finish, if you want i will post a link here to it.
ptit developer said:
I will continue to develop this idea : "A esay way to use ADB Menu".
When i will have finish, if you want i will post a link here to it.
Click to expand...
Click to collapse
sure mate.. ill edit the op if you like and can sort something out?
i think the simpler nature allows for much to be automated for mundane tasks... as long as you keep the fastboot commands manual so noobs dont do anything incorrect
I will use what you want, and i will add what i post in my first answer here.
In addition of this, i will post the final "A easy way to use ADB Menu" on a new topic on other section.
And i will post news here, because i think you will look it.
UPDATE: First of all, thanks to everyone that responded. You guys are awesome! I'm returning the phone to HTC and hopefully it gets fixed. I do believe its hardware related but I think the real answer is way over my head.
I'm not really sure whats going on here, but the only ROM I can use / flash is Cyanogen. I was running trickdroid and then the phone decided to freeze and just reboot whenever I tried to launch anything. I cant use my nand from stock, install any sense, aokp or miui ROM. They install and even boot, but then it just freezes and reboots as soon as I unlock the lock screen. I even went as far as returning it back to stock with the RUU, but same scenario. I'm completely stumped. Anyone have anything to suggest? Thanks.
You flashed with a fullwipe and boot.img?
I did, multiple times. I typically do a factory reset, wipe cache, format data, format system, format dalvik then install the ROM. Once the ROM is installed, I then reboot back into fastboot and flash the boot.img. Just to add a little more, your ROM rocks man and I really want to go back to using it. The reason why I had to flash the boot by fastboot is because when I used your script it kept telling me permission denied on certain lines.
Bump
try to flash any sense rom, Format /system in recovery before flashing. Then run an RUU
An RUU wont run unless you have a sense ROM already, So dont worry if the phone dont boot, Aslong as the rom flashes, the RUU should work.
Then just start from the beginning.
Oh and RUU requires RELOCKED bootloader and in some cases Stock recovery
azzledazzle said:
try to flash any sense rom, Format /system in recovery before flashing. Then run an RUU
An RUU wont run unless you have a sense ROM already, So dont worry if the phone dont boot, Aslong as the rom flashes, the RUU should work.
Then just start from the beginning.
Oh and RUU requires RELOCKED bootloader and in some cases Stock recovery
Click to expand...
Click to collapse
I tried this and it didn't work. As soon as i unlock the lock screen it just freezes and reboots. So confused....
dubntz said:
I tried this and it didn't work. As soon as i unlock the lock screen it just freezes and reboots. So confused....
Click to expand...
Click to collapse
Yes but dont worry about that, The RUU should still work even with the phone freezing. You just need the Sense ROM on the phone, Whether it boots or not.
azzledazzle said:
Yes but dont worry about that, The RUU should still work even with the phone freezing. You just need the Sense ROM on the phone, Whether it boots or not.
Click to expand...
Click to collapse
Sorry, but what I meant to say is that I put a sense ROM back on, ran the RUU and it still froze once i tried to unlock the lock screen.
dubntz said:
Sorry, but what I meant to say is that I put a sense ROM back on, ran the RUU and it still froze once i tried to unlock the lock screen.
Click to expand...
Click to collapse
Oh i see... That is so weird
Have you asked in the Cyanogen thread ? The ROM must have altered something deep inside for something like this to happen...
Ive never seen anything like it
azzledazzle said:
Oh i see... That is so weird
Have you asked in the Cyanogen thread ? The ROM must have altered something deep inside for something like this to happen...
Ive never seen anything like it
Click to expand...
Click to collapse
I have not posted anything, although i'm going to now. It is so weird. I can install any sense ROM, but it freezes when I try to unlock the lock screen. I can not install AOKP or MIUI as they just boot loop. Cyanogen is the only ROM that I can flash...lol
dubntz said:
I have not posted anything, although i'm going to now. It is so weird. I can install any sense ROM, but it freezes when I try to unlock the lock screen. I can not install AOKP or MIUI as they just boot loop. Cyanogen is the only ROM that I can flash...lol
Click to expand...
Click to collapse
Have you tried taking out your sim card and rebooting? My phone kept freezing as soon as I unlocked the lockscreen and this is what worked for me...
I have, but no luck.
Sent from my HTC One S using Tapatalk 2
I feel like the phone is not properly wiping or installing the boot.img correctly. I have been trying different things for days. Just doesn't make sense. No pun intended..ha
Just some more experimenting. I tried to use a script from the trickdroid ROM to flash to boot and It came back with some permission denied errors. I'm wondering if that has something to do with it. I don't get any errors like that when I install it through fastboot though...
I'm beginning to think it has something to do with the boot.img not flashing properly. I think there might be some permission issues going on with the phone. I just tried to flash the latest CM nightly with the new boot and it just boot loops.
do you have an sdcard bu
you could try formatting and reloading the card, assume you can get to recovery
also, i fastbooted boot img before flashing rom, one right after the other. thought you said you flashed rom rebooted then flashed boot img, not sure if that matters
good you are wiping system also, or that can cause issues too
rugmankc said:
do you have an sdcard bu
you could try formatting and reloading the card, assume you can get to recovery
also, i fastbooted boot img before flashing rom, one right after the other. thought you said you flashed rom rebooted then flashed boot img, not sure if that matters
good you are wiping system also, or that can cause issues too
Click to expand...
Click to collapse
The ONES has an internal SD Card only so I cant remove it; however, I have formatted it and still the same results. I'm thinking I can't install any ROM that requires a new boot.img. Is something not mounting properly?
dubntz said:
Just some more experimenting. I tried to use a script from the trickdroid ROM to flash to boot and It came back with some permission denied errors. I'm wondering if that has something to do with it. I don't get any errors like that when I install it through fastboot though...
Click to expand...
Click to collapse
This script youre running, is it the one linked from the Trickdroid 4.3 thread, from http://d-h.st/2JV ?
If so check below where it tries to chmod +x fastboot-linux comes before the script cd's to the files directory where fastboot-linux actually lives. So fastboot-linux never gets execute permissions and therefore everything except the echo stuff fails.
Code:
@echo off
chmod +x fastboot-linux
echo "Flashin boot.img"
sleep 1
echo ...
cd files
./fastboot-linux flash boot ../boot.img
echo ...
echo "Flashing complete"
echo ...
echo "Erasing cache partition"
sleep 1
./fastboot-linux erase cache
echo ...
echo "Cache partition cleaned"
echo ...
echo "If there were no errors, you can continue"
echo ...
echo "If not, try again!"
echo ...
echo "Enjoy TrickDroid!"
sleep 20
To make it work edit it like this (move the cd files) or go into files and run chmod +x fastboot-linux before running the script. The Mac script has the same problem.
Code:
@echo off
cd files
chmod +x fastboot-linux
echo "Flashin boot.img"
sleep 1
echo ...
./fastboot-linux flash boot ../boot.img
echo ...
echo "Flashing complete"
echo ...
echo "Erasing cache partition"
sleep 1
./fastboot-linux erase cache
echo ...
echo "Cache partition cleaned"
echo ...
echo "If there were no errors, you can continue"
echo ...
echo "If not, try again!"
echo ...
echo "Enjoy TrickDroid!"
sleep 20
Dunno if this will help your general situation though, good luck!
frdd said:
This script youre running, is it the one linked from the Trickdroid 4.3 thread, from http://d-h.st/2JV ?
If so check below where it tries to chmod +x fastboot-linux comes before the script cd's to the files directory where fastboot-linux actually lives. So fastboot-linux never gets execute permissions and therefore everything except the echo stuff fails.
Code:
@echo off
chmod +x fastboot-linux
echo "Flashin boot.img"
sleep 1
echo ...
cd files
./fastboot-linux flash boot ../boot.img
echo ...
echo "Flashing complete"
echo ...
echo "Erasing cache partition"
sleep 1
./fastboot-linux erase cache
echo ...
echo "Cache partition cleaned"
echo ...
echo "If there were no errors, you can continue"
echo ...
echo "If not, try again!"
echo ...
echo "Enjoy TrickDroid!"
sleep 20
To make it work edit it like this (move the cd files) or go into files and run chmod +x fastboot-linux before running the script. The Mac script has the same problem.
Code:
@echo off
cd files
chmod +x fastboot-linux
echo "Flashin boot.img"
sleep 1
echo ...
./fastboot-linux flash boot ../boot.img
echo ...
echo "Flashing complete"
echo ...
echo "Erasing cache partition"
sleep 1
./fastboot-linux erase cache
echo ...
echo "Cache partition cleaned"
echo ...
echo "If there were no errors, you can continue"
echo ...
echo "If not, try again!"
echo ...
echo "Enjoy TrickDroid!"
sleep 20
Dunno if this will help your general situation though, good luck!
Click to expand...
Click to collapse
It flashed the boot with no issues this time. Still not able to use another ROM. Its so odd. They install but as soon as I unlock the lock screen it just freezes and reboots.
assume you are using the latest clockworkmod recovery for the "OneS"
checked all md5's before flashing anything
can you take the system and boot images from a good sense nandroid or sense rom and put them on your pc in your fastboot.exe folder, open command window cd to fasboot.exe folder and adb reboot bootloader to get into fastboot
then run these commands 3 times
fastboot -w
fastboot erase system
fastboot erase cache
fastboot erase boot
fastboot flash system system.img
fastboot flash boot boot.img
fastboot reboot
you will have restore any user data manully
if you don't have a nandroid copied to you pc from phone do that first
It sounds like maybe you have not wiped everything from cm rom from phone, erasing multiple times may help
I get to unlock the bootloader of my kindle hdx 8.9
Prerequisite:
- Bootloader shipped with firmwareversion 1[34].3.1.0 <= x <= 1[34].3.2.4 (as we use the rsa bug)
- Rooted kindle
adb shell
cat /sys/block/mmcblk0/device/manfid
cat /sys/block/mmcblk0/device/serial
create a file unlock.img with following content:
0xmmssssssss
where mm=manfid and ss=serial
encrypt it with my vortox fork of signing tool at
https://github.com/dpeddi/Cuber
./cuber_unlockbl --sign ./unlock.img ./unlock.signed
connect the hdx to a linux box and do following command:
./fastboot -i 0x1949 devices
./fastboot -i 0x1949 flash unlock unlock.signed
./fastboot -i 0x1949 reboot
adb shell
idme print
[...]
unlock_code: AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMsv9S[...]WRUFx7FaA==
to get into fastboot mode you can press:
standby volume+ volume- at the same time and keep pressed
follows list of fastboot command:
fastboot -i 0x1949 getvar product
fastboot -i 0x1949 getvar version
fastboot -i 0x1949 getvar kernel
fastboot -i 0x1949 getvar serialno
fastboot -i 0x1949 getvar production
fastboot -i 0x1949 getvar partition-size:userdata|sytem|cache
fastboot -i 0x1949 getvar partition-type:userdata|sytem|cache
fastboot -i 0x1949 getvar max-download-size
fastboot -i 0x1949 boot (still untested by me)
fastboot -i 0x1949 verify (still untested by me)
fastboot -i 0x1949 flash (still untested by me)
fastboot -i 0x1949 erase (still untested by me)
fastboot -i 0x1949 continue
fastboot -i 0x1949 reboot
fastboot -i 0x1949 reboot-bootloader
fastboot -i 0x1949 oem device-info
fastboot -i 0x1949 oem idme ? (only if unlocked)
fastboot -i 0x1949 oem idme cl3an (untested by me but is destructive!)
fastboot -i 0x1949 oem idme v3rsion (untested by me but seems destructive!)
fastboot -i 0x1949 oem relock (i'm lazy to test it)
fastboot -i 0x1949 dump (don't work with current windows implementation of fastboot that i'm using now - try this)
you can use python only tool too :
http://forum.xda-developers.com/kin...tools-create-unlock-img-fix-boot-img-t3050689
http://forum.xda-developers.com/kin...e-software-t3030281/post58897784#post58897784
Regards and thank to all (ralekdev, jcase, Hashcode, Cpasjuste, Vortox, draxie...)
Congratulations! This is a huge breakthrough. Perhaps this will finally attract the developers these devices deserve.
Just to let you know, there are some errors upon compilation:
Code:
g++ -Wall -Wextra -Wno-unused-result -march=native -O2 -Iinclude cuber.cpp -o cuber -lcrypto
g++ -Wall -Wextra -Wno-unused-result -march=native -O2 -Iinclude cuber_unlockbl.cpp -o cuber_unlockbl -lcrypto
cuber_unlockbl.cpp:204:2: warning: "/*" within comment [-Wcomment]
/*
^
cuber_unlockbl.cpp: In function ‘int sign_image(char*, char*)’:
cuber_unlockbl.cpp:194:11: warning: variable ‘imagesize_actual’ set but not used [-Wunused-but-set-variable]
unsigned imagesize_actual;
^
cuber_unlockbl.cpp:250:16: warning: unused variable ‘hash’ [-Wunused-variable]
unsigned char hash[65];
^
cuber_unlockbl.cpp: At global scope:
cuber_unlockbl.cpp:322:33: warning: unused parameter ‘image_ptr’ [-Wunused-parameter]
int verify_image(unsigned char *image_ptr, unsigned char *signature_ptr, unsigned int image_size)
^
cuber_unlockbl.cpp:322:87: warning: unused parameter ‘image_size’ [-Wunused-parameter]
int verify_image(unsigned char *image_ptr, unsigned char *signature_ptr, unsigned int image_size)
^
cuber_unlockbl.cpp: In function ‘int check_image(char*)’:
cuber_unlockbl.cpp:135:64: warning: ‘imagesize_actual’ may be used uninitialized in this function [-Wmaybe-uninitialized]
verify_image(image, image + imagesize_actual, imagesize_actual);
^
Additionally, how exactly do we create the image file? (i.e. what format and all that)
This is great news! I'll take a further look tomorrow into trying this out. Getting late and time for bed.
As writtten before the unlock file is x9911223344 nothing more.
This file is encripted as well using similar method like the image files.
But is not hashed... just encripted with private key.
Image otherwise is hashed and just the hash is encripted.
I'm not interested in fixing code warning... if you want pull me the fix to github. I was interested only by unlock my device.
dpeddi said:
I get to unlock the bootloader of my kindle hdx 8.9
Prerequisite: 1[34].3.1.0 < x < 1[34].3.2.4 (as it use the rsa bug)
Rooted kindle
cat /sys/block/mmcblk0/device/manfid
cat /sys/block/mmcblk0/device/serial
create a file unlock.img with following content:
0xmmssssssss
where mm=manfid and ss=serial
encrypt it with my vortox fork of signing tool at
https://github.com/dpeddi/Cuber
./cuber_unlockbl --sign ./unlock.img ./unlock.signed
connect the hdx to a linux box and do following command:
./fastboot -i 0x1949 devices
./fastboot -i 0x1949 flash unlock unlock.signed
./fastboot -i 0x1949 reboot
adb shell
idme print
[...]
unlock_code: AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMsv9S[...]WRUFx7FaA==
Regards and thank to all (Hashcode, Cpasjuste, Vortox...)
Click to expand...
Click to collapse
Hearty congratulations @dpeddi !!!!
Can you let us know which sw ver is this applicable to ?
As amazon is again allowing the roll back process with almost no questions asked, if this implies to the downgrade they are allowing its a massive win and breakthrough in HDX DEVELOPMENT (i dont exactly remember the version they are downgrading to - its the one that has been patched with vulnerability)
Edit: its 14.3.2.8
Edit 2 : i believe the answer would be NO, just compared the version number you mentioned, can there be any possibility for 14.3.2.8 version kindles to get root or downgrade or any thing ?
To be honest it would be a shame that just on software version kindle has no future and other software versions have
Again cheers for your achievement
Should be up to 3.2.4. However wit unlocked bl.. development should be a little safer.
Inviato dal mio GT-I9505 utilizzando Tapatalk
dpeddi said:
Should be up to 3.2.4. However wit unlocked bl.. development should be a little safer.
Inviato dal mio GT-I9505 utilizzando Tapatalk
Click to expand...
Click to collapse
Yes true bit this clearly means that 14.3.2.8 will have no development right ?
Exactly. .. encrypted unlock file isn't valid with patched openssl vulnerability. However if you want you can give a try.. i've uploaded more time invalid unlock file with no issue.
I forgot to tell you that if you upgrade bootloader to newer image with fixed openssl you lost unlock.
@dpeddi
I get an error message when I sign the file
I assume that this message is not normal.
My OS is Ubuntu 14.4 x64 and my HDX Modell is Thor 32GB (Bootloaderversion 3.2.3)
./cuber_unlockbl --sign ./unlock.img ./unlock.signed
[ STATUS ] Signing image... ./unlock.img
debug: imagefilesize, :13
debug: image 0x3312345678
[ STATUS ] Checking created signature...
[ STATUS ] Checking created image...
debug: plain_text 0x3312345678
[ ERROR ] Invalid signature
Click to expand...
Click to collapse
rubinho said:
@dpeddi
I get an error message when I sign the file
I assume that this message is not normal.
My OS is Ubuntu 14.4 x64 and my HDX Modell is Thor 32GB (Bootloaderversion 3.2.3)
Click to expand...
Click to collapse
Ok I'll fix the program. However if you have a signed image not empty it should be good.
Please ignore that error...
3am work not always is without stupid warning
fixed error, pull code again. . I confirm the error is not a true error
Is this work on 14.3.1.0?I am little confused cause you said x>14.3.1.0
Sent from my MI 2C using XDA Free mobile app
mxzwhx said:
Is this work on 14.3.1.0?I am little confused cause you said x>14.3.1.0
Sent from my MI 2C using XDA Free mobile app
Click to expand...
Click to collapse
Sure, my wrong... I correct first post
Thanks ,I've noticed one of step need a Linux box,but I just have a Windows PC as I think many people just like me as well,how do we fulfill that step?
Sent from my MI 2C using XDA Free mobile app
mxzwhx said:
Thanks ,I've noticed one of step need a Linux box,but I just have a Windows PC as I think many people just like me as well,how do we fulfill that step?
Click to expand...
Click to collapse
You need linux for all steps (both fastboot and signing).
I read here (at xda) that windows fastboot can't run with Kindle hdx.
dpeddi said:
You need linux for all steps (both fastboot and signing).
I read here (at xda) that windows fastboot can't run with Kindle hdx.
Click to expand...
Click to collapse
Fastboot works fine on my Windows 8.1 x64
I use following Amazon adb/fastboot drivers.... https://mega.co.nz/#!8JtUkSyZ!UbWCYyHVlfpk51FMYzQ5wR89CLWu9gTccJFVEx0lhjI
I have the unlock procedure now been successfully completed. I think at least. (thx @dpeddi)
Do you know a command that I can query the bootloader status ? "oem unlock" does not work
with "fastboot -i 0x1949 oem device-info" comes following message ... Device tampered: false. (whatever that means)
rubinho said:
Fastboot works fine on my Windows 8.1 x64
I use following Amazon adb/fastboot drivers.... https://mega.co.nz/#!8JtUkSyZ!UbWCYyHVlfpk51FMYzQ5wR89CLWu9gTccJFVEx0lhjI
I have the unlock procedure now been successfully completed. I think at least. (thx @dpeddi)
Do you know a command that I can query the bootloader status ? "oem unlock" does not work
with "fastboot -i 0x1949 oem device-info" comes following message ... Device tampered: false. (whatever that means)
Click to expand...
Click to collapse
Look at photo attached on my first post.
You should see unlock successful. Fastballs one unlock doesn't exist on our device.
Adb shell idme print should show you if unlock is ok.
You should see unlock code set with as ascii
OK thx for the info.
The result was exactly as you described it have.
Thus my bootloader should be unlocked.
Hello,can you teach me step by step to unlock the bootloader on Windows 8.1 64bit version ?I am afriad something would go wrong if I do it myself .
Sent from my Nexus HDX 8.9 using XDA Free mobile app
---------- Post added at 02:21 PM ---------- Previous post was at 02:18 PM ----------
rubinho said:
OK thx for the info.
The result was exactly as you described it have.
Thus my bootloader should be unlocked.
Click to expand...
Click to collapse
@rubinho, is that okay ?
Sent from my Nexus HDX 8.9 using XDA Free mobile app