xLink Documentation |
Version | Dated | Release notes |
1.0 | 1 Oct. 96 |
|
1.01 | 3 Dec. 96 |
|
1.02 | 12 Feb. 97 | |
1.03 | 23 Mar. 97 |
|
1.04 | 03 July 1997 |
|
1.05 | 20 July 1997 |
|
1.06 | 21 September 1997 |
|
1.10 | Real soon now! |
|
Usage: xlink [options] -l <linkfile> [options] Options: -h This text -? This text -m <mapfile> Write a mapfile -n <symfile> Write a NO$GMB compatible symfile -z <hx> Set the byte value (hex format) used for uninitialised data (default is ? for random) -s <symbol> Perform smart linking starting with <symbol> -t <target> Output target gb Gameboy ROM image(default) gb-s Gameboy small mode (32kB) p2 Psion2 reloc module ti83 TI-83 Program ti83+ TI-83+ Program -u Do not protect the program (TI-8x only) -U Do not sqish the program (TI-83 only) -v Verbose mode
A linkfile is used to tell xLink which objects to include and what the outputname should be. It is in plain ASCII-format.
# Linkfile for foobar.gb [Objects] foo.obj bar.obj [Libraries] mylib.lib [Output] foobar.83p
A line starting with # is ignored.
If you use libraries they will only be included if one of the objects actually reference them. This works on a SECTION level and not on a module level. This means that when you write libraries you can put each subroutine in its own SECTION so only the relevant bits are included.
Sections created with HOME in the assembler are placed in the GB bank #0 (the fixed bank $0000-$3FFF) in the order they are loaded from the objectfiles specified in the linkfile. So you want the first file in the linkfile to contain your header. CODE/DATA sections are placed in any bank other than #0. This means you have absolutely no control over which sections goes where. This insures minimal slack (unused bytes) at the end of each bank in the image.
Currently the linker doesn't calculate the GB checksums.
You must use RGBFix to do this.
Small mode forces all DATA/CODE sections to be of type HOME and increases the HOME section size from 16kB to 32kB. This also means that CODE/DATA/HOME sections are written to the final image in the order you have specified in the linkfile.
Currently the linker doesn't calculate the GB checksums. You must use RGBFix to do this.
This is a fileformat for the Psion2 that allows you to load your code into where ever there's any free space. The only sections types allowed are HOME, DATA and BSS. All CODE and DATA sections are written to the output file in the order specified in the linkfile. The BSS are actually then expanded to DATA sections filled with zeroes and appended. This might change later.
The file looks like this (all values are big endian):
LONG NumberOfDataBytes REPT NumberOfDataBytes DB x ENDR LONG NumberOfPatches REPT NumberOfPatches LONG x ; A value to add to the word at address x in the code ENDR
All CODE/DATA sections are places into the TI83 program. The following section types are also allowed: SAVESCREEN, STATVARS, TEXTSHADOW, and PLOTSCREEN. The TI-83+ mode outputs an actual .8xp file, as oppossed to a .83p file renamed as .8xp (as in devpac83).
Last updated 14 January 2003 by Aaron St.John