How Tos

HOWTO run Heimdall on Samsung devices in Santoku Linux


This HOWTO will guide you through the process of using Heimdall on a Samsung Android device.

USE AT YOUR OWN RISK. This information is provided for reference only and on an “as is” basis without any warranty whatsoever. Heimdall is a permanent flashing utility and should be used with caution.

Contents

What you will need:

  • Santoku 0.1 or later
  • Heimdall or Heimdall-Frontend Binary (Already included with Santoku)
  • A Samsung Android device
  • The files required to flash to your Android device
    • Note: The files required for each device and need is different. In this HOWTO we are flashing the recovery image, therefore we are using a recovery.bin file specific to our device. If you find a file that works for a device, please comment on this blog and share with the Community.

Top

About Heimdall:

Heimdall is used to flash firmware onto Samsung Galaxy S devices. Flashing firmware allows the user to flash custom ROMs and custom recovery partitions on their Android device. For example, the HOWTO below walks you through flashing a temporary custom recovery image to a Samsung device. This temp recovery image gives the user root shell on a device where root shell was not possible otherwise. From the custom recovery the examiner is able to pull the /data and /system partitions from the device (among others), providing critical data during a forensic examination.

Whether your goal is to flash a custom ROM to your Samsung Galaxy S device, to gain root access on an otherwise locked device, or to flash a separate partition for other means, Heimdall is a great tool to get you there.

Top

Known supported devices:

  • Samsung Captivate
  • Samsung Vibrant
  • Samsung Fascinate
  • Samsung Mesmerize
  • Samsung Epic 4G
  • Samsung Galaxy S 4G
  • Samsung Infuse 4G
  • Samsung GT-I9000T
  • Samsung Galaxy Tab
  • Samsung Galaxy S II
  • Samsung GT-I9000
  • Samsung Galaxy S GT-I9000

Top

Run the Heimdall GUI:

In Santoku navigate to Santoku –> Development Tools –> Heimdall GUI

Put your device in download mode:

Note: All commands listed below are applicable with both the Heimdall GUI and Heimdall in terminal.

With your mobile device connected to your computer, reboot your device into download mode. Type:

adb reboot download

You should now see a screen with a yellow triangle and the words “Downloading…” similar to this:

Download Mode

Top

In Heimdall, create and download necessary files:

Download your device’s Partition ID Table (PIT). On the “Utilities”tab, under the “Download PIT” section select “Save As…”, name the PIT file, and click “Save”, then “Download”.

A message will let you know that the PIT file has been downloaded successfully. Once you see your PIT file and Heimdall states “Re-attaching kernel driver”, you have successfully downloaded your device’s PIT file.

Download partition and device files specific for what you want to flash. In this example, we want to flash a temporary recovery image to the recovery partition. To do this, we downloaded a recovery.bin file created by ClockworkMod that was specific to our model Samsung.

Top

Flash your target partitions:

In Heimdall, select the “Flash” tab. Browse to your newly created PIT file. Ensure that “Repartition” is unchecked and “No Reboot” is checked. Click “Add” in the Partition box on the right. Select the device’s target partition you are attempting to flash in the dropdown menu to the left. Browse to the target file you want to flash to the device and press “Start”.

If your flash is successful you should see a blue bar appear on your device like this:

Heimdall will let you know the process has succeeded by re-attaching the kernel driver. Remove the battery, reinsert it and reboot.

Top