yashsingh1/xdaforums huggingface dataset:
[Galaxy S I9000 Android Development] Viearical:
Updated second boot loader now working in Mac OS X?

Hey Ben,

First thanks for the awesome work in creating and maintaining Heimdall!

Second, I know Heimdall wasn't working with Captivate on OS X due to the second boot loader not being recognized properly by OS X, and in this post you showed which boot loaders you could flash and get it working.

My question, now that the official Froyo update for Captivate is out, have you heard, or know if it contains the updated second boot loader so OS X properly recognizes the phone in download mode?

Thanks for all the help!
[Galaxy S I9000 Android Development] apollo15rover:
I'm getting "expected end of line but found unknown token" error..
[Galaxy S I9000 Android Development] coderunner:
Does this program only work with 64 bit architecture? I am running 32 bit linux system is there a way to get this to work?
[Galaxy S I9000 Android Development] intronauta:
I'm running heimdall 1.1.1 in ubuntu 10.10 64bits with the precompilated binaries without problems, but compile it is very easy ;)
[Galaxy S I9000 Android Development] coderunner:
Ya but I only have a 32 bit computer
[Galaxy S I9000 Android Development] pietro_spina:
You will have to compile it. what exactly are you running?

If you are not new to compiling you can grab the source and follow the instructions in the README

git clone git://github.com/Benjamin-Dobell/Heimdall.git

If you are new then there are a few more things to learn... :-)
[Galaxy S I9000 Android Development] gehzumteufel:
Are you on Windows, Linux, or Mac? If Windows or Mac, you needn't worry.
[Galaxy S I9000 Android Development] Benjamin Dobell:
A lot of you will be happy to know that I grabbed a 32-bit version of Ubuntu 10.10 today. So I'll compile and publish official 32-bit debian binaries soon. If I get a chance I'll try finish off 1.2 as well.
[Galaxy S I9000 Android Development] BL4zD:
It's been a while since I cross compiled, but you don't need to be using the environment you want to compile for. Back in the day, I used to compile for all kinds of different architectures (ppc, 64bit, etc.) from my 32bit amd processor.

I believe the command to gcc should be something like -m32 and -m64.
[Galaxy S I9000 Android Development] Benjamin Dobell:
Thanks for the advice, I have cross-compiled in the past (to ARM usually) however this works out to be slightly easier for me. Otherwise I'd have to setup a proper cross-compiling environment with 32-bit libraries as well as an environment to build the debian package (which is unfortunately the hard part).
[Galaxy S I9000 Android Development] Galaid:
Benjamin, could you or someone else please make Fedora binaries? Thanks!
[Galaxy S I9000 Android Development] papazche:
Yeah, Where can be this downloaded ?
[Galaxy S I9000 Android Development] pietro_spina:
From the link in the first post you skimed. ;-)
[Galaxy S I9000 Android Development] distortedloop:
Really? I had occasion to restore a nandroid on the SGS recently and didn't notice any difference from my previous use of the phone in that state.

Guess I better check the clockwork thread to see if this is known issue and how bad.
[Galaxy S I9000 Android Development] Benjamin Dobell:
At present I have not implemented any means to dump the firmware. However if that "Dump" button everybody seems afraid to push in Odin turns out to work, then yeah I can add functionality to do it. Essentially I can only do what the Loki protocol supports. At the moment the only thing I can grab from the phone is the PIT file and that's because there is a dedicated command to retrieve it.

I do plan to extend Heimdall to do more complex tasks other than just flashing via Loke however. Examples of what I'd like to do include; downloading of (any) official firmware, patching official firmware, one-click rooting, and hopefully firmware dumps.
[Galaxy S I9000 Android Development] Benjamin Dobell:
So... how about those alpha testers, eh? ;)
[Galaxy S I9000 Android Development] EarlZ:
Looking forward to the development of this program as Odin is annoying me lately with all of these errors before the flashing even starts..
[Galaxy S I9000 Android Development] Brock Samson:
I can't wait until this comes to mac. I hate having to drive to my mom's to use her pc to play with the phone. Keep up the great work.
[Galaxy S I9000 Android Development] Unimaginative:
Y'know, as soon as I got hold of Odin I thought, being the inquisitive chap I am, "HURR WUNDER WAT 'Dump' DUZ" and proceeded to enter '0' for ID and hit dump (then sat there and scratched myself for the next hour or so). I am now the proud owner of a ~250mg .dump which I was stupid enough to keep but too lazy to play with. I was thinking about throwing it at 7z the other day but, suddenly, beer.

In other news I'll give Heimdall a go the next time I flash. Was going to play around with eugene373's potential win-bomb tonight or tomorrow which from the sounds of it isn't a keeper just yet. Two birds with one block of old cheese.
[Galaxy S I9000 Android Development] Benjamin Dobell:
That's great news. If the dump mechanism uses the same chip id scheme as flashing files onto then the phone, then 0 should be NAND and 1 modem/radio.

That would be great, thanks.
[Galaxy S I9000 Android Development] AllGamer:
Hey Ben,

Did you check this out?

http://xdaforums.com/showthread.php?p=7916657

I was thinking maybe you can partner up with them to bring everything together, it just makes sense to be able to do it on any platform, specially if no PC are required it'll be best
[Galaxy S I9000 Android Development] Benjamin Dobell:
Yeah I saw that thread. It's great news. However Heimdall makes use of Loke's/Odin's protocol so my work wouldn't really be of any use to them. Once flashing via Redbend Update Agent is in a usable state some people might find the simple flashing functionality of Heimdall a bit redundant. The only minor issue with that method is of course that your phone actually needs to boot up. Hopefully that is always the case but Heimdall should make a good recovery tool regardless.

Once I get some positive reports of Heimdall's basic flashing functionality from testers I will add support for as many tasks as I can, firmware dumps, patching firmware (lag-fixes etc.) and anything else I can come up with. If that all gets wrapped up in a nice user interface then hopefully Heimdall can become an all-in-one tool for the community :)
[Galaxy S I9000 Android Development] AllGamer:
that is exactly what i was thinking.

both tools can cover for each other weknesses,

one we get both into full release we wont need to depend on KIES/ODIN for the upgrades anymore
[Galaxy S I9000 Android Development] blingblingslyna:
pleeease give me a linuxbin!
[Galaxy S I9000 Android Development] neldar:
@Benjamin:

Did you already have a look at the kies firmware update process?

The update process downloads a zip file and this zip-file contains two files: a firmware .tar-file and a dll-file named SS_DL.dll.

This SS_DL.dll could be interesting for you, it contains some odin-functions.

I have attached this to the post.
[Galaxy S I9000 Android Development] dkcldark:
How is it going?

I'm really looking forward to seeing it :D

compiling in ubuntu and going to windows is really annoying!!:mad:

Thanks!
[Galaxy S I9000 Android Development] Benjamin Dobell:
@blingblingslyna:

Sorry I'm still waiting on people to test the windows binary :(

@neldar:

My phone is still off being repaired (it's taking forever) but when I get it back I'll take a look at how Kies does things.

@dkcldark:

It's going slow. I need some testers to report their experiences with the Windows alpha then I can get onto making a real release for all platforms.
[Galaxy S I9000 Android Development] lordjubblydave:
Any updates on the linux version?

Would it be safe enough to test yet?
[Galaxy S I9000 Android Development] dirk1978:
+1 for the Linux version here. I'm sure you'll get a lot more testing done by the people who actually need it.
[Galaxy S I9000 Android Development] youneek:
Download link doesn't work.
[Galaxy S I9000 Android Development] FadeFx:
when did you send your phone in? mine is also on a repair trip, now for almost three weeks...
[Galaxy S I9000 Android Development] atenrok:
exactly! Windows users don't care about openness and stuff. And besides, they already have odin, so why bother...
[Galaxy S I9000 Android Development] insty:
Mac release :>?
[Galaxy S I9000 Android Development] bahathir:
First of all, I really like to thank to the author/developers of this marvelous project. :) At last, I can stayed away from bloated MS Windows and Kies.

I just compiled the source from git on my Slackware64 13.1 which runs on Macbook Pro 15" (mid-2010). The main command line program compiled smoothly, and that is the only program which I needed.

I'll try it with my wife's SGS, when I get home.

Thank you.
[Galaxy S I9000 Android Development] nedthehead:
Could someone upload the custom front-end file which works on OS X 10.6.6? Every time I've tried to create this file, the program refuses to open on me. I hate having to use Bootcamp to access Odin :/
[Galaxy S I9000 Android Development] gehzumteufel:
I am on 10.6.6 and I haven't any issues. Runt he pkg, install QT framework if necessary, and then run the program. Easy as pie.
[Galaxy S I9000 Android Development] nedthehead:
Shoot, I guess I should read more. I'll pick up the QT framework and then report back :p
[Galaxy S I9000 Android Development] gehzumteufel:
From what I know of, he was supposed to have gotten that fixed, but since I still don't get how to uninstall pkg based installers on the Mac, and I already have the QT framework installed, I haven't a clue if it is actually necessary anymore.

And make sure to only download the 400mb installer. Not the 1gb installer.
[Galaxy S I9000 Android Development] nedthehead:
Definitely got the front-end up and running. That was exactly what it needed. Thanks!
[Galaxy S I9000 Android Development] gehzumteufel:
Sweet! Glad I was able to assist! :)
[Galaxy S I9000 Android Development] HeisRisen:
+1 for the 32 bit architecture
[Galaxy S I9000 Android Development] rmcusc:
I previously installed heimdall 1.1.0 (on mac) and qt. I then uninstalled 1.1.0 and installed heimdall 1.1.1. The application still says it is 1.1.0. wtf?

I also cant get the program to work. Is there any way to "fix the bootloader" w/o windows?

also, I am on a samung fascinate (verizon)
[Galaxy S I9000 Android Development] Benjamin Dobell:
That's just a mistake. I forgot to update the Heimdall Frontend 1.1.1 user interface to actually say "1.1.1".

Linux.
[Galaxy S I9000 Android Development] Benjamin Dobell:
Okay, I've just uploaded Heimdall 1.1.1 32-bit debian binaries. The Heimdall command-line tool compiled, ran and packaged up fine. However Heimdall Frontend is using crazily weird fonts on my system. If you guys get the same crazy weird fonts let me know. The frontend package also complained of missing dependencies, so I just ignored the warning for now, let me know if you have problems.

I'm not going to add the links to the Glass Echidna website until I know the font issue I'm seeing with Heimdall Frontend isn't a problem (i.e. It's just my system). So for now here are some direct links:

Heimdall Command Line Tool 1.1.1 (Debian i386)

Heimdall Frontend 1.1.1 (Debian i386)
[Galaxy S I9000 Android Development] HeisRisen:
Weird that ubuntu software center won't install these.

and this is what happens when I try from command

brenda@brenda-HPG71-linux:~/Downloads$ sudo dpkg -i heimdall-frontend_1.1.1-1_i386.deb
Selecting previously deselected package heimdall-frontend.
(Reading database ... 229555 files and directories currently installed.)
Unpacking heimdall-frontend (from heimdall-frontend_1.1.1-1_i386.deb) ...
dpkg: dependency problems prevent configuration of heimdall-frontend:
heimdall-frontend depends on heimdall (>= 1.1.1); however:
Package heimdall is not installed.
dpkg: error processing heimdall-frontend (--install):
dependency problems - leaving unconfigured
Errors were encountered while processing:
heimdall-frontend
[Galaxy S I9000 Android Development] a.vandelay:
i repartition flashed my captivate and i believe i hard bricked my phone. probably a bad boot.bin?
[Galaxy S I9000 Android Development] Benjamin Dobell:
This might be a stupid question, but did you install Heimdall before installing Heimdall Frontend?

It's more likely to be a bad secondary bootloader or param.lfs than it is the primary bootloader. If that's the case then you should be able to boot into download mode using a custom jig.
[Galaxy S I9000 Android Development] HeisRisen:
Yes, I had to uninstall it, reboot and reinstall to get the front end installed. Thanks Benjamin.
[Galaxy S I9000 Android Development] Benjamin Dobell:
Great!

Does the Frontend look normal on your computer? Or do the fonts look really strange? If they do look strange then you'll definitely know what I'm talking about.
[Galaxy S I9000 Android Development] HeisRisen:
Will let you know, the front end installed to some mystery place. Going to look for it in the morning.
[Galaxy S I9000 Android Development] Benjamin Dobell:
It should be /usr/bin/
[Galaxy S I9000 Android Development] pikachu01:
Quick question, when I first tried Heimdall, I read the README stating that I need to replace my drivers in order for it to work.

I tried not replacing the drivers and flashing using Heimdall and that failed. I tried replacing the drivers and flashing using Heimdall and that failed too.

I'm on Windows 7 64-bit btw. Anything I did wrong here?
[Galaxy S I9000 Android Development] gehzumteufel:
Did you use the built in utility to replace the drivers? If so, you have to then unplug then replug the device. At least that was my experience. YMMV.
[Galaxy S I9000 Android Development] pikachu01:
If I replace the drivers, will my Kies stop working?
[Galaxy S I9000 Android Development] Benjamin Dobell:
Windows seems to replace the drivers on a per USB port basis. However, yes if you replace Samsung's drivers with the libusb-1.0 compatible drivers for a USB port then Kies will not detect your device when it is plugged into that USB port. Heimdall's README also includes instructions that explain how to uninstall Heimdall's drivers, in which case you can then reinstall Samung's/Kies' drivers.
[Galaxy S I9000 Android Development] bassnfool:
Used heimdall on fedora 14 for first time to install cm7 kernel... worked great thanks
[Galaxy S I9000 Android Development] monoxide.tryst:
Is it just me, and im handicapped, or is there nothing for x86???
[Galaxy S I9000 Android Development] gehzumteufel:
X86 = 32bit. The windows binary is 32bit.
[Galaxy S I9000 Android Development] monoxide.tryst:
Sorry, I forgot to mention that im looking for debian : ) I read around the website, and it seems there isnt any yet : (
[Galaxy S I9000 Android Development] Benjamin Dobell:
Check one page back in this thread for a link. They're brand new and I need the Frontend verified as working (without weird fonts), once someone does that I'll put the links up on my website.
[Galaxy S I9000 Android Development] monoxide.tryst:
Ok thanks, i saw those but checked the web site instead of downloading those. Ill check it : )

Well the fonts all work, but im not really sure how to use it yet. But it is confirmed that fonts are all fine with Ubuntu 10.10
[Galaxy S I9000 Android Development] HeisRisen:
Fonts are fine. Well I be able to take a tar'd md5 and put it in each requested section of the flash? Seems like odin had only two files to load. A pit and a tar
[Galaxy S I9000 Android Development] pietro_spina:
You have to extract that tar further so that you can put the specific files in the specific slots where they belong.
[Galaxy S I9000 Android Development] ceno808:
Its nowhere written that we need Qt...
[Galaxy S I9000 Android Development] gehzumteufel:
It is written and displayed, bit only for the older builds. Maybe Ben can add this note back for the newest build too. He thought he fixed it, but there is a good possibility it is not.
[Galaxy S I9000 Android Development] pikachu01:
Guys, I bricked my phone trying to flash the 3-button download mode fix using Heimdall.

Here's what I did:

Preparation:

1. Put phone into debugging mode.

2. Plugged in phone into the USB.

Procedure:

1. Used ADB to reboot into download mode

2. Replaced the Kies drivers with Heimdall drivers.

3. Unplugged the USB and replugged the USB for safety reasons.

4. Opened Heimdall.

5. Put in boot.bin and SBL.bin as primary and secondary bootloader.

6. Pressed start.

7. Noticed that progress bar in Heimdall is not moving after 10secs.

8. Noticed that progress bar is non-existent in phone.

9. Minimized Heimdall.

10. Maximized Heimdall and saw Start button unpressed.

11. Pressed Start Button again and got the error message: failed to retrieve config descriptor

12. Bricked my phone :(
[Galaxy S I9000 Android Development] Benjamin Dobell:
Before you pushed "Start" for the second time there would have been something displayed, "Done" or some sort of error message. If it did complete successfully then your device should have rebooted. Did your device reboot? If your device did reboot then the flash went through successfully.

The error message you received the second time "failed to retrieve config descriptor" indicates that the operating system is unable to communicate with the device, Heimdall is yet to actually make any communication with the device. This could have been because the device has already rebooted or a faulty USB port, which if the phone hadn't rebooted, would explain the first failed flash.

When you say your device is bricked do you mean hard-bricked or soft-bricked (PC screen). Either way if you don't have 3 button mode then you're going to need a custom jig to try boot up using the backup secondary bootloader. If that doesn't work then you're going to need to send your device off for a JTAG repair.

EDIT: Obviously if you've flashed an incorrect bootloader your device won't actually reboot after a successful flash, however the phone would be turned off.
[Galaxy S I9000 Android Development] pikachu01:
Thanks for the quick reply.

The phone doesn't have any screen indicators that it was doing any flashing. Heimdall's progress bar was not moving at all. It doesn't even have a progress bar indicator. It's just a blank placeholder for the progress bar. This went on for 20secs. I've flashed with Odin before, it takes 10secs. Hence I minimized Heimdall to check that the files I have was correct. Maximizing Heimdall, I see that the progress bar dissappeared, and the Start button unpressed.

Feeling curious, I tried pressing Start again, and I got the error. I've successfully flashed another phone using Odin on the same laptop with no errors.

Edit: It's soft brick. It still has the phone-PC icon flashing when battery is inserted, and powered on.

Edit2: Download mode was still there when I tried flashing. No screen indicators, hence I believe that flashing hasn't even started. Is it a negotiation error?
[Galaxy S I9000 Android Development] Benjamin Dobell:
Okay, that makes sense. I think you must have received that same error the first time you attempted to flash. That error essentially means that when libusb-1.0 asked the OS/drivers for information about the connected device then the information failed to be retrieved. This usually indicates a faulty USB port although it could also indicate a faulty phone, however the latter is unlikely.

Faulty USB ports are surprisingly common and it doesn't necessarily mean they fail all the time. If you've used this same port in the past with Odin then it seems that this time you just got really unlucky.

Although, one other user did report similar problems when they tried to flash a kernel after flashing a particular Sbl.bin. Once they flashed to their previous Sbl.bin both Heimdall and Odin started working again.

I'm not certain what the problem is in your exact situation, however given you've just got the PC screen you'll definitely be able to recover. If you don't have 3-button mode then unfortunately you will have to use a custom jig.
[Galaxy S I9000 Android Development] ceno808:
Is there an Documentation how to use or a Faq?

Tryed yesterday to flash my SGS ith Heimdall on Snow Leopard. it gave an error (can't find phone) and killed my phone...
[Galaxy S I9000 Android Development] pikachu01:
Can you confirm that the bootloader is untouched, that the soft-brick is just a communication error between USB ports?
[Galaxy S I9000 Android Development] Benjamin Dobell:
Heimdall can't "kill" your phone if it can't detect it. If your device isn't detected then Heimdall performs absolutely no communication with the device.

For documentation please read the official website and the README.

EDIT: Read this thread for details as to how you can fix the issue with your phone not being detected in OS x.

I'm not quite sure what you're asking.

I can't confirm what happened because I don't know what happened the first time you tried to flash. I can however confirm, based on the error you quoted, that the bootloader was not touched the second time you tried to flash.

However now that I think about it the way you get stuck on the PC screen is when a flash fails. The first thing Heimdall, Odin or Kies do when flashing is start a session with the device being flashed. This seems to set a flag on the phone that indicates a flash started. The last thing Heimdall, Odin or Kies do after a flash is end the session, which unsets the flag on the phone. If the phone stops responding (which is what happens when a flash fails) then the session is never ended, so the flag remains set. When the flag is set your phone is forced to boot into the PC screen. If you have a working download mode, closing this screen is as simple as running:

Which literally just starts and ends a flashing session (causing the flag to be unset) without flashing any files to the phone.

If your phone is booting up to the PC screen then we know that at least the primary bootloader is functional. If that's the case then even if the main secondary bootloader is corrupt, using a custom jig will cause your phone to boot up making use of the backup secondary bootloader.
[Galaxy S I9000 Android Development] zurchpet:
I'm curious... so there is an always untouched backup secondary bootloader, that can be reached with the JIG and a working primary bootloader?

So the only real way to brick is to **** up the primary bootloader?

Thank you for all your efforts :)
[Galaxy S I9000 Android Development] pikachu01:
Thanks Ben for the reassuring words :)

I'm more convinced now that my USB doesn't work with Heimdall. Though, strangely, Odin works everytime. I just flashed a kernel to my other SGS.
[Galaxy S I9000 Android Development] Benjamin Dobell:
Essentially yes. Although you can actually flash over the backup secondary bootloader if you really want to. Heimdall 1.1.1 allows you to do this via command line, the functionality is intentionally not available from Heimdall Frontend.

There may also be a backup primary bootloader, although I am yet to find any reference to one.
[Galaxy S I9000 Android Development] titooo7:
I cant have Heimdall 1.1.1 working on Snow Leopard.

When I try to open it I receive a message saying that it can't be opened due to some problem, so I tried the fix mentioned in this thread:

I created a file called heimdall-frontend and wrote the follwing content inside it:

Then i placed it inside /Applications/heimdall-frontend.app/Contents/MacOS and changed the name of the file that was previously there from heimdall-frontend to heimdall-frontend-old

But when i click on the app nothing happens... Any other tips?
[Galaxy S I9000 Android Development] gehzumteufel:
That old script is unnecessary. Undo that, and install QT framework.
[Galaxy S I9000 Android Development] bahathir:
I am happy with CLI version of Heimdall. It is very straight forward and easy to use. Learn how to use command shell. ;)
[Galaxy S I9000 Android Development] Digiguest:
Err.....with all dues respect can we have this in simple instructions please? File name, paths....etc?