The TallyGenicom 7265 provides rugged, versatile impact printers useful in a variety of
applications. Flexibility of use is guaranteed by the wide range of software emulations and
programming options. The current printer characteristics are the result of years of application
experience. It is a hallmark of TallyGenicom products that they may be used with a broad
range of systems, hardware, emulations, and protocols.
All trademarks and registered trademarks are property of their respective holders.
CENTRONICS of GENICOM LLCEpson of Epson America, Incorporated
DEC of COMPAQ Corporation GENICOM of TallyGenicom LP
IBM and Proprinter of International Business Machines Corporation
The information in this manual is believed to be accurate and correct. However, TallyGenicom
makes no claim as to its absolute accuracy and reserves the right to make improvements to this
document from time to time.
The TallyGenicom imple m entation of ANSI X3.64 is the native control protocol for the 7265
printer, as it is for a variety of other TallyGenicom impact matrix printer families. The control
functions presented here are a superset of ANSI control sets familiar to our customers. For the
most part, ANSI drivers written for other TallyGenicom printers should only need to be modified as
features introduced on the 7265 Series printers are exercised. Examples of such new features
include user-defined formats, alternate paper paths, user-defined character substitutions, and
remote selection of emulations.
Enabling the application to select among emulations provides access to some of the 7265
features not supported in emulated products. Toward this end, the printer can be commanded to
maintain the current status of fonts, pitches, tabs, margins and so forth across emulation
changes. Although some minute differences due to translations from, say, columns to decipoints
may be discernible when switching from one emulation to another, the printer is quite predictable
when switching from another emulation to ANSI and then back again.
The 7265 is a decipoint machine. Locations and dimensions such as tabs, margins, absolute and
relative positions, and form lengths are described in ANSI control sequences in units of 1/720
inch. If you have the choice of describing your page in one or another of the supported
emulations, consider that ANSI gives you more flexible control of locations of objects on the page.
In this chapter we include spaces between characters in escape sequences for clarity. ESC H,
for instance, is easier to read than is ESCH. Where the space character forms a component of a
control sequence, then it is designated by <SP> .
Listed below are the control codes interpreted by this printer, along with page numbers where you
can find detailed descriptions.
IND84IndexESC D1B 44
NEL85Next LineESC E1B 45
HTS88Set Horizontal TabESC H1B 48
VTS8ASet Vertical TabESC J1 B 4A
PLD8BPartial Line DownESC K1B 4B
PLU8CPartial Line UpESC L1B 4C
RI8DReverse IndexESC M1B 4D
DCS90Device Control StringESC P1B 50
PU191Private Use 1ESC Q1B 51
CSI9BControl String IntroducerESC [1B 5B
ST9CString Terminat orESC \1B 5C
OSC 9D Straps and Options Introducer ESC ] 1B 5D
8-bit Control Codes
ANSI assigns control functions to characters 80 hex through 9F hex and calls these characters
C1 codes. You can set the printer to either interpret 80 hex - 9F hex as control codes or not. The
ISU default status of this option is disabled.
You can toggle the status of the 8-bit control code enable from the Emulations Options Menu or
with escape sequences. The pertinent escape sequences are the ANSI private use sequences
described on page 12. In 8-bit mode, all of the lower contro l codes and ESC sequences remain
active. For example, you can use either PLD or ESC K for subscript printing. In 7-bit mode, only
ESC K is available.
If 8-bit control code interpretation is disabled, then the printer processes characters 80 hex
through 9F hex according to IBM PC character sets 1 or 2, depending on which is currently
selected. The default is character set 1. You can toggle the character set selection from the
Emulation Options Menu.
If 8-bit control code interpretation is disabled and character set 1 is active, then the printer strips
the most significant bit of characters 80 hex through 9F hex. For example, if you send 8A hex
when 8-bit control code interpretation is disabled and character set 1 is active, then the printer
treats 8A hex as 0A hex and performs a line feed.
ESC [(p)aHorizontal Position Relative
ESC [(p)dVertical Position Absolute
ESC [(p)eVertical Position Relative
ESC [(p1);(p2)fVertical and Horizontal Position Absolute
ESC [(Ps)gClear Tabs
ESC [(p1);...(pn)hSet Auto CR on LF
ESC [>(p1);...(pn)hSet Mode (GENICOM)
ESC [(p)jHorizontal Position Backwards
ESC [(p)kVertical Position Backwards
ESC [(p1);...(pn)lReset Auto CR on LF
ESC [>(p1);...(pn)lReset Mode (GENICOM)
ESC [(P1);...(Pn)mFonts and Print Modes (SGR)
ESC [(p1)pSelect Paper Path
ESC [(p1)qSelect Graphics Density
ESC [(p1);(p2);(p3)rForms Setup
ESC [(p1);(p2)sSets Left and Right Margins
ESC [(p1)tENA/DIS Oversized/Expanded/Bar Code
ESC [(p1);(p2);...(p22)uSet Horizontal Tabs at Certain Positions
ESC [(p1);(p2);...(p12)vSet Vertical Tabs at Certain Positions
ESC [(p1);(p2);…}Set Bar Code Parameters
ESC [(p)xNational Character Sets
In serial interface, if the printer is strapped for XON/XOFF handshaking, then
the printer sends DC1 to the host to signal that the printer is ready to accept
data.
In parallel interface, if the printer is strapped for select/ deselect by received
DC1/DC3 codes, then the host sends DC1 to the printer to set the printer
online.
Dec 17Hex 11
DC3PRINTER NOT READY
In serial interface, if the printer is strapped for XON/XOFF handshaking, then
the printer sends DC3 to the host to signal that the printer cannot, for the
moment, accept any more data.
In parallel interface, if the printer is strapped for select/ deselect by received
DC1/DC3 codes, then the host sends DC3 to the printer to set the printer to
Standby. In Standby, the printer will accept and acknowledge data from the
interface, but will discard all data received.
Dec 19Hex 13
ETXETX/ACK COMMUNICATION PROTOCOL
In serial interface, if the printer is strapped for ETX/ACK handshaking, then the
host sends the ETX control code at the end of a block of data.
Dec 3Hex 03
ACKETX/ACK COMMUNICATION PROTOCOL
In serial interface, if the printer is strapped for ETX/ACK handshaking, then the
printer sends an ACK in response to and ETX from the host to indicate that it is
ready to receive more data.
You can strap the printer to start either barcode (page 37) or oversized (page 64)
mode, whichever is enabled, on receipt of SO. The ISU status of SO/SI control is
disabled. You can enable SO/SI control from Software Options on the printed menu,
or from the host via the Straps and Options control sequence. See page 14.
Dec 14 Hex 0E
SISHIFT IN
If the printer is strapped to turn on barcode or oversized on receipt of SO, then SI
turns barcode (page 37) or oversized (page 64) mode off.
Dec 15 Hex 0F
ESCESCAPE
Introduces an escape sequence. The printer evaluates characters following the ESC
character to determine if the sequence is valid. If the sequence is valid, then the
printer responds to the command. If the sequence is not valid, then the printer aborts
the process, discarding at least the first character following ESC.
Dec 27Hex 1B
ESC P
(DCS)
ESC [
(CSI)
ESC \
(ST)
ESC ]
(OSC)
DEVICE CONTROL STRING
The control function introducer for the device control string structure, which is used to
frame graphics.
Dec 144Hex 90
The CSI character is the control function introducer for the ANSI control sequence.
Control sequences are multi-character control functions that accept parameters.
Dec 155Hex 9B
STRING TERMINATOR
Terminates the DCS and the OSC sequence.
Dec 156 Hex 9C
The OSC character is the introducer for straps and options.
DEL is a printable character, or is a valid graphics data byte if received
in dot graphics
Dec 127 Hex 7F
ESC [(p1);
(p2)<SP>~
SELECT EMULATION
If p2 is 0, which is the default, then the current settings in the printer remain in effect
through the emulation change to the extent that selected features are supported in
the target emulation. This affects such things as, font selection, character pitch,
margins, tabs, and so forth. If p2 is 1, then the status of such parameters reverts to
defaults dependent on the selected emulation.
p1 selects
0 GENICOM ANSI
1 Tally ANSI
2-21 Reserved
22 Epson FX286e
mode.
p2 selects
0-1 full reset
Example: Select Epson emulation with full reset:
Dec 27 91 50 50 59 49 32 126 Hex 1B 5B 32 32 3B 31 20 7E
ESC [(p1)pSELECT PAPER PATH
p1 selects
08 unload current path
10 unload current path and load tractor 2
12 unload current path and load tractor 1
Forms in the current path should be torn off before changing paper paths. If
you send a command to change paper paths and there is more paper
downstream of the print head than 1/2 times the current form length or six
inches, whichever is greater, then the printer returns paper to the position that
was current before the command was received, and a fault condition is set.
If you send a command to change paper paths and the target path is the
current path, then the printer executes a form feed. If you load tractor 2
when tractor 2 is not installed, the command will be ignored.
Example: Unload tractor 1 and load tractor 2:
Dec 27 91 49 48 112 Hex 1B 5B 31 30 70
0 reset special modes
1 select oversized printing4-2
2 select expanded printing 4-2
3 select bar code 3-6
Oversized printing and bar codes are explained in separate chapters. When
expanded printing is selected, the current font is expanded horizontally and vertically
in 100% increments according to expansion factors specified by ESC
[(p1);(p2)<SP>B (see page 11). The range of expansion is 1x through 8x.
GRAPHIC SIZE MODIFICATION
Sets the size of expanded and oversized characters. The effect of this command on
oversized is explained in a separate chapter.
When expanded print is selected, the argument units for parameters p1 and p2 are
percentages of the vertical and horizontal dimensions of the current font. Parameter
p1 controls the vertical expansion and p2 controls the horizontal expansion. The
argument limits for expanded print are 800;800 (8x the parent font size).
Oversized enables much larger expansions. Parameters are rounded down to the
nearest 100.
Note: This printer goes into expanded mode immediately on receiving this
command. Any text between this sequence and a countermanding ESC [(p1)t
sequence (see page 11) is printed according to the specified expansion.
If height and width are different values, the height will be set the same as the width.
ESC [(p1);
...(pn)h
SET MODE (ANSI)
p Effect
20auto CR on LF
Dec 27 91 50 48 104 Hex 1B 5B 32 30 68
RESET MODE (ANSI)
Resets mode(s) set by ESC [(p1);..(pn)h.
p Effect
20reset auto CR on LF
Example: reset auto CR on LF
Dec 27 91 50 48 108 Hex 1B 5B 32 30 6C
ESC [>
(p1);..(pn)h
ESC [>
(p1);..(pn)l
SET MODE (GENICOM)
This is an ANSI private use sequence.
p Effect
1 proportional print
2 reserved
3 80 hex - 9B hex interpreted as C1 control codes
4 bold mode accomplished by overstrike
5 select character set 2
Example: set proportional print
Dec 27 91 62 49 104 Hex 1B 5B 3E 31 68
RESET MODE (GENICOM)
Resets modes set by ESC [>(pn)h. See the previous command. The parameter
definitions are the same.
Example: reset proportional print
Dec 27 91 62 49 108 Hex 1B 5B 3E 31 6C
PAPER SHEAR
If the paper shear option is installed, then note that the appropriate strap must be set
in the hardware options menu in order for the paper shear to work.
Parameter p1 = 1 selects the paper shear.
Parameter p2 = 1 executes a cutting sequence: If the vertical position is not at top-of-
form, then a form feed is executed. Paper is advanced to the shear position and cut.
Next, it is advanced an inch to eject the sheet that has been cut off; then it is
retracted to the top margin on the following form. The horizontal position following a
shear is the left margin. The shear position should be set from the control panel so
that paper is cut precisely at the perforation. If a non-zero top print reference is
needed, then set the top print reference first and then set the shear position.
STRAPS AND OPTIONS
This command enables downline control of options found at various places in the
printer menus. This includes the Emulation and Software Options menus, as well as
the User-defined Options menu. For details and descriptions, see the User’s
Manual.
0 USA
1 Germany
2 French A
6 Italian
7 United Kingdom
8 Spanish
9 Danish/Norwegian A
16 Swedish/Finnish D
If a parameter value (p) is not recognized, then the default character set (0 - USA) is
selected.
To use substitutions that have characters in the 80 hex to 95 hex range, first disable
8-bit control code processing, either by escape sequence or from the Emulation
Options Menu. Next, enable character set 2, either by the Straps and Options control
sequence on page 14 or from the Emulation Options menu. This causes ASCII
codes 80 hex - 9F hex to be mapped to printable characters instead of control codes.
Example: To select the United Kingdom character set:
Dec 27 91 55 120 Hex 1B 5B 37 78
LINE/CHARACTER SPACING
Sets the vertical and horizontal pitch in decipoints. Parameter (p1) is the
spacing between lines and (p2) is the spacing between characters.
Unspecified parameters remain at their current values. This command
does not affect oversized printing selected by ESC [1t.
LINE/CHARACTER SPACING
p1 = line spacing parameter p2 = character spacing parameter
If you select doublewide printing (ESC [5m), then the printer doubles character
spacing set by this command. If the designed pitch of the current font is 10 cpi and
doublewide is set, then a character spacing argument of 72 results in a pitch of 5 cpi,
at which horizontal segments of line-draw characters are contiguous.
Example: ESC [90;60 <sp> G
sets the vertical spacing to 8 lines per inch and the horizontal spacing to 12
characters per inch. (720 divided by 8 = 90, and 720 divided by 12 = 60).
FORMS SETUP
Sets top of form and sets form length, as well as top and bottom margins, in decipoints.
Parameter
p1 is form length 720ths ,
p2 is the top margin,
p3 sets the length of white space between the baseline of the last allowed
line and the end of form.
p4is the top print reference, and
p5 is the left print reference
Any parameter not specified is assigned its default value. Maximum form length is
15840 decipoints (22 inches).
Default Values
p17920 decipoints 11-inch form
p2 0 decipoints 0-inch top margin
p3 0 decipoints 0-inch bottom margin
p40 decipoints0-inch top print reference
p50 decipoints0-inch left print reference
Example:
Set 8-inch form length, one-inch top margin, one-inch bottom margin
Dec 27 91 53 55 54 48 59 55 50 48 59 55 50 48 114
Hex 1B 5B 35 37 36 30 3B 37 32 30 3B 37 32 30 72
Note: Before you send this command, verify that the top print reference is zero in the
target paper path. One way to do this is to park and then load paper in the target path.
The top edge of the paper should line up with the top of the print head. If not, then set
the top print reference to zero from the menu and save the change to the format
associated with the target paper path. You must once again park and load paper in the
target path in order for the new print reference to take effect.
Next, send a command to set the vertical position-absolute to zero. If you do not do
this, then the printer establishes top-of-form at the current top margin, and form
registration is lost.
NOTE: The partial line up does not respect top of form; that is, following a form feed, ESC L causes a partial line
movement upward. Also, partial line down does not respect bottom of form; that is, when printing the last line on
the form, ESC L causes a partial line movement downward.
SUBSCRIPT PRINTING
Moves paper 1/2 line below the current line for subscript printing. ESC K is used to
return to the original line following ESC L (superscript).
If 8-bit control code processing is enabled then
Dec 139 Hex 8B
otherwise
Dec 27 75 Hex 1B 4B
SUPERSCRIPT PRINTING
Moves paper 1/2 line above the current line for superscript printing. ESC L is used to
return to the original line following ESC K (subscript).
If 8-bit control code processing is enabled then
Dec 140 Hex 8C
otherwise
Dec 27 76 Hex 1B 4C
When printing the last line on a form, do not send a line feed (LF) code to move directly from superscript to
subscript. The LF code will be acted upon as the bottom of form terminator.
Absolute positions are calculated from the top and left print references without respect to margin
settings. The top of a character cell located at vertical position-absolute 0 is at top print reference.
The left edge of a character cell located at horizontal position-absolute 0 is at the left print
reference. If the default left print reference is current, and if the left tractor position(s) are as
shipped, then this is about 0.6 inches from the left edge of the paper.
Top and left print references are adjustable from the printer menu.
To
Shee
A
Extreme
Left Position
Character Printed at Zero Position
CAUTION: Do not attempt reverse paper motion across a perforation, since this may cause the
paper to snag on the print head. Vertical position accuracy is not specified for reverse paper
moves greater than 1.5 inches.
Advances the paper one line according to the spacing currently in effect.
Dec 10 Hex 0A
VTVERTICAL TAB
Advances paper to the next vertical tab setting. If the current print position is at or
beyond the last tab setting, the paper advances to the top of form. If no tabs are set,
then VT is processed according to the status of emulation option strap 14.
Dec 11 Hex 0B
FFFORM FEED
Advances the paper to the top margin on the next form.
Dec 12 Hex 0C
ESC D
(IND)
ESC E
(NEL)
ESC M
(RI)
INDEX
Advances the paper to the next line. The current column is not changed, regardless
of the status of auto CR on LF.
Dec 132 Hex 84
NEXT LINE
The next line character advances the paper to the next line. The current column is
reset to the left margin. Auto CR on LF has no effect.
Use the Forms Setup command, page 2-39, to set vertical margins.
CommandsDescription
ESC [(p1);6 (p2)sSET LEFT AND RIGHT MARGIN
Sets the left and right margin in decipoints; p1 is the left margin and p2 is the
right. Distances are measured from the left print reference. This command
takes effect following the next line terminator (you cannot set margins for the
current line).
EXAMPLE: Set the left margin at 0.4 inch and right margin at 6.9 inches,
making a 6.5-inch print line.
Assigns the default parameters. Sets the left margin to zero, right margin to
maximum print line width of the printer. This command takes effect following the
next line terminator.
Causes the current print position to move to the next tab stop. If no tabs are set, then
the current position moves one space. If tab(s) are set but no tab(s) are set between
the active print position and the right margin, then following characters on the line are
either discarded or printed on the next line, depending on the status of auto wrap.
Dec 9 Hex 09
CRCARRIAGE RETURN
Initiates printing and returns the current print position to the left margin.
Dec 13 Hex 0D
ESC [(p)aHORIZONTAL POSITION RELATIVE
Advances the current print position by the distance specified. Parameter p is
specified in decipoints.
Example: ESC [1080a advances the print position 1.5 inches.
Dec 27 91 49 48 56 48 97 Hex 1B 5B 31 30 38 30 61
ESC [(p)jHORIZONTAL POSITION BACKWARDS
Moves the horizontal position (p) decipoints left of the current position.
Actual distance between symbols separated by this command is the argument (p)
minus the current horizontal pitch (text or graphics). For example, if you print an
uppercase E at 10 cpi, move backwards by (p), and print another uppercase E, then
the distance between leading edges of the two characters is (p) - 72 decipoints. If you
print graphics at 72 dpi, move backwards by p, and print another graphics column,
then the distance between the two graphics columns is (p) – 10 decipoints.
This command enables printing left of the left margin. Any data located left of the left
print reference is discarded.
Example: ESC [1080j moves the horizontal position back by 1.5 inches.
Dec 27 91 49 48 56 48 106 Hex 1B 5B 31 30 38 30 6A
This printer stores tab stops in NVRAM while power is off. Therefore, all tab stops should be cleared before new
stops are set.
CommandsDescription
ESC H
(HTS)
ESC [(p1)
(p2);..(p22)u
ESC J
(VTS)
ESC [(p1);
(p2);.. (p12)v
ESC [(Ps)gCLEAR TABS
SET HORIZONTAL TAB AT CURRENT POSITION
If 8-bit control code processing is enabled then both
Dec 136 Hex 88
otherwise only
Dec 27 72 Hex 1B 48
SET HORIZONTAL TABS AT SPECIFIED POSITIONS
Sets up to 22 stops at one time. The value of p1, p2, etc. are in
decipoints (1 inch = 720 decipoints).
The above example sets tabs at 1 inch and 4 inches. Existing tab stops ar e not
cleared. Margin settings have no effect on the positions of tab stops.
SET VERTICAL TAB AT CURRENT POSITION
If 8-bit control code processing is enabled then both
Dec 138 Hex 8A
otherwise only
Dec 27 74 Hex 1B 4A
SET VERTICAL TABS AT SPECIFIED POSITIONS
Sets vertical tabs at positions p1, p2, p3, etc. Up to 12 stops can be set at one
time. Tab stops are measured in decipoints from the top print reference.
Example: Set tab stops at 4 and 7 inches.
0 clear horizontal tab at current print position
1 clear vertical tab at current position
3 clear all horizontal tabs
4 clear all vertical tabs
Example: Clear all horizontal tabs
Dec 27 91 51 103 Hex 1B 5B 33 67
Dot graphics allows you to print individual dots at any position on the page and thus to print
pictures as well as text. When you enter dot graphics, the printer defaults to a dot density of 72
dpi horizontally and vertically, and a line spacing of 12 lpi. Exiting from dot graphics returns the
printer to its prior lpi setting. You can also choose a density of 144 dpih x 72 dpiv. The printer
powers up in low density. The density remains as last set until it is changed, or until power is
turned off.
Each byte of graphics data defines one column of dots that is six dots high. You can think of the
least significant six bits in the byte as controlling the topmost six wires of the print head, with the
first bit controlling the top wire and the sixth bit controlling the sixth wire down. If you wanted to
fire all six wires, then you would send a byte with a decimal value of 63. Byte values of 0 through
31 decimal are interpreted as control codes, so you have to add 64 to any graphics data byte less
than 32 decimal.
You would expect to be able to simply add the value 64 decimal to every graphics data byte; in
other words, just set the seventh bit. This is risky because some variations within the 3000
product family interpret decimal 127, the Delete character, within a graphics sequence. The effect
is to delete everything following the last line terminator. The safest course is:
The set of control codes that are interpreted while in graphics mode are shown in the following
charts. Bytes less than 32 decimal that are not interpreted as control codes are ignored. The
printer processes valid escape sequences within a graphics data sequence. This is potentially
useful, for instance, in the cases of the absolute and relative position commands. A valid escape
sequence that is not applicable to graphics mode, such as bold printing mode, will be
implemented for text on exiting graphics. If the printer receives a nonvalid escape sequence while
in graphics mode, then it drops out of graphics mode.
CommandsDescription
BELBELL
Causes the beeper to sound for about 1/2 second.
Dec 7 Hex 07
HTHORIZONTAL TAB
Causes the print head to move to the next tab stop.
Dec 9 Hex 09
LF
(NEL)
VTVERTICAL TAB
FFFO RM FEED
CRCARRIAGE RETURN
INDINDEX
RIREVERSE INDEX
ESC PENTER DOT GRAPHICS MODE
ESC \EXIT DOT GRAPHICS MODE
LINE FEED
Graphics next line. Causes printing to move to the left margin on the following line.
If 8-bit control code processing is enabled, then NExt Line does the same thing.
Dec 10 or 133 Hex 0A or 85
Causes printing to move to the left margin at the next vertical tab stop.
Dec 11 Hex 0B
Causes printing to move to the top left margin on the following form.
Dec 12 Hex 0C
Causes printing to move to the left margin on the current line. This permits
overprinting the current line.
Dec 13 Hex 0D
If 8-bit control code processing is enabled, then a line feed is performed at the
graphics vertical pitch. The horizontal position stays the same.
Dec 132 Hex 84
If 8-bit control code processing is enabled, then a reverse line feed is performed at
the graphics vertical pitch. The horizontal position stays the same.
Dec 141 Hex 8D
Also sets line spacing to 1/12 inch so that LF produces contiguous graphics lines.
Dec 27 80 Hex 1B 50
Also restores line spacing to its previously set value.
This chapter describes the characteristics and lists ANSI control sequences for 23 resident bar
code styles. You have to be in ANSI emulation to print the resident bar codes. You can adjust
various bar code attributes including rotation, height, print density, status of the human-readable
line, and element widths. Subject to some constraints based on style and rotation, the humanreadable font is also selectable. For some styles, the printer will calculate checksum characters
for you.
To print a bar code symbol, you need to:
1) Set the printer to ANSI emulation.
2) Send the escape sequence to set the user-adjustable attributes. Always do this at least
once.
3) Send the control sequence to turn on bar code.
4) Send the ASCII representation of symbol data you want to encode.
5) Send the control sequence to turn off bar code.
6) Send a line terminator at some point thereafter.
In bar code parlance, a module is the narrowest nominal width of measure, while an element is a
single bar or space. A character is a group of elements that represents a number, letter, or
punctuation mark. A symbol is a group of characters that can stand alone in terms of being
interpreted by the reader. A symbol always comprises one or more data characters framed by
white spaces known as quiet zones. The symbol frame almost always includes start and stop
characters. Depending on the style, some bar code symbols can also include check characters,
center characters, and guard bars.
Among printers that generate bar codes internally and that also support any user-adjustment of
bar code widths, some enable the specification of module width, while others, such as this one,
enable the adjustment of element widths. From the programmer's point of view, adjustable
module widths tend to guarantee that the ratio among element widths remains correct, while
adjustable element widths afford more flexibility.
When we ship the printer, the ratios among element widths in a given bar code style are within
generic specifications for that style. You can restore these default element widths by performing
an initial setup (ISU) as described in the User's manual. Since this printer lets you specify
element widths independently of each other, it is possible to print bar codes that are outside of
generic specifications, or outside of the limits of your particular reading system, or both. You need
to know the requirements of your system before you program your printer.
Bar codes printed with this printer are suitable for readers designed for low- or medium-density
bar code symbols. Avoid readers with apertures smaller than 7 mils. If bar codes are to be read
with an infrared reader, then you must use a special carbon ribbon.
The examples given in this section use the Code 3-of-9 format.
Programmers tend not to trust form feeds and sometimes use line feeds instead to move from
one form to another. If there is any advantage to that approach, it is that the vertical move will not
depend on the current form length. When printing bar codes on labels, you can greatly simplify
your task by setting a form length that exactly matches the length of your physical form and then
using form feeds to make vertical moves between labels or rows of labels.
If you print nothing but text, then the vertical position following each line feed lies on a grid that is
evenly spaced according to the line feed increment. If you print a bar code symbol, then positions
established by subsequent line feeds may not be on that grid. The vertical position following a bar
code symbol becomes the origin for a subsequent line feed; this new origin must be computed
based on bar code height, and the status of the human-readable line.
If you do not initialize your vertical position with a form feed for each row of labels, then printed
objects may creep cumulatively up or down with respect to the top of your physical form.
Values of all the adjustable bar code parameters are stored in NVRAM while power is off. You
can restore the bar code attributes to the factory settings by performing an ISU on the printer.
pn Attribute
p1style
p2height
p3human readable line enable
p4narrow bar width
p5wide bar width
p6narrow space width
p7wide space width
p8 N / A
p9rotation
p10horizontal print density
p11check character
p12human readable font
p13height (in 1/24” increments)
General Rules for Assigning Parameters
You can send the sequence to modify bar code parameters any time except when bar code
mode is active.
If you assign a parameter value outside the permissible range, then that parameter value
reverts to the default value.
Values for narrow bars must be less than values for wide bars. Values for narrow spaces
must be less than values for wide spaces. The ratio between wide and narrow elements
should be about 3:1.
As with other ANSI escape sequences that take multiple parameters, you can use the semicolon
as a place holder when you want to change a higher-numbered parameter while leaving lowernumbered parameters alone. For example, to set the horizontal print density to 60 dpi without
changing any other bar code attributes, you could send:
ESC [;;;;;;;;;0;;}
Semicolons that trail the last specified parameter are optional. For example, to turn off the
human-readable line without changing any other parameters, you could send:
ESC [;;0}
Or, you could send:
ESC [;;0;;;;;;;;;}
Note: The term “default” is misleading when applied to bar code parameters. This printer stores
bar code parameters in nonvolatile RAM while power is off; except for an ISU or an out-of-range
argument, you might never see the effects of the factory defaults. For this reason, your
application should probably initialize all 12 parameters one time before any symbols are sent.
This is particularly true when other bar code applications are sharing the printer.
Note: Each of the four Codabar styles will accept any combination of valid start-stop characters
that you send. If you do not send any start-stop characters, then the printer generates start-stop
characters according to the style in force.
Height of the bar code in 1/12-inch increments. The default is ¾ inch, which corresponds to an
argument of 9.
Caution: In some versions of the printer, the last non-zero value of p13 supplants all subsequent
values of p2 until you ISU that printer. (See page 41.)
An argument of 1 turns on the human-readable line, while 0 turns it off. The default is on. When
the human readable line is enabled, it is printed in the font specified by parameter p12. There is
0.1" between the bottom edge of the bar code and the top of the characters in the human-
readable line.
Element Widths
The default element widths are the narrowest that we recommend for consistent readability.
The argument units for horizontal bar code element widths are 1/120 inch. The print wire diameter
is 1/72 inch; a printed dot is about 1/60 inch in diameter. This is the finest line that the printer can
make. The printer accepts an element width of 1 as a valid argument, but the actual width of the
resulting element is 1/60 inch, the same as if you had specified a width of 2.
If the element width argument is greater than 2, then the printer rounds down odd numbers. A
width argument of 5 produces the same result as a width argument of 4.
p4 - Narrow Bar Width
Argument units are 1/120 inch if the bar code is horizontal (0o or 180o rotation) or 1/144 inch if the
bar code is vertical (90
p5 - Wide Bar Width
Argument units are 1/120-inch increments if the bar code is horizontal or 1/144 inch if the bar
code is vertical. The default is 6.
p6 - Narrow Space Width
Argument units are 1/120-inch increments if the bar code is horizontal or 1/144 inch if the bar
code is vertical. The default is 2.
p7 - Wide Space Width
Argument units are 1/120-inch increments if the bar code is horizontal or 1/144 inch if the bar
code is vertical. The default is 6.
Wide space and wide bar are both set to the smaller of the two values. This sets the proportion
of the large to small the same for spaces as it is for bars.
Sets the absolute rotation in 90 degree increments. If parameter p12 = 0, then the humanreadable font is shown in the following table:
p9RotationHR Font if p12 = 0
0no rotation (default)current font
1no r otat ionspecial bar code HR font
2o270 rotation special bar code HR font
3 no rotation special bar code HR font
4 270o rotation special bar code HR font
A value of 0 is 60 dots per inch, while a value of 1 is 1/120 dots per inch. The default depends on
the style in force. EAN and UPC styles default to 1. All other styles default to 0.
Note: This parameter affects bar codes printed at 0
resolution, then bar codes are darker and are printed at a somewhat slower speed.
p11 - Check Character Enable
N / A
p12 - Human Readable Font
N / A
p13 - Height in 1/24-inch Increments
Normally, bar code height is specified in 1/12-inch increments by p2. Only specify p13 if your job
requires the associated higher resolution of bar code height. A non-zero value of p13 supplants
the value of p2.
Caution: In some versions of the printer, a non-zero value of p13 supplants all subsequent
values of p2 until you ISU that printer. To be on the safe side, if you do not plan to use p13, then
set p13 to 0. NOTE: Bar code height is limited to 10 inches.
A bar code delimiter is a character or control function that tells the printer where one bar code symbol ends and
an adjacent symbol begins. Different bar code styles accept different delimiters, which might be spaces,
commas, asterisks, horizontal tabs, or horizontal position-relative commands. Valid delimiters for the various
styles are listed in the Bar Code Style Characteristics section.
There is always a minimum one-fourth inch of white space called the quiet zone on either side of a bar code
symbol, so there is always an irreducible half-inch space between adjacent symbols, no matter which delimiter is
used. The space character occupies an additional tenth of an inch. Neither the comma nor the asterisk imposes
any additional space between symbols. Asterisks are valid delimiters in Code 3 of 9 (style 4) only, and are
normally used in pairs.
110 LPRINT CHR$(27);"[0;9;1}"; 'height 3/4", hr = on, interleaved 2 of 5
120 LPRINT CHR$(27);"[3t"; 'turn on bar code
140 LPRINT "001234,001234"; 'comma delimiter
150 LPRINT CHR$(27);"[0t"; 'turn off bar code
160 LPRINT "comma delimiter"
170 LPRINT
180 LPRINT CHR$(27);"[3t"; 'turn on bar code
190 LPRINT "001234 001234"; 'space delimiter
200 LPRINT CHR$(27);"[0t"; 'turn off bar code
210 LPRINT "space delimiter"
220 LPRINT
230 LPRINT CHR$(27);"[4}"; 'style 4 = 3 of 9
240 LPRINT CHR$(27);"[3t"; 'turn on bar code
250 LPRINT "*1234**1234*"; 'asterisk delimiter
260 LPRINT CHR$(27);"[0t"; 'turn off bar code
270 LPRINT
280 LPRINT "asterisk delimiters are used in pairs"
The HT control code (09) is a valid delimiter in all bar code styles. The leading quiet zone of a subsequent
symbol begins at the first tab stop right of the trailing quiet zone of the current symbol. This is evident in the
sample, where the quiet zone of the second symbol begins at the third tab stop.
Since this printer stores tabs in nonvolatile RAM while power is off, and since the control sequence that sets
horizontal tabs does not clear existing tabs, you should clear all tabs before setting tabs. Note also that new tab
stops do not take effect until you send a line terminator; in other words, you cannot set tabs for the current line.
The superfluous tab stops in the following example are included to show you how the function works. If you use
horizontal tabs for delimiters, then set no more tab stops than you plan to use.
100 LPRINT CHR$(27);"[4;9;1}";‘3 of 9
110 LPRINT CHR$(27);"[3g"; 'clear all h_tabs
120 'set horizontal tabs at 1/2-inch intervals
130 LPRINT CHR$(27);"[360;720;1080;14 40; 180 0;21 60 u"
150 FOR K = 1 TO 6'show where the tabs are
160 LPRINT CHR$(9);"T";
170 NEXT K
180 LPRINT
190 LPRINT CHR$(27);"[3t";'turn on bar code
200 LPRINT "1234";CHR$(9);"1 234 ";
210 LPRINT CHR$(27);"[0t";'turn off bar code
The horizontal position-relative command is a valid delimiter in all bar code styles except POSTNET.
ESC [(Pn)a
The argument units for this command are decipoints (1/720 inch), which the printer rounds off to the nearest
1/120 inch. This command is a valid delimiter even when issued with an argument of zero.
110 LPRINT CHR$(27);"[4;9;1}"; 'height 3/4", hr = on
120 LPRINT CHR$(27);"[3t"; 'turn on bar code
140 LPRINT "1234"; 'send a symbol
150 LPRINT CHR$(27);"[720a"; 'hp_relative 1 inch
160 LPRINT "1234"; 'send a symbol
170 LPRINT CHR$(27);"[0t"; 'turn off bar code
180 LPRINT "hp_rel delimiter"
If you rotate a bar code 90o or 270o, then space imposed by delimiters is not rotated, but is applied horizontally, as
the sample shows. The symbol dimensions that used to be horizontal are shortened to 120/144 of what they used
to be; this includes the quiet zones.
100 LPRINT CHR$(27);"[4;9;1}";‘3 of 9
110 LPRINT CHR$(27);"[3g"; 'clear all h_tabs
120 'set horizontal tabs at 1/2-inch intervals
130 LPRINT CHR$(27);"[360;720;1080;14 40; 180 0;21 60 u"
140 LPRINT CHR$(27);"[0;9;1;;;;;;2}";
150 FOR K = 1 TO 6 'show where the tabs are
160 LPRINT CHR$(9);"T";
170 NEXT K
180 LPRINT
190 LPRINT CHR$(27);"[3t"; 'turn on bar code
200 LPRINT "1234";CHR$(9);"5678" ;
210 LPRINT CHR$(27);"[0t" 'turn off bar code
220 LPRINT CHR$(27);"[3t"; 'turn on bar code
230 LPRINT "2345";CHR$(9);"6 789 ";
240 LPRINT CHR$(27);"[0t" 'turn off bar code
We show characters per inch at the default element widths and 0o/180o rotation for each style in
the following chapter. All of our numbers ignore the quiet zones; you need to allow 1/2 inch per
symbol for the horizontal rotations.
Defining characters per inch for fixed-length codes is straightforward in that the start-stop and
center characters always take up the same portion of length of the symbol. The styles that have
center characters are all fixed-length.
For variable-length codes, net characters per inch depends on the number of data characters in
the symbol. The overhead imposed by start-stop characters is the same whether a symbol
represents 1 data character or 10, so the net cpi is greater for longer symbols. We show the
overhead imposed by start-stop characters separately for the variable length codes.
The default element widths are the narrowest that we recommend. If you use wider element
widths and maintain a 3:1 ratio of wide elements to narrow elements, then you can extrapolate
characters-per-inch for wider symbols. If you depart from the 3:1 ratio, then it's simpler for you to
print test symbols and derive formulae based on what you measure than it is for us to tell you how
to do the computation for each style.
One way to determine the combined length of start-stop characters for a variable-length symbol is
to print two symbols, one with twice as many data characters as the other. Measure the shorter
symbol and call this L1; measure the longer symbol and call this L2. The combined length of the
start-stop characters is:
d = (2 x L1) - L2
To summarize, when using our cpi figures to predict the length of a symbol, remember:
• Allow for two quiet zones per symbol.
• For variable-length symbols, allow the combined start-stop character length for each symbol.
• If you use a check character, then allow for the check character.
The following pages show specific information about the various styles. A NULL character is a
combination of bars and spaces unique to a particular style that is printed when a nonvalid
character is encountered in received bar code symbol data. A null character in the symbol shows
up as a diamond in the human-readable line if the HRL is enabled.
Interleaved 2 of 5 (Style 0)
1Bars per unit (2 characters): 5 dark bars and 5 light bars
2Character set: 0 through 9
3Start character: 2 dark bars and 2 light bars Stop character: 2 dark bars and 1
light bar
4Center character code: None
5NULL character: Yes
6Intercharacter gap: None
7Characters per symbol: Variable
8 Check digit: None.
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters: Currently selected font, special HR font, special OCR-A/O CR-B
font (120 DPI only)
11CPI at default element widths: 6.857
12Combined start-stop character length: 0.167"
Bidirectional/Industrial 2 of 5 (Styles 1 and 3)
1Bars per character: 5 dark bars and 4 light bars
2Character set: 0 through 9
3Start/Stop characters: 2 dark bars and 1 light bar
4Center character code: None
5NULL character: Yes
6 Intercharacter gap: None
7Characters per symbol: Variable
8 Check digit: None
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters: Currently selected font, special HR font, special OCR-A/O CR-B
font (120 DPI only)
11CPI at default element widths: 4.3
12Combined start-stop character length: Style 1 = 0.319", Style 3 = 0.139"
1Bars per character: 3 dark bars and 2 light bars
2Character set: 0 through 9
3Start/Stop characters: 3 dark bars and 2 light bars
4Center character code: None
5NULL character: Yes
6 Intercharacter gap: None
7Characters per symbol: Variable
8 Check digit: None
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters: Currently selected font, special HR font, special OCR-A/O CR-B
font (120 DPI only)
11CPI at default element widths: 6.0
12Combined start-stop character length: 0.278"
Code 3 of 9 (Style 4)
1Bars per character: 5 dark bars and 4 light bars
2Character set: 0 through 9, upper case letters A through Z characters - . $ / + %
and the space character
3Start/Stop characters: Yes
4Center character code: None
5NULL character: Yes
6 Intercharacter gap: None
7Characters per symbol: Variable
8 Check digit: None
9Delimiters: Comma, asterisk (use in pairs--one before the bar code symbol and
one following it), horizontal tab, hp_relative
10HR characters: Currently selected font, special HR font, special OCR-A/O CR-B
font (120 DPI only)
11CPI at default element widths: 3.78
12Combined start-stop character length: 0.514"
1Bars per character: 2 dark bars and 2 light bars
2Character set: 0 through 9
3Start/Stop characters: 2 dark bars and 1 light bar
4Center character code: Yes
5NULL character: Yes
6Intercharacter gap: None
7Characters per symbol: 8
8 Check digit: The check digit can be
supplied by the data source.
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters (without guard bars): Currently selected font, special HR font,
special OCR-A/OCR-B font (120 DPI only), HR characters (with guard bars):
OCR-B font
11CPI at default element widths: 7.385
EAN-13 (Style 6)
1Bars per character: 2 dark bars and 2 light bars
2Character set: 0 through 9
3Start/Stop characters: 2 dark bars and 1 light bar
4Center character code: Yes
5NULL character: Yes
6Intercharacter gap: None
7Characters per symbol: 13
8 Check digit: The check digit can be
supplied by the data source.
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters (without guard bars): Currently selected font, special HR font,
special OCR-A/OCR-B font (120 DPI only), HR characters (with guard bars):
1Bars per character: 4 dark bars and 3 light bars
2Character set: 0 through 9 and the four additional characters :/ . +
3Start/Stop characters: Yes (A,B,C,D/A,B,C,D,T,N,*,E)
4Center character code: None
5NULL character: Yes
6 Intercharacter gap: None
7Characters per symbol: Variable
8Check digit: If needed, it must be generated by the data source
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters: Currently selected font, special HR font, special OCR-A/O CR-B
font (120 DPI only)
11CPI at default element widths: 5.05
12Combined start-stop character length: 0.458"
UPC-A (Style 13)
1Bars per character: 2 dark bars and 2 light bars
2Character set: 0 through 9
3Start/Stop characters: 2 dark bars and 1 light bar
4Center character code: Yes
5NULL character: Yes
6Intercharacter gap: None
7Characters per symbol: 12
8 Check digit: The check digit can
be supplied by the data source
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters: Currently selected font, special HR
11CPI at default element widths: 7.64
Ten digits must be entered as input. The first five represent a vendor number and the last five
represent a product number. Onl y 6 of the 10 input digits are enco ded in the bar code s ymbo l.
The six characters to be encoded in the symbol are determined as follows:
If the vendor number (first five digits) ends in 000, 100, or 200, then the product number (second
five digits) must be between 00000 and 00999. The six digits encoded are the first two characters
of the vendor number followed by the last three characters of the product number, followed by the
third character of the vendor number. (1st, 2nd, 8th, 9th, 10th, 3rd)
1. If the vendor number ends in 300, 400, 500, 600, 700, 800, or 900, then the product number
must be between 00000 and 00099. The six digits encoded are the first three characters of
the vendor number followed by the last two characters of the product number, followed by a
“3”. (1st, 2nd, 3rd, 9th, 10th, “3” )
2. If the vendor number ends in 10, 20, 30, 40, 50, 60, 70, 80, or 90, then the product number
must be between 00000 and 00009. The six digits encoded are the first four characters of the
vendor number followed by the last character of the product number, followed by a “4”. (1st,
2nd, 3rd, 4th, 10th, “4”)
3. If the vendor number does not end in zero, then the product number must be between 00005
and 00009. The six digits encoded are all five digits of the vendor number followed by the last
character of the product number. (1st, 2nd, 3rd, 4th, 5th, 10th)
1Bars per character: 2 dark bars and 2 light bars
2Character set: 0 through 9
3Start/Stop characters: 2 dark bars and 1 light bar
4Center character code: None
5NULL character: Yes
6Intercharacter gap: None
7Characters per symbol: 10
8Check digit: Automatically generated by the printer and used to check parity. It is
not encoded in the bar code symbol.
9Delimiters: Space, comma, horizontal tab, hp_relative
10HR characters (without guard bars): Currently selected font, special HR font,
special OCR-A/OCR-B font (120 DPI only) HR characters (with guard bars):
1Bars per character: 3 dark bars and 3 light bars
2Character set: All 128 ASCII characters
3Start/Stop characters: Yes. (Stop character has 4 dark bars and 3 light bars)
4Center character code: None
5NULL character: Yes
6Intercharacter gap: No
7Characters per symbol: Variable
8 Check digit: Always required. Must be generated by data source. See page 58
9Delimiters: Horizontal tab. (When no tabs are defined, a space is inserted.),
hp_relative
10HR character s: Currently selected font, special HR font, special OCR-A/OCR-B
font (120 DPI only)
11CPI at def ault element widths: 6.85
12Combined st art- stop character length: 0.333"
Code 128 (Style 16)
1Bars per character: 3 dark bars and 3 light bars
2Character set: Any of 3 subsets. The printer automatically shifts among subsets
based on the data that you send. Subset A --All standard alphanumeric
keyboard characters, control characters and special characters Subset B --All
standard alphanumeric keyboard characters, lower case alpha characters and
special characters Subset C --Set of 100 digit pairs from 00 to 99
3Start/Stop characters: Yes
4Center character code: None
5NULL character: Yes
6Intercharacter gap: None
7Characters per symbol: Variable
8Check digit: Automatically generated by the printer. (Cannot be disabled.)
9Delimiters: Horizontal tab. (When no tabs are defined, a space is inserted.),
hp_relative
10Autom atic data compression and subset selection
11CPI at def ault element widths: 11.07
12Combined st art- stop character length: 0.583"
You cannot adjust POSTNET bar code attributes with ESC[(p1);..(p12)}. All attribute parameters
except the style parameter (p1) are ignored by POSTNET, although they are processed, saved,
and would apply to a subsequent bar code of another style if not overwritten. To select
POSTNET, you need to send only ESC [50}. You cannot print human-readable characters with
this bar code style.
There are three variations of POSTNET. They are ZIP, ZIP+4, and ABC. The printer determines
which variation is being called for by the number of characters in the symbol string. Legal
characters are the numerals 0 - 9 (30 hex - 39 hex) and the dash symbol (2D hex), which is
ignored. Any other printable characters in the symbol string cause an error character (diamond) to
be printed.
ZIP5 digits plus 1 check digit
ZIP+49 digits plus 1 check digit
ABC11 digits plus 1 check digit
The check digit is the digit that makes the sum of the digits in the symbol string, including the
check digit, evenly divisible by 10. For example, if you send the ZIP symbol string "12345", then
the sum of those five digits is 15, so "123455" would be the complete ZIP symbol.
If you do not send a check digit, then the printer computes it and prints it. If you do send a check
digit, the printer compares your check digit with its internal computation; and if the two numbers
do not agree, then an error character is printed.
A 3 of 9 symbol is a variable-length string which can include the digits 0 - 9, uppercase A - Z, and
six additional punctuation characters. The values used to compute the checksum for a 3 of 9
symbol are the locations of individual characters in the unique 3 of 9 character table. Your
program will need to refer to a 3 of 9 look-up table to acquire values for the characters you want
to encode, and again to convert the computed checksum back to a valid 3 of 9 character.
The check digit is the modulus 43 sum of all the character values in a given symbol.
1. Compute the check character for the character string:
12345ABCDE/
2. Sum the values of the characters based on their locations in the 3 of 9 character table:
4. The check character is the character corresponding to location 29 in the 3 of 9 character
table, which is T. Send to the printer:
12345ABCDE/T
Code 3 of 9 Character Table
0012C24O36- (minus sign)
1113D25P37. (period)
2214E26Q38 (space)
3315F27R39$
4416G28S40/
5517H29T41+
6618I30U42%
7719 J31 V
8820 K32 W
9921 L33 X
10A22M34Y
11B23N35Z
Calculating the Checksum for CODE 93
A Code 93 symbol consists of a start code, a variable number of data characters, two check digits
(referred to as "C" and "K"), and a stop code.
The values used to compute the checksum for a Code 93 symbol are the locations of individual
characters in the Code 93 character table. Check digit "C" is the modulo 47 sum of the character
values and a weighting sequence, where the weights from right to left are in the sequence 1, 2,
3...19, 20, 1, 2, 3...19, 20....
Check digit "K" is the modulo 47 sum of the character values and a weighting sequence, where
the weights from right to left, starting with the check character "C", are in the sequence
You can send any of the 128 ASCII characters verbatim in a Code 93 symbol. You would not
need to worry about Code 93 control codes if you did not need to compute checksums.
The four control characters in the Code 93 character table do not correspond to any byte values
sent to the printer, but instead refer to “precedence codes” that the printer generates. If you send
the printer a lowercase “a” in a Code 93 symbol, for instance, then the printer prints bars and
spaces that correspond to the <CTRL> + code in front of bars and spaces that correspond to the
uppercase “A”. The reader then interprets this character combination as a lowercase “a”.
So far, this process is transparent both to routines sending symbol strings to the printer and to
routines receiving decoded data from the reader. When ASCII characters are represented as
character combinations, however, the reader expects to see a checksum based on the values of
these combinations; this is the reason that the control codes are assigned values in the Code 93character table. The following example illustrates the calculation of the check digits for the
symbol Cat :
This chapter describes the characteristics and lists the ANSI control sequences for the rotatable
oversized font, a unique sans-serif font with character shapes designed to accommodate very
large expansions. This is an industrial-strength feature. Horizontal resolution is held to 120 dpi to
enable oversized printing at carriage speeds of up to 50 inches per second. Combined with
vertical logic seeking, this enables the 7265 to print complex mixes of character sizes and
rotations at creditable throughputs.
The oversized font is monospaced only. ANSI print modes: bold, underscored, doublewide, and
proportional have no effect. You can print characters 20 hex through 7F hex; characters above
this range are ignored. User-defined character substitutions do not work in oversized, so you
cannot use the IBM line-draw characters. The resident international character substitutions work
the same as in normal text.
In contrast to the oversized function on earlier products, the 7265 interprets escape sequences
and control codes within an oversized string. As of this writing, however, we recommend that you
exit oversized before sending any other control functions.
To maintain compatibility with existing printers, the 7265 printer does not back paper up to print
oversized characters on the current baseline. If you enter an oversized mode and immediately
print one character, then the top of the character is at the vertical position that was current when
you entered oversized. This is no problem if all characters on a line are the same size. To mix
oversized with either normal type or with different expansions on the same baseline, however,
you will need to write a routine to find the baseline. We cover this later in this chapter.
Some of the oversized control sequences are redundant. The nonrotatable controls that let you
optionally toggle oversized with SHIFT OUT and SHIFT IN are retained for compatibility with older
printers. You could reasonably choose to use only the escape sequences for rotatable oversized
(ESC [(Ps)| ) for new applications.
Cancels oversized, whether set with ESC [1t or ESC [(Ps)|, and also expanded and
bar code modes. This command does not clear the oversized dimensions set by ESC
[(Pv);(Ph)<sp>B.
Dec 27 91 48 116Hex 1B 5B 30 74
ESC [1tNON-ROTATABLE OVERSIZED
Included for compatibility with older products. Use if you want to toggle oversized with
SHIFT OUT and SHIFT IN.
Dec 27 91 49 116Hex 1B 5B 31 74
ESC [2tEXPANDED PRINTING
Selects expanded (as opposed to the oversized) printing at the current
expansion factor. Dec 27 91 50 116 Hex 1B 5B 32 74
SET CHARACTER SIZE
Sets the expansion of oversized characters in percentage points. Pv is the vertical
expansion and Ph is the horizontal expansion. The parent font is a 10-point font.
Dimensions established by this sequence are stored in nonvolatile RAM while power is
off.
Caution: Any text between receipt of this command and a countermanding mode
selection command, either ESC [(Ps)| or ESC[(Ps)t, will be printed in expanded mode.
If you do not want this to happen, then you must follow this command immediately with
a mode selection command.
The range of valid parameters (in the sense that a valid parameter does not abort the
escape sequence) is 0 <= Pn < 32767. The printer rounds off dimension parameters
as follows:
If Pn < 100, then Pn = 100
If 100 < Pn < 18700, then Pn is rounded down to the nearest 100.
If Pn >= 18700, then Pn = 18700
Example - to set 20-point type at 1:1 aspect ratio:
There are two ANSI functions that print characters scaled according to the Graphics Size Modification
parameters. Both expanded and oversized are standard features with this printer. You can get into expanded
mode accidentally when you send the Graphic Size Modification sequence.
Expanded mode is based on the current font, is limited to 8x the parent font size, and propagates
up from the baseline. Reverse paper motion occurs for vertical expansions. The horizontal
resolution reflects the current font selection. If you send a line feed character while in expanded
mode, then the paper advances by the current vertical expansion factor times the current linefeed increment.
Oversized is based on a unique font, is rotatable, expandable to 1870x, and propagates down
from the top of the character cell. The resolution is always 120 dpih x 144 dpiv. If you send a line
feed character while in oversized, then paper advances five dot rows for 0
nine dot rows for 270
obviously better.
o
rotation. The scaling algorithms for the oversized function are
o
rotation, or
Setting the Expansion
The size of the parent oversized font is 10 points (12 cpi). You can set the horizontal and vertical
dimensions of oversized characters separately in increments of 100% of the parent font size.
Limits are 100% to 18,700%. The larger number corresponds to an uppercase M about 18.7
inches high. The control sequence that sets the expansion is the ANSI Graphic Size Modification:
where (pv) is the vertical expansion, (ph) is the horizontal expansion, and <SP> is the space
character (20 hex).
o
For 0
rotation, you can think of parameter (pv) as 10 times the point size of the
oversized character. If you set a 600 x 600 expansion and print an uppercase “E” at zero rotation,
then the resulting character will nearly match the 60-point Helvetica “E” on a typesetter's scale.
A sideways character shares neither the size nor the aspect ratio of a vertical character printed at
the same expansion factors. Relationships between expansion and character dimensions for
o
rotation reflect differences in the horizontal and vertical resolutions of the printer in
270
oversized mode.
Remember to always follow the graphic size modification command immediately with either ESC
[0t or the desired oversized mode selection if you do not want to drop into expanded mode.
Device Timeout with Very Large Characters
Normally, one byte of data in the printer's input buffer represents one text character, which takes
milliseconds to print. If our host creates a huge character using dot graphics, then one byte of
data in the buffer corresponds to one dot column. If we set oversized, however, then one byte of
data can command the printer to render several hundred thousand dot columns. A big oversized
character can take a while to print.
If we fill the printer's input data buffer while a big oversized character is printing, then the printer
goes BUSY. The big character, as well as a buffer full of following objects, has to be printed
before the printer goes READY again.
If the host now tries for some period of time to send data to the printer without seeing a READY at
the interface, then the host might decide that the printer is not working, show you a device
timeout message, and abort the data transfer.
This same possibility exists with large bar codes, and we discuss remedies in the ANSI Bar Code
chapter.
A character cell is the rectangular array of locations at which dots can be printed to form one
character.
All character cells for a given monospaced font at a given pitch are the same size. If you print a
line of characters with no countermanding motion instructions, then no character cell will impinge
horizontally on the character cell of an adjacent character. You can determine character cell width
in a monospaced font by measuring the distance from the leading edge of, say, an uppercase “E”
to the leading edge of an adjacent uppercase “E”.
In an impact-matrix printer font, the printed portion of a character is often centered horizontally in
the character cell. There might be a fixed number of dot columns on either end of the character
cell that are never printed. This is analogous to the side bearings in a typeset character.
Figure 4-2 Character Cells
In the oversized font, on the other hand, characters are left-justified in the cells. This lets you print
a larger character when you are printing, say, one huge character on a sheet. The 7265 printer
prints as much of an oversized character as will fit between the margins. If your character is going
to be clipped at the right margin, then you might rather clip the side bearing than clip a printed
portion of that character.
In the oversized font, the topmost dot in the uppercase “E”, for instance, is centered on the upper
boundary of the character cell. The lowest dot on the descender of the lowercase “j” is centered
on the lower boundary of the character cell.
The width of an oversized character cell is 0.72 decipoints times the
horizontal expansion factor. In thousandths of an inch, it is the same as the horizontal expansion
factor. If you set a horizontal expansion of 1000, then characters will be 1 inch, or 720 decipoints,
apart.
Figure 4-3 Vertical Characte r Dimensions
o
The height of an oversized character cell is 0.9 decipoints times the
vertical expansion factor. In thousandths of an inch, it is 1.25 times the vertical expansion factor.
If you set a vertical expansion of 1000, then the top of the uppercase “E” is 1.25 inches, or 900
decpoints, from the bottom of the lowercase “j”.
The distance from the top of an oversized character cell to the baseline
is 0.7 decipoints times the vertical expansion factor. Top of the character cell means the upper
boundary of the cell before it was rotated.
The width of a character cell is 0.6 decipoints times the horizontal
expansion factor. Width means the dimension that is left-to-right as you read the character.
The height of a character cell is 1.08 decipoints times the vertical
expansion factor. Height means the dimension that is vertical as you read the character.
Figure 4-4 Sideways Character Dimensions
The distance from the top of the character cell to the baseline is 0.76
decipoints times the vertical expansion factor. Top-of-cell means the upper boundary of the
character cell as you read the character.
o
When printing strings of sideways characters, the printer adds horizontal space between
character cells. This space is equal to 0.36 decipoints times the vertical expansion factor.
Vertical Position-Relative in Oversized
Normally, the origin of a vertical position-relative move is the current position. If the last object
printed on the current line was an oversized character, however, then the origin of a vertical
position-relative move is the top of that character cell, where top-of-cell means the character cell
boundary that is uppermost on the paper. This is true whether or not you are still in oversized
when the vertical position-relative command is sent.
A good technique is to exit oversized with ESC [0t and send a vertical and horizontal position
absolute command:
ESC [(Pv);(Ph)f
where (Pv) is decipoints from the top print reference and (Ph) is decipoints from the left print
reference. The logic seeking of the printer minimizes redundant paper motion associated with
position-absolute commands. You could also use vertical position-relative to implement line
feeds.
Try a line feed increment of 1.2 decipoints times the vertical expansion
factor.
If you send a line feed character while in oversized, then paper advances five dot rows for the 0
rotation.
If you print sideways text, then the vertical move that otherwise corresponded to a line feed now
sets the distance from the leading edge of one character cell to the leading edge of the next
character cell (as you read the characters). A good starting value for this move is the character
cell width, which is 0.6 decipoints times the horizontal expansion factor.
Strings of sideways characters propagate left-to-right across the portrait page. The printer makes
“ line feeds” for you by inserting space between the trailing cell boundary of the previous
character and the leading cell boundary of the next character. This space is 0.36 decipoints times
the vertical expansion factor, which is generous line spacing.
If this line spacing is not satisfactory, then send sideways text one character at a time, preceded
by a locating command for each character. If you use the resident line spacing for sideways lines,
then you will probably use a character array to rotate text. In that case, remember to fill your array
with space characters (20 hex) before you copy strings into it.
ACK Acknowledge
BEL Bell
BS Back Space
CR Carriage Return
CSI Control String Introducer, ESC [
DC1 Select printer (Data Control 1)
DC3 Deselect printer (Data Control 3)
DEL Delete
ENQ Enquiry
ESC Escape
ESC \ or ST String Terminator
ESC c Reset to Initial State (RIS)
ESC D or IND Index
ESC E or NEL Next line
ESC H or HTS Horizontal Tab Setting
ESC J or VTS Vertical Tab Setting
ESC K or PLD Partial Line Down
ESC L or PLU Partial Line Up
ESC M or RI Reverse Index
ESC P data or DCS Enter Dot Graphics Mode (Device Control String)
ESC [ p1; pn } Sets bar code parameters (GENBC)
ESC [ p1;....pn m Select Graphics Rendition (SGR), Character Pitch, Print Modes and
Color Ribbon color.
ESC [ p1; p2 SP B Graphic Size Modification (GSM)
ESC [ p1; p2 s Left/Right Margin Set (GENSLR)
ESC[ p1; pn u Sets horizontal tab stops at specified positions
Multiple Horizontal Tab Set (GENHTS)
ESC [ p1; pn g Tab Clear (TBC)
ESC [ p1; pn v Sets vertical tab stops at specified positions
(Multiple Vertical Tab Set - GENVTS)
ESC [ p1; p2; p3 r Form Definition (GENFD)
ESC [ p1; p2 <SP> G Sets the line/character spacing
ESC [ p1;...pn h Set Mode (SM)
ESC [ p1; pn l Reset mode (RM)
ESC [ p1 ’ Horizontal Position Absolute (HPA)
ESC [ p1 a Horizontal Position Relative (HPR)
ESC [ p1 d Vertical Position Absolute (VPA)
ESC [ p1 j Horizontal Position Backward (HPB)
ESC [ p1 k Vertical Position Backward (VPB)
ESC [ p1 q Select Graphics Mode/Density(GENGRM)
ESC [ p1 t Special Print Mode (Oversize/Expanded/Bar code Mode - GENSPM)
ESC [ p1; p2 f Horizontal and Vertical Position Absolute (HVP)
ESC [ p1 e Vertical Position Relative (VPR)
ETX End of transmission
FF Form Feed
HT Horizontal tab
LF Line Feed
NUL Ignored
OSC Operating System Command, ESC ]
SI Shift In
SO Shift Out
SP Space
VT Vertical tab
Commands not implemented in the 7265 ANSI Emulation
ESC ] p1;pn<ST> User Defined Character Substitution (GENUDS)
ESC ] p1;p2;p3;data<ST> Operating system command (Load Mode OSC)
ESC [ p1;p2 SP ~ Selects emulation (GENEMU)
ESC [ p1;pn { Unidirectional Printing (GENUPD)
ESC [ p1;p2;p3 SP | Customer Setup Save/Unsave (GENCSX)
ESC [ p1;pn p Assign Source for Forms (GENASF)
ESC [ p1 x Selects National character set (Select National Characters - GENSNC)
ESC k Print Test Character (GENPTC)
ESC Q or PU1 Executes Self Test
Exceptions
1.) Barcode ratios are controlled by one parameter that affects both width and height.
2.) Block characters print at a fixed size.
3.) Block characters printed with a fixed rotation.
4.) The Genicom printer saves ESC sequence changes to powerup; we load from the powerup menu.
5.) <DEL> character prints a space; Genicom prints a “house” character.
6.) Across 13.6 inches we print one less character per line in the following CPI's:
6, 6.25, 6.67, 8.33, 8.57, 9, 12, 12.5, 13.3, 17.14 and 18
7.) If we set Auto CR to ON then form feeds also get a CR, where Genicom does not add CR to form feeds.
Genicom does add CR to FF if "Auto CR on Vertical Tab" is enabled.
8.) Different combinations of adding and removing vertical tabs will produce different results compared to the
Genicom printer.
9.) Differences when mixing some form lengths with top and bottom margins.
10.) Some illegal parameters are treated different than the Genicom printer.
11.) Default horizontal and vertical tabs are not defined at power up.
This User’s Manual describes the sum of all EPSON Escape sequences, regardless of
the specific EPSON emulation used by your printer. The only differentiation is made between 9 and 24 needle printers as well as the maximum possible paper width of 8 inches
(80 column printer) or 13.6 inches (136 column printer). Please note that the print quality
LQ (Letter Quality) is only available in the 24 needle printer.
Please be sure to observe the notes and steps described in the Operator’s Manual as
well as the specific EPSON emulations implemented in your printer and which of the
described sequences are thus not available for that specific emulation.
Select the EPSON mode as described in the Operator’s Manual. Selecting this emulation
mode will automatically select the Epson character set.
Read the Operator’s Manual to see whether it is also possible to use ANSI (MTPL)
sequences in addition to the special Epson sequences.
The following explanations will help you understand the sequences better:
Every sequence description begins with a header, in which the function and the short
form of the sequence are listed without parameters, e.g.:
Introduction
2
Setting the form length in lines
Setting the form length in inches
ESC
The
ters following the ESC control code (here C) determine the sequence’s function.
control code (hex. 1B, dec. 27) introduces every Escape sequence. The charac-
ESC C
ESC C NUL
This is followed by the Data Structure in ASCII, hexadecimal and decimal syntax with the
necessary parameters, e.g.:
ASCIIESC "C"<n>Setting the form length in lines
hex.1B43<n>
dec.2767<n>
For the parameter (here n) it is necessary to differentiate between two types of syntax.
if the parameter is in pointed parentheses, the decimal value is transferred
if the parameter is not in pointed parentheses, the ASCII value is transferred
Example:
Parameter syntax:<n>, with n=0
to be transmitted:ASCII "NUL" (hex.00, dec.0)
Parameter syntax:n, with n=0
to be transmitted:ASCII "0" (hex.30, dec.48)
Character explanation and symbol description
Lower case "l"
l
Information
Sequence only applies for 9 needle printer
Sequence only applies for 24 needle printer
Sequence only applies for ESC/P2 printers
On the next page you will find examples for Escape sequences complete with BASIC programming examples.
Introduction
3
Setting the form length to 72 lines
Escape SequenceESCC<n>
TransferASCIIESC"C""H"
hex.1B4348
dec.276772
100 REM Sample for the ESC C <n> sequence in ASCII,
110 REM using form with 72 lines.
120 REM Please note, in ASCII-Syntax you can use ASCII values
130 REM equal or bigger codetable no. 32 only.
140 REM LPRINT CHR$(27);"C";"H": REM mixed syntax;
150 REM set form length up to 72 lines
160 REM The same sequence written in hexadecimal syntax
170 LPRINT CHR$(&H1B);CHR$(&H43);CHR$(&H48);
180 REM set form length up to 12 lines
190 REM The same sequence written in decimal syntax
200 LPRINT CHR$(27);CHR$(67);CHR$(72);
210 REM set form length up to 72 lines
Setting the form length to 12 inches
Escape SequenceESCCNUL<n>
TransferASCIIESC"C"NULFF
hex.1B43000C
dec.2767012
with n=72
with n=12
Introduction
4
100 REM Sample for the ESC C NUL <n> sequence in ASCII,
110 REM using form with 12 inch length.
120 REM Please note, in ASCII-Syntax you can use ASCII values
130 REM equal or bigger codetable no. 32 only.
140 REM LPRINT CHR$(27);"C";CHR$(0);CHR$(12): REM mixed syntax;
150 REM set form length up to 12 inch
160 REM The same sequence written in hexadecimal syntax
170 LPRINT CHR$(&H1B);CHR$(&H43);CHR$(&H0);CHR$(&HC);
180 REM set form length up to 12 inch
190 REM The same sequence written in decimal syntax
200 LPRINT CHR$(27);CHR$(67);CHR$(0);CHR$(12);
210 REM set form length up to 12 inch
Paper and Text Formatting
Form Length in Lines
Form Length in Inches
Data Structure
Description
ASCIIESC "C"<n>set form length in lines
hex.1B43<n>
dec.2767<n>
ASCIIESC "C"<0> <n>set form length in inches
hex.1B430<n>
dec.276700<n>
This code sequence sets the form length to n times the current line feed pitch (in in-
➊
ches). Also the current print position is simultaneously defined as top of form.
The value specified for n must be an integer in the range of 1 to 127. This value is mul-
tiplied by the current line feed pitch to obtain the form length. For example, if 60 is
specified for n and the current line feed pitch is
ches. Once set by this sequence, the form length is not affected by changing the line
spacing. This code sequence is ignored if the value specified for n is not in the range
of 1 to 127.
This code sequence sets the form length to the number of inches specified by n. It
➋
also defines the current print position as top of form.
The value specified for n must be an integer in the range of 1 to 22; otherwise the se-
quence will be ignored.
ESC C
ESC C NUL
➊➌
➋➌
1
inch, the form length is set to 10 in-
⁄
6
This code sequence resets the perforation skip function (ESC N).
➌
Paper and Text Formatting
5
Example10 REM form length
20 FF$=CHR$(12)
30 K=1
40 LPRINT CHR$(27);"C";CHR$(4);
50 FOR F=1 TO 3
60 FOR L=1 TO K
70 LPRINT "length 4: form";F;"line";L
80 NEXT L
90 K=K+1
100 LPRINT FF$;
110 NEXT F
120 K=1
130 LPRINT CHR$(27);"C";CHR$(3);
140 FOR F=1 TO 3
150 FOR L=1 TO K
160 LPRINT "length 3: form";F;"line";L
170 NEXT L
180 K=K+1
190 LPRINT FF$;
200 NEXT F
210 END
Paper and Text Formatting
6
Set Page Length in Units
ESC ( C
Data Structure
ASCIIESC "(""C"<n
hex.1B2843<n
dec.274067<n
DescriptionValid values:
n
= 2, nH = 0
L
0 < ((m
x 256) + mL) x (defined unit) ≤ 22
H
Defines page length in untis previously defined with the sequence ESC ( U (see page 62).
(page length) = ((m
(page length) x
m
= INT
H
m
= MOD
L
This sequence sets top and bottom margins to default.
x 256) + mL) x (defined unit)
H
256
(page length) x
256
><nH><mL><mH> set page length in units
L
><nH><mL><mH>
L
><nH><mL><mH>
L
1
(defined unit)
(defined unit)
1
Set page length first, then load paper. Using this sequence within the form sets top of
form position at the current position.
Paper and Text Formatting
7
Set Page Format
ESC ( c
Data Structure
ASCIIESC "(""c"<n
hex.1B2863<n
dec.274099<n
DescriptionValid values:
n
= 4, nH = 0
L
((t
x 256) + tL) < ((bH x 256) + bL)top margin < bottom margin
H
((b
x 256) + bL) x (defined unit) ≤ 22bottom margin < 22 inches
H
Defines top and bottom margins previously defined with the sequence ESC ( U
(see page 62).
(top margin) = ((t
(top margin) x
= INT
(top margin) x
t
H
t
= MOD
L
><nH><tL><tH><bL><bH> set page format
L
><nH><tL><tH><bL><bH>
L
><nH><tL><tH><bL><bH>
L
x 256) + tL) x (defined unit)
H
1
(defined unit)
256
(defined unit)
256
1
(top margin) = ((t
b
= MOD
H
= MOD
b
L
Paper and Text Formatting
8
x 256) + tL) x (defined unit)
H
(bottom margin) x
(bottom margin) x
256
256
1
(defined unit)
1
(defined unit)
This sequence sets new top and bottom. it does not affect the current page length setting.
Set top and bottom margin first, then load paper. Using this sequence within the form
sets top margin at the current position.
Paper and Text Formatting
9
Perforation Skip
ESC N
Reset Perforation Skip
Data Structure
Description
ASCIIESC "N"<n>set space before perforation (perforation skip)
hex.1B4E<n>
dec.2778<n>
This code sequence enables the perforation skip function and sets the bottom margin
➊
(distance between the last print line of one page and the first print line of the following
page) to n lines. The value specified for n must be in the range of 1 to 127 and must
be smaller than the form length minus the top margin.
The printer automatically advances the paper to the first printable line of the next page
whenever the current print line falls within the margin area defined as n lines from the
bottom of the current page (n being the value specified for the bottom margin area).
The margin area before and after the perforation is n times the current line spacing.
Once this margin area has been defined, it will not be affected by changing the line
spacing and remains effective until the printer receives code sequence ESC O (reset
perforation skip), or until form length is changed by ESC C or ESC C 0.
This code sequence deselects the perforation skip function set by ESC N <n>.The bot-
➋
tom margin is set to 0 lines, thus disabling perforation skip. This results in continuous
printout, unless the software used in the computer defines the form length by counting
the printed lines.
ESC O
➊
➋
This function only applies for fanfold paper, not for cut sheet processing or with mounted
sheet feeder.
Paper and Text Formatting
10
Example10 REM skip
20 LPRINT CHR$(27);"C";CHR$(6);:REM form length
30 LPRINT CHR$(27);"N";CHR$(1);:REM set skip
40 FOR F=1 TO 2
50 FOR L=1 TO 5
60 LPRINT "form";F;" line";L
70 NEXT L:NEXT F
80 END
Paper and Text Formatting
11
Right Margin
ESC Q
Left Margin
Data Structure
Description
ESC
ASCIIESC "Q"<n> set right margin
hex.1B51<n>
dec.2781<n>
ASCIIESC "
hex.1B6C<n>
dec.27108 <n>
Character
density
10 cpi
12 cpi
15 cpi
17.1 cpi
20 cpi
Values for n are valid for a line length of 8 inch (80 columns printer) or 13.6 inch
(136 columns printer) set in the menu.
The absolute margin position depends on whether enlarged print mode, compressed print
mode, Pica or Elite are selected. When using proportional spacing, the setting of the margins corresponds to the setting when in Pica font type (10 cpi).
The command for setting the margins must be given at the beginning of a line, all data of
the same line are lost in the print buffer.
"<n> set left margin
l
Values for n
80 columns
printer
1... 80
1... 96
1...120
1...136
1...160
136 columns
printer
1...136
1...163
1...204
1...232
1...255
➊
➋
l
The right margin is set to n columns, depending on the character density selected. As
➊
soon as the right margin is reached after this command has been given, a carriage return and a line feed are added to the characters to be printed.
The left margin is set to n columns, depending on the character density selected.
➋
Paper and Text Formatting
12
Example10 REM left and right margin
20 LPRINT " 1 2 3 4 5"
30 LPRINT "12345678901234567890123456789012345678901234567890123"
40 LPRINT CHR$(27);"l";CHR$(10);CHR$(27);"Q";CHR$(53);
50 LPRINT "Now the left margin is set to column 10 and";
60 LPRINT "the right margin is set to column 53."
70 LPRINT CHR$(27);"l";CHR$(5);CHR$(27);"Q";CHR$(41);
80 LPRINT "Now the left margin has been reduced";
90 LPRINT "to column 5 and the right margin has";
100 LPRINT "been set to column 41."
110 END
Paper and Text Formatting
13
Justification and Centering
ESC a
Data Structure
Description
ASCIIESC "a"<n>
hex.1B61<n> or n
dec.2797<n> or n
In some cases it is necessary to center headlines or to have the text printed in a way that
left or right margin or both margins are justified. By means of this code sequence the printer automatically justifies the text.
Justification mode depends on the value selected for n:
0 (hex.00 or hex.30) left justification (default setting)
1 (hex.01 or hex.31)centered
2 (hex.02 or hex.32)right justification
3 (hex.03 or hex.33)left and right justification
The justification mode must always be set at beginning of the line.
Justification mode can be used in all print qualities.
If left and right justification is activated, the validity of codes ESC $, ESC\ and HT at
➊
the beginning of the line is checked.
Left and right justification is only achieved if the length of the data line (measured from
the start of data input up to a CR or LF code) fills 75% to 125% of the given printed
area.
At less than 75%, left and right justification justification is not achieved. If the length of
the printed line extends more than 25% outside of the printed area, left and right justification justification is carried out for the character spacing which comes closest to the
value of 100% within the printed area. The remaining data are printed in the next line.
➊
Paper and Text Formatting
14
Example10 REM justification and centering
20 WIDTH "LPT1:",255
30 LPRINT CHR$(27);"Q";CHR$(48);:REM set right margin
40 LPRINT CHR$(27);"a";CHR$(1);"CENTERED"
50 LPRINT "HEADLINE"
55 LPRINT CHR$(27);"a";CHR$(3)
60 LPRINT "Now the right and the left justification ";
70 LPRINT "is on. The lines are filled with blanks ";
80 LPRINT "until they are long enough to reach the ";
90 LPRINT "right margin."
100 LPRINT
110 LPRINT CHR$(27);"a";CHR$(2);"These lines are only"
120 LPRINT "justificated on the"
130 LPRINT "right margin."
140 LPRINT
150 LPRINT CHR$(27);"a";CHR$(0);"Now the default setting"
160 LPRINT "is selected again. The lines are"
170 LPRINT "justified on the left margin."
180 END
Paper and Text Formatting
15
Character Spacing
Set HMI (Horizontal Motion Index)
Data Structure
DescriptionValid values:
ASCIIESC "c"<n
hex.1B63<n
dec.2799<n
0 ≤ n
≤ 4
H
0 ≤ n
≤ 255
L
0 < ((n
x 256) + nL)) ≤ 1080; HMI ≤ 3.00 inches
H
The normal print density is enlarged according this formula:
x 256) + nL
(n
= INT
H
360
HMI x 360
256
HMI x 360
256
HMI =
n
H
nL = MOD
><nH> set HMI (Horizontal Motion Index)
L
><nH>
L
><nH>
L
inch
ESC c
Character Spacing
16
This sequence terminates previously set additional character space defined with
ESC SP.
Following sequences will cancel the HMI mode:
ESC !print mode selection
ESC @printer initialization
DC2reset condensed print
DC4reset enlarged print mode (set by <SO> or ESC <SO>)
ESC gcharacter density 15 cpi
ESC Mcharacter density 12 cpi (Elite)
ESC Pcharacter density 10 cpi (Pica)
ESC pproportional spacing ON/OFF
ESC SPcharacter spacing
ESC Wcontinuous enlarged print mode ON/OFF
SIcondensed print ON
SOenlarged print mode (automatically reset after one line)
Character Spacing
17
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.