× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi All,

Apologies if this post is too long; hopefully I got all the necessary info
in one go.

I'm on a 440 machine, copying a byte stream file that contains HP PCL
commands from the IFS to a spool file such that it will be sent to the
printer unmodified, i.e. I created the spool file with DEVTYPE(*USERASCII).

The problem is, the printer appears to ignore it.  Even with the printer in
display mode (Esc-Y), nothing seems to arrive at the printer, although the
status goes from RDY to SND to SAV.

Since the spool file contains ASCII data, OS/400 will not display it for me.
So I found the QSPL file and member containing it, and it appears to have
the HP PCL stuff in it.  Here's a sample of the contents of the file,
starting with rec 1 pos 1, as shown by DSPPFM after pressing F10, F11:

*...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+.
...8....
áÃ`ÃìÃßÃìËøÎÂèøÌßËøÎÂè<|å|øÌß
ËøÎ
1412637126350012635126351273373373635001273337351273737363333544441273333735
12737337
B5B6619B6688DAB6619B6608B830101060284DABA0150809B8310660241684CF7FBA01620809
B8310146

Here's what I expect:

00000000  1B 45 1B 26 66 31 79 1B 26 66 38 58 0D 0A 1B 26
.E.&f1y.&f8X...&
00000010  66 31 59 1B 26 66 30 58 1B 28 73 30 31 70 31 30
f1Y.&f0X.(s01p10
00000020  76 30 62 38 54 0D 0A 1B 2A 70 31 35 30 78 30 59
v0b8T...*p150x0Y
00000030  1B 28 73 31 70 36 76 30 62 34 31 36 38 54 4C 4F
.(s1p6v0b4168TLO
00000040  47 4F 1B 2A 70 31 36 32 30 78 30 59 1B 28 73 31
GO.*p1620x0Y.(s1

Looks like it's got it.  So why doesn't this get sent to the printer?

More info: the printer is a setup as a network printer, the outq definition
is:

Remote system  . . . . . . . . . . . . :   MISTESTPRT
Remote printer queue . . . . . . . . . :   MISTESTPRT
Queue for writer messages  . . . . . . :   QSYSOPR
  Library  . . . . . . . . . . . . . . :     *LIBL
Connection type  . . . . . . . . . . . :   *IP
Destination type . . . . . . . . . . . :   *OTHER
Host print transform . . . . . . . . . :   *YES
Manufacturer type and model  . . . . . :   *HP6
Workstation customizing object . . . . :   ERPRT
  Library  . . . . . . . . . . . . . . :     HS#LIBR
Image configuration  . . . . . . . . . :   *NONE
Destination options  . . . . . . . . . :   *NONE
Print separator page . . . . . . . . . :   *NO
User defined option  . . . . . . . . . :   *NONE
User defined object:
  Object . . . . . . . . . . . . . . . :   *NONE
    Library  . . . . . . . . . . . . . :
  Object type  . . . . . . . . . . . . :
User driver program  . . . . . . . . . :   *NONE
  Library  . . . . . . . . . . . . . . :
Spooled file ASP . . . . . . . . . . . :   *SYSTEM

And the workstation customizing object is:

:WSCST DEVCLASS=TRANSFORM.
    :TRNSFRMTBL.
    :PRTDTASTRM
      DATASTREAM=HPPCL5.
    :INITPRT
      DATA ='1B26733043'X             /* esc &s0C -- enable end-of-line wrap
*/
            '1B266C304C'X             /* esc &l0L -- disable perf skip mode
*/
            '1B266C3145'X             /* esc &l1E -- set top margin to 1
line */
            '1B266C363446'X           /* esc &l64F - set text len to 64
lines */
            '1B266631793458'X         /* esc &f1y4X - enable MACRO 1 for
OVERLAY */
            '1B2A7030783136353059'X   /* position to 0 x 1650 Y */
            '1B283855'X               /* esc ( 8 U -- symbol set HP Roman */
            '1B28733070'X             /* esc ( s 0 p -- fixed-pitch font */
                  '313068'X           /*         1 0 h -- 10cpi */
                  '313276'X           /*         1 0 v -- 10pt font */
                  '3073'X             /*         0 s -- style upright */
                  '3354'X.            /*         3 T -- COURIER typeface*/


   :RESETPRT
     DATA ='1B45'X.      /* esc E -- reset printer */

   :CPICOR
     CPI=10
     ASCIIFNT=  11
     FNTWTH=   144
     FNTATR=    1
     DATA =''X.

   :CPICOR
     CPI=12
     ASCIIFNT=  85
     FNTWTH=   120
     FNTATR=    1
     DATA =''X.

    :CPICOR
      CPI=15
      ASCIIFNT=  222
      FNTWTH=     96
      FNTATR=    1
      DATA =''X.

    :BELL
      DATA ='07'X.

    :SPACE
      DATA ='20'X.

    :CARRTN
      DATA ='0D'X.

    :FORMFEED
      DATA ='0C'X.

    :LINEFEED
      DATA ='0A'X.

:EWSCST.


There's an interesting aside here.  I did a DSPFFD on the QSPL file and saw
the following:

Field Level Information
             Data        Field  Buffer    Buffer        Field    Column
  Field      Type       Length  Length  Position        Usage    Heading
  SEQUENCE#  CHAR            6       6         1        Both
    Coded Character Set Identifier  . . . . . :  65535
  DATETIME   CHAR            6       6         1        Both
    Coded Character Set Identifier  . . . . . :  65535
             CHAR         4067    4067         1        Both
    Renamed field . . . . . . . . . . . . . . :  RECORD
    Coded Character Set Identifier  . . . . . :  65535

Note that all 3 fields start in buffer position 1.  Try *that* with DDS!
Then there's the "Renamed field" which apparently was named blanks prior to
the rename.  So for extra credit, what's the actual position of SEQUENCE#
and DATETIME, and how did they do that?

tia,
Peter Dow
Dow Software Services, Inc.
909 425-0194 voice
909 425-0196 fax



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com



As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.