beautypg.com

Digital image user's guide for hp printers, Using troy digital image fonts, Programming example for troy digital image fonts – TROY Group Digital Image User's Guide for HP Printers User Manual

Page 6

background image

Digital Image User's Guide for HP Printers

Document #50-70297-001 Rev. G

Page 6 of 6

Using TROY Digital Image Fonts

(non-Microsoft Windows)

1. Review

the

TROY Digital Image Data Sheet for the section labeled PCL Image Selection Sequence,

and note the pattern of characters. This pattern is used to generate the digital image.

2. Send

the

PCL Image Selection Sequence to the printer. Remember to replace the character with

the non-printable escape character (ASCII 27 / HEX 1B). This PCL command is a font selection
command, which selects the digital image within the printer.

3. Position the printer's cursor (the printer has an invisible cursor, all dots addressable) to the desired area

of the page. There are three methods for cursor positioning; decipoints, rows/columns, and PCL units
(dots). PCL units are used for this example. The PCL units are usually defined at 300 DPI (Dots Per
Inch) but may vary. Experimentation may be necessary for your application. To position the cursor,
calculate the desired X (horizontal) and Y (vertical) position for the image placement. For this example,
the values are in PCL units (dots); therefore, if the units are set to 300 DPI, 1 inch = 300 dots. The
following PCL positioning command will move the cursor 6 inches horizontally from the left edge of
the logical page (6 x 300 = 1800) and 3 inches vertically (3 x 300 = 900) on the page. The command is:
*p1800x900Y.

A difference between horizontal and vertical positioning is the horizontal value originates from the left-
edge of the logical page, but the vertical positioning value originates from the top margin, which can be
adjusted. Therefore, if the top margin value is changed, the image will shift vertically. The printer also
supports the print and space method of printing. This means the printer's cursor will move when it
receives control codes such as a space bar, carriage return, line feed, etc. With this in mind, if you
create a PCL positioning command, the text/data must immediately follow the command. If the
positioning command is sent separately followed by a carriage return/line feed, the cursor has now
moved to the next row and to the first column. The result would be loss of the desired position.

4. Enter

the

pattern of characters found on the TROY Digital Image Data Sheet. Once again, this pattern

is used to generate the digital image. Example: abcdef. If the pattern of characters is more than one
line, you must enter a separate position call for each line of characters.

5. Print the document. A standard form feed may be used, or send the PCL command &l0H (prints

the current page).

Programming Example for TROY Digital Image Fonts

(non-Microsoft Windows)

(201Q(s0p2h72v0s0b201T

' select the Digital Image.

*p1800x900Yabcdef

' cursor position followed by the pattern of characters.

&l0H

'

print

the

current

page.




Obtaining Technical Assistance

If you experience any difficulties with the installation process, please call TROY Technical Support at
(800) 332-6427, between the hours of 8:00 AM and 8:00 PM, Monday through Friday, Eastern Standard
Time. Customers outside the United States, please call (304) 232-0899.