Dec 252017
 
Control Epson printer from OS/2, use functions not supported by the OS/2 driver.
File PRNTR15.ZIP from The Programmer’s Corner in
Category OS/2 Files
Control Epson printer from OS/2, use functions not supported by the OS/2 driver.
File Name File Size Zip Size Zip Type
PRINTER.DOC 7823 2988 deflated
PRINTER.EXE 13599 8506 deflated

Download File PRNTR15.ZIP Here

Contents of the PRINTER.DOC file


PRINTER Version 1.5 for OS/2
(c) Mitchell Fisher 1990

PRINTER is a utility for OS/2 that allows the user to set various setting on
the printer. This particular version will ony handle EPSON or EPSON
compatables. To get a list of commands type PRINTER without any command line
options. If you do not have an EPSON or compatable, read the message at the
bottom of the documentation file.


I started PRINTER because on my OS/2 1.2, the print manager with spooler would
only print my files uni-directional and in draft even after setting the
appropriate settings so I decided to write this program so I could see if I
could change the settings that the Print Manager produced, I couldn't. So I
disconnected the Print Manager and spooler my printer worked great!
According to IBM's System Programmers, this is common on several printers so I
knew that nothing was wrong with my system. PRINTER then allowed me to use my
Epson LX-800 to its full extent from the command line, and now I present it to
you, the users who may find a use for it.


PRINTER 1.0 was very simple. It allowed you to pass printer options to the
printer from the command line, however, it did not allow you to print a file.
PRINTER 1.3 allows you to specify a file name on the command line to print.
What PRINTER really does is it finds an option on the command line that is not
a valid command, it treats it as a filename to be printed.

PRINTER 1.3 will format the page for you by displaying the filename on
the upper left corner of the page and the current page number on the upper
right corner of the page. If you select a 80 column mode (NLQ, DRAFT) the top
header will be adjusted to fit on the page. If condensed (132 columns) are
selected, it will also be automatically adjusted. However, these options are
only selected on the command line:

PRINTER Condensed C:\SOURCE\PRINTER.C

This will be printed in condensed mode and the header on the page will print
properly. If I now enter the following command:

PRINTER C:\SOURCE\DUMP.C

The printer will not work to what I expected, the printer still is in
condensed mode since PRINTER does not initialize the printer upon startup.
Also PRINTER defaults to an 80 column header. If PRINTER does not see a
CONDENSED command on the command line, it will use 80 column calculations. To
solve the problem we need to have entered the above command like so:

PRINTER Init C:\Source\DUMP.C

The INIT command will initialize the printer and send it back into draft, 80
columns.


If you do not want page formatting (the header and automatic skip over
perferation) you must specify NO_FORMAT on the command line BEFORE the
filename to be printer. The command FORMAT is the opposite command and
PRINTER defaults to this setting but you may also specify it on the command
line as in the following example:

PRINTER Init NLQ NO_FORMAT C:\CONFIG.SYS FORMAT C:\SOURCE\TEST.C

The above example first initializes the printer, sets it into NLQ mode and
selects NO_FORMAT for Config.sys. After CONFIG.SYS has been printed, the
FORMAT command brings it back into format mode and then it prrints TEST.C.


PRINTER 1.4 corrects a problem with printing any type of formatting characters
for printf (i.e. %s, %c, etc.). The printed output would have some type
of erroneous information in place of these characters. PRINTER 1.4 also
resets the page number variable when printing multiple files.


PRINTER 1.5 corrected a bug when printing in condensed mode but the most
inportant addition is the ability to put variable options on the command
line such as a number to specify the LeftMargin size. Also, as just mentioned
a few new commands have been added, these are

LeftMargin
RightMargin
PageLength and
SkipPerf


All these commands require a second parameter to be supplied:

LeftMargin 5

I think that a few of these new commands should be explained, however, they
comply to the EPSON printer manual of the LX-800:

The Left and Right Margins work the same way as any left and right
margins would work:
LeftMargin 5 RightMargin 75 ....

The PageLength command specifies how many LINES the printed page is.
This number must be a number from 1 - 127. This command may not work
properly with FORMATted output since the FORMAT command sends a
FormFeed to the printer after a set number of lines. This will be
changed in other versions.

The SkipPerf command has changed somewhat from previous versions. In
this version, you must specify how many LINES to skip from the last
line of the printed page to the first line of the next page. Normally
this is set as follows:

SkipPerf 6

This would, on a 66 line page, print a page of 60 lines then skip to
the next page. This used to be what SkipPerf_ON in previous versions
of PRINTER was set to. Now you can change the value to whatever you
would like, however, this value does not work in conjunction with the
FORMATted ouput of this current version of PRINTER.


I have mentioned above that certain print options do not work with the
FORMATted output, however, FORMATted out will work just fine as long
as these parameters are not changed or if the printer is Initialized
before printing with the FORMAT option; FORMATted output assumes that
the page length is 66 lines and automatically sends a FormFeed after
60 lines are printed.


Also, the FORMAT option as a system default has been changed to NO_FORMAT
since I have found that more people tend to use the NO_FORMAT option more
often that FORMAT.

------------------------------------------------------------------------------

I have had a better that expected responce from this program so I will keep
on working and improving it. Expect to see a Command line and PM version
bundled under the next major version (2.0).


THE FUTURE:

As described, a PM version is in the works, however, I still plan
to Spiff up PRINTER with the following new options:

Have an ASCII configuration file so the user can create default
preferences to suit his/her needs.

Have the printer commands and escape sequences in a file as well
as memory so other printer options can be added by the user in
addition to the commands currently supported. Also, a file can
be created that will be used in place of the commands in memory
so a person with a different type of printer can create codes
and use this program instead of having the customizations hard
coded into the executable.



If you find this program useful, please send $5 to:

Mitchell Fisher
5914 W. Golden Lane
Glendale, AZ 85302


If you register you will receive PRINTER updates at no extra cost and you
will also receive the source code to the program. PRINTER is planned to be
expanded to be used as a PM program in the future fo ease of use.

IF YOU DO NOT HAVE AN EPSON PRINTER:

Please register this copy of printer and send with it a copy of your
printer escape sequences and commands and I will customize this to your
printer. There will be no additional fee for this service. Also, if
your EPSON compatable does not work well with PRINTER, please send the
printer codes and I will suit this to your printer also.


If you have any comments or new ideas please send them to the above address.


11/22/90




 December 25, 2017  Add comments

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)