• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

PostScript set printer tray for HP Laserjet M608

New Here ,
Feb 14, 2020 Feb 14, 2020

Copy link to clipboard

Copied

Hi Everyone,
We have around 7 HP LaserJet M605 printers, and a process breaks pdf files into one page .ps files. While the .ps files are created, the following code is added to the .ps file:

 

currentpagedevice /InputAttributes get 2 get
dup null eq
{ pop }
{ dup length 1 add dict copy
dup /InputAttributes
1 dict dup /Priority [0 1 2 3] put
put setpagedevice
} ifelse

 

Depending on digit/number in the "get 2 get" line these .ps files are sent to the printer and it correctly prints each paper type from the correct tray -- envelope, letterhead, plain.

We just bought new printers LaserJet M608. The same post script code additions mentioned above, does not print the envelope from the correct tray. It wants to print it from the manual tray. I kept changing the "get 2 get" line from 0-4  (4 trays) and  still the envelope keeps printing from the manual feed tray. Does anyone know if the attributes for selection of trays are different in M608 printers compared to M605? Do you have any recommendation of what I should do next to troubleshoot this issue.

I would like to add that some people were able to resolve this issue with changing the PCL settings and change the Media Source Mapping from "Standard" to "Classic". I tried the same but it did not work. 
I also get the "ERROR undefined OFFENDING COMMAND: get" for the envelope when the "get 2 get" line has the number '2' in it, and when I change the number to 1, 3 or 0, it defaults to the manual feed tray. So basically it doesn't print from any other tray other than the manual feed tray. 

Also I read that you need to complete two steps, load a postscript module on printer control library, and It associates the special media type with the tray number within the PostScript interpreter. The second module is a form setup module which requests that the PostScript interpreter select the tray with the desired media type.


I appreciate any help,

Thank you,

-Ned
TOPICS
Programming

Views

548

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 14, 2020 Feb 14, 2020

Copy link to clipboard

Copied

Each PS printer needs it’s own specific device control. It is not generic. The place to find device control code is in the printer PPD. That’s why PPD files exist. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Mar 03, 2020 Mar 03, 2020

Copy link to clipboard

Copied

LATEST

Ned-l

 

HP is using PJL wrapper commands to control their printer  -  other vendors do the same Konica Minolta!  and the PJL syntax is different from vendor to another

You must reffer to the manufacturer documentation to see the proper set of PJL command.

One woraround I used to do I just use windows driver for HP - for example -  and print any page from text editor using the HP printer and capture the output on file (print to file)  and see the set of PJL commands sent by the driver to select the tray.

This is more better.

 

Cheers

Adam  

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines