Product manual
Data compression
47
The following table illustrates this simplified operation.
Input
Byte
Current
String
Match
Build
Entry
Output Code
Value
RR Y — —
IRI NRI(R)
—I Y — —
NIN N IN(I)
—N Y ——
TNT N NT(N)
—T Y ——
ITI N TI(T)
—I Y ——
NIN Y ——
T INT N INT (IN)
—T Y ——
ITI Y ——
N TIN N TIN (TI)
—N Y ——
Dictionary
The dictionary is built and contained logically in external RAM and is not output as a
distinct item. Rather, the decompressor recreates the dictionary to recreate the
original data.
The dictionary allows up to 4,096 entries with each entry made up of:
•
The unique string found in the data stream
•
The codeword for that string
Codewords represent strings of up to 128 characters and are formed by adding a
new character to an existing codeword. These codewords range from 9 through 12
bits in size and are assigned a number in the range 0 through 4,095.
These codewords are either control flags, encoded bytes or dictionary codes. The
following points explain these three types of codewords.
•
Control Flags, codewords 0 through 7: These control flags are reserved
codewords that flag specific conditions as follows:
0 Dictionary frozen
1 Dictionary reset
2 Increment codeword size
3 End of record (EOR)
4–7 Reserved
•
Encoded bytes, codewords 8 through 263: These encoded bytes represent
single bytes of the input data stream and contain the values 0 through 255.