Go Back   Android Forums > Android Phones > HTC Desire > Desire - All Things Root

Get excited for the Samsung Galaxy S5! Find everything you need and discuss it in our Galaxy S5 Forum!

test: Reply
 
LinkBack Thread Tools
Old May 17th, 2011, 07:04 AM   #1 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default [FAQ] ADB and FASTBOOT for Windows (Updated 1st June 2011)

This is a very basic FAQ. Its not aimed at new users or advanced users explicitly. It is very much a work in progress and will need to be updated to add more information.

As I understand what I have put in this FAQ, it would be useful if you could comment on anything that is not clear or explained in this thread.

Please note, adb and fastboot are NOT the same. They are both command line tools but the similarity ends there. This FAQ contains information about both

Contents:


What is adb shell?
How do I set up my Windows PC to use adb and fastboot?
How do I get into adb shell?
How do I use adb (examples)?
What other adb examples / commands are there?
What is fastboot?
How do I use Fastboot?
Why would I flash a Hboot?
Why use fastboot to flash radio?

What is adb shell?
adb shell is a linux command line tool (because android is based on linux) used to send commands to your android device. For S-ON devices, this is crucial for modifying files in the /system partition (where the rom sits) as you cannot modify anything in /system when the rom is running without S-OFF (e.g removing system apps).

From Google:

Android Debug Bridge (adb) is a versatile tool lets you manage the state of an emulator instance or Android-powered device. It is a client-server program that includes three components:
  • A client, which runs on your development machine. You can invoke a client from a shell by issuing an adb command. Other Android tools such as the ADT plugin and DDMS also create adb clients.
  • A server, which runs as a background process on your development machine. The server manages communication between the client and the adb daemon running on an emulator or device.
  • A daemon, which runs as a background process on each emulator or device instance.

How do I set up my Windows PC to use adb and fastboot?

  • Download SDK Tools only
  • Open the .rar file, then drag and drop the folder "android-sdk-windows" to the C: drive
  • Right click My computer > Properties > Advanced > Environment Variables
  • under system variables click "path" and click "edit"
  • at the end of the line add a sem semi colon ";" and without a space put C:\android-sdk-windows\tools - It should look like ;C:\android-sdk-windows\tools then click ok.

*Thanks to Rastaman-fb for this.

As I am rooted using unrevoked already, I have got the hboot drivers installed. I haven't tested this on a clean machine. If this does not work for you / does not connect to the device, please install the Hboot Drivers - follwing the steps in the rooting guide pre-requisites section here

How do I get into adb shell?
Once set up like above, open a command prompt (Start > Run > type "cmd" and press [ok]).

From here, type "adb shell" and press Enter.

Code:
adb shell


How do I use adb (examples)?
If you are modifying /system, it is best to boot into recovery, connect the phone via usb and start adb shell as instructed above. If you are S-ON, you can only modify system whilst in recovery anyway. S-OFF users can use the app root explorer***

To modify /system, you must mount system.

So after starting adb shell, type "mount /system" and press enter. e.g.

Code:
adb shell
mount /system
From here, you can now replace existing / install new system apps. Lets say for example, you have a Gmail.apk (different version to installed) on your c: drive (c:\Gmail.apk) that you want to replace in /system/app. You need to have mounted system, then exited adb shell before "pushing" the apk.

The command is adb push and is case sensitive. The destination name, if it differs to the source name will cause the file to be renamed to the destination name, so take care.

From start to finish this would be:

Code:
adb shell
mount /system
exit
adb push c:\Gmail.apk /system/app/Gmail.apk
You can do similar with install for new apks.

You can also list the system/apps to check it is there.

Code:
adb shell
mount /system
exit
adb install c:\Gmail.apk /system/app/Gmail.apk
ls /system/app
You can also push new frameworks that you may have themed.

Code:
adb shell
mount /system
exit
adb push c:\framework-res.apk /system/framework/framework-res.apk
ls /system/app
You can also pull apps using adb pull and using the same concept, you need to designate where to pull it too.

Code:
adb shell
mount /system
exit
adb pull /system/app/Gmail.apk c:\
But I prefer to use the filename to ensure it is definitely in the correct place.

Code:
adb pull /system/app/Gmail.apk c:\Gmail.apk
adb pull can be useful if you want to edit the .apk on your PC

Please note if you are still in command prompt, you only need to mount /system once.

***It's worth noting, if you are S-OFF and intend using ADB whilst android is running (although may as well use a terminal emulator on the phone) You must mount /system as read / write.

eg:

Code:
mount -o rw,remount /dev/block/mtdblock3 /system
What other adb examples / commands are there?
Code:
adb devices
Prints a list of all attached emulator/device instances.

Code:
adb help
Prints a list of supported adb commands.

Code:
adb shell
Issues a shell command in the target emulator/device instance and then exits the remote shell.

Code:
adb push
Copies a specified file from your development computer to an emulator/device instance

Code:
adb pull
Copies a specified file from an emulator/device instance to your development computer.

Code:
adb install
Pushes an Android application (specified as a full path to an .apk file) to the data file of an emulator/device.

Code:
adb logcat
This lists all the things in command line format that your phone is doing. It can be very useful to determine if you have a boot loop as you will see the same lines of code looping on the screen. If you have installed a theme, it may even be able to identify if a specific image is missing from your framework-res.apk

A full list of commands can be found here

There is an application from PC you can use here:

About QtADB

I have not tested this myself though, so I cannot recommend it personally. Give it a try and let me know. I will test it in due course.

What is fastboot?
Fastboot is 2 things. It is a mode on the phone, which looks a little like Bootloader. You can access it by holding back whilst turning on the phone (from off, Back+power)

It is also a way of flashing radios, Splash screens, recovery and Hboots in a command line method from a PC much like adb. You can only use this method to flash if you are S-OFF

How do I use Fastboot?
If you are simply flashing recovery, radio, hboot, fastboot commands are best. For Splash Screens, I tend to use Android Flasher as it converts the .bmp image for you.

The thread is here on XDA But I use this version: Android Flasher for no particular reason other than I know it works for me.

It is simple to use. You open the app, tell it that you want to flash a splash screen and click the begin button. Browse to the file and bingo. Done. You need to have the phone in fastboot mode as previously mentioned.

**Please note that you can only flash .img files via fastboot. However, Fastboot flasher will convert splash screen images from .bmp files to .img for you (as it isn't usually straight forward) so if you have a splash image already in .img format, flash it using manual commands. I recommend using fastboot commands for everything where possible.

It is very important when fastboot flashing, to ensure the process is not interupted by power loss, usb disconnects

Fastboot commands (Via command prompt similar to adb).

Code:
fastboot flash radio c:\radio.img
...assuming your radio is called radio.img and is on c:\

Code:
fastboot flash recovery c:\recovery.img
Code:
fastboot flash splash1 c:\splash.img
Code:
fastboot flash hboot c:\hboot.img
and so on...

***please note the command for radio or recovery will always start:
Code:
fastboot flash radio
Code:
fastboot flash recovery
Where the third word is telling what and to where is being flashed. Only the fourth string will change and this is dependant on your file name and location

Why would I flash a Hboot?
If you have decided to flash an alpharev partition table, you would flash this as a hboot to change the internal memory NAND partitions.

Why use fastboot to flash radio?
There are a couple of reasons for this.

1) You are s-off, so you may have changed your partition table / layout. Flashing a radio.zip via recovery means that the .zip file will unpack the radio.img in the /cache partition. This requires over 25MB /cache available to do so. If there is not enough space, you could have big problems.

2) Its better. It removes the additional layer of software (i.e recovery) on your phone to go wrong.



*as mentioned earlier, this is a work in progress and will need a lot of work to get all the info you may need. Please do feel free to comment in this thread as to what is required.

Thanks to all past and present who have contributed to this.

SUroot is offline  
Last edited by SUroot; May 11th, 2012 at 10:07 AM.
Reply With Quote
The Following 21 Users Say Thank You to SUroot For This Useful Post:
Abdur (November 8th, 2011), Aggi (January 7th, 2012), alshop (July 23rd, 2011), dan55 (June 30th, 2012), ernolander (October 4th, 2011), Exiled_SouL (June 12th, 2011), Fishyweb (August 24th, 2011), Flumme (May 13th, 2012), GrenW (May 17th, 2011), jdash (May 29th, 2012), kewlbuddy (May 17th, 2011), MandaNick (May 24th, 2011), mollymalone (December 26th, 2011), Rastaman-FB (May 17th, 2011), shauny13 (May 17th, 2011), sirpaa (September 14th, 2012), SumoTaz (June 18th, 2011), TheCrackInTime (May 24th, 2011), tipa (December 2nd, 2011), Tyseyh (November 13th, 2011), Usta (May 17th, 2011)
sponsored links
Old May 17th, 2011, 07:10 AM   #2 (permalink)
Senior Member
 
Usta's Avatar
 
Join Date: Jul 2010
Location: The Netherlands
Posts: 2,586
 
Device(s): SGS II I9100
Carrier: Not Provided

Thanks: 127
Thanked 1,338 Times in 331 Posts
Default

Very informative. Excellent post!
Usta is offline  
Reply With Quote
The Following User Says Thank You to Usta For This Useful Post:
SUroot (May 17th, 2011)
Old May 17th, 2011, 07:13 AM   #3 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Quote:
Originally Posted by Usta View Post
Very informative. Excellent post!
Thanks.

Please do let me know if you see something obvious missing or that doesn't make sense.

I created this in a piece-work fashion between incidents at work, so its not necessarily articulate
SUroot is offline  
Reply With Quote
Old May 17th, 2011, 07:18 AM   #4 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

looks good man
__________________
Samsung Galaxy S3 (playing with roms still)
Siyah Kernel

Rastaman-FB is offline  
Reply With Quote
The Following User Says Thank You to Rastaman-FB For This Useful Post:
SUroot (May 17th, 2011)
Old May 17th, 2011, 09:10 AM   #5 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Added:

Quote:
It's worth noting, if you are S-OFF and intend using ADB whilst android is running (although may as well use a terminal emulator on the phone) You must mount /system as read / write.

eg:

Code:

mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
SUroot is offline  
Reply With Quote
Old May 17th, 2011, 09:55 AM   #6 (permalink)
Member
 
Join Date: Jan 2011
Location: Germany
Posts: 272
 
Device(s): Nexus 4
Carrier: Not Provided

Thanks: 77
Thanked 33 Times in 32 Posts
Default

good post.

may be you can also add tools such as android flasher,fastboot commander and qtadb which are simple to use.
my .2

edit: just saw you already added android flasher
kewlbuddy is offline  
Reply With Quote
The Following User Says Thank You to kewlbuddy For This Useful Post:
SUroot (May 17th, 2011)
Old May 17th, 2011, 10:22 AM   #7 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Fastboot commander I also have linked in the useful downloads thread, but I could link it here. not used it myself though.

Haven't seen QTadb. Whats that?
SUroot is offline  
Reply With Quote
Old May 17th, 2011, 10:26 AM   #8 (permalink)
Member
 
Join Date: Jan 2011
Location: Germany
Posts: 272
 
Device(s): Nexus 4
Carrier: Not Provided

Thanks: 77
Thanked 33 Times in 32 Posts
Default

Features QtADB

easy for push and pull
kewlbuddy is offline  
Reply With Quote
The Following User Says Thank You to kewlbuddy For This Useful Post:
SUroot (May 17th, 2011)
Old May 17th, 2011, 10:41 AM   #9 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

I've put a link in just above where fastboot section starts. As I haven't tested it myself, I can't give it a recommendation but always useful for people to be aware.
SUroot is offline  
Reply With Quote
Old May 17th, 2011, 10:56 AM   #10 (permalink)
Senior Member
 
shauny13's Avatar
 
Join Date: May 2010
Location: Beautiful Dorset
Gender: Male
Posts: 1,193
 
Device(s): HTC Desire, dGB, S-OFF.(retired) HTC One X. rooted running viper rom 2.01
Carrier: 3 uk

Thanks: 172
Thanked 274 Times in 243 Posts
Default

Thankyou so much, this is one area i defo need help with, always been crap with command prompt type stuff.
__________________
ROOTING FAQS
shauny13 is offline  
Reply With Quote
sponsored links
Old May 17th, 2011, 10:59 AM   #11 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Cool. Well have a play and see if theres anything that I need to elaborate on please
SUroot is offline  
Reply With Quote
Old May 17th, 2011, 05:04 PM   #12 (permalink)
Senior Member
 
ajh94's Avatar
 
Join Date: Dec 2010
Location: Essex, UK
Posts: 1,072
 
Device(s): HTC One X (Orange UK) - SGS2 (giffgaff) - HTC Desire (SIMless)
Carrier: Not Provided

Thanks: 60
Thanked 73 Times in 62 Posts
Default

Really helpful... Cheers man!
__________________
Devices:
- HTC One X (Stock on Orange UK)
- Samsung Galaxy S II (Running D4 ROM on giffgaff)
- HTC Desire (Running GingerVILLAIN, with no SIM )
ajh94 is offline  
Reply With Quote
Old May 17th, 2011, 05:06 PM   #13 (permalink)
Senior Member
 
Usta's Avatar
 
Join Date: Jul 2010
Location: The Netherlands
Posts: 2,586
 
Device(s): SGS II I9100
Carrier: Not Provided

Thanks: 127
Thanked 1,338 Times in 331 Posts
Default

A small comment:
In the section "How do I set up my Windows PC to use adb and fastboot?", it is not enough to unpack the SDK Tools only in C:\. You will need to go deep to select "android-sdk-windows" directory (just above "tools") and move it directly under c:\. Only then the adb commands get recognized in cmd shell.
Usta is offline  
Reply With Quote
The Following User Says Thank You to Usta For This Useful Post:
SUroot (May 17th, 2011)
Old May 17th, 2011, 05:23 PM   #14 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Quote:
Originally Posted by Usta View Post
A small comment:
In the section "How do I set up my Windows PC to use adb and fastboot?", it is not enough to unpack the SDK Tools only in C:\. You will need to go deep to select "android-sdk-windows" directory (just above "tools") and move it directly under c:\. Only then the adb commands get recognized in cmd shell.
Ah yes you're right.

Will adjust, thanks

edit> changed .rar directory structure and reworded the line.
SUroot is offline  
Last edited by SUroot; May 17th, 2011 at 05:31 PM.
Reply With Quote
Old May 17th, 2011, 05:28 PM   #15 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

Quote:
Originally Posted by Usta View Post
A small comment:
In the section "How do I set up my Windows PC to use adb and fastboot?", it is not enough to unpack the SDK Tools only in C:\. You will need to go deep to select "android-sdk-windows" directory (just above "tools") and move it directly under c:\. Only then the adb commands get recognized in cmd shell.
ive just tested it as i packed those tools
you can extact to c:\ as the folder inside is android-sdk-windows and as such when exctracted becomes c:\android-sdk-windows

it was correct

the error happens if you right click and click "extract to android-sdk-windows" which would then become c:\android-sdk-windows\android-sdk-windows\
if you put it in c and click "extract here" or click "extract files" and choose C:\ its correct

EDIT: did you change my folder structure SUroot as its a rar instead of a zip?
Rastaman-FB is offline  
Last edited by Rastaman-FB; May 17th, 2011 at 05:36 PM.
Reply With Quote
Old May 17th, 2011, 05:33 PM   #16 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Quote:
Originally Posted by Rastaman-FB View Post
ive just tested it as i packed those tools
you can extact to c:\ as the folder inside is android-sdk-windows and as such when exctracted becomes c:\android-sdk-windows

it was correct
Yeah but as dropbox only does single files, I .rar'd the whole folder that contains the zip and the readme.

I've edited the one linked so its just a .rar with the android-sdk-windows and read me. Then I edited the line in the faq to ope rar and drag android-sdk-windows to c:\
SUroot is offline  
Reply With Quote
Old May 17th, 2011, 05:37 PM   #17 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

Quote:
Originally Posted by SUroot View Post
Yeah but as dropbox only does single files, I .rar'd the whole folder that contains the zip and the readme.

I've edited the one linked so its just a .rar with the android-sdk-windows and read me. Then I edited the line in the faq to ope rar and drag android-sdk-windows to c:\
i see
Rastaman-FB is offline  
Reply With Quote
Old May 19th, 2011, 08:35 AM   #18 (permalink)
Senior Member
 
Usta's Avatar
 
Join Date: Jul 2010
Location: The Netherlands
Posts: 2,586
 
Device(s): SGS II I9100
Carrier: Not Provided

Thanks: 127
Thanked 1,338 Times in 331 Posts
Default

In the section "How do I use Fastboot?" when using Android Flasher, perhaps it is handy to mention what what each item in checklist is trying to flash (it is not explained properly at XDA).

For example, I was confused with Splash item: it wants to flash a bmp file, while Alpharev gives you an img file:
Quote:
You can download the stock splash1 screen for HTC Desire from here. http://alpharev.nl/desire_stock_splash1.img
Usta is offline  
Reply With Quote
The Following User Says Thank You to Usta For This Useful Post:
SUroot (May 19th, 2011)
Old May 19th, 2011, 08:39 AM   #19 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Quote:
Originally Posted by Usta View Post
In the section "How do I use Fastboot?" when using Android Flasher, perhaps it is handy to mention what what each item in checklist is trying to flash (it is not explained properly at XDA).

For example, I was confused with Splash item: it wants to flash a bmp file, while Alpharev gives you an img file:

added:

**Please note that you can only flash .img files via fastboot. However, Fastboot flasher will convert splash screen images from .bmp files to .img for you (as it isn't usually straight forward) so if you have a splash image already in .img format, flash it using manual commands
SUroot is offline  
Reply With Quote
The Following User Says Thank You to SUroot For This Useful Post:
Usta (May 19th, 2011)
Old May 24th, 2011, 06:37 AM   #20 (permalink)
Junior Member
 
Join Date: Jun 2010
Posts: 26
 
Device(s):
Carrier: Not Provided

Thanks: 7
Thanked 0 Times in 0 Posts
Default

Hi,I want a new Hboot (oxygen)
I currently have CM7 hboot
When using android flasher - I get a cant find cache error and it just fails..
any ideas? I dont know how to use fastboot (tried to read up on it but no idea when I'm supposed to be typing all these commands)

is android flasher the best way to flash a hboot?
thanks
MB
melonbaps is offline  
Reply With Quote
sponsored links
Old May 24th, 2011, 07:03 AM   #21 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

If you read this FAQ, it advises how to set up your PC to use fastboot and ADB.

Once you have done that, the fastboot commands are input in cmd (command prompt).

The command you will want is:

Code:
fastboot flash hboot c:\bravo_alphaspl-oxygen.img
for example, providing the file is called that and is on the C:\ drive and not in any folders.

Your phone needs to be in fastboot mode too. This is all explained in the FAQ, except your specific command of course
SUroot is offline  
Reply With Quote
Old May 24th, 2011, 09:02 AM   #22 (permalink)
Junior Member
 
Join Date: Jun 2010
Posts: 26
 
Device(s):
Carrier: Not Provided

Thanks: 7
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by SUroot View Post
If you read this FAQ, it advises how to set up your PC to use fastboot and ADB.

Once you have done that, the fastboot commands are input in cmd (command prompt).

The command you will want is:

Code:
fastboot flash hboot c:\bravo_alphaspl-oxygen.img
for example, providing the file is called that and is on the C:\ drive and not in any folders.

Your phone needs to be in fastboot mode too. This is all explained in the FAQ, except your specific command of course
ok, thanks, so I've set up SDK and changed patch system variables.
so I plug in phone before I start, making sure its in fastboot USB and type in command prompt "fastboot flash hboot c:\bravo_alphaspl-oxygen.img"

do I need to point the command prompt to the phone in anyway or just the fact Ive input "fastboot" point the image to the phone? I'm just worried about doing something bad to my c:/ drive (sorry complete noob here)

thanks SUroot for your help so far..
melonbaps is offline  
Reply With Quote
Old May 24th, 2011, 09:30 AM   #23 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Once your device says "fastboot USB" on the screen, it is connected and automatically becomes the target device.

You can't do anything to your C: drive using this command.

fastboot flash hboot c:\bravo_alphaspl-oxygen.img

Basically means:

run fastboot tool to flash to connected device a hboot image which is this file
SUroot is offline  
Reply With Quote
The Following User Says Thank You to SUroot For This Useful Post:
Tyseyh (March 9th, 2012)
Old May 24th, 2011, 09:43 AM   #24 (permalink)
Junior Member
 
Join Date: Jun 2010
Posts: 26
 
Device(s):
Carrier: Not Provided

Thanks: 7
Thanked 0 Times in 0 Posts
Default

great thankyou all worked a treat
MB


Quote:
Originally Posted by SUroot View Post
Once your device says "fastboot USB" on the screen, it is connected and automatically becomes the target device.

You can't do anything to your C: drive using this command.

fastboot flash hboot c:\bravo_alphaspl-oxygen.img

Basically means:

run fastboot tool to flash to connected device a hboot image which is this file
melonbaps is offline  
Reply With Quote
Old May 24th, 2011, 09:46 AM   #25 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Good news. Now enjoy!
SUroot is offline  
Reply With Quote
Old May 25th, 2011, 06:39 AM   #26 (permalink)
Senior Member
 
GingaB's Avatar
 
Join Date: Dec 2010
Location: London, UK
Posts: 856
 
Device(s): HTC Desire (Retired)
Carrier: Not Provided

Thanks: 28
Thanked 63 Times in 61 Posts
Default

Another excellent guide Dan. I always recommend your easy guides to rooting to all noobs.
__________________
Samsung Galaxy S3 LTE (i9305)
T-Mobile UK
4.1.2 Stock Rom


GingaB is offline  
Reply With Quote
The Following User Says Thank You to GingaB For This Useful Post:
SUroot (May 25th, 2011)
Old May 25th, 2011, 06:39 AM   #27 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Thanks matey. Much appreciated.
SUroot is offline  
Reply With Quote
Old May 30th, 2011, 04:51 PM   #28 (permalink)
Senior Member
 
Eris Ed's Avatar
 
Join Date: Jul 2010
Location: Manchester, UK
Posts: 982
 
Device(s): HTC Desire (GalnetMIUI ICS, S-OFF), HTC Sensation, Orange San Francisco (CM7), Nexus S (ICS 4.0.3),
Carrier: Not Provided

Thanks: 103
Thanked 248 Times in 146 Posts
Default

I have a question, I guess this is probably the best place to ask it.

I used AlphaRev to S-OFF which worked perfectly. Now I'm trying to flash a partition table and it's not working as expected. Here's what I've done so far:

1. Downloaded PB99IMG_bravo_sense.zip from AlphaRev.
2. Renamed it PB99IMG.zip on my PC and put it on the root of SD card.
3. Shut down phone
4. Start phone in bootloader (Vol down + power)
5. phone starts ok but stalls when looking for the PB99IMG.zip

I get this message: "CID Incorrect!! Update fail"

Now, I suspect that the CID error may be because my phone was originally Orange-branded, and I'm not using the goldcard I made when I first rooted - is this correct? I can't use my original goldcard with my current set up so my next step is to flash the extracted .img file via PC using fastboot.

Still, I'd like to understand why the .zip file wouldn't flash, just so I know >)
__________________
HTC Sensation | [ROM] Android 2.3.4 Gingerbread
HTC Desire | [ROM]: Galnet MIUI ICS Build 1.11.9 | AlphaRev S-OFF
Orange San Francisco | [ROM]: Android 2.3.3 Gingerbread | CyanogenMod 7.0.3
Follow Me on TWITTER: @TonyP_UK | IAmAndroid Profile: TonyP
Eris Ed is offline  
Last edited by Eris Ed; May 30th, 2011 at 05:09 PM.
Reply With Quote
Old May 30th, 2011, 05:08 PM   #29 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Ive never used the PB99IMG for this kind of thing, but CID is carrier ID and that error normally happens when flashing an RUU for another carrier so it is possible you are correct about the cause.
SUroot is offline  
Reply With Quote
Old May 30th, 2011, 05:13 PM   #30 (permalink)
Senior Member
 
Eris Ed's Avatar
 
Join Date: Jul 2010
Location: Manchester, UK
Posts: 982
 
Device(s): HTC Desire (GalnetMIUI ICS, S-OFF), HTC Sensation, Orange San Francisco (CM7), Nexus S (ICS 4.0.3),
Carrier: Not Provided

Thanks: 103
Thanked 248 Times in 146 Posts
Default

Quote:
Originally Posted by SUroot View Post
Ive never used the PB99IMG for this kind of thing, but CID is carrier ID and that error normally happens when flashing an RUU for another carrier so it is possible you are correct about the cause.
The method seems established, and is one of the methods stated on the AlphaRev website. But, there's a few people on Twitter who have had errors when trying to follow that route, and resorted to fastboot/PC to complete the flash. It's a shame really.....dropping the zip on SD and rebooting the phone is such a simple solution!
Eris Ed is offline  
Reply With Quote
sponsored links
Old May 30th, 2011, 06:04 PM   #31 (permalink)
Senior Member
 
Usta's Avatar
 
Join Date: Jul 2010
Location: The Netherlands
Posts: 2,586
 
Device(s): SGS II I9100
Carrier: Not Provided

Thanks: 127
Thanked 1,338 Times in 331 Posts
Default

Quote:
Originally Posted by Eris Ed View Post
The method seems established, and is one of the methods stated on the AlphaRev website. But, there's a few people on Twitter who have had errors when trying to follow that route, and resorted to fastboot/PC to complete the flash. It's a shame really.....dropping the zip on SD and rebooting the phone is such a simple solution!
I also couldn't use PB99IMG.zip file because my phone was also branded.
Anyway, I'm using now Android flasher for that and other purposes. It is simple to use and does the job.
Usta is offline  
Reply With Quote
Old May 31st, 2011, 03:26 AM   #32 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

fastboot flash hboot aphaxxxxxxxx.img is easiest
you dont have to drop it on to sdcard then
Rastaman-FB is offline  
Reply With Quote
Old June 1st, 2011, 02:12 PM   #33 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Added further clarification to the fastboot command.
SUroot is offline  
Reply With Quote
Old June 1st, 2011, 03:51 PM   #34 (permalink)
Senior Member
 
Eris Ed's Avatar
 
Join Date: Jul 2010
Location: Manchester, UK
Posts: 982
 
Device(s): HTC Desire (GalnetMIUI ICS, S-OFF), HTC Sensation, Orange San Francisco (CM7), Nexus S (ICS 4.0.3),
Carrier: Not Provided

Thanks: 103
Thanked 248 Times in 146 Posts
Default

fastboot flash hboot bravo_alphaspl.img
fastboot reboot-bootloader
fastboot erase cache

That did the trick
Eris Ed is offline  
Reply With Quote
Old July 14th, 2011, 02:00 PM   #35 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

added

Quote:
fastboot flash hboot c:\hboot.img
For ducky
SUroot is offline  
Reply With Quote
The Following User Says Thank You to SUroot For This Useful Post:
ducky1979 (July 15th, 2011)
Old July 29th, 2011, 11:55 AM   #36 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Added Anchor tags
SUroot is offline  
Reply With Quote
Old August 23rd, 2011, 04:06 PM   #37 (permalink)
Senior Member
 
ducky1979's Avatar
 
Join Date: Dec 2010
Location: Buxton, Derbyshire
Gender: Male
Posts: 910
 
Device(s): Samsung Galaxy S3, HTC Desire (retired)
Carrier: Vodafone UK

Thanks: 42
Thanked 96 Times in 78 Posts
Default

so ive got a new windows lappy running windows 7, ive downloaded the adk and put it into c drive ive plugged in in hboot and updated the driver, ive got the htc drivers installed, but when i type adb shell it says no device found. any help please.
ducky1979 is offline  
Reply With Quote
Old August 23rd, 2011, 04:10 PM   #38 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

Quote:
Originally Posted by ducky1979 View Post
so ive got a new windows lappy running windows 7, ive downloaded the adk and put it into c drive ive plugged in in hboot and updated the driver, ive got the htc drivers installed, but when i type adb shell it says no device found. any help please.
is your device booted?
if so what is it booted too?
in device manager can you see android > adb interface?
Rastaman-FB is offline  
Reply With Quote
Old August 23rd, 2011, 04:43 PM   #39 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

Try and do from cmd:

Code:
adb kill-server
Then try again.
SUroot is offline  
Reply With Quote
Old August 23rd, 2011, 05:08 PM   #40 (permalink)
Senior Member
 
ducky1979's Avatar
 
Join Date: Dec 2010
Location: Buxton, Derbyshire
Gender: Male
Posts: 910
 
Device(s): Samsung Galaxy S3, HTC Desire (retired)
Carrier: Vodafone UK

Thanks: 42
Thanked 96 Times in 78 Posts
Default

Quote:
Originally Posted by Rastaman-FB View Post
is your device booted?
if so what is it booted too?
in device manager can you see android > adb interface?
booted? yes
booted to? hboot
device manager? android usb/ my htc if phone powerd on android interface if hboot usb

ive tried it now with phone powered on and after i type adb shell i get a # type mount /system and all it says is mount:cant read '/etc/fstab' : no such file or directory
ducky1979 is offline  
Reply With Quote
sponsored links
Old August 23rd, 2011, 05:13 PM   #41 (permalink)
Senior Member
 
ducky1979's Avatar
 
Join Date: Dec 2010
Location: Buxton, Derbyshire
Gender: Male
Posts: 910
 
Device(s): Samsung Galaxy S3, HTC Desire (retired)
Carrier: Vodafone UK

Thanks: 42
Thanked 96 Times in 78 Posts
Default

Quote:
Originally Posted by SUroot View Post
Try and do from cmd:

Code:
adb kill-server
Then try again.
tried this and same result as above
ducky1979 is offline  
Reply With Quote
Old August 23rd, 2011, 05:24 PM   #42 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

you cant adb from hboot. recovery.
SUroot is offline  
Reply With Quote
Old August 23rd, 2011, 05:47 PM   #43 (permalink)
Senior Member
 
ducky1979's Avatar
 
Join Date: Dec 2010
Location: Buxton, Derbyshire
Gender: Male
Posts: 910
 
Device(s): Samsung Galaxy S3, HTC Desire (retired)
Carrier: Vodafone UK

Thanks: 42
Thanked 96 Times in 78 Posts
Default

Yeah I realised that, so just plugged in when phone was running, but it came back with the above fail message.
ducky1979 is offline  
Reply With Quote
Old August 23rd, 2011, 05:52 PM   #44 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

Quote:
Originally Posted by ducky1979 View Post
booted? yes
booted to? hboot
device manager? android usb/ my htc if phone powerd on android interface if hboot usb

ive tried it now with phone powered on and after i type adb shell i get a # type mount /system and all it says is mount:cant read '/etc/fstab' : no such file or directory
lol ducky
hboot doesnt use adb
the reason i asked how you were booted was for this reason
either booted into android when you type adb shell you will get a #
system is already mounted when booted into android and if you do adb devices at this point you will see a device id

you can do this in recovery too
Rastaman-FB is offline  
Reply With Quote
Old August 23rd, 2011, 05:52 PM   #45 (permalink)
ROM Developer
Thread Author (OP)
 
SUroot's Avatar
 
Join Date: May 2010
Location: Riddlesden, West Yorkshire, UK
Posts: 23,926
 
Device(s): SGS3 (Current) HTC Desire (Retired)
Carrier: 3 UK

Thanks: 1,923
Thanked 5,320 Times in 3,994 Posts
Default

use recovery option to mount /system then
SUroot is offline  
Reply With Quote
Old August 23rd, 2011, 06:37 PM   #46 (permalink)
Senior Member
 
ducky1979's Avatar
 
Join Date: Dec 2010
Location: Buxton, Derbyshire
Gender: Male
Posts: 910
 
Device(s): Samsung Galaxy S3, HTC Desire (retired)
Carrier: Vodafone UK

Thanks: 42
Thanked 96 Times in 78 Posts
Default

Quote:
Originally Posted by Rastaman-FB View Post
lol ducky
hboot doesnt use adb
the reason i asked how you were booted was for this reason
either booted into android when you type adb shell you will get a #
system is already mounted when booted into android and if you do adb devices at this point you will see a device id

you can do this in recovery too

So it was already mounted? Even though I didn't type mount system? And when I did it gave me the above info. So what's the best thing to type to test if its connected successfully?
ducky1979 is offline  
Reply With Quote
Old August 23rd, 2011, 07:46 PM   #47 (permalink)
Senior Member
 
ducky1979's Avatar
 
Join Date: Dec 2010
Location: Buxton, Derbyshire
Gender: Male
Posts: 910
 
Device(s): Samsung Galaxy S3, HTC Desire (retired)
Carrier: Vodafone UK

Thanks: 42
Thanked 96 Times in 78 Posts
Default

got it working now, i couldnt sleep till i had. it was a driver issue. it couldnt see the phone in recovery so i had to tell it to use existing driver for the interface and now all is well, adb is working well.
cheers guys.
ducky1979 is offline  
Reply With Quote
Old August 24th, 2011, 08:33 PM   #48 (permalink)
New Member
 
Join Date: Aug 2011
Location: MA
Posts: 13
 
Device(s):
Carrier: Not Provided

Thanks: 2
Thanked 1 Time in 1 Post
Default

Hey all. My phone will not complete the Odin flashed due to the internal file system being screwed up. I am in the ADB and it works. How do I format the internal sdcard and partition it correctly OR can I just force flash the boot, phone, and pda files?
apicia is offline  
Reply With Quote
Old August 31st, 2011, 04:36 AM   #49 (permalink)
Senior Member
 
Rastaman-FB's Avatar
 
Join Date: Sep 2009
Location: UK
Posts: 6,113
 
Device(s): HTC Desire (depreciated) Blue Galaxy s3 (international)
Carrier: Not Provided

Thanks: 114
Thanked 1,016 Times in 838 Posts
Default

Quote:
Originally Posted by apicia View Post
Hey all. My phone will not complete the Odin flashed due to the internal file system being screwed up. I am in the ADB and it works. How do I format the internal sdcard and partition it correctly OR can I just force flash the boot, phone, and pda files?
wrong area mate, you need help from people who use samsungs
Rastaman-FB is offline  
Reply With Quote
Old September 1st, 2011, 05:53 AM   #50 (permalink)
New Member
 
Join Date: Jun 2010
Posts: 2
 
Device(s):
Carrier: Not Provided

Thanks: 0
Thanked 0 Times in 0 Posts
Default Unable to rename system file

I've had a good search around but I cannot find a solution to my particular problem.

I want to rename the file camera_click.ogg in system/media/audio/ui to disable the shutter sound when taking a picture.

My phone is rooted (using UnrEVOked 3.21) and S-OFF (using alpharev 1.8) so I assumed this would be easy.
I am running CyanogenMod 7.0.3 and trying to use the terminal emulator that was installed with this ROM.

I ran the emulator and typed the following, as I understand it this would mount the system area as read/write

mount -o rw, remount /dev/block/mtdblock3 /system

When I hit enter I got this response

Mount: permission denied (are you root?)

Can anyone help me with this as I am obviously missing something?

Phone info is
BRAVO PVT1 SHIP S-OFF
HBOOT 0.93.0001
dbarny_2000 is offline  
Reply With Quote
Reply


Go Back   Android Forums > Android Phones > HTC Desire > Desire - All Things Root
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 09:21 PM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.