Personal tools
  [ Home | Forum ]
TOOLBOX
LANGUAGES

Treo 650 Bootloader Custom Code

From ShadoWiki

Jump to: navigation, search

The current method for running custom code in the bootloader is to use a combination of the mb and mw commands to write arm code to RAM, then using the jump command to jump to it.

Creating custom code requires three pieces:

1.  The ARM toolchain from handhelds.org
2.  The armletld script
3.  The makescript tool

When writing code, the code must be compiled with the -fpic GCC flag to specify that it should be linked as "position independent".

Disk-on-chip Layout

The disk-on-chip is organized into three volumes: two "translated volumes" (on storing ROM, the other storing NVFS) and one "binary volume" with the signature "BIPO" that stores the SPL.

Total number of volumes: 2
Scanning Volume 0
=================
mounting...
returned status: 0x0 ...
logicalSectors = 14144
bootAreaSize = 524288
baseAddress = 0
flashType = 39030
physicalSize = 33554432
physicalUnitSize = 32768
DOCType = 8
lifeTime = 1
driverVer = OS Less 6.6.1.0.0
OSAKVer = 6.1.0.0
cylinders = 1010
heads = 14
sectors = 1


Scanning Volume 1
=================
mounting...
returned status: 0x0 ...
logicalSectors = 48704
bootAreaSize = 8093696
baseAddress = 0
flashType = 39030
physicalSize = 33554432
physicalUnitSize = 32768
DOCType = 8
lifeTime = 1
driverVer = OS Less 6.6.1.0.0
OSAKVer = 6.1.0.0
cylinders = 1014
heads = 16
sectors = 3


Total number of binary partitions: 1
Starting block: 262144
Length: 262144