Back to ARM page
This patching tool works for simple programs that don't use globals and large variables (like arrays).
You need the patch&convert tool.
For multiple files compilation, follow the next steps:
- go to the gcc-arm-elf/bin directory, put all tools inside.
- Compile the C sources :
C:> arm-elf-gcc.exe -c file1.c file2.c -mtune=arm920t -mcpu=arm920t -mlittle-endian -mapcs-32 -fPIC -fomit-frame-pointer -O3
- use the linker for elf format:
C:>arm-elf-ld.exe -Ttext 0 --entry=main -nodefaultlibs -nostdlib -static file1.o file2.o -o prog.exe
Just a void main() entry point is needed here. Registers will be saved and main will
be called by the patcher.
- Patch the exe file to obtain a HP string containing the binary:
./HPpatch prog.exe prog.hp
You can use the [-v] flag to see the output and entry points table.
- Send it to the HP49 and use the ARM launcher
("A>CP" version, see Al's page).
The HPpatch only works for C programs without globals&arrays.