Chapter 6
Downloadable Graphics
428M Operator’s Manual - 880028-0112 6-5
6.5.3
Binary Compression Algorithm
The binary data that make up the image file is a run-length compressed version of the
image data described in Section 7.2. Bytes with a value of “0” HEX or “FF” HEX are
followed by another byte indicating the number of times that value is repeated.
For example: Suppose the original (uncompressed) image file has a sequence of bytes like:
(All values are listed in Hexadecimal)
“00 01 02 03 04 00 00 00 00 00 00 FF FD FF FF FF FF FF 00 FF”
The encoded result would like this:
“00 00 01 02 03 04 00 05 FF 00 FD FF 04 00 00 FF 00”
Result interpretation:
00 - the first byte is 00
00 - count of 0 (the previous 00 byte is not repeated or repeated zero times)
01 - a 01 byte
02 - a 02 byte
03 - a 03 byte
04 - a 04 byte
00 - another “00” byte in the file
05 - the “00” byte is repeated 5 times for a total of 6 “00” bytes (00+05=6 “00” bytes)
FF - a “FF” byte
00 - count of 0 (the previous “FF” byte is not repeated or repeated zero times)
FD - a FD byte
FF - another FF byte
04 - the FF byte is repeated 4 times for a total of 5 “FF” bytes (FF+04 = 5 “FF” bytes)
00 - another 00 byte
00 - repeat count = 0
FF - another FF byte
00 - repeat count = 0
The compression scheme is slightly inefficient for single 00 HEX and FF HEX occurrences
by entering two for each of these occurrences but most image bitmaps include large areas
of either blank space (00 HEX) or black space (FF HEX).
If a string of more than 255 “00” HEX or “FF” HEX occurs, the byte-plus-count sequence
may be repeated as often as necessary to incorporate all occurrences of the byte. For
example, a string of 1132 “FF” HEX bytes in sequence may be encoded as:
“FF FF FF FF FF FF FF FF FF 6B”
The first four pairs of “FF” HEX each encode 256 bytes of “FF” HEX (one for the first “FF”
byte and 255 copies) totaling 1024 bytes of “FF” HEX. The next “FF” HEX byte adds
another and the 6B HEX adds 107 additional copies for a total of 1132 FF HEX bytes.
(4 X 256)+1+107 = 1132
6.5.4
Uncompressed FONT to RAM (^D104)
This command allows graphic and/or font images (fonts must be less than 64KB
uncompressed) to be transmitted in ASCII-HEX, thereby allowing all data to pass over 7 or
Summary of Contents for 428M
Page 2: ......
Page 4: ......
Page 10: ...vi 428M Operator s Manual 880028 0112 List of Tables 13 9 ...
Page 12: ...viii 428M Operator s Manual 880028 0112 ...
Page 122: ...Downloadable Fonts Chapter 7 7 8 428M Operator s Manual 880028 0112 ...
Page 144: ...Bar Codes Chapter 8 8 22 428M Operator s Manual 880028 0112 ...
Page 150: ...Code Switching Chapter 9 9 6 428M Operator s Manual 880028 0112 Figure 9 5 Code Page 850 ...
Page 154: ...Code Switching Chapter 9 9 10 428M Operator s Manual 880028 0112 Figure 9 9 Code Page 852 ...
Page 158: ...Code Switching Chapter 9 9 14 428M Operator s Manual 880028 0112 Figure 9 13 Code Page 437 ...
Page 162: ...Code Switching Chapter 9 9 18 428M Operator s Manual 880028 0112 ...
Page 168: ...Printer Maintenance Chapter 10 10 6 428M Operator s Manual 880028 0112 ...
Page 180: ...13 10 428M Operator s Manual 880028 0222 ...
Page 182: ...12 2 428M Operator s Manual 880028 0112 ...
Page 184: ...12 4 428M Operator s Manual 880028 0112 ...
Page 204: ...12 24 428M Operator s Manual 880028 0112 ...
Page 206: ...12 26 428M Operator s Manual 880028 0112 ...
Page 207: ......