Graphics mode, Eight-pin graphics modes, Nine-pin graphics modes – Intermec PK80 User Manual

Page 73: Esc k—select single-density graphics mode, Esc k — select single-density graphics mode

Advertising
background image

Graphics Printing

Appendix

C

61

PK80 Series 80-Column Printer User’s Manual

Graphics Mode

Eight-Pin Graphics Modes

All 8-pin graphics functions require parameters, n1 and n2, which repre-
sent the length of the graphics string that follows the Select Graphics Mode
command, and are calculated as follows (assuming a temporary variable n):

n = total number of graphics dots needed for the graphic string
n2 = integer of (n divided by 256)
n1 = remainder of the n2 calculation

The simplest calculation, is to divide n (total number of dots needed for
the graphics string) by 256. Then n2 is the quotient (the whole number)
and n1 is the remainder. If you require less than 256 dots (columns), then
n1 indicates the number of dots and n2 is set to zero.

Nine-Pin Graphics Modes

These 9-pin graphics functions also require two parameters, n1 and n2.
However, they are calculated slightly different than in the 8-pin graphics
modes. Since each dot column to print must be represented by two data
bytes, the total length of the graphic string (following the Select ... Graphics
Mode
command) first need to divide by 2. These parameters are calculated
as follows (assuming a temporary variable n):

n = total number of dots needed, divided by 2
n2 = integer of (n divided by 256)
n1 = remainder of the n2 calculation

First, divide n (the total number of dots needed for the graphics string) by
2, then divide the result by 256. Then, n2 is the quotient (the whole num-
ber) and n1 is the remainder. If you require less than 256 dots (columns),
then n1 indicates the number of dots and n2 is set to zero.

Pins are numbered 1–9, top to bottom, with byte 1 containing the infor-
mation for pins 1–8. Pin 1 is the most significant byte (MSB) of byte 1.
Byte 2 contains the information for pin 9 and is the MSB of this byte.

ESC K — Select Single-Density Graphics Mode

This control code sequence enables 8-pin single density graphics. The total
number of dot columns to print is represented by n1 and n2, which indi-
cates the length of the graphic string that immediately follows. The length
of the graphic string must equal to n1 + (n2 * 256). Graphic string data
that exceeds the length of the print line is discarded. The maximum num-
ber of columns to print in this mode is 480.

Hexadecimal Format

1b 4b n1 n2

Advertising