Host Printing Reference

IBM Host On-Demand Version

Host Printing Reference

Thirteenth Edition (March 2019)

This edition applies to Version 14.0 of IBM(R) Host On-Demand (program number 5724-I20) and to all subsequent releases and modifications until otherwise indicated in new editions.

(C) Copyright International Business Machines Corporation 1997, 2019. All rights reserved.

Note to U.S. Government Users -- Restricted Rights -- Use, duplication, or disclosure restricted by GSA, ADP Schedule Contract with IBM Corp.


Contents:


About this book
Conventions used in this book
Introduction to Host Printing (3270)
      Automatic detection of LU type
      Emulation of a 3287 printer
      The Print Setup Window (3270)
            Print methods
            Using the print methods on the Windows platform
            Using the print methods on UNIX, AIX, or Linux
            Using the print methods on OS/2
      Print Technologies
            Windows Native Printer Interface mode
            Windows Spooler Interface mode
            Java File Interface mode
      Specifying a File Path and Name
      Creating Adobe PDF Files
      Creating a PDT file
            More about Printer Definition Files
            More about Printer Definition Tables
            Starting the Printer Definition Table Compiler
            Locating Predefined Printer Definition Files and Tables
            Supported Printer Emulation Modes
Creating a Printer Definition Table (3270)
      Creating a Printer Definition File
      Using the Printer Definition Table Compiler
            Printer Definition Table Description
            Running the Compiler in Graphical Mode
            Running the Compiler in Nongraphical Mode
Understanding the Format of Printer Definition Files (3270)
      Macro Definitions
      Formatting Controls
            Session Parameters
                   ASCII_PASSTHRU? Keyword Support
                   EBCDIC_PASSTHRU? Keyword Support
            Control Codes
                   Control Codes used for both SBCS and DBCS Languages
                          START_JOB and END_JOB
                          SET_VARIABLE_LINE_DENSITY
                          CHARACTER_PITCH
                          REVERSE_VIDEO and BLINK
                   Using Custom Control Codes (LU1 and LU3)
                   Additional Control Codes for DBCS
                   Definition of Printer Control Code Parameters
      Character Definitions
Introduction to Host Printing (5250)
      Host Print Key
      Host Print Transform
Introduction to Host Printing (VT)

Appendix A. Printer Data Stream Information (3270)
      Introduction to Print Data Stream
      Supported Commands and Orders in the 3270 Data Stream
            Write Control Character (WCC) byte
      Query Replies
      Function Management Header 1 (FMH-1) Support
      Delimiting Print Jobs
      SNA Character String Data Stream
      Command Descriptions
Appendix B. National Language Support
      Euro Currency Symbol Support
      Japanese Code Page Support
      User-defined Characters for Host Printing Sessions
Appendix C. Advanced Configuration Options (3270)
Appendix D. Troubleshooting
      Inactivity Timer
      Problem Resolution
      What to do if you still have a problem
Appendix E. Associated Printer Sessions (3270)
Appendix F. Printer Definition File Example (3270)
Appendix G. Notices
      Trademarks

About this book

The Host Printing Reference describes the host printing functions provided by Host On-Demand.

This document is written for application developers and administrators.

The Host Printing Reference is also available both on the product DVD-ROM and in the Host On-Demand online Knowledge Center at http://www-01.ibm.com/support/knowledgecenter/SSS9FA/hod_family_welcome.html.

The MySupport feature enables you to personalize your support view and to register to receive weekly e-mail notifications alerting you to new patches, new downloads, and other timely technical support information for IBM products. To register for MySupport, follow the instructions in the Technote found at the following URL: http://www-01.ibm.com/support/docview.wss?uid=swg21460904

Conventions used in this book

The following typographic conventions are used in the Host Printing Reference:

Convention Meaning
Monospace Indicates text you must enter at a command prompt and values you must use literally, such as commands, functions, and resource definition attributes and their values. Monospace also indicates screen text and code examples.
Italics Indicates variable values you must provide (for example, you supply the name of a file for file_name). Italics also indicates emphasis and the titles of books.
Return Refers to the key labeled with the word Return, the word Enter, or the left arrow.

Graphic Image
This graphic is used to highlight notes to the reader.




Introduction to Host Printing (3270)

The Host On-Demand client supports 3270 printing. You can direct a 3270 Logical Unit Type 3 (LU3) or Logical Unit Type 1 (LU1) print data stream to any of the following print destinations:

A Host On-Demand 3270 printer session emulates an IBM 3287 printer running in either LU3 or LU1 mode.

Automatic detection of LU type

When you configure a 3270 Printer session, you do not have to specify whether the session uses LU Type 3 or LU Type 1. Instead, the Host On-Demand client automatically detects the LU type when the client connects with the 3270 host.

The term Logical Unit (LU) comes from the Systems Network Architecture (SNA). In a 3270 Printer session, the Host On-Demand client connects with a Telnet server rather than with an SNA server. However, the LU3 or LU1 data stream transmitted by the Telnet server is identical with the LU3 or LU1 data stream transmitted by an SNA server.

Emulation of a 3287 printer

Because the purpose of a Host On-Demand 3270 Printer session is to emulate a 3287 printer, a 3270 Printer session does not offer the same options that you may be used to seeing when you print a document from a word-processing program. In particular, you will find these differences:

The Printer Setup window (3270)

This section contains background information to help you understand how to configure the Printer Setup window for a 3270 Printer session.

To open the Printer Setup window for a 3270 Printer session, follow these steps:

  1. Open the session properties window for a 3270 Printer session.
  2. In the left pane, click Printer Setup.

You can also open the Printer Setup window from other contexts (see Printer Setup (3270 Printer session, 5250 Printer session, and 3270 Display session) in the online help). Configuring the Printer Setup window in these contexts is similar to the configuration described here.

Print methods

The Print to listbox at the top of the Printer Setup window offers (depending on the client platform) up to five print methods:

These five print methods employ a somewhat confusing variety of print technologies, which are described in a later section (see Print Technologies ). The current section attempts to steer clear of describing print technologies and instead to describe only how to configure the Printer Setup window to accomplish various tasks.

The following sections describe how to use the print methods on the following Host On-Demand client platforms.

Using the print methods on the Windows platform

The following table shows the print methods available when the Host On-Demand client is running on a Windows platform and summarizes the characteristics associated with each print method:

Print method: Characteristics:
A. Windows Printer, with Use Printer Definition Table set to No
  • Default method for this platform.
  • You can select a Windows printer.
  • You can select a Windows font.
  • You can easily modify Windows printer properties (such as Portrait or Landscape, Pages Per Sheet, Print Quality, and other properties) using the Windows Print Setup dialog.
  • This print method is useful when it is not possible to access the printer without using the Windows printer driver (as is the case with a USB printer or a Windows-only printer) or when a PDT file is not available (as is the case with a PostScript printer).
  • This print method can print some special characters (such as the euro character) even if the special characters are not present in the printer's firmware.
  • Processing is slower than with print method B.
  • This print method may not be able to handle the 3270 data stream command TRN (Transparent).
B. Windows Printer, with Use Printer Definition Table set to Yes
  • The administrator must provide a Printer Definition Table (PDT).
  • You can select a Windows printer.
  • This print method cannot print some special characters (such as the euro character) unless the special characters are present in the printer's firmware.
  • Processing is faster than with print method A.
C. Other Printer (always uses a Printer Definition Table)
  • This print method is called Printer on non-Windows platforms.
  • The administrator must provide a Printer Definition Table (PDT).
  • Normally you do not need to use this print method on the Windows platform.
D. File, with Use Adobe PDF set to No (always uses a Printer Definition Table)
  • The administrator must provide a Printer Definition Table (PDT).
  • This print method is useful if you do not want to send the print output to a printer immediately.
  • This print method is useful if you want to generate print output in a flat ASCII format.
E. File, with Use Adobe PDF set to Yes (does not use a Printer Definition Table)
  • A PDT is not required.
  • The print output is written to the specified file in Adobe PDF format.
The remainder of this subsection describes how to use each print method on the Windows platform.

A. Windows Printer, with Use Printer Definition Table set to No

This is the default print method for the Host On-Demand client running on a Windows platform. To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click Windows Printer.
  3. Set Use Printer Definition Table to No.

You can select the Windows printer that you want to use, either a local printer or a network printer. To select a Windows printer:

  1. Open the Printer Setup window.
  2. To use the default Windows printer, set Choose Windows Printer to Use Default.
  3. To select another Windows printer:
    1. Set Choose Windows Printer to Other.
    2. Click Select Printer

You can select a Windows font. To select a Windows font:

  1. Open the Page Setup window.
    1. In the session properties window, in the left pane, click Page Setup.
  2. Click Select Font.
  3. In the Font window, select a font from the Font column.
    • Do not use the Font style and Size settings in the Font window. Even though these settings appear to be enabled, they have no effect on Host On-Demand client printing.

You can easily modify Windows printer properties (such as Portrait or Landscape, Pages Per Sheet, Print Quality, and other properties) using the Windows Print Setup dialog. To modify Windows printer properties:

This print method (Windows Printer, with Use Printer Definition Table set to No) is useful when it is not possible to access the printer without using the Windows printer driver (as is the case with a USB printer or a Windows-only printer) or when a PDT file is not available (as is the case with a PostScript printer).

Because this print method uses Windows Native Printer Interface (WNPI) mode:

B. Windows Printer, with Use Printer Definition Table to Yes

To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click Windows Printer.
  3. Set Use Printer Definition Table to Yes.
  4. Expand the Printer Definition Table listbox and select a PDT.

Before the Host On-Demand client can use this print method, the Host On-Demand administrator must provide a Printer Definition Table (PDT) (see Creating a PDT file ).

You can select the Windows printer that you want to use, either a local printer or a network printer. To select a Windows printer:

  1. Open the Printer Setup window.
  2. To use the default Windows printer, set Choose Windows Printer to Use Default.
  3. To select another Windows printer:
    1. Set Choose Windows Printer to Other.
    2. Click Select Printer

Because this print method uses Windows Spooler Interface (WSI) mode:

C. Other Printer (always uses a Printer Definition Table)

On non-Windows platforms, this print method is called Printer.

Normally you do not need to use this print method on the Windows platform. It produces the same output as method A or method B, but is less user friendly.

To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click Other Printer.
  3. Expand the Printer Definition Table listbox and select a PDT.

Before the Host On-Demand client can use this print method, the Host On-Demand administrator must provide a Printer Definition Table (PDT) (see Creating a PDT file ).

In the Printer Name field, you can type any one of the following:

D. File, with Use Adobe PDF set to No (always uses a Printer Definition Table)

To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click File.
  3. Set Use Adobe PDF to No.
  4. In the File Path and Name field, type a valid file path and name.
  5. Expand the Printer Definition Table listbox and select a PDT.

Before the Host On-Demand client can use this print method, the Host On-Demand administrator must provide a Printer Definition Table (PDT) (see Creating a PDT file ).

For the file path and name, see Specifying a File Path and Name.

You can also use the File Path and Name field to specify one or more native console commands to be run after the host print job completes (see Running external commands after host print jobs in the online help).

This print method is useful when you do not want to send the print output to a printer immediately. For example:

This print method also is useful when if you want to generate print output in a flat ASCII format.

E. File, with Use Adobe PDF set to Yes (does not use a Printer Definition Table)

To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click File.
  3. Set Use Adobe PDF to Yes.
  4. In the File Path and Name field, type a valid file path and name.

The Host On-Demand client transforms the print output to binary data in Adobe PDF format, and writes the binary data into the specified file. The file can be viewed with Adobe Reader version 4.0 or later.

This print method is useful when you want to transform the data to a portable and easily viewable format.

This method does not require a PDT.

Using the print methods on UNIX, AIX, or Linux

The following table shows the print methods available when the Host On-Demand client is running on a UNIX, AIX, or LINUX platform, and summarizes the characteristics associated with each print method:

Print method: Characteristics:
A. Windows Printer, with Use Printer Definition Table set to No
  • Not available on UNIX, AIX, or Linux.
B. Windows Printer, with Use Printer Definition Table set to Yes
  • Not available on UNIX, AIX, or Linux.
C. Printer (always uses a Printer Definition Table)
  • This print method is called Other Printer on Windows platforms.
  • This is the default print method for UNIX, AIX, and Linux.
  • The administrator must provide a Printer Definition Table (PDT).
D. File, with Use Adobe PDF set to No (always uses a Printer Definition Table)
  • The administrator must provide a Printer Definition Table (PDT).
  • This print method is useful if you do not want to send the print output to a printer immediately.
  • You must also use this method when you want to send the print output to a network printer.
E. File, with Use Adobe PDF set to Yes (does not use a Printer Definition Table)
  • A PDT is not required.
  • The print output is written to the specified file in Adobe PDF format.
The remainder of this subsection describes how to use each print method on the UNIX, AIX, and Linux platforms.
A. Windows Printer, with Use Printer Definition Table set to No

This print method is not available on UNIX, AIX, or Linux.

B. Windows Printer, with Use Printer Definition Table set to Yes

This print method is not available on UNIX, AIX, or Linux.

C. Printer (always uses a Printer Definition Table)

On Windows platforms, this print method is called Other Printer.

This is the default print method for the Host On-Demand client when it is running on a UNIX, AIX, or Linux platform. To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click Other Printer.
  3. Expand the Printer Definition Table listbox and select a PDT.

Before the Host On-Demand client can use this print method, the Host On-Demand administrator must provide a Printer Definition Table (PDT) (see Creating a PDT file ).

To send the print output to a printer attached directly to the workstation, you must type a valid device name (such as /dev/lp0) into the Printer Name field. The Host On-Demand client writes the print data stream to the device that you specify.

To send the print output to a network printer, you cannot use this method on UNIX, AIX, or Linux. Instead, use method D.

D. File, with Use Adobe PDF set to No (always uses a Printer Definition Table)

To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click File.
  3. Set Use Adobe PDF to No.
  4. In the File Path and Name field, type a valid file path and name.
  5. Expand the Printer Definition Table listbox and select a PDT.

Before the Host On-Demand client can use this print method, the Host On-Demand administrator must provide a Printer Definition Table (PDT) (see Creating a PDT file ).

For the file path and name, see Specifying a File Path and Name.

You can also use the File Path and Name field to specify one or more native console commands to be run after the host print job completes (see Running external commands after host print jobs in the online help).

This print method is useful when you do not want to send the print output to a printer immediately. For example:

You must also use this method when you want to send print output from an UNIX, AIX, or Linux workstation to an available network printer. Follow these steps:

  1. Use the File print method to send the output to a file.
  2. From the command prompt, issue the appropriate command to send the file to the network printer. For example, if the name of the file is hprint.000 and the name of the remote printer is prtq1, then you might type:
    lp  -dprtq1  hprint.000
    or
    lp  -Pprtq1  hprint.000

E. File, with Use Adobe PDF set to Yes (does not use a Printer Definition Table)

To select this print method:

  1. Open the Printer Setup window.
  2. Expand the Print to listbox and click File.
  3. Set Use Adobe PDF to Yes.
  4. In the File Path and Name field, type a valid file path and name.

The Host On-Demand client transforms the print output to binary data in Adobe PDF format, and writes the binary data into the specified file. The file can be viewed with Adobe Reader version 4.0 or later.

This print method is useful when you want to transform the data to a portable and easily viewable format.

This method does not require a PDT.

Print Technologies

The Host On-Demand host print clients (3270 Printer session and 5250 Printer session) use the following three print technologies (or print "modes"):

The 3270 Display session uses a fourth print technology:

The following table summarizes the relationships between the five print methods described in the preceding sections and the three print technologies used by host print clients:

Print method: Print technology:
Windows Printer, with Use Printer Definition Table set to No Windows Native Printer Interface (WNPI) mode
Windows Printer, with Use Printer Definition Table set to Yes Windows Spooler Interface (WSI) mode
Other Printer or Printer (always uses a Printer Definition Table) Java File Interface (JFI) mode
File, with Use Adobe PDF set to No (always uses a Printer Definition Table) Java File Interface (JFI) mode
File, with Use Adobe PDF set to Yes (does not use a Printer Definition Table). Java File Interface (JFI) mode and libraries for generating Adobe PDF format.

The following subsections describe each of the three print technologies (print "modes")

Windows Native Printer Interface mode

This mode is supported by Host On-Demand Version 12.0 and later versions and is available only on clients running a Windows platform.

In this mode, the Host On-Demand client sends the print data stream to the printer by making Graphics Device Interface (GDI) API calls to the Windows printer driver for the selected printer via the Java Native Interface (JNI).

Because the Host On-Demand client is communicating with the Windows printer driver, this mode is useful:

Because the Host On-Demand client communicates with the Windows printer driver:

The Windows Native Printing mode uses two Windows native library files (hodprint.dll and hodprinterdriver.dll), which are automatically installed to your local file system. The directory where those files are installed varies depending on the Windows platform and the browser you are using.

Windows Spooler Interface mode

This mode is supported by Host On-Demand Version 12.0 and later versions and is available only on clients running a Windows platform.

In this mode, the Host On-Demand client:

  1. Uses a Printer Definition Table (PDT) to transform the 3270 print data stream to a printer data stream that is meaningful to the selected printer.
  2. Sends the printer data stream to the printer by calling the Windows Spooler Interface API via the Java Native Interface (JNI).

The use of a Printer Definition Table (PDT) often provides greater flexibility than may be available with Windows Native Printer Interface (WNPI) mode, because the PDT can specify printer data stream features that may not be supported by the Windows printer driver.

The Windows Spooler Interface mode uses two Windows native library files (hodprint.dll and hodspoolermode.dll), which are automatically installed to your local file system. The directory where those files are installed varies depending on the Windows platform and the browser you are using.

Java File Interface mode

This mode is supported on all Host On-Demand client platforms that support host print.

In this mode the Host On-Demand client:

  1. Uses a Printer Definition Table (PDT) to transform the 3270 print data stream to a printer data stream that is meaningful to the printer.
  2. Writes the printer data stream to a printer device (such as LPT1, \\myServer\myPrinter, or /dev/lp0) or to a file.

The use of a Printer Definition Table (PDT) provides great flexibility, because the PDT can specify detailed printer data stream features.

Specifying a File Path and Name

When you select to print to a file in the drop-down list of Print To options in the Printer window, you can type the File Path and Name. 

Creating Adobe PDF Files

3270 printer sessions now include the option to print to Adobe PDF files. This feature allows users to view files in a standard Web browser with the Adobe Acrobat plug-in installed. The Advanced Options panel enables the selection of  paper size, paper orientation, and Adobe PDF fonts.

The following table lists all of the supported paper sizes for Adobe PDF files. The default paper size for US English and Canadian locales is Letter. For all other locales, the default paper size is A4. 

Table 5. Supported Paper Sizes

Name Region Physical Width Physical Height
North American Media Sizes
Number 10 North America 4.125 in. 9.500 in.
Number 9 North America 3.875 in. 8.875 in.
Continuous Sheet (132 columns) North America 11.000 in. 13.200 in.
Continuous Sheet (80 columns) North America 8.000 in. 11.000 in. 
Executive North America 7.250 in. 10.500 in.
Ledger North America 11.000 in. 17.000 in.
Legal  North America 8.500 in. 14.000 in.
Letter North America 8.500 in. 11.000 in. 
Monarch North America 3.875 in. 7.500 in.
ISO/Japanese Media Sizes
A3 ISO/Japan 297.0 mm 420.0 mm
A4 ISO/Japan 210.0 mm 297.0 mm
A5 ISO/Japan 148.0 mm 210.0 mm
B4 (ISO) ISO 250.0 mm 353.0 mm
B4 (JIS) Japan 257.0 mm 364.0 mm
B5 (ISO) ISO 176.0 mm 250.0 mm
B5 (JIS) Japan 182.0 mm 257.0 mm
C5 ISO 162.0 mm 229.0 mm
DL ISO 110.0 mm 220.0 mm

For continuous sheets, the default margin value on all sides (top, bottom, right, and left) is 0. For North American paper (not including continuous sheets), the default margin value is 0.25 inches on all sides. For ISO/Japanese paper, the default margin value is 5 mm on all sides. 

Code pages used in Adobe PDF files

If the specified host code page is not Bidi or DBCS, Host On-Demand uses an internal Windows code page in the generated Adobe PDF file. The following list shows the Windows code pages that are used for specific host code pages:

Since Greek host code page 875 and Estonian host code pages 1122 and 1157 have characters that are not included in the Windows code pages above, the following characters cannot be printed:

Creating a PDT file

Please note the following definitions:

Broadly, the steps in compiling a PDF are as follows:

  1. Start the Printer Definition Table Compiler.
  2. Select a Printer Definition File (PDF).
  3. Click OK to compile the PDT.
  4. The PDT Compiler compiles the PDF file, generates the PDT file, and places the PDT file in a directory on the server.

To deploy a PDT file to the workstation on which the Host On-Demand client is running:

The following subsections describe how to create PDTs in more detail.

More about Printer Definition Files

A printer definition file (PDF) is an ASCII file that contains macro definitions, session parameters, formatting controls, and character definitions. You can edit a PDF with an ASCII text editor to customize it for your printer. Most printers support similar commands for basic functions, but they differ widely in their support for more advanced functions. Several PDFs are provided that should be suitable for most printers, except those that use PostScript and the HP Printing Performance Architecture (PPA).

You can compile and use PDFs from IBM Personal Communications for Host On-Demand. However, not all controls are supported.

Note that there is no connection between the PDFs in Host On-Demand and the Adobe PDF (Portable Document Format) files.

More about Printer Definition Tables

A printer definition table (PDT) is a file that is used to format the data stream that the host application sends. The Host On-Demand emulator converts the data stream from EBCDIC to ASCII (unless there is a passthru command in the data stream), formats the data according to controls specified in the data stream or in the PDT itself, and sends the data to the printer. You can use a simple PDT that contains basic instructions. However, if you want to use some of the newer workstation-printer functions, such as the ability to change fonts or paper-drawers, the PDT must be customized for your printer, and the host application must send the necessary commands. You must, in any case, use a PDT that is suitable for the emulation mode that the printer supports (HP PCL Level 3, IBM PPDS, and so on).

Several generic and specific PDTs are provided with Host On-Demand for both Single-byte Character Set (SBCS) and Double-byte Character Set (DBCS) printers. You can create customized versions of these or you can create entirely new ones. In either case, you need a Printer Definition File (PDF) from which to create a PDT.

Starting the Printer Definition Table Compiler

The compiler is a Java application that runs on a Host On-Demand server or a locally installed client. The compiler does not run on a download client.

When you start the compiler, it presents a graphical interface consisting of two entry fields: one for a PDT name and one for a printer description. A Status and Error Information window also appears. A log file called pdtc.log is created.

On a Windows XP, Windows 7, Windows 8, Windows 10, Windows Server 2008, Windows Server 2010 or a Windows client, you can start the compiler through Administration on the Start menu. On other platforms, you must start the compiler with a Java command. Sample command files are provided.

You can also start the compiler in non-graphical mode from a command line.

Locating Predefined Printer Definition Files and Tables

The PDFs and PDTs provided by IBM are installed in the pdfpdt subdirectory of the publish directory on a server (for example, <HostOnDemandInstallLocation>\HOD\pdfpdt) and in the equivalent subdirectory on a locally installed client ).

PDFs have the extension .pdf, and PDTs have the extension .hodpdt. A number of other PDFs are provided as examples and can be found in the samples\pdf directory of the publish directory (for example, %HostOnDemandInstallLocation%\HOD\samples\pdf).

For Arabic and Hebrew, prn*.pdf files are provided in the samples\pdf directory. To use one of these prn*.pdf files, copy the file from the samples\pdf directory to the pdfpdt\usrpdf directory, modify the copied file if necessary, and then compile it.

When compiling printer definition files shipped with Host On-Demand that contain Arabic or Hebrew markers, the resulting PDT does not appear in the Print Definition Table drop-down list in the printer properties on non-Hebrew or non-Arabic machines.  Refer to the Host On-Demand Hints and Tips website for detailed information.

Single-byte Character Set (SBCS) PDFs and PDTs

The following PDFs and PDTs are provided specifically for Host On-Demand:

basic Basic ASCII text mode
A simple PDF that produces readable output from most printers
LaserPCL HP PCL Level 3 (Laser Printers)
Suitable for most laser printers in PCL mode
LaserPPDS IBM PPDS Level 2
Suitable for most laser printers in PPDS level-2 mode
Proprinter IBM PPDS Level 1 (Proprinter XL, X24, XL24)
Suitable for most printers in PPDS level-1 mode

PDFs contain annotations that explain the purpose of parameters. Each section begins with text that explains how the parameters can be used. For more information, refer to Understanding the Format of Printer Definition Files and Printer Definition File Example (3270).

Thai PDTs and PDFs

When the host code page is Thai (838 or 1160), the following PDFs and PDTs are available:

Thai

basic_thai Basic ASCII text mode
esc_pthai Thai EPSON ESC/P compatible printers
esc_p2thai Thai EPSON ESC/P2 compatible printers
necthai Thai NEC printers

Double-byte Character Set (DBCS) PDFs and PDTs

For DBCS printers, the following PDTs and PDFs are provided:

Japan

basic_dbcs ASCII text mode: A simple PDF that produces readable output from most printers
esc_p Printers based on ESC/P 24-J84: Suitable for most EPSON ESC/P printers
ibm5577 IBM 5577-B02, F02, G02, H02: Appropriate for IBM 5577-series printers
ibm5585 IBM 5585-H01 Printer: Appropriate for IBM 5585 printers and printers based on pages
ibm5587 IBM 5587-G01, H01: Appropriate for IBM 5587 printers (without advanced function)
lips3a4 Printers based on LIPS 3: Appropriate for Canon LIPS printers (A4 size)
lips3b4 Printers based on LIPS 3: Appropriate for Canon LIPS printers (B4 size)

Korean

ibm5577k Korea IBM 5577 printer: Appropriate for IBM 5577 printers
kssm_jo KSSM_jo Printer: Appropriate for "combined" character-code-mode printers
kssm_wan KSSM_wan Printer: Appropriate for "complete" character-code-mode printers
ks_jo KS_jo Printer: Appropriate for "combined" character-code-mode printers
ks_wan KS_wan Printer: Appropriate for "complete" character-code-mode printers

China and Taiwan

esc_pp Simplified Chinese ESC/P Printer: Appropriate for most EPSON ESC/P printers in China
esc_5550 Traditional Chinese ESC/P Printer (5550): Appropriate for most EPSON printers in 5550-character-code mode in Taiwan
esc_big5 Traditional Chinese ESC/P Printer (big-5): Appropriate for most EPSON printers in Big-5-character-code mode in Taiwan
esc_cns Traditional Chinese ESC/P Printer (cns): Appropriate for most EPSON printers in CNS-character-code mode in Taiwan
esc_tca Traditional Chinese ESC/P Printer (tca): Appropriate for most EPSON printers in TCA-character-code mode in Taiwan
ibm5577t Traditional Chinese IBM 5577 Printer: Appropriate for IBM 557x-series printers in Taiwan
ibm5585t Traditional Chinese IBM 5585 Printer: Appropriate for IBM 5585 PAGE printers in Taiwan

The list of printer definition tables that appears on the Printer page of the session-configuration panel varies according to the Host Code Page that you set on the Connection page. In addition to those PDTs appropriate to the code page, the list includes any PDTs that you have created. If a session is configured for a DBCS code page, but you want to use an SBCS PDT, copy the appropriate PDF to the usrpdf directory and compile it with another name. It will then be a user-created PDT and will appear in the list on the configuration panel.

Supported Printer Emulation Modes

A PDT must be appropriate to the printer-emulation mode you want to use. For SBCS printers, the supported modes are:

For DBCS printers, the supported modes are:

If you are not sure which emulation modes or languages your printer supports, refer to the printer's technical documentation.

In some cases, it may be necessary to change the settings on the printer so that they match the mode for which the PDT is written. Some printers can switch between modes automatically or have software that enables you to change the mode. It is important to refer to the printer documentation to decide which PDT to use and how to set the correct mode on the printer. The printer manufacturer's Web site is another valuable source of information.

  • Most laser printers can use HP PCL level 3. Level-3 commands are understood by printers that support newer levels.
  • All printers that provide the PPDS mode support PPDS level 1.
  • Printers that support later levels of PPDS (3 or 4) will work with the LaserPPDS PDT.
  • Proprinter-compatible printers and printers that support only PPDS level 1 cannot switch code-pages, so use the Proprinter PDT for these printers.
  • Try basic ASCII text mode if your printer does not allow one of the other modes supported by Host On-Demand. However, if you use this mode, the commands that are unique to your printer will not be available.
  • PDT mode does not support PostScript; however, the Native Printing mode does support PostScript though the appropriate PostScript printer driver.

Creating a Printer Definition Table (PDT) (3270)

If you are not able to use any of the IBM-provided PDTs, you can create one. However, you cannot create a PDT directly. You must first create a printer definition file (PDF), and then compile it to create a PDT.

Creating a Printer Definition File

You can create a new PDF either by typing it or by customizing one of the IBM-supplied PDFs. In either case, use an ASCII editor, because word-processing programs sometimes introduce spurious codes into the text.

Save the PDFs you create in the pdfpdt\usrpdf subdirectory of the publish directory of the Host On-Demand server (for example, <HostOnDemandInstallLocation>\HOD\pdfpdt\usrpdf) or in the equivalent directory on a locally installed client.

Before you attempt to create a PDF, you should understand its structure and the types of statements that can be included. See Understanding the Format of Printer Definition Files for help.

You should have the technical documentation for your printer available so you can look up the needed control codes. There are many variations from printer to printer.

If you want to customize one of the IBM-supplied PDFs to create your own, copy it from the pdfpdt directory to the pdfpdt\usrpdf subdirectory, modify it, and then compile it.

 

Using the Printer Definition Table Compiler

When you have created or modified a PDF, use the Printer Definition Table Compiler to create a PDT. You can run the compiler in graphical or nongraphical mode. PDTs that you create have names in the format usr*.hodpdt, where * is the name of the PDF that you compiled.

Printer Definition Table Description

Every PDT must have a unique description because this identifies the PDT when you configure a printer session. In graphical mode, the compiler checks that a unique description has been assigned. If it finds that a PDT with the same description already exists, it stops compiling and displays an error message. You can then  change the description and click OK to start again. In nongraphical mode, the compiler does not check that the description is unique.

Running the Compiler in Graphical Mode

The graphical mode lets you compile PDFs interactively. A log file called pdtc.log is saved in the pdfpdt\usrpdf directory.

Compiling a PDT on a Windows workstation or server

To compile a printer definition table on a Windows workstation or server:

  1. Create a PDF and save it in the pdfpdt\usrpdf directory (for example, <HostOnDemandInstallLocation>\HOD\pdfpdt\usrpdf).
  2. Click Start > Programs > IBM Host On-Demand > Administration > Printer Definition Table Compiler.
  3. Select the printer definition file from the pull-down list.
  4. Type a description for the printer definition table that you are going to create. A description is essential because it serves to identify the PDT when you configure a printer session.
    If the description is not unique, an error message appears.
  5. Click OK. The PDT is created in the pdfpdt directory. Status and error information appears at the bottom of the window and in the log file. If there are errors in the PDF, correct them and then recompile.

    If you want to compile other PDFs, repeat steps 3 - 5.

  6. Click Exit when you have finished.

Compiling a PDT on an AIX, or UNIX server

  1. Copy the PdtCompilerApplication-AIX (or UNIX, or OS/2) file from the lib/samples/PdtCompiler directory in the Host On-Demand install directory (for example, from /opt/IBM/HostOnDemand/lib/samples/PdtCompiler) to a user directory (for example, /usr/local).
  2. Modify the three variables in the PdtCompilerApplication-AIX file to match the installed system. Use the directions provided in the command file.
  3. For UNIX servers only, change the file permissions for PdtCompilerApplication-UNIX to executable.
  4. Run the PdtCompilerApplication-AIX (or UNIX, or OS2).
  5. Select a PDF file from the pull-down and use it or modify it.
  6. Enter a PDT description. This is name that Host On-Demand will use to identify this PDT.
  7. Click OK.
  8. Copy the PDF file to the pdfpdt/usrpdf directory. You may need to create the usrpdf directory.

Compiling a PDT on an iSeries server

To compile a printer definition table on an iSeries server, do the following:

  1. Copy the PdtCompilerApplication-OS400 file from the lib/samples/PdtCompiler directory (for example, from /QIBM/ProdData/hostondemand/lib/samples/PdtCompiler) to your work directory
  2. Edit the file to reflect your environment.
  3. Run the qsh command to start a shell session.
  4. Run the command file that you edited in step 2.

The compiler runs in nongraphical mode.

Compiling a PDT on z/OS

To compile a printer definition table on z/OS, do the following:

  1. Save the PDFs created or modified in the pdfpdt/usrpdf subdirectory of the publish directory (for example, /usr/lpp/HOD/hostondemand/HOD/pdfpdt/usrpdf). Create the directory if it does not exist. 
  2. Edit the PdtCompilerApplication-S390 found in /usr/lpp/HOD/hostondemand/HOD/samples/PdtCompilerCommandFiles. 
  1. Verify the JAVA_ENGINE variable has the correct Java path.  
  2. Modify the NONGUI_COMMAND line for the .pdf name and description. 
  1. Run the PdtCompilerApplication-S390 command. 

The compiler runs in nongraphical mode.

Compiling a PDT on other platforms

On other platforms, you are suggested starting the compiler with a command. To make this easier, sample command files are provided in the pdtcompilercommandfiles directory.

  1. Copy the sample command file to a proper directory in your environment.
  2. Edit the file to reflect your environment.
  3. Run the command.
  4. Select a printer definition file from the pull-down list.
  5. Type a description for the printer definition table that you are going to create.
    If the description is not unique, an error message appears.
  6. Click OK. The PDT is created in the pdfpdt directory. Status and error information appears at the bottom of the window and in the log file. If there are errors in the PDF, correct them and then recompile.

    If you want to compile other PDFs, repeat this process.

  7. Click Exit.

 

Status and Error Information

The bottom window of the graphical interface displays status and error information. When you use the graphical interface, a history of each compiler run is saved in pdtc.log in the usrpdf subdirectory. The log is overwritten each time you start the compiler.

In addition to verifying that the PDT description is unique, the compiler checks that the syntax of the PDF is correct. Errors found are displayed in the Status and Error Information window and saved in the log.

Running the Compiler in Nongraphical Mode

This section does not apply to zOS.

If you want to compile several PDTs at one time, you can run the compiler in nongraphical batch mode by creating a command file and including multiple instances of the command that runs the compiler.

You can modify a version of the appropriate sample command-file provided in the pdtcompilercommandfiles directory; add any of the parameters listed below as necessary. If you compile several PDTs at one time, use the -NOINDEX parameter for each instance except the last, for which you should use the INDEX parameter. Create an index only after you have done the other compilations.

-NOINDEX
Causes the compiler to run in nongraphical mode and does not generate an index. This parameter is not recognized in graphical mode.
INDEX
Causes the compiler to run in nongraphical mode and to create an index, which lets Host On-Demand keep track of PDTs. When you use INDEX, you may not use any other options. Note that INDEX must not have a dash ( - ) before it.
-PATH pathSpecification
Causes the compiler to look for PDFs in the [pathSpecification]\pdfpdt directory.
-ENCOD encodingSpecification
Causes the PDF to be interpreted with the Java encoding-table specified rather than with the default table. You should use this if you are running the compiler on MVS and the MVS system uses an encoding-table different from that in which the PDF was created.

The command to invoke the compiler in nongraphical mode is:

   INSTALL_PATH/lib/samples/PdtCompiler/PdtCompilerApplication-XXX
   [-NOINDEX] | [-PATH pathSpecification] | [-ENCOD encodingSpecification] [PDF_file_name PrinterDescription]
where XXX is the appropriate suffix for compiler application file for your platform.
Operating Systems XXX Option
AIX PdtCompilerApplication-AIX
OS400 PdtCompilerApplication-OS400
s390 PdtCompilerApplication-s390
UNIX PdtCompilerApplication-UNIX
  • If the PDF_file_name is present, the PrinterDescription must also be present.
  • If the PDF_file_name is not present, the compiler runs in graphical mode.

After you have compiled your PDT(s), you must run the compiler again to create an index, which is essential. The command to invoke the compiler to create only an index is:

   INSTALL_PATH/lib/samples/PdtCompiler/PdtCompilerApplication-XXX INDEX
where XXX is the appropriate suffix for compiler application file for your platform.

Compiled printer definition tables are saved in the pdfpdt directory (for example, in <HostOnDemandInstallLocation>\HOD\pdfpdt).

In nongraphical mode, compiler messages are displayed in English only.


Understanding the Format of Printer Definition Files (3270)

A PDF contains three main sections:

Macro Definitions

This section of a PDF contains macros that consist of a single mnemonic that represents a control code or a sequence of control codes. A mnemonic simplifies the definition of control sequences for PC printers and makes it easier to read the information in the PDF. The PDFs provided by IBM include many macros, but you can define also your own.

The following table shows the structure of a macro definition statement. A macro definition is composed of four parts:

1 2 3 4
name EQU PC printer control codes Comments

For example:

   FFF    EQU   0C               /* Form Feed */

Part 1 is the mnemonic or macro name. This must be three characters long and must not begin with a number. It is helpful to define a meaningful mnemonic, such as P17 for 17.1 pitch.

Part 2, stands for "equates to" and must be coded as EQU.

Part 3, the hexadecimal control code, must be defined specifically for the printer you intend to use, because printer manufacturers use different codes for the same function. For example, the IBM LaserPrinter uses control codes defined by the IBM Personal Printer Data Stream (PPDS), whereas Hewlett-Packard printers use control codes defined by the Hewlett-Packard Printer Control Language (PCL). These control codes are defined in the reference manual for the printer (which you might need to order).

Some printer manuals describe control sequences as a string of ASCII symbols, such as ESC W 1. Others use hexadecimal numbers, such as 1B 57 01. Still others use decimal values, such as 027 087 001. The PDT compiler accepts any of these formats.

The control codes in the macro definitions section can be any of the following:

If the control code part of a macro (part 3) is blank, it is interpreted as a null string. If a code is defined more than once in the file, the last definition is used.

Part 4, the comment section, must be enclosed by /* and */. Comments can be included at any point in the file and are ignored by the compiler.

The following macro definition example is for a printer that supports IBM PPDS:

CRR EQU 0D             /* Carriage Return                             */
SEL EQU 11             /* Select Printer                              */
P10 EQU 12             /* 10 Pitch (characters/inch)                  */
P12 EQU 1B 3A          /* 12 Pitch (characters/inch)                  */
P05 EQU 1B 57 01       /* 5 Pitch (characters/inch), double wide      */
CDW EQU 1B 57 00       /* Cancel Double Wide                          */
CDL EQU 14             /* Cancel Double Wide line                     */
CS2 EQU 1B 36          /* Select character set 2                      */
SVT EQU 1B 42          /* Set vertical tabs                           */
CAT EQU 1B 52          /* Cancel all tabs (clears VT)                 */
SFL EQU 1B 43 00       /* Set Form Length                             */
SDS EQU 1B 47          /* Start Double Strike                         */
CDS EQU 1B 48          /* Cancel Double Strike                        */
SUL EQU 1B 2D 01       /* Start Underline                             */
CUL EQU 1B 2D 00       /* Cancel Underline                            */
CP8 EQU 1B 5B 54 04 00 00 00 03 52     /* select code page 850        */
CP4 EQU 1B 5B 54 04 00 00 00 01 B5     /* select code page 437        */
LL8 EQU 1B 41 09 1B 32 /* Set line length 8 lines/inch                */

Here is an example of how a macro might be used.

The host data stream contains a Word Underscore (WUS) command (LU1 SCS command 23). This indicates that the preceding word or string must be underlined. Host On-Demand converts the WUS command into START_HIGHLIGHT_UNDERLINE before the word and END_HIGHLIGHT_UNDERLINE after the word.

These controls are defined as macros SUL and CUL in the Control Codes section of the PDF:

     START_HIGHLIGHT_UNDERLINE=SUL
     END_HIGHLIGHT_UNDERLINE=CUL
These macros are defined in the Macros section (see above).

 

When Host On-Demand receives the WUS command, it looks up the control codes and then looks up the macros. It finally sends the escape sequences defined in the macros to the printer. If the host sent a WUS command following the string "This is underscored", the following codes would be sent to the printer:

     54686973   20    6973   20    1B2D01   756E64657273636F726564   1B2D00

      T h i s  space   i s  space    SUL     u n d e r s c o r e d     CUL

The printed output is: "This is underscored"

Refer to Appendix A. Printer Data Stream Information for more information.


Formatting Controls

This section describes the session parameters, control codes, and highlighting specifications that can be included in a PDF.

Field Names and Parameter Definitions

The parameter to the left of the equal sign is a keyword and must be coded exactly as shown. The keyword defines a statement. The value to the right of the equal sign can be a word, a macro, a control code, a decimal number, or a hexadecimal number (sometimes referred to as a parameter).

Session Parameters

Session parameters determine the way in which the output is formatted. The session parameters in a PDF are related to the parameters in the Advanced Options panel of a session configuration, though there are many more options in a PDF than in the panel. If you do not change the defaults in the configuration panel, the values for the equivalent parameters in the PDT are used. Any change you make in the panel overrides the value in the PDT. Refer to Appendix C. Advanced Configuration Options for the list of session parameters that can be set in the panel.

The following table lists the field names and meanings of the Session Parameters.

Table 1. Session Parameters

Field Name Value or Remarks
ASCII_PASSTHRU? YES/NO. For LU1 only. Host data sent without any translation. For host applications that generate PC printer control codes directly. See below for more information.
EBCDIC_PASSTHRU? YES/NO. For LU1 only. SCS commands ignored and data sent to the printer after EBCDIC-to-ASCII translation. See below for more information.
MAXIMUM_PAGE_LENGTH 001 to 255. Number of lines that could print on a sheet of paper. For example, 66 means an 11-inch sheet at 6 lines per inch. If you change this value, you must change the value in the "SET_PAGE_LENGTH=SFL value" control code to be the same.
MAXIMUM_PRINT_POSITION 001 to 255. Number of characters that could fit on a line.
DEFAULT_CPI? 010, 012, 017. Default characters per inch.
DEFAULT_LPI? 002, 003, 004, 006, 008, 010. Default lines per inch.
COMPRESS_LINE_SPACING? YES/NO. For LU3 only. Determines whether a line is to be printed if all characters on that line are nulls or blanks.
FORM_FEED_ANY_POSITION? YES/NO. For LU3 only. Determines whether a form feed is to be active in any position. If NO, a form feed will be active only in the following positions:
  • First print position of the buffer
  • After a valid new-line operation
  • First print position of a line
OVERRIDE_FORMATTED_PRINT? YES/NO. For LU3 Only. Specifies whether to print null characters as blanks.
HORIZONTAL_PEL Number of pels in one inch (X-direction).
VERTICAL_PEL Number of pels in one inch (Y-direction).
LINE_SPACING_RATIO Integer value equivalent to one inch. Used as the unit for SET_VARIABLE_LINE_DENSITY. 72 for PPDS, 4 8 for PCL.
TOP_MARGIN Decimal value. Default is top of sheet.
LEFT_MARGIN Decimal value. Default is left edge of sheet.
AUTO_NEWLINE_AT_MAX_POS? YES/NO. Specifies whether CR and LF are inserted at MPP.
IGNORE_FORM_FEED_AT_FIRST_POS? YES/NO. Specifies whether FF at the first position is ignored.
FORM_FEED_TAKES_POSITION? YES/NO. For LU3 only. Specifies whether FF occupies a space.
NO_AUTO_NL_IF_CR_AT_MPP_PLUS_1? YES/NO. For LU3 only. Specifies whether auto-new-line is suppressed when CR is at MPP+1. When this is set to YES, auto-new-line is suppressed.
NO_AUTO_NL_IF_NL_AT_MPP_PLUS_1? YES/NO. For LU3 only. Specifies whether auto-new-line is suppressed when NL is at MPP+1. When this is set to YES, auto-new-line is suppressed.
INTERV_REQ_TIMER 000 TO 255. Determines the delay before an "intervention required" message is sent. A value of 000 disables the timer. A value below 011 sets an interval of 10 seconds.
FORM_FEED_AT_END_OF_JOB NONE/ALWAYS/CONDITIONAL. Specifies how form feed is inserted at the end of the job. When this is set to NONE, no form feed is inserted at the end of the job. When this is set to ALWAYS, form feed is always inserted at the end of the job. When this is set to CONDITIONAL, form feed is inserted only when a job was not ended at the page boundary. The default value is CONDITIONAL.

ASCII_PASSTHRU? Keyword Support (LU1 Only)

If you add the following line to a PDF, Host On-Demand sends host data to the printer without translation:

     ASCII_PASSTHRU? = YES

This option is for host applications that generate PC printer control codes directly.

  1. Even if ASCII_PASSTHRU? is set, control codes defined in the START_JOB and END_JOB sections of the PDF are sent to the printer at the start and end of a print job respectively. Remove them, if needed.
  2. If ASCII_PASSTHRU? is set, all character definition lines, such as EBCDIC_xx, are ignored.
  3. If both ASCII_PASSTHRU? and EBCDIC_PASSTHRU? are set, ASCII_PASSTHRU? takes precedence.

EBCDIC_PASSTHRU? Keyword Support (LU1 Only)

If you add the following line to a PDF, Host On-Demand ignores all SCS commands and sends only data to the printer after EBCDIC-to-ASCII translation:

     EBCDIC_PASSTHRU? = YES

  1. If EBCDIC_PASSTHRU? is set, control codes defined in the START_JOB and END_JOB sections of the PDF are sent to the printer at the start and the end of a print job respectively. Remove them, if needed.
  2. If both ASCII_PASSTHRU? and EBCDIC_PASSTHRU? are set, ASCII_PASSTHRU? takes precedence.

The default EBCDIC-to-ASCII translation table used for U.S. English host code page 037 is as follows:

     Hex    0 1  2 3  4 5  6 7  8 9  A B  C D  E F
     ---------------------------------------------
       0 | 2020 2020 2020 2020 2020 2020 2020 2020
      10 | 2020 2020 2020 2020 2020 2020 2020 2020
      20 | 2020 2020 2020 2020 2020 2020 2020 2020
      30 | 2020 2020 2020 2020 2020 2020 2020 2020
      40 | 20FF 8384 85A0 C686 87A4 BD2E 3C28 2B7C
      50 | 2682 8889 8AA1 8C8B 8DE1 2124 2A29 3BAA
      60 | 2D2F B68E B7B5 C78F 80A5 DD2C 255F 3E3F
      70 | 9B90 D2D3 D4D6 D7D8 DE60 3A23 4027 3D22
      80 | 9D61 6263 6465 6667 6869 AEAF D0EC E7F1
      90 | F86A 6B6C 6D6E 6F70 7172 A6A7 91F7 92CF
      A0 | E67E 7374 7576 7778 797A ADA8 D1ED E8A9
      B0 | 5E9C BEFA B8F5 F4AC ABF3 5B5D EEF9 EF9E
      C0 | 7B41 4243 4445 4647 4849 F093 9495 A2E4
      D0 | 7D4A 4B4C 4D4E 4F50 5152 FB96 8197 A398
      E0 | 5CF6 5354 5556 5758 595A FDE2 99E3 E0E5
      F0 | 3031 3233 3435 3637 3839 FCEA 9AEB E9FF

You can modify this code page by using EBCDIC_xx keywords. Note that the EBCDIC_PASSTHRU? line must precede any EBCDIC_xx lines in a PDF because Host On-Demand re-initializes the EBCDIC-to-ASCII translation table when EBCDIC_PASSTHRU? is set.


Control Codes

The control codes section of a PDF defines which ASCII escape sequence is sent to the printer when a host control code is received. The escape sequence varies from printer to printer. The PDF must be written specifically for the emulation mode you use.

Control Codes used for both SBCS and DBCS Languages

The following table lists the field names and meanings of control codes that are used for both SBCS languages and DBCS languages.

Table 2. Control Codes

Field name Value or remarks
SET_AUTO_PERFORATION_SKIP Sets the number of lines needed to skip over the perforation between pages
PAGE_LENGTH_TYPE?
  • LINE (= number of lines)
  • INCH (= number of inches)
  • 6INCH (= increments of 1/6 inch)
Defines the unit to be used in SET_PAGE_LENGTH
SET_VARIABLE_LINE_DENSITY Sets the line spacing. Uses the unit defined in the LINE_SPACING_RATIO field (a session parameter)
START_JOB Sets control codes to be sent to a printer at the start of a job
END_JOB Sets control codes to be sent to a printer at the end of a job
BACKSPACE Backspace control code
BEL Bell control code
CARRIAGE_RETURN Carriage return control code
NEW_LINE New line (CR/LF) control code
LINE_FEED Line feed control code
FORM_FEED Form feed (FF) control code
HORIZONTAL_TAB Horizontal tab control code
VERTICAL_TAB Vertical tab control code
DESELECT Device control 3 control code
DUP Character used to print the DUP order (*)
FIELD_MARK Character used to print the FIELD MARK order (;)
SET_HORIZONTAL_TABS Horizontal tabs (column numbers)
SET_VERTICAL_TABS Vertical tabs (line numbers)
SET_HORIZONTAL_MARGINS Right and left margins (column numbers)
SET_PAGE_LENGTH The page length as a multiple of the unit defined in PAGE_LENGTH_TYPE
SET_2_LINES_PER_INCH Line-spacing definition (2LPI)
SET_3_LINES_PER_INCH Line-spacing definition (3LPI)
SET_4_LINES_PER_INCH Line-spacing definition (4LPI)
SET_6_LINES_PER_INCH Line-spacing definition (6LPI)
SET_8_LINES_PER_INCH Line-spacing definition (8LPI)
SET_10_LINES_PER_INCH Line-spacing definition (10LPI)
SET_10_CHARACTERS_PER_INCH Character-pitch definition (10CPI)
SET_12_CHARACTERS_PER_INCH Character-pitch definition (12CPI)
SET_17_CHARACTERS_PER_INCH Character-pitch definition (17.1CPI)
FORWARD_HORIZONTAL_SKIP Defines the unit to be used in the HORIZONTAL_PEL session parameter
FORWARD_VERTICAL_STEP_FEED Defines the unit to be used in the VERTICAL_PEL session parameter
START_HIGHLIGHT_INTENSE Highlight printing (double strike) start
END_HIGHLIGHT_INTENSE Highlight printing (double strike) end
START_HIGHLIGHT_UNDERLINE Underline start
END_HIGHLIGHT_UNDERLINE Underline end
START_HIGHLIGHT_REVERSE_VIDEO Reverse video start
END_HIGHLIGHT_REVERSE_VIDEO Reverse video end
START_HIGHLIGHT_BLINK Blink start
END_HIGHLIGHT_BLINK Blink end
START_DOUBLE_WIDTH_CHARACTER Double-width characters start
END_DOUBLE_WIDTH_CHARACTER Double-width characters end
CUSTOM_CONTROL_CODES? See Using custom control codes (LU1 and LU3).
CUSTOM_CONTROL_CODES_HEADER See Using custom control codes (LU1 and LU3).
CUSTOM_CONTROL_CODES_LENGTH See Using custom control codes (LU1 and LU3).
CUSTOM_CONTROL_CODES_TRAILER See Using custom control codes (LU1 and LU3).

START_JOB and END_JOB

The control codes associated with START_JOB are sent at the start of each host print job. The control codes associated with END_JOB are sent at the end of each job.

Another application or a print job from another user might leave the printer in a mode that does not suit the job you want to print (for example, portrait orientation and Courier font). Set all printer options to a known or desired state at the beginning of each job using START_JOB. Similarly, because several users and applications share the printer, reset the printer to a known state at the end of each job using END_JOB.

For example:

     START_JOB=SEL CDW CDL CUL CDS CP8 CS2 SLO
     END_JOB=CAT CDW CDL CUL CDS CP4 SPO

In this example, the SLO macro is included in the START_JOB statement and the SPO macro is included in the END_JOB statement. The macros are coded as follows:

     SLO EQU 1B 6C     /* Set Landscape Orientation */
     SPO EQU 1B 6B     /* Set Portrait Orientation  */

The result is that the START_JOB statement sends a command to print the job in landscape orientation. The END_JOB statement sends a command to reset the printer to portrait orientation at the end of the job.

SET_VARIABLE_LINE_DENSITY

Use the SET_VARIABLE_LINE_DENSITY statement in combination with the lines-per-inch option in the Advanced Options panel of the session configuration.

The PDT substitutes the value set in the lines-per-inch field, divided into the LINE_SPACING_RATIO (72 for PPDS, 48 for PCL), for the value keyword in the SET_VARIABLE_LINE_DENSITY statement. The format of the PPDS command requires the result in binary form. The format of the PCL format requires the result in decimal (ASCII) form. For PPDS, the statement is:

     SET_VARIABLE_LINE_DENSITY=ESC A value ESC 2
If lines-per-inch is set to 8, the SET_VARIABLE_LINE_DENSITY parameter is:
     SET_VARIABLE_LINE_DENSITY=ESC A 09 ESC 2
where 09 is the result of 72/8. The control code sent to the printer to set the line density (spacing) is:
     1B    41    09    1B    32
    (ESC    A    09    ESC    2)
If SET_VARIABLE_LINE_DENSITY does not have a value, the value of the SET_(n)_LINES_PER_INCH statement is used.

 

CHARACTER_PITCH

On most printers, the default pitch is 10 characters per inch. This is usually coded in the PDF as:

SET_10_CHARACTERS_PER_INCH=P10

where P10 is coded in the macro definition section as:

P10 EQU 12     /* 12 is the printer control code for 10 pitch /*

 

REVERSE_VIDEO and BLINK

The reverse-video and blink codes do not have specified values because printers do not use them. You can use them to send any command you want to the printer by defining a macro, specifying the macro as the value for one of these codes, and sending the code (for example, START_HIGHLIGHT_BLINK) in the host data stream.

Using Custom Control Codes (LU1 and LU3)

Host On-Demand supports custom control codes in 3270 Printer LU1 sessions and in 3270 Printer LU3 sessions. (Host On-Demand does not support custom control codes for 5250 Printer sessions).

A custom control code is a pair of EBCDIC characters that Host On-Demand translates into a hexadecimal byte. Each member of the EBCDIC pair must be either in the range F0-F9 (representing '0'-'9'), or in the range C1-C6 (representing 'A'-'F'), or in the range 81-86 (representing 'a'-'f'). The first member of the pair represents the high nibble of the hexadecimal byte. The second member of the pair represents the low nibble of the hexadecimal byte. For example, the custom control code 81 f0 is translated into the hexadecimal byte a0.

Note: In fact, the translation is in two steps:

  1. Host On-Demand converts an EBCDIC pair to an ASCII pair. For example, EBCDIC 81 f0 is converted to ASCII 61 30.
  2. Host On-Demand translates the ASCII pair to a hexadecimal byte. For example, ASCII 61 30 is translated to hexadecimal a0.
For the EBCDIC-to-ASCII conversion, Host On-Demand uses the current host code page and the current local code page. For virtually all code pages: However, if the EBCDIC-to-ASCII conversion is different from the above, either because of the host code page, or because of the local code page, or because of a custom PDT table, then you must use the EBCIDIC control codes that convert to the proper ASCII characters. (For example, if you want to create a hexadecimal 1b, then you need to specify the two EBCDIC characters that translate to ASCII 31 62.)

In the LU1 or LU3 print data stream, custom control codes must occur inside a custom control code block (which is discussed later in this section). Any number of custom control code blocks can occur in a print data stream. Each custom control code block can contain one or more custom control codes (that is, one or more pairs of EBCDIC characters).

Notice the following:

Control codes

The control codes used to manage custom control codes are:

The control code CUSTOM_CONTROL_CODES? is used to enable or disable custom control codes:

The control code CUSTOM_CONTROL_CODES_HEADER, when it appears in the LU1 or LU3 print data stream, signals the beginning of a custom control code block. You must define this control code in the control codes section of your PDF file, setting it to some macro value or to some series of literal values. For example,

CUSTOM_CONTROL_CODES_HEADER=6c 6c

The control code CUSTOM_CONTROL_CODES_TRAILER is used only in header-trailer mode (see below). This control code, when it appears in the LU1 or LU3 print data stream after a CUSTOM_CONTROL_CODES_HEADER, signals the end of a custom control code block. You must define this control code in the control codes section of your PDF file, setting it to some macro value or to some series of literal values. For example,

CUSTOM_CONTROL_CODES_TRAILER=6c 6c
The value of the trailer can be the same as the value of the header, or different from the value of the header. Often it is convenient to assign the same value to the header and the trailer.

The control code CUSTOM_CONTROL_CODES_LENGTH is used only in header-length mode (see below). This control code does not appear in the LU1 or LU3 print data stream. Instead, it defines the fixed number of custom control codes (EBCDIC pairs) that occur in every custom control code block in the print data stream. You must define this control code in the control codes section of your PDF file, setting it to some macro value or to some series of literal values. For example:

CUSTOM_CONTROL_CODES_LENGTH=1
The above definition of CUSTOM_CONTROL_CODES_LENGTH states that each custom control code block occurring in the print data stream contains one custom control code (one pair of EBCDIC characters).
Modes

Within a single LU1 or LU3 print data stream, you can use custom control codes either in header-trailer mode or in header-length mode. You cannot use both modes in the same print data stream.

Header-trailer mode

In header-trailer mode, a custom control code block consists of:

You must have Host On-Demand use header-trailer mode when the print data stream contains custom control code blocks of different lengths. For example, you must have Host On-Demand use header-trailer mode if the print data stream contains some custom control code blocks containing one control code (1 EBCDIC pair) and other custom control code blocks containing two control codes (2 EBCDIC pairs).

To indicate that you want Host On-Demand to use header-trailer mode, define the CUSTOM_CONTROL_CODES_TRAILER in the control codes section of your PDF file. Here is an example of how to define the relevant control codes in your PDF file when you want to use header-trailer mode:

CUSTOM_CONTROL_CODES?=YES
CUSTOM_CONTROL_CODES_HEADER=6c 6c
CUSTOM_CONTROL_CODES_TRAILER=6c 6c
Do not define the CUSTOM_CONTROL_CODES_LENGTH control code. Host On-Demand ignores this control code when you define CUSTOM_CONTROL_CODES_TRAILER.

Here is an example of a custom control code block that Host On-Demand could process using the above definitions.

6c 6c f1 82 f1 83 6c 6c
Host On-Demand processes these characters as follows:
  1. When it encounters the header 6c 6c, Host On-Demand recognizes that it must process subsequent pairs as custom control codes.
  2. Host On-Demand converts EBCDIC f1 82 to hexadecimal 1b, and then sends this hexadecimal 1b to the print destination.
  3. Host On-Demand converts EBCDIC f1 83 to hexadecimal 1c, and then sends this hexadecimal 1c to the print destination.
  4. When it encounters the trailer 6c 6c, Host On-Demand recognizes that it has reached the end of the custom control code block.

Additional rules for header-trailer mode:

Header-length mode

In header-length mode, a custom control code block consists of:

You can have Host On-Demand use header-length mode only when the print data stream contains custom control code blocks all of the same length. For example, you can have Host On-Demand use header-length mode if the print data stream includes only custom control code blocks that contain two control codes (2 EBCDIC pairs).

To indicate that you want Host On-Demand to use header-length mode, define the CUSTOM_CONTROL_CODES_LENGTH in the control codes section of your PDF file. Here is an example of how to define the relevant control codes in your PDF file when you want to use header-length mode:

CUSTOM_CONTROL_CODES?=YES
CUSTOM_CONTROL_CODES_HEADER=5f 5f
CUSTOM_CONTROL_CODES_LENGTH=2
Please notice:

Here is an example of a custom control code block that Host On-Demand could process using the above definitions.

5f 5f f1 82 f1 84
Host On-Demand processes these characters as follows:
  1. When it encounters the header 5f 5f, Host On-Demand recognizes that it must process subsequent pairs as custom control codes.
  2. Host On-Demand converts EBCDIC f1 82 to hexadecimal 1b, and then sends this hexadecimal 1b to the print destination.
  3. Host On-Demand converts EBCDIC f1 84 to hexadecimal 1d, and then sends this hexadecimal 1d to the print destination.
  4. Having processed two control codes (two EBCDIC pairs), Host On-Demand recognizes that it has reached the end of the custom control code block.

Additional rules for header-length mode:

Additional Control Codes for DBCS

The following table lists the field names and meanings of the DBCS-specific Control Codes. Refer to Code Pages Supported in Host On-Demand for the complete list of code pages.

Table 3. Additional Control Codes for DBCS

Field name Value or remarks
START_LIPS_GRID Start grid (Canon LIPS printers)
END_LIPS_GRID End grid (Canon LIPS printers)
LIPS_IMAGE Send image data (Canon LIPS printers)
IMAGE_TRANSMISSION Image data setup (vertical 24-dot image)
KANJI_CODE?
  • Japanese - JIS, SHIFT_JIS
  • Traditional Chinese - BIG5, TCA, IBM5550, CNS
  • Korean - KS_COMBINE, KS_COMPLETE, KSSM_COMBINE, KSSM_COMPLETE
ZENKAKU_SPACE The size (adjustment unit) of a user-defined character or SBCS character
SBCS_FONT_LOAD Load a SBCS user-defined character
DBCS_FONT_LOAD Load a DBCS user-defined character
SET_LOCAL_FONT Set a font set of user-defined characters. Remove this field when user-defined characters are not loaded to a printer
RESET_LOCAL_FONT Reset a font set of user-defined characters. Remove this field when user-defined characters are not loaded to a printer
KANJI_ON Set kanji mode
KANJI_OFF Reset kanji mode
ATTRIBUTE_GRID_LINE Grid-line print
OLD_JIS? If YES, use old JIS table; if NO, use new JIS table
CP943_IBM? If YES, use IBM code points for 13 IBM-NEC duplicated code points (non-Kanji); if NO, use NEC code points

When ESC_P.PDF is used, DBCS (2-byte) characters are placed to the left of the character pitch, not in the center. To place DBCS characters in the center of the character pitch, change these IBM-supplied values in ESC_P.PDF:

  P10 EQU 1B 50 1B 20 00 1C 53 00 0C 1C 54 00 00
  P12 EQU 1B 4D 1B 20 00 1C 53 00 06 1C 54 00 00
  P13 EQU 1B 67 1B 20 01 1C 53 00 03 1C 54 00 01
  P15 EQU 1B 67 1B 20 00 1C 53 00 00 1C 54 00 00

to the following:

  P10 EQU 1B 50 1B 20 00 1C 53 06 06 1C 54 00 00
  P12 EQU 1B 4D 1B 20 00 1C 53 03 03 1C 54 00 00
  P13 EQU 1B 67 1B 20 01 1C 53 02 01 1C 54 00 01
  P15 EQU 1B 67 1B 20 00 1C 53 00 00 1C 54 00 00

 

Definition of Printer Control Code Parameters

The way you define a parameter depends on the parameter type. If the wrong definition method is used, you will not get the output you want.

The following table lists the types of printer control parameters and their meanings:

Table 4. Printer Control Parameters

Parameter Type Meaning
Byte value, or value 1-byte parameter
Byte values, or values Multi-byte parameter; use if operands are fixed
Word value (HL) One-word parameter (high-order byte first)
Word value (LH) One-word parameter (low-order byte first)
Length (HL) values Multi-byte parameter requiring operands. An operand consists of high and low-order bytes (high first); use if operands are variable
Length (LH) values Multi-byte parameter requiring operands. An operand consists of low and high-order bytes (low first); use if operands are variable.
Length (HL) images Image data requiring operands. An operand consists of a high and low-order byte (high first)
Length (LH) images Image data requiring operands. An operand consists of low and high-order bytes (low first)
Decimal characters Decimal character parameter


Character Definitions

EBCDIC-to-ASCII Conversion

Host On-Demand 3270 sessions use the Telnet3270E protocol, in which all character data is defined by an EBCDIC character set. Because workstation printers use ASCII character sets, EBCDIC-to-ASCII code conversion is performed for print data, unless ASCII_PASSTHRU?=YES is specified in the PDF.

When you configure session properties, the Host Code-Page field in the Connection window sets the EBCDIC code page, and the printer-font code-page field in Page Setup > Advanced Options sets the ASCII code page. Refer to Code Pages Supported in Host On-Demand for a complete list of code pages.

Code page 850 is used as the default printer-font code page for SBCS host code pages that do not support the euro currency symbol. If you select an SBCS host code page that does support the euro currency symbol, code page 858 is used. There are restrictions on euro currency symbol support. Refer to Code Pages Supported in Host On-Demand for details.

For DBCS countries or regions, the following code pages are used as the default printer-font code pages:

     942 943 (Japan)
     949     (Korea)
    1386     (China)
     950     (Taiwan)
There are two ways to modify the default SBCS EBCDIC-to-ASCII conversion tables by using Character Definitions in a PDT; the list below describes the two methods.

There is no way to modify the default EBCDIC-to-ASCII conversion tables used for DBCS.

If two or more character definitions exist for the same code point, the following precedence rules are used:
  1. Character definitions in EBCDIC take precedence over those in ASCII.
  2. The last character definition supersedes preceding definitions.

Introduction to Host Printing (5250)

Host On-Demand provides the following functions for 5250 host printing:

For 5250 host printing, only the Java File Interface mode and the Windows Spooler Interface mode (Windows platforms only) are supported. The Windows Native Printing mode is not supported.

Host Print Key

The Host Print key is available in a 5250 Display session; it is the key that tells the host to print the contents of the presentation space as text.

Host Print Transform

Host print transform is an i5/OS and OS/400 function that converts an SNA character string (SCS) or Advanced Function Printer (AFP) data stream into an ASCII data stream. The ASCII data stream is then formatted and sent to an ASCII printer through a Host On-Demand 5250 printer session. The conversion is done on the iSeries, which provides these advantages:

How Host Print Transform Works

The 5250 host print transform (HPT) converts the iSeries print data stream just before it is sent from the iSeries to the printer spool file. Because the iSeries does the conversion, the host does most of the print processing instead of the workstation.

Many printers, including IBM printers, support the ASCII print-data stream. The ASCII data stream uses iSeries system objects that describe the characteristics of a particular ASCII printer. When you configure a printer session, you select the printer from the list provided.

By default, Host On-Demand uses the SCS-to-ASCII transform, but you can configure the iSeries to do an AFP-to-ASCII transform, which Host On-Demand also supports. The ASCII data stream is passed through the emulator using the SCS ASCII Transparency (ATRN) command. Host On-Demand deletes the ASCII Transparency command and passes the ASCII data stream to the workstation printer.

 

For more information about the host print transform, refer to the iSeries Printer Device Programming documentation.


Introduction to Host Printing (VT)

Host On-Demand provides VT host printing in much the same manner as a VT 420 terminal would provide this service to a VT host. Typically in this environment, the active host application can address:

In a traditional VT host print session, the host application determines when a print operation is desired (typically, a print operation is triggered by a user's action). In a VT print session, the same host-terminal connection used for screen-based information is used to pass information to the printer. Once the host determines that a print job is to start, a terminal sequence is sent by the host to the terminal to initiate the desired print operation. The host sends all desired print information and then ends the process by sending a print termination sequence to the terminal. In some cases, both the screen and the printer may be the simultaneous destination of the information sent by the host.

Host On-Demand supports all of the VT 420-defined print sequences; however, due to limitations in the Java environment, not all printer status commands are supported. The Windows Spooler Interface and the Windows Native Printing modes are not supported on VT host print sessions.


Appendix A. Printer Data Stream Information (3270)

This appendix describes the Host On-Demand host-directed print data streams.


  • Introduction to Print Data Streams
  • Supported Commands and Orders in the 3270 Data Stream
  • Query Replies
  • Function Management Header 1 (FMH-1) Support
  • Delimiting Print Jobs
  • SNA Character String Data Stream
  • Introduction to Print Data Streams

    Host On-Demand supports two types of print data stream: the 3270 data stream and the SNA character string (SCS) data stream. The 3270 data stream is used for LU Type 3 sessions and the SCS data stream for LU Type 1 sessions.

    The term Logical Unit (LU) is usually used in Systems Network Architecture (SNA). Even though Host On-Demand supports only Telnet, which is not an SNA protocol, the terms "LU1" and "LU3" describe sessions whose outbound data is identical to those on corresponding SNA LUs.

     

    The 3270 data stream is buffer-oriented (it is also used for 3270 display sessions, but this document deals only with the 3270 data stream for printers). The print data is formatted as if it were displayed on a screen, and the host system sends commands to format the presentation space. When the data formats, the host turns on the START PRINT bit in the Write Control Character (WCC) byte and prints the presentation space as accurately as the printer hardware allows. For more detailed information about the 3270 data stream, refer to IBM 3270 Information System Data Stream Programmer's Reference (GA23-0059).

    The SCS data stream consists of a sequential string of SCS controls and data characters. Unlike the 3270 data stream, the SCS data stream requires no presentation space. A detailed description of the SCS data stream is contained later in this document.

    For protocol-level information, refer to Internet RFCs (especially RFC 2355).

     


    Supported Commands and Orders in the 3270 Data Stream

    The commands that can be sent in the 3270 data stream are:

    Table 6. 3270 Data Stream Commands

    Command Meaning
    W Write
    EW Erase/Write
    EWA Erase/Write Alternate
    EAU Erase All Unprotected
    WSF Write Structured Field

    The orders that can be sent in the 3270 data stream are:

    Table 7. 3270 Data Stream Orders

    Order Meaning
    SBA Start Buffer Address
    SF Start Field
    IC Insert Cursor
    PT Program Tab
    RA Repeat to Address
    EUA Erase Unprotected to Address
    SFE* Start Field Extended
    SA* Set Attribute
    MF* Modify Field

    * The last three orders in this list manage the extended highlighting and color programmed-symbol attributes for fields and individual characters.

    In addition to those commands and orders, you can include these special formatting control codes listed in the data stream:

    Table 8. 3270 Data Stream Control Codes

    Code Description
    NL New Line moves the print position to the left margin and down one line.
    CR Carriage Return moves the print position to the left margin.
    EM End of Message ends the print operation.
    FF Form Feed moves the print position to the left margin at the top of the next page.

    Note: NL, CR, and EM are valid only if a line-length format is specified in the WCC. The FF code is valid in any buffer position, depending on the option setting.

    Host On-Demand printer support interprets each 3270 attribute and printer control code and translates it into a sequence of one or more workstation-printer control codes.

    Write Control Character (WCC) Byte

    The Write Control Character (WCC) byte follows the 'write type' command in a 3270 data stream. The bit definitions of the WCC byte for 3270 printers are:

    Table 9. Write Control Character (WCC) byte for 3270 printers

    Bit Explanation
    0-1 In an SNA or EBCDIC environment, these bits are ignored by the printer.
    2-3 Defines print format as follows:
    00
    The NL or CR orders in the data stream determine the print-line length, and EM designates the end of the message. If neither of these orders is present, an NL is inserted at MPP.
    01
    Specifies a 40-character print line.
    10
    Specifies a 64-character print line.
    11
    Specifies an 80-character print line.
    4 Start-printer bit. When set to 1, initiates a print operation at the completion of the write operation.
    5 Sound-alarm bit. When set to 1, sounds an audible alarm if one is provided on the printer.
    6 Keyboard restore bit.
    7 Reset MDT bit.


    Query Replies

    The Query Reply structured field contains responses from Query requests located in the Read Partition structured field.

    In reply to a Query, the device transmits a set of structured fields inbound to the host that describe the device's features. Only the Query Replies that reflect the functions and features supported by the device are transmitted.

    Different sets of Query Reply are sent, depending on the printer session type (LU1 or LU3). For structured field support on an LU1 session, refer to Function Management Header 1 (FMH-1) Support, which is used for structured fields for LU1 sessions. All the query replies that Host On-Demand sends are hardcoded except MPP, MPL, GCSGID, CPGID, and Buffer Size (LU3 only).

    Query Replies for LU1 Sessions

    Summary Query Reply

    Table 10. Summary Query Reply (LU1 - SBCS)

     

    Byte Bit Contents Meaning
    0-1 - X'000A' Length of this structure
    2 - X'81' Query Reply
    3 - X'80' Summary
    4-n  
    X'80'
    X'81'
    X'85'
    X'87'
    X'9F'
    X'A0'
    Summary
    Usable Area
    Character Sets
    Highlighting
    Begin/End of File
    Device Characteristics

    Table 11. Summary Query Reply (LU1 - DBCS)

    Byte Bit Contents Meaning
    0-1 - X'000B' Length of this structure
    2 - X'81' Query Reply
    3 - X'80' Summary
    4-n  
    X'80'
    X'81'
    X'85'
    X'87'
    X'8C'
    X'9F'
    X'A0'
    Summary
    Usable Area
    Character Sets
    Highlighting
    Field Outlining
    Begin/End of File
    Device Characteristics

    Usable Area Query Reply

    Table 12. Usable Area Query Reply (LU1 - SBCS)

    Byte Bit Contents Meaning
    0-1 - X'0017' Length of this structure
    2 - X'81' Query Reply
    3 - X'81' Usable Area
    4
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'1'
    B'1111'
    Reserved
    Not a Pageprinter
    Reserved
    A hardcopy device
    Unmapped
    5
    0
    1
    2
    3-7
    B'0'
    B'0'
    B'0'
    B'0000'
    Variable cells not supported
    Matrix character
    Value in bytes 6-9 (cells)
    Reserved
    6-7 - X'nnnn' Width of usable area in cells (MPP), as the Advanced Options panel.
    8-9 - X'nnnn' Height of usable area in cells (MPL), as the Advanced Options panel.
    10 - X'00' Unit of measure (inches)
    11-14 -
    X'00010078'
    Distance between points in the X-direction
    (1/120 inch)
    15-18 -
    X'00010048'
    Distance between points in the Y-direction
    (1/72 inch)
    19 -
    X'0D'
    Number of X units in the default cell
    (13 dots)
    20 -
    X'1C'
    Number of Y units in the default cell
    (28 dots)
    21-22 - X'0000' Character Buffer Size

    Table 13. Usable Area Query Reply (LU1 - DBCS)

    Byte Bit Contents Meaning
    0-1 - X'0017' Length of this structure
    2 - X'81' Query Reply
    3 - X'81' Usable Area
    4
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'1'
    B'1111'
    Reserved
    Not a Pageprinter
    Reserved
    A hardcopy device
    Unmapped
    5
    0
    1
    2
    3-7
    B'0'
    B'0'
    B'0'
    B'0000'
    Variable cells not supported
    Matrix character
    Value in bytes 6-9 (cells)
    Reserved
    6-7 - X'nnnn' Width of usable area in cells (MPP), as the Advanced Options panel.
    8-9 - X'nnnn' Height of usable area in cells (MPL), as the Advanced Options panel.
    10 - X'00' Unit of measure (inches)
    11-14 -
    X'000100B4'
    Distance between points in the X-direction
    (1/180 inch)
    15-18 -
    X'000100B4'
    Distance between points in the Y-direction
    (1/180 inch)
    19 -
    X'0F'
    Number of X units in default cell
    (15 dots)
    20 -
    X'18'
    Number of Y units in default cell
    (24 dots)
    21-22 - X'0000' Character Buffer Size

    Character Sets Query Reply

    Table 14. Character Sets Query Reply (LU1 - SBCS)

    Byte Bit Contents Meaning
    0-1 - X'001B' Length of this structure
    2 - X'81' Query reply
    3 - X'85' Character sets
    4
    0
    1
    2
    3
    4
    5
    6
    7
    B'1'
    B'0'
    B'0'
    B'0'
    B'0'
    B'0'
    B'1'
    B'0'
    Graphic escape
    Multiple LCIDs are not supported
    LOAD PS SF (not supported)
    LOAD PS EXTENDED (not supported)
    Multiple char slot sizes (not supported)
    2-byte character sets (not supported)
    GCID is present
    Reserved
    These are all hardcoded.
    5
    0
    1
    2
    3-7
    B'0'
    B'0'
    B'0'
    B'0000'
    Reserved
    LPS slot size match is required
    Reserved
    Reserved
    6 -
    X'09'
    Default character slot width
    (9 dots)
    7 -
    X'0E'
    Default character slot height
    (14 dots)
    8-11 - X'00000000' Load PS (not supported)
    12 - X'07' Length of each symbol-set descriptor
    13 - X'00' Device-specific character set ID (SBCS)
    14
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'0'
    B'0000'
    Non-loadable character set
    Single-plane character set
    Double-byte-coded character set
    LCID compare
    Reserved
    15 - X'00' Local Character Set ID
    16-17 - X'nnnn' SBCS GCSGID
    18-19 - X'nnnn' SBCS CPGID
    20 - X'01' Device-specific character set ID
    21
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'0'
    B'0000'
    Non-loadable character set
    Single-plane character set
    Double-byte-coded character set
    LCID compare
    Reserved
    22 - X'F1' Local Character Set ID
    23-24 - X'03C3' APL GCSGID (963)
    25-26 - X'0136' APL CPGID (310)

    Table 15. Character Sets Query Reply (LU1 - DBCS)

    Byte Bit Contents Meaning
    0-1 - X'002E' Length of this structure
    2 - X'81' Query reply
    3 - X'85' Character sets
    4
    0
    1
    2
    3
    4
    5
    6
    7
    B'1'
    B'0'
    B'0'
    B'0'
    B'0'
    B'1'
    B'1'
    B'0'
    Graphic escape is supported
    Multiple LCIDs are not supported
    LOAD PS SF is not supported
    LOAD PS EXTENDED is not supported
    Multiple char slot sizes are not supported
    2-byte character sets are supported
    GCID is present
    Reserved
    5
    0
    1
    2
    3-7
    B'0'
    B'0'
    B'0'
    B'0000'
    Reserved
    LPS slot size match is required
    Reserved
    Reserved
    6 -
    X'0C'
    Default character slot width
    12 dots
    7 -
    X'18'
    Default character slot height
    24 dots
    8-11 - X'00000000' Load PS is not supported
    12 - X'07' Length of each symbol-set descriptor
    13 - X'00' Device-specific character set ID (SBCS)
    14
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'0'
    B'0000'
    Non-loadable character set
    Single-plane character set
    Double-byte-coded character set
    LCID compare
    Reserved
    15 - X'00' Local Character Set ID
    16 - X'00' Width of character slots (default)
    17 - X'00' Height of character slots (default)
    18 - X'00' Start of subsection of DBCS
    19 - X'00' End of subsection of DBCS
    20-21 - X'nnnn' SBCS GCSGID
    22-23 - X'nnnn' SBCS CPGID
    24 - X'80' Device-specific character set ID
    25
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'1'
    B'0'
    B'0000'
    Non-loadable character set
    Single-plane character set
    Double-byte-coded character set
    LCID compare
    Reserved
    26 - X'F8' Local Character Set ID
    27 - X'18' Width of character slots (24 dots)
    28 - X'18' Height of character slots (24 dots)
    29 - X'41' Starting subsection of DBCS
    30 - X'7F' Ending subsection of DBCS
    31-32 - X'nnnn' GCSGID of DBCS
    33-34 - X'nnnn' CPGID of DBCS
    35 - X'01' Device specific character set ID
    36
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'0'
    B'0000'
    Non-loadable character set
    Single-plane character set
    Double-byte-coded character set
    LCID compare
    Reserved
    37 - X'F1' Local character set ID
    38 - X'00' Width of character slots : default
    39 - X'00' Height of character slots : default
    40 - X'41' Indicates start of DBCS subsection
    41 - X'7F' Indicates end of DBCS subsection
    42-43 - X'03C3' APL GCSID (963)
    44-45 - X'0136' APL CPGID (310)

    Highlighting Query Reply

    Table 16. Highlighting Query Reply (LU1)

    Byte Bit Contents Meaning
    0-1 - X'000D' Length of this structure
    2 - X'81' Query Reply
    3 - X'87' Highlighting
    4 - X'04' Number of attribute/action pairs
    5-6 - X'00F0' Default is normal highlight
    7-8 - X'F1F1' Blink is blink
    9-10 - X'F2F2' Reverse is reverse
    11-12 - X'F4F4' Underscore is underscore

    Field Outlining Query Reply

    Table 17. Field Outlining Query Reply (LU1)

    Byte Bit Contents Meaning
    0-1 - X'000A' Length of this structure
    2 - X'81' Query Reply
    3 - X'8C' Field Outlining
    4 - X'00' Reserved
    5
    0
    1-7
    B'0'
    B'0000000'
    Separation (not supported)
    Reserved
    6 -
    X'06'
    Location of the vertical line of an SBCS character
    It is drawn at the 7th dot in the X-direction (hardcoded).
    7 - X'00' Location of overline/underline
    8 - X'00' Location of overline (separation is not supported)
    9 - X'00' Location of underline (separation is not supported)

    Begin/End of File Query Reply

    Table 18. Begin/End of File Query Reply (LU1)

    Byte Bit Contents Meaning
    0-1 - X'0005' Length of this structure
    2 - X'81' Query Reply
    3 - X'9F' Begin/End of File
    4 - X'00' reserved

    Device Characteristics Query Reply

    Table 19. Device Characteristics Query Reply (LU1)

    Byte Bit Contents Meaning
    0-1 - X'000A' Length of this structure
    2 - X'81' Query Reply
    3 - X'A0' Device Characteristics
    4-5 - X'000B' Length of Horizontal Dimensional Parameters (HDP) descriptor
    6-7 - X'FF01' Identifier of HDP
    8
    .
    0
    1-7
    FLAGS
    SPDSUP
    RES
    .
    B'1' SPD supported
    Reserved
    9-10 - X'0A50' Character Density and MPP (CPI=10, MPP=80)
    11-12 - X'0C60' Character Density and MPP (CPI=12, MPP=96)
    13-14 - X'1189' Character Density and MPP (CPI=17.1, MPP=137)
    15-16 - X'000F' Length of Vertical Dimensional Parameters (VDP) descriptor
    17-18 - X'FF02' Identifier of VDP descriptor
    19
    .
    0
    1-7
    FLAGS
    SLDSUP
    RES
    .
    B'1' SLD supported
    Reserved
    20-21 - X'247F' Typographic points and MPL (LPI=2, MPL=127)
    22-23 - X'187F' Typographic points and MPL (LPI=3, MPL=127)
    24-25 - X'127F' Typographic points and MPL (LPI=3, MPL=127)
    26-27 - X'0C7F' Typographic points and MPL (LPI=6, MPL=127)
    28-29 - X'0A7F' Typographic points and MPL (LPI=8, MPL=127)
    30-31 - X'0005' Length of Page Presentation Media (PPM) descriptor
    32-33 - X'FF03' Identifier of PPM descriptor
    34
    .
    0
    1-7
    FLAGS
    PPMSUP
    RES
    .
    B'0' PPM not supported
    Reserved
    35-36 - X'0005' Length of Set Text Orientation (STO) descriptor
    37-38 - X'FF04' Identifier of STO descriptor
    39
    .
    0
    1-7
    FLAGS
    STOSUP
    RES
    .
    B'0' STO not supported
    Reserved

    Query Replies for LU3 Sessions

    Summary Query Reply

    Table 20. Summary Query Reply (LU3 - SBCS)

    Byte Bit Contents Meaning
    0-1 - X'000B' Length of this structure
    2 - X'81' Type (Query Reply)
    3 - X'80' Summary
    4-n  
    X'80'
    X'81'
    X'85'
    X'87'
    X'88'
    X'9F'
    X'A6'
    Summary
    Usable Area
    Character Sets
    Highlighting
    Reply Modes
    Begin/End of File
    Implicit Partition

    Table 21. Summary Query Reply (LU3 - DBCS)

    Byte Bit Contents Meaning
    0-1 - X'000D' Length of this structure
    2 - X'81' Type (Query Reply)
    3 - X'80' Summary
    4-n  
    X'80'
    X'81'
    X'85'
    X'87'
    X'88'
    X'8C'
    X'91'
    X'9F'
    X'A6'
    Summary
    Usable Area
    Character Sets
    Highlighting
    Reply Modes
    Field Outlining
    DBCS Asia
    Begin/End of File
    Implicit Partition

    Usable Area Query Reply

    Table 22. Usable Area Query Reply (LU3 - SBCS)

    Byte Bit Contents Meaning
    0-1 - X'0017' Length of this structure
    2 - X'81' Query Reply
    3 - X'81' Usable Area
    4
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'1'
    B'0001'
    Reserved
    Not a Pageprinter
    Reserved
    A hardcopy device
    12/14-bit addressing allowed
    5
    0
    1
    2
    3-7
    B'0'
    B'0'
    B'0'
    B'0000'
    Variable cells not supported
    Matrix character
    Value in bytes 6-9 (cells)
    Reserved
    6-7 - X'0000' Should be set to 0 on LU3
    8-9 - X'0000' Should be set to 0 on LU3
    10 - X'00' Unit of measure (inches)
    11-14 -
    X'00010078'
    Distance between points in X-direction
    (1/120) inch
    15-18 -
    X'00010048'
    Distance between points in Y-direction
    (1/72) inch
    19 -
    X'0D'
    Number of X units in default cell
    (13 dots)
    20 -
    X'1C'
    Number of Y units in default cell
    (28 dots)
    21-22 - X'nnnn' Character Buffer Size

    Table 23. Usable Area Query Reply (LU3 - DBCS)

    Byte Bit Contents Meaning
    0-1 - X'0017' Length of this structure
    2 - X'81' Query Reply
    3 - X'81' Usable Area
    4
    0
    1
    2
    3
    4-7
    B'0'
    B'0'
    B'0'
    B'1'
    B'0001'
    Reserved
    Not a PagePrinter
    Reserved
    A hardcopy device
    12/14-bit addressing allowed
    5
    0
    1
    2
    3-7
    B'0'
    B'0'
    B'0'
    B'0000'
    Variable cells (not supported)
    Matrix character
    Value in bytes 6-9 (cells)
    Reserved
    6-7 - X'0000' Should be set to 0 on LU3
    8-9 - X'0000' Should be set to 0 on LU3
    10 - X'00' Unit of measure: inches
    11-14 -
    X'000100B4'
    Distance between points in X-direction
    (1/180) inch
    15-18 -
    X'000100B4'
    Distance between points in Y direction
    (1/180) inch
    19 -
    X'0F'
    Number of X units in default cell
    (15 dots)
    20 -
    X'18'
    Number of Y units in default cell
    (24 dots)
    21-22 - X'nnnn' Character Buffer Size

    Character Sets Query Reply

    Same Query Reply is sent for this both on LU1 and 3. See "Character Sets Query Reply" for details.

    Highlighting Query Reply

    Same Query Reply is sent for this both on LU1 and 3. See "Highlighting Query Reply" for details.

    Reply Modes Query Reply

    Table 24. Reply Modes Query Reply (LU3)

    Byte Bit Contents Meaning
    0-1 - X'0007' Length of this structure
    2 - X'81' Query Reply
    3 - X'88' Reply Modes
    4 - X'00' Field mode is supported
    5 - X'01' Extended field mode is supported
    6 - X'02' Character mode is supported

    Field Outlining Query Reply

    Same Query Reply is sent for this both on LU1 and 3. See "Field Outlining Query Reply" for details.

    DBCS Asia Query Reply

    Table 25. DBCS Asia Query Reply (LU3)

    Byte Bit Contents Meaning
    0-1 - X'000B' Length of this structure
    2 - X'81' Query Reply
    3 - X'91' Identifier of DBAC Asia
    4 - X'00' Reserved
    5 - X'03' Length of SO/SI SDP
    6 - X'01' SO/SI
    7 - X'80' Identifier of the SO character set
    8 - X'03' Length of input control SDP
    9 - X'02' Identifier of input control
    10 - X'01' SO/SI creation is supported

    Begin/End of File Query Reply

    LU1 and 3 use the same query reply. See "Begin/End of File Query Reply" for details.

    Implicit Partition Query Reply

    Table 26. Implicit Partition Query Reply (LU3)

    Byte Bit Contents Meaning
    0-1 - X'0011' Length of this structure
    2 - X'81' Length of Query Reply
    3 - X'A6' Implicit Partition
    4-5 - X'0000' Reserved
    6 - X'0B' Length of this self-defining parameter
    7 - X'03' Identifier of partition sizes for printer devices
    8 - X'00' Reserved
    9-12 - X'00000780' Default printer buffer size (=80*24)
    13-16 - X'nnnn' Alternate printer buffer size (=buffer size of alternate screen)


    Function Management Header 1 (FMH-1) Support

    The following headers

     X'06 01 00 0B 60 00' (for outbound data)
    
     X'06 01 00 8B 60 00' (for inbound data)
    are called FMH-1 (Function Management Header Type 1). This is used to send structured fields to an LU1 session. To use FMH-1, byte 6 bit 1 of the BIND parameter should be set to 1.

    FMH-1 is placed at the beginning of the data stream and one or more structured fields follow, like this:

     +-------+------------------+-....-+------------------+
     | FMH-1 | Structured Field | .... | Structured Field |
     +-------+------------------+-....-+------------------+
    FMH-1 for inbound data is used for replies to Read Partition (Query).

    Note: On an SNA connection, a Format Indicator (bit 4 of the first byte in the RH) is used to indicate that an FMH is contained in the following RU. However, because there is no corresponding indicator on a Telnet connection, Host On-Demand checks the first 6 bytes of every record to determine whether the record contains an FMH-1 or not.

    Structured Fields

    Following is the list of the structured fields that are used with FMH-1 in an outbound data stream:

    Following is the list of structured fields that are used with FMH-1 in an inbound data stream as a reply to a Read Partition (Query) structured field:


    The general format for the structured field is:

     +--------+------+-----------+
     | Length | Type | Parameter |
     +--------+------+-----------+
    Length is represented in 2 bytes and gives the length of the structured field, including Length itself. However, in the following cases, it can be X'0000,' which means that all data belong to the structured field:

    SCS Data

    This structured field is used to send SCS data to printer. If another structured field is found in the same record, SCS data must be sent using the SCS Data structured field.

    The format of the SCS Data structured field is as follows:

    Table 27. Format of the SCS Data structured field

    Byte Contents Description
    0-1 X'nnnn' or X'0000' Length
    2 X'41' Type (SCS data)
    3 X'00' reserved
    4-n data SCS data

    Read Partition (Query)

    This structured field is used to get the characteristics and functions of the printer. A Query Reply structured field is returned in the inbound data stream.

    1. More than two Read Partition (Query) structured fields cannot be included in one FMH-1.
    2. If a Read Partition (Query) structured field is sent with other structured fields, it should be placed last.

     

    The format of Read Partition (Query) is the same as that used in the 3270 data stream.

    Begin/End of File

    Refer to "Begin/End of File Structured Fields"

    Query Reply

    Refer to "Query Replies"

    Delimiting Print Jobs

    Many print jobs can be sent from multiple sources over a single Host On-Demand printer session, and multiple sessions and applications can share a single workstation printer. Host On-Demand needs to know when each print job starts and ends so that printers can be shared properly and so that begin-job and end-job strings can be sent at the appropriate times. To do this, Host On-Demand recognizes a number of different ways of delimiting a print job:

    By Session
    The printer support assumes, by default, that all print jobs are delimited by the printer session. That is, in the absence of all other indicators, it assumes that a print job begins when a printer session is started and ends when it is stopped. Termination of a session is identified by the receipt of UNBIND data or by termination of the socket connection.
    By PRINT-EOJ
    A TN3270E message with DATA-TYPE set to PRINT-EOJ can be used as a delimiter. Host On-Demand opens the printer when it receives the first print data for a job, and then processes and prints data. It closes the printer when it receives PRINT-EOJ. When it receives more print data, it again opens the printer and begins processing the job.
    Terminate Time
    Print jobs can be delimited by a user-specified timeout interval called the Terminate Time, which can be specified when the session is configured.
    Structured Fields
    The host can use structured fields to indicate to the device that the current file is complete or that a new file is beginning. The Begin of File structured field indicates to a printer that a new file is beginning and the End of File structured field indicates that the current file is complete. Host On-Demand supports these indicators.

    Structured Fields

    The host uses Begin of File and End of File structured fields to indicate to a device that a file is beginning or ending.

    Begin or End of File Query Reply

    The Begin or End of File query reply indicates that a device supports Begin of File and End of File to delimit print jobs. Host On-Demand sends a query reply, as shown in Table 18, in response to a Read Partition General query.

    Begin/End of File Structured Fields

    Begin/End of File structured fields are accepted on both LU1 and LU3 sessions. Table 28 shows their formats.

    Table 28. Begin/End of File Structured Field Format

    Byte Bit Contents Description
    0-1   X'0007' The length of this structure
    2-3   X'0F85' Begin/End of File
    4   PID Partition ID
    5
    0-1
    
    
    
    
    
    
    
    
    
    2-7
    FLAG1 1
    
    B'00'
    
    B'01'
    
    B'10'
    
     B'11'
    
    
    Reserved
    
    End of File is being sent
    
    Begin of File is being sent
    
    Reserved
    
    Reserved
    6   FLAG2 Reserved; must be set to 0s.
    1 This byte indicates whether Begin of File or End of File is being sent.

    Processing Begin or End of File Structured Fields

    When Begin or End of File structured fields are used with PRINT-EOJ or the Terminate Time, they take precedence over PRINT-EOJ or Terminate Time in determining when a print job begins or ends. Refer to the following examples:

    For predictable results, each data block must be enclosed by a Begin of File and an End of File structured field. The following example shows three print jobs, all delimited correctly:

    Begin of File Structured Field, ...Data1...,
    End of File Structured Field, (= end of job1)
    
    Begin of File Structured Field, ...Data2..., End of File Structured Field, (= end of job2)
    
    Begin of File Structured Field, ...Data3..., End of File Structured Field, (= end of job3)
    
    PRINT-EOJ (ignored)

    Host On-Demand always keeps track of PRINT-EOJ and Terminate Time commands. After the emulator receives a Begin of File structured field, it takes no action on PRINT-EOJ or on the timeout of the Terminate Time until it receives an End of File structured field. Once a valid End of File structured field is processed, the emulator defaults to delimiting jobs by PRINT-EOJ or timeout intervals until it receives the next Begin of File structured field.

    Begin or End of File Structured Field Error Conditions

    Host On-Demand does not accept transmission of data belonging to two separate print jobs in the same record. For a print job to be accepted by the emulator, a Begin of File structured field must be the first structured field of a record and an End of File structured field must be the last.

    Processing SCS Data Streams

    When processing an SCS data stream, Host On-Demand treats Begin or End of File structured fields as follows:

    Processing a 3270 Data Stream

    When processing a 3270 data stream, Host On-Demand treats Begin or End of File structured fields as follows:

    If Host On-Demand receives a Begin of File structured field and an End of File structured field without at least some print data separating them, it ignores the structured fields.

    SNA Character String Data Stream

    Overview

    This section describes the SCS commands supported by Host On-Demand.

    The following list and table summarize the SCS commands supported by Host On-Demand.


    Table 29. SCS Commands Supported by Host On-Demand

    SCS Control Code Value SBCS DBCS
    Backspace BS X'16' X X
    Bell BEL X'2F' X X
    Carriage Return CR X'0D' X X
    Enable Presentation ENP X'14' X X
    Form Feed FF X'0C' X X
    Graphic Escape GE X'08' X X
    Horizontal Tab HT X'05' X X
    Inhibit Presentation INP X'24' X X
    Interchange Record Separator IRS X'1E' X X
    Line Feed LF X'25' X X
    New Line NL X'15' X X
    Null NUL X'00' X X
    Set Attribute SA X'28' X X
    Set Horizontal Format SHF X'2BC1xxyy...' X X
    Set Line Density SLD X'2BC6xxyy' X X
    Set Print Density SPD X'2BD2xx29yy' X X
    Set Vertical Format SVF X'2BC2xxyy...' X X
    Shift In SI X'0F' - X
    Shift Out SO X'0E' - X
    Transparent TRN X'35xx...' X X
    Vertical Channel Select VCS X'04xx' X X
    Vertical Tab VT X'0B' X X
    Word Underscore WUS X'23' X -

    Table 30. SA Controls Supported by Host On-Demand

    SA Control type Value SBCS DBCS
    Highlighting X'2841xx' X X
    Character set X'2843xx' X X
    Grid attribute X'28C2xx' - X
    Reset characteristics X'2800xx' X X

    Command Descriptions

    This section describes each SCS command in detail.

    Backspace (BS)

    BS moves the presentation position horizontally one position to the left. If the presentation position is at column one, the function becomes a no-op. Left margin settings are ignored.
    BS
    +----+
    | 16 |
    +----+
    The following description applies only to DBCS.

    After receiving an SO or an SA that specifies the DBCS character set, BS moves the presentation position horizontally two positions (one character for DBCS) to the left. If the presentation position is column 2, BS moves it to column 1.

    Bell (BEL)

    BEL sends the BEL control code if that control code is defined in the PDT.
    BEL
    +----+
    | 2F |
    +----+

    Carriage Return (CR)

    CR moves the presentation position horizontally to the left margin on the same line. If the current position is already the left margin, the function becomes a no-op.
    CR
    +----+
    | 0D |
    +----+

    Enable Presentation (ENP)

    ENP is handled as NUL.
    ENP
    +----+
    | 14 |
    +----+

    Form Feed (FF)

    FF moves the presentation position to the top and left margins of the next presentation surface.
    FF
    +----+
    | 0C |
    +----+

    Graphic Escape (GE)

    GE indicates that the 1-byte value that follows is to be interpreted as a code point in the APL character set. Host On-Demand prints all APL characters as hyphens ('-').
    GE,VALUE
    +----+-------+
    | 08 | VALUE |
    +----+-------+
    |    |       |
    0----8-------16
    

    Horizontal Tab (HT)

    HT moves the presentation position horizontally to the right to the next tab stop. Horizontal tab-stop values may be set by using SHF (set horizontal format). If no horizontal tab stops are set to the right of the current presentation position, HT results in a space.
    HT
    +----+
    | 05 |
    +----+
    The following description applies only to DBCS.

    Spaces caused by HT are treated as spaces for grid printing. That is, if there are spaces caused by HT just after SA to start a grid, grid printing starts from there. If there are spaces caused by HT just after SA to end a grid, grid printing ends there. Grids are printed on the space positions caused by HT.

    Inhibit Presentation (INP)

    INP is handled as NUL.
    INP
    +----+
    | 24 |
    +----+

    Interchange Record Separator (IRS)

    IRS is handled as NL.
    IRS
    +----+
    | 1E |
    +----+

    Line Feed (LF)

    LF moves the presentation position vertically down to the next line. The column position remains unchanged.
    LF
    +----+
    | 25 |
    +----+

    New Line (NL)

    NL moves the presentation position horizontally to the left margin, and vertically down to the next line.

    NL is functionally equivalent to CR followed by LF.

    NL
    +----+
    | 15 |
    +----+

    Null (NUL)

    NUL is treated as a no-op.
    NUL
    +----+
    | 00 |
    +----+

    Set Attribute (SA)

    SA associates attribute values to the graphic characters that follow it in the data stream to define:

    SA appears as:

    SA,TYPE,VALUE
    +----+------+-------+
    | 28 | TYPE | VALUE |
    +----+------+-------+
    |    |      |       |
    0----8------16------23
    
    where:
    TYPE
    Characteristic to be defined:
    X'00'
    Reset characteristics
    X'41'
    Highlighting
    X'42'
    Character set
    X'C2'
    Grid attribute (DBCS only)

    VALUE
    Attribute value to be associated with the SCS graphic characters that follow according to the type code.

    Values are shown below by type:

    Reset characteristics
    X'00'
    The value must be set to X'00'. SA with this type and value resets all attribute values to X'00'.
    Highlighting
    X'00'
    Default
    X'F0'
    None
    X'F1'
    Blink
    X'F2'
    Reverse
    X'F4'
    Underline
    The value X'00' selects the device default highlighting indicated in the Query Reply (Highlight) structured field.
    Character Set
    X'00'
    Default (base character set)
    X'F1'
    APL character set
    X'F8'
    DBCS character set (DBCS only)
    X'FF'
    Reserved

    Grid attribute (DBCS only)
    X'00'
    None
    X'01'
    Lower side
    X'02'
    Right side
    X'03'
    Lower and right side
    X'04'
    Upper side
    X'05'
    Upper and lower side
    X'06'
    Upper and right side
    X'07'
    Upper, right, and lower side
    X'08'
    Left side
    X'09'
    Left and lower side
    X'0A'
    Left and right side
    X'0B'
    Left, right, and lower side
    X'0C'
    Left and upper side
    X'0D'
    Left, upper, and lower side
    X'0E'
    Left, upper, and right side
    X'0F'
    Rectangle

    The default values are:

     

    Highlighting
    No highlighting, normal presentation of graphics

    Character set
    Base character set

    Grid attribute (DBCS only)
    No grid

    SA values are associated with their respective type when set, and until receipt of another SA control of the same type. Therefore, the setting of an attribute value is a composite by attribute type of the attribute specified in any previously encountered SA control.

    For DBCS only, the following attributes are reset to the default values at the end of a record:

    For the character set attribute, conditions set for SO and SI are also applicable.

    Examples

    Table 31. SBCS

    Setting Highlight Character set
    Initial Setting Default Default
    SA character set X'F1' Default X'F1'
    SA highlight underline Underline X'F1'

    Unrecognized attribute values are handled in the following way:

     

    Highlighting
    Invalid values are rejected with a negative response.
    Character Set
    Unsupported values are rejected with a negative response.

    Table 32. DBCS

    Setting Grid Character set
    Initial Setting Default Default
    SA Grid upper Grid upper Default
    SA character set X'F8' Grid upper X'F8'

    Unrecognized attribute values are handled in the following way:

     

    Grid attribute
    The following cases are rejected with a negative response:
    Type = X'43' and Value = X'FF'
    Type = X'C2' and Value is not between X'00' and X'0F'
    Type = X'00' and Value is not X'00'
    Invalid values are rejected with a negative response.
    Character Set
    Unsupported values are rejected with a negative response.

    Set Horizontal Format (SHF)

    SHF sets horizontal formatting controls, including maximum presentation position, left and right margins, and horizontal tab stops. A 1-byte binary count follows the SHF control; it indicates the number of bytes to the end of the SHF sequence, including the count byte. The first three parameters following the count define the maximum presentation position, the left margin, and the right margin, respectively. Tab-stop parameters follow the right-margin (RM) parameter position. Parameters of SHF are 1 byte each and contain binary numbers in the range 0-255.

    The receipt of an SHF control sets all horizontal formatting controls to their default values. The minimum valid sequence that may be sent is SHF with a count of one, in which case all horizontal formatting controls have default values. A zero value for any other SHF parameter is a no-op and results in the function retaining its default value. The default values to be assumed are those described below under the definition of each parameter. SHF appears as:

    CSP,CLASS,COUNT,MPP,LM,RM,T1,...Tn
    +----+----+-----+-----+----+----+----+-----+---+
    | 2B | C1 | CNT | MPP | LM | RM | T1 | ... | Tn|
    +----+----+-----+-----+----+----+----+-----+---+
    |    |    |     |     |    |    |    |     |   |
    0----8----16----24----32--40----48---56----n---+
    
    where:
    MPP
    Maximum presentation position specifies the horizontal extent of the presentation surface (for example, print-line length, in number of characters, with column one being the origin). Valid MPP values are less than or equal to the device's physical maximum presentation position. The MPP default value is defined in the MAXIMUM_PRINT_POSITION entry in the PDT. It can be overridden on the Advanced Options panel.
    LM
    Left margin value specifies the column value of the leftmost presentation position. LM also serves as the first horizontal tab stop. Valid LM values are values less than or equal to MPP. The default value is one and it can be overridden by the LEFT_MARGIN entry in the PDT.
    RM
    Right margin is ignored. Valid RM values are greater than or equal to MPP. The default value for RM is MPP.
    T1...Tn:
    Horizontal tab-stop parameters should be set for use with the Horizontal Tab (HT) function. The tab string does not have to be in sequence. Valid tab-stop values other than zero are values equal to or greater than LM and less than or equal to RM.

    The LM parameter is the first horizontal tab stop. Repeating the LM value in the horizontal tab-stop parameter sequence is redundant. When no tab-stop values are set to the right of the current presentation position column value, the HT function acts as a space function.

    The following algorithm is executed when SHF is received:

    1. The SHF parameters are scanned, checked for validity, and saved in an SCS control vector.
    2. If an error is detected, an appropriate negative response is sent. The effects of the saved parameters are not defined in the architecture. For predictable results, any recovery sequence must include a valid SHF.

    The SHF parameters become effective immediately upon successful processing of a SHF.

    Set Line Density (SLD)

    SLD specifies the distance to be moved for a single-line vertical space as in LF or NL. It contains a 1-byte count field and a 1-byte binary parameter. The binary parameter expresses the vertical distance in standard typographic points (one point = 1/72 inch). A value of 12 points indicates six lines to the inch, 9 points indicates eight lines to the inch, and 72 points indicates one line to the inch.

    When the device receives the SLD control, it sets line density to its default value before analyzing the count and density fields. The following parameter values are accepted without rejection with default values retained:

    Count byte = X'02' and points byte = X'00'
    Count byte = X'01' (indicates no points byte)
    Count values other than X'01' and X'02' and points values other than X'00' and those implemented by the device must be rejected with an error response, indicating an invalid parameter. SLD appears as:
    CSP,CLASS,COUNT,POINTS
    +----+----+-----+------+
    | 2B | C6 | CNT | PNTS |
    +----+----+-----+------+
    |    |    |     |      |
    0----8----16----24-----32
             
    The implementing device must specify the points value that it implements and the default value. The default value may be established by Host On-Demand from the setting in the Advanced Options panel. If so, the locally established values are assumed as defaults in the cases mentioned above. To avoid unpredictable results, such as loss of forms integrity, an SLD must be followed by an FF control. Although the FF control does not have to immediately follow the SLD, there must be no intervening data or control code that causes movement of the formatting controls (for example, SLD, SHF). The ordering of the sequence has no effect on the execution of the formatting controls.

    The FF control causes exiting of the current presentation surface in terms of the old SLD parameter, but positioning in the next presentation surface is done in terms of the new SLD parameter.

    The line density specified by the SLD becomes effective immediately on receipt of SLD.

    Failure to observe the following rules results in misalignment of the printed output relative to the form:

    The following description applies only to DBCS.

    Host On-Demand accepts the following values for the points parameter:

    X'00'
    for default setting (6 LPI)
    X'0C'
    for setting 6 LPI
    X'12'
    for setting 4 LPI
    X'18'
    for setting 3 LPI
    X'24'
    for setting 2 LPI
    If Host On-Demand receives any other value as the points parameter of the SLD, it rejects the SLD with a negative response.

    Set Print Density (SPD)

    SPD is a formatting control; it specifies the number of characters to be presented per inch in the horizontal direction. SPD appears as:
    CSP,CLASS,COUNT,TYPE,CHARACTER-DENSITY
    +----+----+-----+----+----+
    | 2B | D2 | CNT | 29 | CD |
    +----+----+-----+----+----+
    |    |    |     |    |    |
    0----8----16----24---32---47
    
    where:
    CD:
    Character density is a 2-byte binary number from 1 to 255 specifying the number of characters to be printed per inch.

    Host On-Demand handles only the following CD values: 10, 12, 15, and 17. All others cause Host On-Demand to reset density to the default of 10.

    Numbers 256 to 65535 are reserved. If CNT = X'04' and CD = X'0000' or CNT = X'02', the default value of the device is used.

    The character density specified in the SPD becomes effective immediately on receipt of the SPD. When the SPD code X'2BD20229' is received, the device sets the character density to its default value. The default value is retained unless valid count and character density values are received.

    For SBCS sessions, if the SHF (set horizontal format) parameter is not used to change LM, RM, and MPP to compensate for a change in character density, the left and right margins might be misaligned. For DBCS sessions, the CPI value used to set LM is always the value that is set in the configuration panel, so SPD does not cause the left margin to be misaligned.

    Set Vertical Format (SVF)

    SVF sets vertical formatting controls, including maximum presentation line (page size), top margin, bottom margin, and vertical tab stops. A 1-byte binary count follows the SVF control. It indicates the number of bytes to the end of the SVF sequence, including the count byte. The first three parameters following the count define the maximum presentation line, the top margin, and the right margin, respectively. Tab-stop parameters follow the bottom-margin (BM) parameter position. Parameters are 1 byte each, and contain binary numbers in the range 0-255.

    The receipt of an SVF control sets all vertical formatting controls to their default values. The minimum valid sequence that may be sent is SVF with a count of one, in which case all vertical formatting controls have default values. A zero value for any other SVF parameter is a no-op and results in the function retaining its default value. The default values to be assumed are those described below under the definition of each parameter. SHF appears as:

    CSP,CLASS,COUNT,MPL,TM,BM,T1,...Tn
    +----+----+-----+-----+----+----+----+-----+---+
    | 2B | C2 | CNT | MPL | TM | BM | T1 | ... | Tn|
    +----+----+-----+-----+----+----+----+-----+---+
    |    |    |     |     |    |    |    |
    0----8----16----32----40---48---56---n
    
    where:
    MPL
    Maximum presentation line specifies the vertical extent of the presentation surface with origin of line one. This is the page depth for a printer. All values from 1 to 255 are valid. A page size defined by SVF takes precedence over a fixed device value. The default value is defined in the MAXIMUM_PAGE_LENGTH entry in the PDT. It can be overridden on the Advanced Options panel.
    TM
    Top margin specifies the line value to be used as the top presentation line of the page. The TM is also the first vertical tab stop. Valid TM values are equal to or less than MPL. The TM default value is one. It can be overridden by the TOP_MARGIN entry in the PDT.
    BM
    Bottom margin specifies the line value that, if exceeded by the current line, causes an automatic skip to the TM of the next presentation surface. BM must be greater than or equal to TM, and less than or equal to MPL. The BM default value is the MPL value.
    T1...Tn

    Vertical tab stops, selected by VT, or vertical channels, selected by VCS.

    Each vertical tab-stop parameter specifies a single-line value for use with the vertical tab (VT) function. Valid vertical tab values are equal to or greater than TM (the first vertical tab stop which must not be specified explicitly) and equal to or less than BM or X'00'. While X'00' is a permissible tab-stop value, only nonzero values are processed. MPL must be specified as a value greater than one if useful vertical tab stops are to be available. Vertical tabs must be listed in increasing order if predictable results are to be achieved with the VT function. Vertical tab stops may be set at any line, except TM, down to, and including, bottom margin.

    Tab-stop parameters 1 through 11 are also used to set line values for corresponding control channels 2 through 12; channel 1 is set by the TM. This allows vertical formatting to be accomplished with the vertical channel select (1-12) function in addition to the VT function. The value zero may appear in any of tab stops 1 through 11. A zero line value specified to correspond to any of channels 2 through 12 will result in a default to the LF function when a select channel is given for that channel number. A select channel 1 causes line positioning to move to the TM of the next presentation surface with no change in column position. Vertical tab line values must be in increasing order when used to set channel stops, except that the value zero may appear out of sequence.

    The following algorithm is executed when SVF is received:

    1. The SVF parameters are scanned and checked for validity and saved.
    2. An appropriate negative response is sent if an error is detected. The effects of the saved parameters are not defined in the architecture. For predictable results, any recovery sequence must include a valid SVF.

    The SVF parameters become effective immediately on receipt of an SHF. The device assumes that the form is aligned to the line specified by the TM parameter.

    Unless the using application always specifies TM = 1, the form must be manually aligned to the line specified by TM prior to the receipt of SVF. Failure to observe this rule results in misalignment of the printed output relative to the form.

    Shift In (SI)

    This command applies only for DBCS.

    SI specifies that data be handled as SBCS characters.

    SI
    +----+
    | 0F |
    +----+
    Character data after SI are handled as SBCS characters until one of the following occurs:

    From the start of a record, all character data are handled as SBCS characters until either of the above two conditions is met. SI does not take a character position.

    Shift Out (SO)

    This command applies only for DBCS.

    SO specifies that data be handled as DBCS characters.

    SI
    +----+
    | 0E |
    +----+

    Character data after SO are handled as DBCS characters until one of the following occurs:

    After an SO, SCS controls and their parameters are handled as single bytes. A control cannot be inserted between the 1st and 2nd bytes of DBCS data. It if is, it is handled as an invalid character and printed as a 2-byte solid block.

    SI does not take a character position.

    Transparent (TRN)

    TRN is a data-defining control used to denote the start of a transparent data stream. There are two types of transparent data stream:

    ATRN (ASCII TRN)
    sends all codes to the printer without EBCDIC->ASCII code translation. This is the default for SBCS sessions.
    ETRN (EBCDIC TRN)
    sends codes to the printer with EBCDIC->ASCII code translation. Codes below code point X'40' are always printed as hyphens. This is the default for DBCS sessions.
    How to change the setting for TRN data stream
    The default setting can be changed by a TRANSPARENT_ON? entry in the PDT.
       TRANSPARENT_ON? = YES         /* use ATRN mode */
       TRANSPARENT_ON? = NO          /* use ETRN mode */
    

    TRN appears as:

    TRN,COUNT
    +----+-----+
    | 35 | CNT |
    +----+-----+
    |    |     |
    0----8-----15
    
    where:
    CNT
    Indicates the number of bytes of transparent data (not including the count byte).

    After the TRN data has been processed, the presentation position must be moved CNT positions.

    Vertical Channel Select (VCS)

    For DBCS, VCS is the same as LF if the channel parameter for SBCS is valid (X'81'-X'89', X'7A'-X'7C').

    For SBCS, VCS is a formatting control used to select one of twelve vertical channels for the purpose of controlling the vertical format of a presentation surface.

    VCS appears as:

    SEL,CHANNEL-CODE
    +----+------+
    | 04 | CODE |
    +----+------+
    |    |      |
    0----8------15
    
    where: (the following explanations apply only to SBCS)
    CODE
    X'81'
    Select channel one
    X'82'
    Select channel two
    X'83'
    Select channel three
    X'84'
    Select channel four
    X'85'
    Select channel five
    X'86'
    Select channel six
    X'87'
    Select channel seven
    X'88'
    Select channel eight
    X'89'
    Select channel nine
    X'7A'
    Select channel ten
    X'7B'
    Select channel eleven
    X'7C'
    Select channel twelve

    Unless the default values are to be used, line-stop values for each channel used must be designated before these select functions are used. See Set Vertical Format (SVF).

    When the current line number is greater than the largest line value specified for the channel selected, a form feed is issued and the line value specified for the selected channel is used on the next page. When there are no line values specified for a channel, a select channel function for that channel defaults to LF (line Feed).

    Vertical Tab (VT)

    VT is a formatting control that moves the presentation position vertically down to the next tab-stop setting. Vertical tab-stop values may be set by using SVF (Set Vertical Format). If there are no vertical tab stops set below the current line number, VT defaults to LF (line feed). While zero is a permissible tab-stop value, only non-zero values are processed.
    VT
    +----+
    | 0B |
    +----+

    Word Underscore (WUS)

    WUS is a device control which underscores the entire word immediately preceding the WUS control. The underscored word is the string of characters before the WUS code as far back as one of the following: space, underscore, or any of the SCS controls.

     WUS
    +-----------------------+----+
    | (any string)          | 23 |
    +-----------------------+----+
     8n 8n+7

    Appendix B. National Language Support

       

    1. Chinese (Simplified)
      1.  

      2. GB18030 support for 3270 host print on a Windows client with Windows Native Printer Interface Mode
      3. This item discusses the following scenario:
        1. The Host On-Demand client is running on the Windows platform.
        2. The locale is Chinese (Simplified).
        3. The browser is a Java-enabled browser.
        4. A 3270 Printer session has been configured for Windows Native Printer Interface mode. That is, in the session properties, on the Printer tab:
          • Print to has been set to Windows Printer; and
          • User Printer Definition Table has been set to No.
        5. GB18030 support has been installed on the client.
          • Note that this package must be installed, even if you configure the 3270 print session to use the IBM WorldType font Monotype Sans Duospace WT SC, as described below.
        6. The host print job contains GB18030 characters.

        In order for all GB18030 characters to be printed correctly you must use IBM WorldType font Monotype Sans Duospace WT SC.

        Note that if you use the SimSun-18030 font distributed as part of the Microsoft GB18030 Support package, not all GB18030 characters can be printed. However, even if you use the IBM WorldType font Monotype Sans Duospace WT SC, as recommended here, the Microsoft GB18030 Support package itself must be installed.

        Follow these steps to use the IBM WorldType font Monotype Sans Duospace WT SC:

        1. Obtain and install the font.
          1. Obtain the IBM WorldType font Monotype Sans Duospace WT SC by downloading the font file from the Host On-Demand support page at: http://www.ibm.com/software/webservers/hostondemand/support.html. The font file for Chinese (Simplified) is mtsansds.ttf.
          2. Install the font as follows:
            1. Change to the Fonts directory under the Windows directory. That is, assuming that Windows is installed in
              C:\Winnt
              change to the directory
              C:\Winnt\Fonts
            2. Click File > Install New Font....
            3. Follow the directions to install the font.

        2. Configure the 3270 Printer session to use the font.
          1. On the 3270 Printer properties panel click Page Setup.
          2. Click Select Font....
          3. On the Font panel scroll the list box of fonts and select Monotype Sans Duospace WT SC.
          4. Click OK to close the Font panel.

       

    2. Japanese
      1.  

      2. Japanese Code Page Support
      3. Host On-Demand supports three code-pages (932, 942 and 943) for Japanese printers. 942 is used as the default for IBM printers, 943 for others. When 943 is used, NEC code-points are used by default for IBM-NEC duplicated code-points. The KANJI_CODE? statement in a PDF is used to check whether the printer is an IBM printer or not (SHIFT_JIS = IBM, JIS = other).

        Usually, there is no need to change the default value but you can change the printer-font code-page setting on the Advanced Options panel. Refer to your printer manual to find out the code page used by your printer.

        Host On-Demand also provides two PDF parameters for Japanese code page support:

        OLD_JIS? YES/NO
        If this is set to YES, the old JIS table is used, regardless of code page setting. If it is set to NO, the new JIS table is used. The default value is YES for code pages 932 and 942 and NO for 943.
        CP943_IBM? YES/NO
        If this is set to YES, IBM code-points are used for the 13 IBM-NEC duplicated code-points (non-Kanji). If it is set to NO, NEC code-points are used. This option is ignored when code-page 943 is not used. The default value is YES if KANJI_CODE? = SHIFT_JIS; otherwise it is NO.

        Examples

        KANJI_CODE? Option OLD_JIS? Option CP943_IBM? Option Conversion behavior Printers
        SHIFT_JIS YES n/a 942/932 IBM Printers
        SHIFT_JIS NO YES 943-IBM IBM 5577-s02/t02, and Network Printer in PAGES mode when using CP 94 3
        JIS YES n/a 942/932 LIPS Old JIS Seq. Mode
        JIS NO NO 943-NEC ESC/P, LIPS printers


       

    3. User-defined Characters
      1.  

      2. User-defined Characters for Host Printing Sessions
      3. For host printing support of User-Defined Characters (UDCs), in either Java File Interface mode or Windows Spooler Interface mode, you must prepare a UDC font-image file. On a server, this file must be located in the fonts directory (for example, %HostOnDemandInstallLocation%\HOD\fonts) so that it is accessible to clients. In Windows Native Printing mode, you do not have to do this as long as UDCs are defined on your Windows system.

        UDC support is applicable to double-byte languages only.

        On Windows, you must run the w32udcnv.exe utility to find and convert Windows user-defined fonts into a usable font-image file. The utility is provided in the \UDC directory on the Host On-Demand CD; it is not copied to the server during installation. To use the utility:

        1. Run w32udcnv.exe.
        2. Click Convert to start the conversion and generate a font-image file.

        3. After conversion, the font-image file is saved in the C: drive's root and is named according to the language of the operating system you are running:

          Platform Font-image filename
          Japanese Windows jpn24.fnt
          Korean Windows kor24.fnt
          Simplified Chinese Windows chs24.fnt
          Traditional Chinese Windows cht24.fnt

        4. Copy the font-image file to the fonts subdirectory of the publish directory (for example, C:\Program Files\IBM\HostOnDemand\HOD\fonts).

        On an OS/2 server, copy the OS/2 font-image file, $SYS1Z24.FNT, to the fonts directory of the publish directory and rename it according to the table above.

        Limitations

       

    4. Euro Currency Symbol
      1.  

      2. Support for euro currency symbol
      3. The euro is the name of the single currency of the European Union. Host On-Demand supports the euro currency symbol on display sessions. When printing with a PDT, it can support the euro symbol only if the printer fonts include the symbol.

        The default host code pages for display sessions in European languages are those that include support for the euro. For printer sessions, the defaults are non-euro because most printers do not support the euro yet. However, you can use a euro code page if necessary.

        If your printer fonts include the euro symbol, you can print the symbol through Host On-Demand printer sessions by doing the following:

        1. Change the default printer font to one that includes the euro symbol. This operation varies according to the printer type. Refer to your printer's documentation.

        2. Modify the PDF you want to use. Two sections may have to be changed:
          • In the START_JOB/END_JOB entries of some PDFs, commands are defined to switch character sets. Remove these commands because the default printer font is now set in step 1 and should not be changed.
          • Remove all character definitions unless you modified them for some specific purpose, such as to interpret a character that is included in the host data stream.

        3. After making the necessary changes, compile a PDT.

        4. Configure the printer session. You must specify both a euro-enabled host code page and a euro-enabled printer font code page. There are three euro-enabled printer font code pages: 858, 923 and 1252. Refer to your printer documentation to determine which to use.

    Appendix C. Advanced Configuration Options (3270)

    You can set some parameters in the Page Setup and Advanced Options panels when you configure a printer session. These parameters override the values set in the PDT, but they do not modify the PDT.

    The following table shows the fields, ranges, and associated PDT parameter values:

    Table 34. Advanced Options

    Field name Value PDT parameter
    Best Fit Yes/No none
    Characters per inch 10, 12, 17 DEFAULT_CPI?
    Concatenation time integer: 0-32767 none
    Draw field-attribute byte none, here, next none
    FF takes space if before data Yes/No FORM_FEED_TAKES_POSITION?
    Font String none
    Form-feed position Any position/Column 1 only FORM_FEED_ANY_POSITION?
    Ignore attributes Yes/No none
    Ignore FF when at first position Yes/No IGNORE_FORM_FEED_AT_FIRST_POS?
    Inactivity time integer 0, 10-255 INTERV_REQ_TIMER
    Inherit parameters Yes/No none
    Lines per inch 2, 3, 4, 6, 8, 10 DEFAULT_LPI?
    Maximum characters per line integer: 1-255 MAXIMUM_PRINT_POSITION
    Maximum lines per page integer: 1-255 MAXIMUM_PAGE_LENGTH
    Printer-font code-page integer: (for example 850) none
    Print nulls as spaces Yes/No OVERRIDE_FORMATTED_PRINT?
    SCS sense-code Yes/No none
    Suppress NL if CR at MPP+1 Yes/No NO_AUTO_NL_IF_CR_AT_MPP_PLUS_1?
    Suppress NL if NL at MPP+1 Yes/No NO_AUTO_NL_IF_NL_AT_MPP_PLUS_1?
    Suppress null lines Yes/No COMPRESS_LINE_SPACING?
    Termination time integer: 0-32767 none
    Tractor feed Yes/No none


    Appendix D. Troubleshooting

    If the print function fails completely, first try to re-install the server code. If the print function still fails, contact your IBM Service Representative.

    If the printed output is not as you want it to be, and you cannot correct the problem by referring to the rest of this book, the following information might help you:

    Inactivity Timer

    Host On-Demand has an inactivity timer that monitors print jobs and pops up an 'intervention required' message if an error occurs. If the message appears, check the following:

    After you correct the error, printing resumes and the message disappears, but you can click OK at any time to remove the message.

    If you cannot correct the error condition, close and restart the browser. In some cases, you might have to reboot the machine.

    The inactivity time is controlled by the value set in the session Properties > Connection window for 3270 Printer sessions, Properties > Printer window for the 5250 Printer session, or the INTERV_REQ_TIMER= session parameter in the PDT. The default value is 25 seconds (025), but you can change it on the panel or by modifying and compiling the PDF. A value of 000 disables the timer; a value below 011 sets an interval of 10 seconds; the maximum value is 255. You might need to increase the value if you have a slow printer.

    Problem Resolution

    For additional information related to Print Troubleshooting, see the Printing Toubleshooting Checklist in the IBM Host On-Demand Troubleshooting Guide.

    No output on the printer (3270)

    1. Can you print without Host On-Demand?
      Can you print a test page from the printer properties window (Windows), or print an ASCII file from an OS/2 window, or send a file to the printer (AIX, UNIX)?
    2. Can you print a Host On-Demand test page?
      To find out, start the printer session. Click Print > Print Test Page from the menu. A message tells you that the page has been printed, but it might not print until you click OK.

      You do not need a connected session to print a test page.

    3. Can you print your host document to a file?

    No output on the printer (5250)

    1. Can you print without Host On-Demand?
      Can you print a test page from the printer properties window (Windows), or print an ASCII file from an OS/2 window, or send a file to the printer (AIX, UNIX)?

      Printing may be halted by the host iSeries system. To check the status of a printer, use the WRKWTR command on the AS/400 command line. Use option 7 to display the printer operator messages. If you frequently receive the "Load form type '*STD' device ..." message, consider having the iSeries system administrator perform the following command: ADDRPYLE SEQNBR(99999) MSGID(CPA3394) RPY('G').


    2. Can you print your host document to a file?

    3. Can you print your host document to another printer using Host On-Demand?
    4. Is your printer supported by your iSeries?

    No output on the printer (VT)

    1. Can you print without Host On-Demand?
      Can you print a test page from the printer properties window (Windows), or print an ASCII file from an OS/2 window, or send a file to the printer (AIX, UNIX)?

    2. When your host application attempts to print, do you see the Printer Error message in the VT session status bar?

    3. Do you see the Printer Started and Printer Stopped messages in the VT session status bar?

    4. Go to the computer system where your printer is locally attached. Verify that your printer is ready to print and no error messages are displayed.

      Check for the following conditions:
      Correct the problem and retry.

    Garbage mixed in with the text on the printout

    Character attributes are not correct on an AIX-attached printer

    If you see incorrect character attributes (for example, CPI or LPI) in printouts on an AIX-attached printer, the printer control codes added by the AIX printer driver may be causing the problem. In order to send host print jobs unmodified to the printer, use AIX's splp command with the -p+ flag. Refer to the AIX Commands Reference for details about the splp command.

    Printer session does not connect (3270)

    For a printer session to be established, the iSeries Telnet server must support TN3270E and be configured for LU1 or LU3 sessions.

    Display session starts, but the associated printer session does not (3270)

    Session does not support associated printer (3270)

    If you get this message when you start a display session, an associated printer session has been specified in the display-session configuration on the client but the Telnet server to which the session has connected does not support TN3270E. Printer sessions are supported only by the Extended TN3270 protocol.

    Print-to-file does not work

    If you receive a message indicating that an error has occurred, check the following:

    1. Does the disk that you specified exist?
    2. Do you have write access to the disk?
    3. Is there enough space on the disk?
    4. If the file name already exists, is it write protected or in use by the operating system?
    5. Is there a system-I/O error or is an error mentioned in the Java console?

    Correct the problem and try again.

    If you do not receive an error message, the file might have been written to the disk:

    1. If you did not specify a path, the file was written to the browser's default directory.
    2. If you did not specify a name, a default name default.prn was used. If the printer is configured for separate files, the names will be default.prn.000, default.prn.001 and increment in number as the files are created.

    10 characters per inch is the only CPI value selectable in session Properties > Page Setup for 3270 Printer sessions

    If you are using a PDT such as Basic ASCII text mode, you can choose only 10 characters per inch because that is the default when no character-density statements are defined in the PDT. Host On-Demand supports 10, 12, or 17 characters per inch if the following options are defined, with valid control codes, in the PDT:

    SET_10_CHARACTERS_INCH
    SET_12_CHARACTERS_INCH
    SET_17_CHARACTERS_INCH
    

    If your printer supports these character densities and you want to select them, you must use one of the other PDTs supplied or create and compile a PDF with these Control Codes defined.

    If you receive unexpected CPI in a print job, check the START_JOB and END_JOB control codes to see if they have been defined with CPI controls. If you are using an LU1 session, also check whether an SCS command, Set Print Density, which affects CPI, is being sent from the host.

    6 lines per inch is the only LPI value selectable in the Advanced Options window (3270)

    If you are using a PDT such as Basic ASCII text mode, you can choose only 6 lines per inch because that is the default when no line-density statements are defined in the PDT. Host On-Demand supports 2, 3, 4, 6, or 8 lines per inch if the following options are defined, with valid control codes, in the PDT:

    SET_2_LINES_INCH
    SET_3_LINES_INCH
    SET_4_LINES_INCH
    SET_6_LINES_INCH
    SET_8_LINES_INCH
    
    
    or
    
    
    SET_VARIABLE_LINE_DENSITY
    LINE_SPACING_RATIO
    

    If your printer supports these line densities and you want to use them, you must use one of the other PDTs supplied or create and compile a PDF with these Control Codes defined.

    If you receive unexpected LPI in a print job, check the START_JOB and END_JOB control codes to see if they have been defined with CPI controls. Additionally, SET_VARIABLE_LINE_DENSITY and LINE_SPACING_RATIO affect how line-density is controlled. If you are using an LU1 session, also check whether an SCS command, Set Line Density, which affects LPI, is being sent from the host.

    An Intervention Required message appears

    If you receive a message indicating that an error has occurred, check the following:

    1. Is the Printer Name a valid port or device?
    2. Is there paper, ink, ribbon, and so on in the printer?
    3. Is the cable between the computer and the printer connected?
    4. Is the printer switched on and online?
    5. Is there a printer error?

    Correct the problem and click Retry or Cancel Job.

    If the only response available in the message box is OK, the message occurred because Host On-Demand recognized that there had been no activity within the timeout period of the inactivity timer. If your printer is slow, but seems to be functioning correctly, click OK. Host On-Demand should continue printing. You can also disable the time-out or lengthen the timer.

    Printing stops in the middle of a print job (3270)

    If there is a problem with the file or device and the inactivity timer is active, you should receive a message indicating an error. Correct the error and send the job again.

    If there is a problem in the host data stream, an error code is returned to the host. Correct the error and send the job again. However, if you want to try to print even though the data stream is not correct, change SNA sense-code to No in the Advanced Options configuration window. This option lets the print job continue even though there are data stream errors.

    If there is a problem with the connection, changing SNA sense-code to No will have no effect. Check the Java console for indications of failure, and if necessary, take a Transport trace to diagnose the problem further.

    Unexpected page ejects

    If you are experiencing unexpected page ejects when using 3270 host-directed printing with Host On-Demand, read these suggestions for the source of your problem.

    Cannot pause printer jobs from the spooler (for example, the Windows printer-status window)

    Because of current Java limitations on printing, Host On-Demand writes to the printer device or port through the Java file interface. On Windows operating systems, handling a local port (LPT1) as a file causes the print job to bypass the spooler. Therefore, if you want to hold jobs before printing, you should print to a file, and then copy the file to the printer. Refer to How Host Printing Works for more information.

    Cannot print directly to a remote printer from AIX or UNIX

    For AIX or UNIX, print output goes directly to a printer if you enter a device name such as /dev/lp0. However, printing to a network printer is a two-stage process:

    1. Configure the session with Print Destination set to File, and Separate Files set to Yes. Enter a valid file name under File Path and Name (for example, hprint.*).
    2. When the print job is finished, go to the command prompt and type the appropriate command to send the file to the remote printer, for example, lp -dprtq1 hprint.000 or lpr -Pprtq1 hprint.000 (the name of the remote printer in this example is Prtq1).

    This can be automated by using the feature described in the help entry "Running external commands after host print jobs."

    Cannot print to LPT1 for HP Deskjet 720 (and others)

    Some HP printers use HP's new Performance Printing Architecture, which improves performance by moving the processing of the HP PCL commands from the printer to the processor, and which uses a proprietary architecture (PPA) between the PC and the printer. Host On-Demand supports HP PCL but, because of Java limitations on printing, it writes directly to the printer port or device through the Java file interface. Writing to local devices such as LPT1 in this manner causes Host On-Demand to bypass the HP software that converts the PCL commands to PPA, with the result being that you cannot print to a local device.

    You can bypass this limitation by defining the printer as a remote (network) printer, which causes the HP PCL commands to go through HP's device software.

    This can be solved by using the feature described in the help entry "Running external commands after host print jobs." This problem can also be resolved by using the Windows Native Printing mode.

    PA1 and PA2 do not function (3270)

    PA1 and PA2 are Program Attention keys for LU1 printer sessions. If these keys are to be active, the host application that receives them must be able to process them. If this is the case but nothing happens when you press one of the keys, verify that the Telnet server to which the session is connected supports them.

    When the PA1 or PA2 key is pressed, Host On-Demand sends APAK 01 or APAK 02 respectively.

    PA1 and PA2 are not applicable to LU3 printer sessions.

    Cannot print to a locally attached printer on LPT1 when a network printer is also mapped to LPT1

    If you have a locally attached printer assigned to LPT1 and map a network printer to LPT1 also on Windows XP, Windows 7, Windows 8, or Windows 10, print jobs from any application are sent to the network printer. You can print to the locally attached printer on LPT1 after you delete the network printer mapping to LPT1.

    What to do if you still have a problem

    If you are sure that you are using the correct type of PDT, and you cannot resolve the problem, call the IBM support center. Before you do so, have the following information ready:

    Table 35. Problem Determination

    Problem Function Component Trace Level
    Output has incorrect formatting HACL Printer 3
    Connection not made or failed HACL Transport 3
    No output HACL Printer 3
    Host data stream HACL
    Check for host messages
    Transport 3
    Session hangs HOD
    HACL
    Java log or console
    PrtTerminal
    Printer
    3
    1
    Wrong status shown HOD PrtTerminal 3

    Windows native trace messages (Windows platforms only): If you have a problem unique to the Windows Spooler Interface mode or the Windows Native Printing mode, get Windows native trace messages using the hodtracetool utility, which is located on the Host On-Demand CD-ROM.

    Invoking the hodtracetool utility with the '?' option will display an explanation about the tool like the following:

    &gt; hodtracetool ? usage: hodtracetool [-options] where options include; -L[trace_level] specifies the trace level (0-3) 0 means no trace 3 means all trace -F[file_name] specifies the output file name -M[max_entry] specifies the maximum number of trace entries example: hodtracetool -L3 -Fc:\temp\trace.txt -M10000

    Invoking the hodtracetool utility without options will display the current setting on Windows native tracing, for example:

    &gt; hodtracetool Trace level: 0 Output filename: $HodNativeTrace.txt Maximum number of trace entries: 1000


    Appendix E: Associated Printer Sessions (3270)

    The Telnet3270E standard lets you specify an association between a display and a printer session. The rules are defined in RFC2355. This is unique to Telnet and is not available in the SNA environment. When you configure a display session, Host On-Demand lets you specify an associated printer session.

    The purpose of the association is convenience:

    The association starts at the Telnet server. In the server's configuration, there is a one-to-one correspondence when defining associated printers. Each printer LU is configured as associated with a particular display LU. However, in the Host On-Demand session configuration, a printer session configuration without an LU name specified can be associated with multiple display sessions because the display session LU name is used to start the associated printer session.

    Association does NOT mean that data sent to print from a display LU automatically goes to the associated printer LU. You always have to tell the host program the name of the LU to which you want to print.

    Host On-Demand applies some variations of its own:

    If you are using explicit LUs, you can enter the LU name of the display session; the server should then provide the name of the printer LU associated with that display. You can also enter the name of the printer LU. If you leave the name blank, Host On-Demand tries to start a printer session that is associated with any active display session.


    Appendix F. Printer Definition File Example (3270)

    The following is a printer definition file for the IBM LaserPrinter PPDS. This is only an example; the actual file may differ.

    LaserPPDS.PDF

    
    /**********************************************************************/
    /*                                                                    */
    /*    PRINTER DEFINITION FILE FOR: IBM PPDS Level 2                   */
    /*                                                                    */
    /*    This PDF is for printers which support IBM PPDS Level 2 mode.   */
    /*    The User's Guide or Reference for the printer will list the     */
    /*    Emulation Mode or Language supported by the printer. Printers   */
    /*    which support PPDS Level 3 or 4 will work with this PDF.        */
    /*    Printers, such as the Proprinter, which do not support code     */
    /*    page selection should not use this PDF.                         */
    /*                                                                    */
    /**********************************************************************/
    /**********************************************************************/
    /*                                                                    */
    /*                        Macro Definitions                           */
    /*                                                                    */
    /* Define values here that will be used commonly throughout your      */
    /* definitions.  Then use the left hand side of the equate as you     */
    /* define characters and control strings.  The PDT compiler           */
    /* will substitute the right hand side of the equate for each         */
    /* occurrence of the left hand side throughout the file.              */
    /*                                                                    */
    /* Macro names must be three characters long and may not begin with   */
    /* a number.                                                          */
    /*                                                                    */
    /* Format                                                             */
    /* A macro name is associated with a value or string of values by the */
    /* EQU statement.  The right hand side of an EQU statement must be a  */
    /* string of zero or more two digit hexadecimal numbers.  If a macro  */
    /* definition is more than one line long, you may extend it to the    */
    /* next line by ending the first line with a comma.  In this manner,  */
    /* you may define a macro which is many lines long. Macro names are   */
    /* not allowed on the right hand side.                                */
    /**********************************************************************/
    
    BEGIN_MACROS
    /* Check your printer manual to verify that these values are correct  */
    /* for your printer.                                                  */
    NUL EQU 00             /* Nul character                               */
    BEL EQU 07             /* Beeper                                      */
    BAK EQU 08             /* Back Space                                  */
    TAB EQU 09             /* Tab                                         */
    LFF EQU 0A             /* Line Feed                                   */
    VTB EQU 0B             /* Vertical Tab                                */
    FFF EQU 0C             /* Form Feed                                   */
    CRR EQU 0D             /* Carriage Return                             */
    P05 EQU 1B 57 01       /* 5 Pitch-Characters/inch                     */
                           /* Same as Double Wide                         */
    SEL EQU 11             /* Select Printer                              */
    P10 EQU 12             /* 10 Pitch-Characters/inch                    */
    CDW EQU 1B 57 00       /* Cancel Double Wide contin.                  */
    CDL EQU 14             /* Cancel Double Wide line                     */
    ESC EQU 1B             /* Escape                                      */
    SPA EQU 20             /* Space                                       */
    P17 EQU 12 0F          /* 17.1 Pitch-Characters/inch                  */
    CS2 EQU 1B 36          /* Select Character Set 2                      */
    CS1 EQU 1B 37          /* Select Character Set 1                      */
    P12 EQU 1B 3A          /* 12 Pitch-characters/inch                    */
    SVT EQU 1B 42          /* Set Vertical Tabs                           */
    SFL EQU 1B 43 00       /* Set Form Length inches                      */
    SHT EQU 1B 44          /* Set Horizontal Tabs                          */
    SDS EQU 1B 47          /* Start Double Strike                         */
    CDS EQU 1B 48          /* Cancel Double Strike                        */
    SSP EQU 1B 4E          /* Set skip perforation                        */
    CSP EQU 1B 4F          /* Cancel skip perforation                     */
    CAT EQU 1B 52          /* Cancel all tabs Clears VT                   */
                           /* and sets HT every 8 position                */
    SUL EQU 1B 2D 01       /* Start Underline                             */
    CUL EQU 1B 2D 00       /* Cancel Underline                            */
    SCP EQU 1B 5B 54 04 00 00 00 /* ESC [ T : select code page            */
    CP8 EQU 1B 5B 54 04 00 00 00 03 52     /* select code page 850        */
    CP4 EQU 1B 5B 54 04 00 00 00 01 B5     /* select code page 437        */
    LL2 EQU 1B 41 24 1B 32 /* Set line length 2 lines/inch                */
    LL3 EQU 1B 41 18 1B 32 /* Set line length 3 lines/inch                */
    LL4 EQU 1B 41 12 1B 32 /* Set line length 4 lines/inch                */
    LL6 EQU 1B 41 0C 1B 32 /* Set line length 6 lines/inch                */
    LL8 EQU 1B 41 09 1B 32 /* Set line length 8 lines/inch                */
    LL0 EQU 1B 41 07 1B 32 /* Set line length 10 lines/inch               */
                           /* actually 7/72 inch                          */
    FRM EQU 1B 64          /* Forward Relative Movement                   */
    VLF EQU 1B 4A          /* Variable Line Feed 1/216 inch units         */
    END_MACROS
    
    
    /**********************************************************************/
    /*                                                                    */
    /*                     Session Parameters                             */
    /*                                                                    */
    /* These parameters determine the way in which output will be         */
    /* formatted for your printer.                                        */
    /**********************************************************************/
    
    /**********************************************************************/
    /* Numeric Parameters                                                 */
    /* These parameters should be defined with a two digit hex number     */
    /* or a three digit decimal number.  The range of the number is zero  */
    /* to 255 (decimal).                                                  */
    /**********************************************************************/
    MAXIMUM_PAGE_LENGTH=066              /* Printed lines per page        */
    MAXIMUM_PRINT_POSITION=080           /* Printed characters per line   */
    HORIZONTAL_PEL=120
    VERTICAL_PEL=216
    LINE_SPACING_RATIO=072
    INTERV_REQ_TIMER=025                 /* Wait time if no printer rsp   */
    TOP_MARGIN=
    LEFT_MARGIN=
    
    /**********************************************************************/
    /* YES/NO Parameters                                                  */
    /* These parameters should be defined with either "YES" or "NO" on the*/
    /* right hand side of the '='                                         */
    /**********************************************************************/
    COMPRESS_LINE_SPACING?=NO              /* Should blank or null lines  */
                                           /* be printed?                 */
    FORM_FEED_ANY_POSITION?=YES            /* Should the form feed be     */
                                           /* valid in any position?      */
    OVERRIDE_FORMATTED_PRINT?=YES          /* Should nulls be printed as  */
                                           /* blanks?                     */
    
    
    /**********************************************************************/
    /*                                                                    */
    /*                         Control Codes                              */
    /*                                                                    */
    /* These definitions tell the emulator what strings to send to        */
    /* your printer to issue control commands.                            */
    /*                                                                    */
    /* Format                                                             */
    /* The name of the control command should always be at the beginning  */
    /* of a line followed by a '=' and then a definition string.          */
    /* A Definition String is any combination of macro names, hexadecimal */
    /* numbers, or characters, separated by blanks.  A macro must have    */
    /* previously been defined in the macro definitions section above.    */
    /* A hexadecimal number must be two digits (0,..,F) long. A           */
    /* character must be preceded and followed by a blank.  If a          */
    /* definition string will not fit on a line, it may be continued on   */
    /* as many lines as you wish by ending each line except the last with */
    /* a comma. You may add any comments you wish by including            */
    /* them between a slash*  and a *slash where slash is the symbol /.   */
    /**********************************************************************/
    
    /* START_JOB is the control string which is sent to the printer       */
    /* at the beginning of each print job.                                */
    START_JOB=SEL CDW CDL CUL CDS CP8 CS2
    
    /* END_JOB is the string which is sent to the printer at the end      */
    /* of each print job.                                                 */
    END_JOB=CAT CDW CDL CUL CDS CP4
    
    /* PAGE_LENGTH_TYPE is used to determine the type of value for the    */
    /* value defined in the SET_PAGE_LENGTH command                       */
    PAGE_LENGTH_TYPE?=INCH
    
    BACKSPACE=BAK
    BEL=BEL
    CARRIAGE_RETURN=CRR
    NEW_LINE=CRR LFF
    LINE_FEED=LFF
    FORM_FEED=FFF
    HORIZONTAL_TAB=TAB
    VERTICAL_TAB=VTB
    DUP=*
    FIELD_MARK=;
    
    /**********************************************************************/
    /* The following control codes contain command strings that include   */
    /* one or more variable values. Place the word "value" in the         */
    /* position in your definition string where Host On-Demand should     */
    /* fill in the hexadecimal value(s) indicated.                        */
    /* For example, on the IBM Proprinter, the SET_HORIZONTAL_TABS        */
    /* definition is: SET_HORIZONTAL_TABS=ESC D values NUL                */
    /**********************************************************************/
    SET_HORIZONTAL_TABS=SHT values NUL     /* "values" are the tab stops  */
                                           /* in column numbers           */
    SET_VERTICAL_TABS=SVT values NUL       /* "values" are the tab stops  */
                                           /* in line numbers             */
    SET_HORIZONTAL_MARGINS=
    SET_PAGE_LENGTH=SFL value              /* "value"=inch of the page    */
    SET_AUTO_PERFORATION_SKIP=             /* "value"=number of lines to  */
                                           /* skip over the perforation   */
                                           /* between pages.  Used to set */
                                           /* top and bottom margins.     */
    SET_VARIABLE_LINE_DENSITY=ESC A value ESC 2
                                           /* "value"=number of points.   */
                                           /* A point is                  */
                                           /* 1/(LINE_SPACING_RATIO) inch.*/
    
    /**********************************************************************/
    /* The following control codes set the printer lines per inch and     */
    /* characters per inch to fixed amounts. If your printer does not     */
    /* support setting the line density in points, you may enter control  */
    /* strings for the following commands. Note that if you provide a     */
    /* command for the SET_VARIABLE_LINE_DENSITY command above, it will   */
    /* be used and any control strings you provide for the set lines per  */
    /* inch commands below will not be used.                              */
    /* When Host On-Demand gets a command from the host to set the        */
    /* lines per inch, it rounds it to the closest lines per inch         */
    /* setting that you provide.                                          */
    /**********************************************************************/
    SET_2_LINES_PER_INCH=LL2
    SET_3_LINES_PER_INCH=LL3
    SET_4_LINES_PER_INCH=LL4
    SET_6_LINES_PER_INCH=LL6
    SET_8_LINES_PER_INCH=LL8
    SET_10_LINES_PER_INCH=LL0              /* 7/72 inch or 9/96 inch      */
    SET_10_CHARACTERS_PER_INCH=P10
    SET_12_CHARACTERS_PER_INCH=P12
    SET_17_CHARACTERS_PER_INCH=P17         /* Condensed mode              */
    START_DOUBLE_WIDTH_CHARACTERS=P05
    END_DOUBLE_WIDTH_CHARACTERS=CDW
    
    /**********************************************************************/
    /* These control codes move the print position (Horizontal/Vertical)  */
    /**********************************************************************/
    FORWARD_HORIZONTAL_SKIP=FRM word-value(LH)
    FORWARD_VERTICAL_STEP_FEED=VLF byte-value
    
    /**********************************************************************/
    /*                        Highlight Specifications                    */
    /* These definitions determine how things which are sent by the       */
    /* host to be displayed or printed as underlined, reverse video, or   */
    /* blinking, will be highlighted on your printer.                     */
    /**********************************************************************/
    START_HIGHLIGHT_INTENSE=SDS           /* This is double strike        */
    END_HIGHLIGHT_INTENSE=CDS
    START_HIGHLIGHT_UNDERLINE=SUL
    END_HIGHLIGHT_UNDERLINE=CUL
    START_HIGHLIGHT_REVERSE_VIDEO=
    END_HIGHLIGHT_REVERSE_VIDEO=
    START_HIGHLIGHT_BLINK=
    END_HIGHLIGHT_BLINK=
    
    /**********************************************************************/
    /*                                                                    */
    /*                      Character Definitions                         */
    /*                                                                    */
    /* The remainder of the definitions are for printable characters.     */
    /* See the Host Printing Reference for the actual character referred  */
    /* to by each character name.                                         */
    /*                                                                    */
    /* Format                                                             */
    /* The format of a character definition is the same as for a control  */
    /* code.                                                              */
    /**********************************************************************/
    SPACE=SPA
    EXCLAMATION_POINT=21
    QUOTATION_MARKS=22
    NUMBER_SIGN=23
    DOLLAR_SIGN=24
    PERCENT_SIGN=25
    AMPERSAND=26
    APOSTROPHE=27
    LEFT_PARENTHESIS=28
    RIGHT_PARENTHESIS=29
    ASTERISK=2A
    PLUS_SIGN=2B
    COMMA=2C
    HYPHEN=2D
    PERIOD=2E
    SLASH=2F
    ZERO=0
    ONE=1
    TWO=2
    THREE=3
    FOUR=4
    FIVE=5
    SIX=6
    SEVEN=7
    EIGHT=8
    NINE=9
    COLON=3A
    SEMICOLON=3B
    LESS_THAN_SIGN=3C
    EQUAL_SIGN=3D
    GREATER_THAN_SIGN=3E
    QUESTION_MARK=3F
    AT_SIGN=40
    A_CAPITAL=A
    B_CAPITAL=B
    C_CAPITAL=C
    D_CAPITAL=D
    E_CAPITAL=E
    F_CAPITAL=F
    G_CAPITAL=G
    H_CAPITAL=H
    I_CAPITAL=I
    J_CAPITAL=J
    K_CAPITAL=K
    L_CAPITAL=L
    M_CAPITAL=M
    N_CAPITAL=N
    O_CAPITAL=O
    P_CAPITAL=P
    Q_CAPITAL=Q
    R_CAPITAL=R
    S_CAPITAL=S
    T_CAPITAL=T
    U_CAPITAL=U
    V_CAPITAL=V
    W_CAPITAL=W
    X_CAPITAL=X
    Y_CAPITAL=Y
    Z_CAPITAL=Z
    LEFT_BRACKET=5B
    BACKSLASH=5C
    RIGHT_BRACKET=5D
    CIRCUMFLEX_ACCENT=5E
    UNDERLINE=5F
    GRAVE_ACCENT=60
    A_SMALL=a
    B_SMALL=b
    C_SMALL=c
    D_SMALL=d
    E_SMALL=e
    F_SMALL=f
    G_SMALL=g
    H_SMALL=h
    I_SMALL=i
    J_SMALL=j
    K_SMALL=k
    L_SMALL=l
    M_SMALL=m
    N_SMALL=n
    O_SMALL=o
    P_SMALL=p
    Q_SMALL=q
    R_SMALL=r
    S_SMALL=s
    T_SMALL=t
    U_SMALL=u
    V_SMALL=v
    W_SMALL=w
    X_SMALL=x
    Y_SMALL=y
    Z_SMALL=z
    LEFT_BRACE=7B
    VERTICAL_BAR=7C
    RIGHT_BRACE=7D
    TILDE_ACCENT=7E
    C_CEDILLA_CAPITAL=80
    U_DIAERESIS_SMALL=81
    E_ACUTE_SMALL=82
    A_CIRCUMFLEX_SMALL=83
    A_DIAERESIS_SMALL=84
    A_GRAVE_SMALL=85
    A_OVERCIRCLE_SMALL=86
    C_CEDILLA_SMALL=87
    E_CIRCUMFLEX_SMALL=88
    E_DIAERESIS_SMALL=89
    E_GRAVE_SMALL=8A
    I_DIAERESIS_SMALL=8B
    I_CIRCUMFLEX_SMALL=8C
    I_GRAVE_SMALL=8D
    A_DIAERESIS_CAPITAL=8E
    A_OVERCIRCLE_CAPITAL=8F
    E_ACUTE_CAPITAL=90
    AE_DIPTHONG_SMALL=91
    AE_DIPTHONG_CAPITAL=92
    O_CIRCUMFLEX_SMALL=93
    O_DIAERESIS_SMALL=94
    O_GRAVE_SMALL=95
    U_CIRCUMFLEX_SMALL=96
    U_GRAVE_SMALL=97
    Y_DIAERESIS_SMALL=98
    O_DIAERESIS_CAPITAL=99
    U_DIAERESIS_CAPITAL=9A
    O_SLASH_SMALL=9B
    POUND_SIGN=9C
    O_SLASH_CAPITAL=9D
    MULTIPLY_SIGN=9E
    A_ACUTE_SMALL=A0
    I_ACUTE_SMALL=A1
    O_ACUTE_SMALL=A2
    U_ACUTE_SMALL=A3
    N_TILDE_SMALL=A4
    N_TILDE_CAPITAL=A5
    ORDINAL_INDICATOR_FEMININE=A6
    ORDINAL_INDICATOR_MASCULINE=A7
    QUESTION_MARK_INVERTED=A8
    REGISTERED_TRADEMARK_SYMBOL=A9
    LOGICAL_NOT=AA
    ONE_HALF=AB
    ONE_QUARTER=AC
    EXCLAMATION_POINT_INVERTED=AD
    LEFT_ANGLE_QUOTES=AE
    RIGHT_ANGLE_QUOTES=AF
    A_ACUTE_CAPITAL=B5
    A_CIRCUMFLEX_CAPITAL=B6
    A_GRAVE_CAPITAL=B7
    COPYRIGHT_SYMBOL=B8
    CENT_SIGN=BD
    YEN_SIGN=BE
    A_TILDE_SMALL=C6
    A_TILDE_CAPITAL=C7
    INTERNATIONAL_CURRENCY_SYMBOL=CF
    ETH_ICELANDIC_SMALL=D0
    ETH_ICELANDIC_CAPITAL=D1
    E_CIRCUMFLEX_CAPITAL=D2
    E_DIAERESIS_CAPITAL=D3
    E_GRAVE_CAPITAL=D4
    I_DOTLESS_SMALL=D5
    I_ACUTE_CAPITAL=D6
    I_CIRCUMFLEX_CAPITAL=D7
    I_DIAERESIS_CAPITAL=D8
    VERTICAL_LINE_BROKEN=DD
    I_GRAVE_CAPITAL=DE
    O_ACUTE_CAPITAL=E0
    SHARP_S_SMALL=E1
    O_CIRCUMFLEX_CAPITAL=E2
    O_GRAVE_CAPITAL=E3
    O_TILDE_SMALL=E4
    O_TILDE_CAPITAL=E5
    MICRO_SYMBOL=E6
    THORN_ICELANDIC_SMALL=E7
    THORN_ICELANDIC_CAPITAL=E8
    U_ACUTE_CAPITAL=E9
    U_CIRCUMFLEX_CAPITAL=EA
    U_GRAVE_CAPITAL=EB
    Y_ACUTE_SMALL=EC
    Y_ACUTE_CAPITAL=ED
    OVERLINE=EE
    ACUTE_ACCENT=EF
    SYLLABLE_HYPHEN=F0
    PLUS_OR_MINUS_SIGN=F1
    THREE_QUARTERS=F3
    PARAGRAPH_SYMBOL=F4
    SECTION_SYMBOL=F5
    DIVIDE_SIGN=F6
    CEDILLA=F7
    DEGREE_SYMBOL=F8
    DIAERESIS=F9
    MIDDLE_DOT_ACCENT=FA
    ONE_SUPERSCRIPT=FB
    THREE_SUPERSCRIPT=FC
    TWO_SUPERSCRIPT=FD
    REQUIRED_SPACE=SPA
    /**********************************************************************/
    /*                      End of Definition File                        */
    /**********************************************************************/
    

    Appendix G: Notices

    This information was developed for products and services offered in the U.S.A. IBM may not offer the products, services, or features discussed in this document in other countries. Consult your local IBM representative for information on the products and services currently available in your area. Any reference to an IBM product, program, or service is not intended to state or imply that only that IBM product, program, or service may be used. Any functionally equivalent product, program, or service that does not infringe any IBM intellectual property right may be used instead. However, it is the user's responsibility to evaluate and verify the operation of any non-IBM product, program, or service.

    IBM may have patents or pending patent applications covering subject matter described in this document. The furnishing of this document does not give you any license to these patents. You can send license inquiries, in writing, to:

    IBM Director of Licensing
    IBM Corporation
    North Castle Drive
    Armonk, NY 10504-1785
    U.S.A.

    For license inquiries regarding double-byte (DBCS) information, contact the IBM Intellectual Property Department in your country or region or send inquiries, in writing, to:

    Intellectual Property Licensing
    Legal and Intellectual Property Law
    IBM Japan, Ltd.
    19-21, Nihonbashi-Hakozakicho, Chuo-ku
    Tokyo 103-8510, Japan

    The following paragraph does not apply to the United Kingdom or any other country where such provisions are inconsistent with local law: INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some states do not allow disclaimer of express or implied warranties in certain transactions, therefore, this statement may not apply to you.

    This information could include technical inaccuracies or typographical errors. Changes are periodically made to the information herein; these changes will be incorporated in new editions of the publication. IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this publication at any time without notice.

    This information could include technical inaccuracies or typographical errors. Changes are periodically made to the information herein; these changes will be incorporated in new editions of the publication. IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this publication at any time without notice.

    Licensees of this program who wish to have information about it for the purpose of enabling: (i) the exchange of information between independently created programs and other programs (including this one) and (ii) the mutual use of the information which has been exchanged, should contact:

    Site Counsel
    IBM Corporation
    2455 South Road
    Poughkeepsie, NY 12601-5400
    U.S.A.

    Such information may be available, subject to appropriate terms and conditions, including in some cases, payment of a fee.

    The licensed program described in this information and all licensed material available for it are provided by IBM under terms of the IBM Customer Agreement, IBM International Program License Agreement, or any equivalent agreement between us.

    Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not tested those products and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products.

    Any references in this information to non-IBM Web sites are provided for convenience only and do not in any manner serve as an endorsement of those Web sites. The materials at those Web sites are not part of the materials for this IBM product and use of those Web sites is at your own risk.

    IBM may use or distribute any of the information you supply in any way it believes appropriate without incurring any obligation to you.

    If you are viewing this information softcopy, the photographs and color illustrations may not appear.

    Trademarks

    The following terms are trademarks of the IBM Corporation in the United States or other countries or both:

    Lotus and Domino Go Webserver are trademarks of Lotus Development Corporation in the United States, or other countries, or both.

    Java and all Java-based trademarks and logos are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.

    Microsoft, Windows, Windows NT, and the Windows logo are registered trademarks of Microsoft Corporation in the United States, other countries, or both.

    UNIX is a registered trademark in the United States, other countries, or both and is licensed exclusively through X/Open Company Limited.

    Other company, product, and service names may be trademarks or service marks of others.