Article View: comp.sys.atari.st
Article #35840Printer configuration
From: Greg Csullog
Date: Sun, 08 Jan 1989 22:36
Date: Sun, 08 Jan 1989 22:36
59 lines
2544 bytes
2544 bytes
CONTROL.ACC has the following dialog box to configure the ST for
printing:
-------------------
PRINTER TYPE: DOT DAISY
COLOR: B/W COLOR
PIXELS/LINE 1280 960
QUALITY DRAFT FINAL
PRINTER PORT PRINTER MODEM
PAPER TYPE FEED SINGLE
-------------------
All choices in the left column have a bit setting of 0, all on the
right have a setting of 1. Therefore, for example, 960 pixels/
line and a single sheet printer would have a register value of
001001 (this is the format used in DESKTOP.INF) or decimal 36. I
wrote the following program to check the value of the printer
configuration register - I tried setting the printer using
CONTROL.ACC and after each setting, ran the program. Everything
checked out, all settings were properly reported.
{***************************************************************}
PROGRAM set_prn ;
VAR
cfg : integer;
result : integer;
dummy : integer;
FUNCTION setprt(VAR config:integer):integer;XBIOS(33);
BEGIN
cfg := -1; {value of -1 = report status}
result := setprt(cfg);
writeln('Status:');
writeln(result);
read(dummy); {wait for keyboard input to quit}
END.
{***************************************************************}
When I added the following two lines to the program (just before
the request to check status) that is when things got really weird:
cfg := $0004;
result := setprt(cfg);
I should have been able to set the value to 4 and had 4 reported
back in the status request. However, I got 3 as the value if I ran
the code from inside the PASCAL shell. From desktop, or from the
AUTO folder, the status reported back as 2!!!! I cannot figure out
what is going on; anyone have an idea? (for the checks, no desk
accessories were installed).
Thanks to Juergen Lanzki for forwarding a binary to set the printer
for me. Juergen, do you have any idea why my Pascal code is giving me
these strange status reports for the printer configuration?????
Technical Details
Message-ID:
<8901082235.AA23978@ucbvax.Berkeley.EDU>Path:
arc1-ca.pugleaf.net!utzoo!attcan!uunet!lll-winken!ames!pasteur!ucbvax!AECLCR.BITNET!01659Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!lll-winken!ames!pasteur!ucbvax!AECLCR.BITNET!01659 From: 01659@AECLCR.BITNET (Greg Csullog) Newsgroups: comp.sys.atari.st Subject: Printer configuration Message-ID: <8901082235.AA23978@ucbvax.Berkeley.EDU> Date: 8 Jan 89 22:36:00 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 59