TI-92 Link Protocol Guide - File formats


File Formats

The TI-92 Graph Link software stores variables in several types of files. Single variables are stored in files that have an extension that corresponds with their type. Groups of variables are stored in files with the extension ".92g" and backups with the extension ".92b". However, all of these file types have a common format.

The different file types and contents that the TI-92 Graph Link software can read and write are shown below.
Extension Description

.92a

TI-92 figure

.92b

TI-92 system backup

.92c

TI-92 data

.92d

TI-92 GDB (Graphic Data Base)

.92e

TI-92 expression

.92f

TI-92 function

.92g

Multiple TI-92 variables of varying types (group)

.92i

TI-92 picture (image)

.92l

TI-92 list

.92m

TI-92 matrix

.92p

TI-92 program

.92s

TI-92 string

.92t

TI-92 text

.92x

TI-92 macro

Early link programs for the TI-92 used an additional file type ".92@" because the TI-Graph Link 92 software had not been released for the PC. That format is described in this section as well.


The TI-92 variable file format

The TI-92 variable file format has three parts: a header, a variable table and a data section.

The header appears at the beginning of the file and takes the following format:
Note - All 2-byte and 4-byte integers are stored little-endian Intel-style (least significant byte first).
Offset Length Description
0 8 bytes 8-character signature. The signature is always "**TI92**".
8 2 bytes 2-byte further signature. These two bytes always contain {01h, 00h} = {1, 0}.
10 (Ah) 8 bytes Default folder name (zero terminated unless 8 characters long).
18 (12h) 40 (28h) bytes Comment. The comment is either zero-terminated or padded on the right with space characters.
58 (3Ah) 2 bytes Number of variable and folder entries in the variable table.
Note: If the first byte of the default folder name is 0, then the default folder is the current folder on the receiving unit.

The variable table comes immediately after the header and consists of a number of 16-byte entries, each taking the format described below. Folder entries share the same table. The variables described before the first folder entry are assumed to be in the default folder. Variables described after any given folder entry are placed in that folder.
If no folder entries are included, then variables are considered to be part of the folder named at file offset 0x0A. If this is null, then it is considered to be in the current directory when a link program sends it.

Each variable entry follows this format:
Offset Length Description
0 4 bytes Offset to the data for this variable from the beginning of the file.
4 8 bytes Name of variable (zero terminated if not 8 characters long).
12 (Ch) 1 byte Type ID of the variable.
13 (Dh) 1 byte Attribute (0: none, 1: locked)
14 (Eh) 2 bytes Unused - each byte has a value of 0.

Folder entries follow this format:
Offset Length Description
0 4 bytes Offset to the data for the next variable from the beginning of the file.
4 8 bytes Name of variable (zero terminated if not 8 characters long).
12 (Ch) 1 byte Type ID of the variable. For folders, this value is always 1Fh.
13 (Dh) 1 byte Unused - this byte has a value of 0.
14 (Eh) 2 bytes The number of variables in this folder.

Finally, the data section, which follows the variable table, has this format:
Offset Length Description
0 4 bytes The file size, in bytes.
4 2 bytes A 2-byte signature. These two bytes always contain {A5h, 5Ah}.
6 n bytes Data section.

The data section consists of several variable data parts back-to-back, in order of their listing in the variable table. Each variable part has this format:
Offset Length Description
0 m bytes The variable data. This field includes all bytes transferred in data packets. The first four bytes usually all have a value of 0.
m 2 bytes Checksum. This is the lower 16 bits of the sum of all bytes in the first four bytes and the variable data.


A simplification of the TI-92 file format for a single variable

Files containing single variables are a simple yet common example of the TI-92 file format. In this special case, the file format can be simplified as follows:
Offset Length Description
0 8 bytes 8-character signature. The signature is always "**TI92**".
8 2 bytes 2-byte further signature. These two bytes always contain {01h, 00h} = {1, 0}.
10 (Ah) 8 bytes The parent folder of the variable (zero terminated if not 8 characters long) - See note below.
18 (12h) 40 (28h) bytes Comment. The comment is either zero-terminated or padded on the right with space characters.
58 (3Ah) 6 bytes These 6 bytes always contain {01h, 00h, 52h, 00h, 00h, 00h} = {1, 0, 82, 0, 0, 0}.
64 (40h) 8 bytes The name of the variable (zero terminated if not 8 characters long).
72 (48h) 1 byte The type ID for this variable.
73 (49h) 3 bytes These three bytes always have a value of 0.
76 (4Ch) 4 bytes The file size, in bytes.
80 (50h) 2 bytes A 2-byte signature. These two bytes always contain {A5h, 5Ah}.
82 (52h) n bytes The variable data. This field includes all bytes transferred in data packets. The first four bytes usually all have a value of 0.
82 (52h)+n 2 bytes Checksum. This is the lower 16 bits of the sum of all bytes in the variable data (@52h).
Note: If the first byte of the name of the parent folder is 0, then the variable is put into the current folder on the receiving unit.


The TI-92 backup file format

The TI-92 backup file format is similar to the group file format, but there are some functional differences. Backup data cannot be stored in the same file as variable data, and some of the bytes in a backup file have special meanings. While the backup is sent in several sections, there is only one variable entry for the backup.

TI-92 backup files follow this format:
Offset Length Description
0 8 bytes 8-character signature. The signature is always "**TI92**".
8 2 bytes 2-byte further signature. These two bytes always contain {01h, 00h} = {1, 0}.
10 (Ah) 8 bytes The first byte always has a value of 0; the other seven can have any value.
18 (12h) 40 (28h) bytes Comment. The comment is either zero-terminated or padded on the right with space characters.
58 (3Ah) 2 bytes These 2 bytes always contain {01h, 00h}.
60 (3Ch) 4 bytes These 4bytes always contain {52h, 00h, 00h, 00h} = {82, 0, 0, 0}.
64 (40h) 8 bytes A string which contains the ROM version of the calculator (zero-terminated). Examples: "1.11", "2.1"
72 (48h) 1 byte This byte always contains 1Dh.
73 (49h) 3 bytes These three bytes always have a value of 0.
76 (4Ch) 4 bytes The file size, in bytes.
80 (50h) 2 bytes A 2-byte further signature. These two bytes always contain {A5h, 5Ah}.
82 (52h) n bytes Raw data, made up of the 1-kilobyte blocks stored back-to-back in order of transmission. These blocks do not include the first four bytes of each of the data packets.
82 (52h)+n 2 bytes File checksum. This is the lower 16 bits of the sum of all bytes in the raw data (@52h).


The early 92@ file format

Linking programs were available for the TI-92 before TI released the TI-92 Graph Link for the PC. The creators of Link92xp, one of these early TI-92 linking programs, designed this file format to store the information. While this format was never supported by TI and is now obsolete, there are still some 92@ files floating about the internet.

92@ files start with a header with this format:
Offset Length Description
0 8 bytes 8-character signature. The signature is always "**TI92**".
8 3 bytes 3-byte further signature. These two bytes always contain {1Ah, 0Ch, 00h} = {26, 12, 0}.
11 (Bh) 42 (2Ah) bytes Comment. The comment is either zero-terminated or padded on the right with space characters.
53 (35h) 2 bytes Length, in bytes, of the data section and the checksum (n+2). This value should be 37h less than the file length.
55 (37h) n bytes Data section - made up of a number of entries, described below.
54 (36h)+n 2 bytes File checksum. This is the lower 16 bits of the sum of all bytes in the data section.

Each variable entry in the data section has this format:
Offset Length Description
0 1 byte Offset from the next byte to the data length field. This number should be 4+m, where m is defined below.
1 2 bytes Offset from the beginning of the entry to the raw data. This number should be 3 more than the value at offset 0.
3 1 byte Variable type ID.
4 1 byte Length, in characters, of the variable directory/name field.
5 m bytes Variable directory/name. If a directory is specified, its name comes first, followed by a backslash (\) character, then the variable name. If no directory is specified, there is no backslash and the variable is put in the current directory of the calculator.
5+m 2 bytes Length, in bytes, of the variable data.
7+m n bytes The variable data, not including the first five bytes sent with the data packet. The first four bytes of the packet are unimportant, and the fifth byte of the packet can be calculated by subtracting 2 from the value at offset 5+m and taking the upper 8 bits.

[previous page]
Variable Formats

[home]
Table of Contents

[next page]
Tokens and Characters


Site maintained by Romain Liévin (roms@lpg.ticalc.org) and Tim Singer (tsinger@gladstone.uoregon.edu)