Brother International PT-P700 Master Command Reference - Page 39

M Select compression mode, Parameters, Description, [TIFF(Pack Bits)], Example

Page 39 highlights

Raster Command Reference M Select compression mode ASCII: M {n} Hexadecimal: 4D {n} Parameters Definitions of {n} 0 No-compression mode (Enabled) 1 Reserved (Disabled) 2 TIFF (Enabled) Description  Selects the compression mode. Data compression is available only for data in raster graphic transfer. [TIFF(Pack Bits)]  1-byte units  If the same data is repeated, the number of data units and that 1 byte of data are specified. If different data is in a series, the number of data items and all of the different data are specified.  If the same data is repeated, the number of data units is specified as the actual number minus 1, expressed as a negative number. If different data is in a series, the number of data units is specified as the number of bytes minus 1, expressed as a positive number.  If the above process results in more than 16 bytes (PT-H500/P700/E500) of compressed data, the data is treated as being all different. As a result, the data will be 17 bytes (PT-H500/P700/E500) , including the 1 byte that specifies the data length. Example 1 raster of raster graphics transfer: Without compression: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 22 22 23 BA BF A2 22 2B...... With compression: ED 00 FF 22 05 23 BA BF A2 22 2B ... a b c a. Since "00h" is repeated for 20 bytes, 20d -> 19d -> 13h changed into a negative number is EDh. Therefore: ED 00 b. Since "22h" is repeated for 2 bytes, 2d -> 1d -> 1h changed into a negative number is FFh. Therefore: FF 22 c. The following 6 bytes remain unchanged. 6d -> 5d -> 5h Therefore: 05 23 BA BF A2 22 2B Continue for the remaining number of bytes for the uncompressed data. Even if 00h continues until the end, it cannot be omitted. - 35 - 4. Printing Command Details

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52

Raster Command Reference
- 35 -
4. Printing Command Details
M
Select compression mode
ASCII:
M
{n}
Hexadecimal: 4D
{n}
Parameters
Definitions of {n}
0
No-compression mode (Enabled)
1
Reserved (Disabled)
2
TIFF (Enabled)
Description
Selects the compression mode. Data compression is available only for data in raster graphic transfer.
[TIFF(Pack Bits)]
1-byte units
If the same data is repeated, the number of data units and that 1 byte of data are specified.
If different data is in a series, the number of data items and all of the different data are specified.
If the same data is repeated, the number of data units is specified as the actual number minus 1,
expressed as a negative number.
If different data is in a series, the number of data units is specified as the number of bytes minus 1,
expressed as a positive number.
If the above process results in more than 16 bytes (PT-H500/P700/E500)
of compressed data, the data
is treated as being all different. As a result, the data will be 17 bytes (PT-H500/P700/E500) , including the
1 byte that specifies the data length.
Example
1 raster of raster graphics transfer:
Without compression:
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 22 22 23 BA BF A2 22 2B……
With compression:
ED 00 FF 22 05 23 BA BF A2 22 2B
a
b
c
a.
Since “00h” is repeated for 20 bytes, 20d
-> 19d -> 13h changed into a negative number is EDh.
Therefore: ED 00
b.
Since “22h” is repeated for 2 bytes, 2d
-> 1d -> 1h changed into a negative number is FFh.
Therefore: FF 22
c.
The following 6 bytes remain unchanged. 6d -> 5d -> 5h
Therefore: 05 23 BA BF A2 22 2B
Continue for the remaining number of bytes for the uncompressed data. Even if 00h continues until the
end, it cannot be omitted.