Sunday Project: Installing CyanogenMod on an HTC Hero

This weekend, I finally rooted my old but functional Sprint HTC Hero, and installed CyanogenMod 6.1.0 on it. Below are my notes on the process.

(Note: This post is more of a compilation than any original work of my own; I’ve tried to reference sources for the information that I present here as best as I recall; please post any links I should have included in the comments.)

I followed the instructions on the CyanogenMod Wiki (edited substantially even in the last twenty-four hours, notably). Details:

  • I found it necessary to downgrade my phone to 2.27.651.5 prior to rooting with Universal Androot.
  • The latest version (R08) of the Android SDK doesn’t include adb in the initial install. Instead, you need to launch the “android” binary from the “tools” subdirectory and install the “Android SDK Platform-tools” package via “Available packages”. (I’m not aware of a CLI way to do this, but that doesn’t mean one doesn’t exist.)
  • The adb server needs to run as root before you connect to your device. E.g.:
    adb kill-server 
    sudo adb start-server
    

    (Ref: ADB: error: insufficient permissions for device)

  • Turn on the screen on your device so that you can okay using root permissions on a pop-up after you run “su” within “adb shell”. (Ref: ADB Shell SU – Permission Denied – On a Rooted Phone)
  • The Wiki instructs you to use “flash_image” which you will likely need to install; see the CyanogenMod Wiki page for flash_image. Note that you will need to remount your sdcard without the noexec option:
    > ./adb shell
    $ su
    # cd /sdcard
    # ./flash_image recovery recovery-clockwork-2.5.0.1-heroc.img
    ./flash_image: permission denied
    # chmod 755 ./flash_image
    # ./flash_image recovery recovery-clockwork-2.5.0.1-heroc.img
    ./flash_image: permission denied
    # mount
    rootfs / rootfs ro 0 0
    tmpfs /dev tmpfs rw,mode=755 0 0
    devpts /dev/pts devpts rw,mode=600 0 0
    proc /proc proc rw 0 0
    sysfs /sys sysfs rw 0 0
    tmpfs /sqlite_stmt_journals tmpfs rw,size=4096k 0 0
    none /dev/cpuctl cgroup rw,cpu 0 0
    /dev/block/mtdblock3 /system yaffs2 ro 0 0
    /dev/block/mtdblock5 /data yaffs2 rw,nosuid,nodev 0 0
    /dev/block/mtdblock4 /cache yaffs2 rw,nosuid,nodev 0 0
    /dev/block//vold/179:1 /sdcard vfat rw,dirsync,nosuid,nodev,noexec,uid=1000,gid=1015,fmask=0702,dmask=0702,allow_utime=0020,codepage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 0
    # mount -o remount,exec /dev/block//vold/179:1 /sdcard
    /sdcard
    # ./flash_image recovery recovery-clockwork-2.5.0.1-heroc.img
    [success!]
    # reboot recovery
    
Advertisement

2 comments

  1. Colin Meyer

    Thanks for documenting your process/experience with this.

    I’ve considered doing this, but haven’t tried quite yet. I’m curious about a few things:

    . what did you do to backup your phone before flashing a new rom?
    . how much of your old configuration were you able to easily recover after installing cyanogen (account info, app installation & configuration, launcher icons placement, etc)?
    . what does cyanogenmod give you over your stock rom?

  2. Andy

    Hey @Colin – good to hear from you again, hope you’ve been doing well.

    -I didn’t do much to backup my phone beyond copying a couple files off the SD card before I flashed it, just in case – I try to keep the phone as disposable as possible in case I lose/drop it. I know Titanium Backup is popular for this use case, but I’ve never tried it.

    -I needed to manually reinstall my apps, but since most of my data “lives” off the phone, a few passwords got me back where I was before. Except icon placement – that was obviously gone.

    -CyanogenMod gives me Froyo instead of Eclair, no more HTC Sense (not a fan myself, although I know others are), better performance, newer (better) Google apps, no more dialer lag. Downsides seem to be poorer battery life, possible stability issues (I’ve had to reset the phone twice) and a poorer soft keyboard.