[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference 7.286::atarist

Title:Atari ST, TT, & Falcon
Notice:Please read note 1.0 and its replies before posting!
Moderator:FUNYET::ANDERSON
Created:Mon Apr 04 1988
Last Modified:Tue May 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:1433
Total number of notes:10312

955.0. "Write to disk." by SUBURB::JAMESH (Left Handed People are SUPER Natural) Tue Sep 04 1990 16:32

    My program only allows me to write to the parallel port of the ST. I
    would like it to write to Disk instead. I've tried the PD people and
    they say they have no program that will redirect the output to the
    disk. My idea was to use the print spooler program in the Abacus book
    and modify it to write to disk instead of parallel port. I failed
    miserably, probably due to the fact I'm not very good at programming.
    Now we have some really good programmers who have ST's and I lay the
    challange for someone to write such a routine.
    Any takers?
    ...Howard
T.RTitleUserPersonal
Name
DateLines
955.1I'm confused...YNOTME::WALLACETue Sep 04 1990 19:2626
I'm confused... What is it that you are trying to do?

>    My program only allows me to write to the parallel port of the ST.
>    I would like it to write to Disk instead.
You mean you want to modify a program you wrote to write something to disk? If
so just can use fopen(), fprintf(), and fclose() (among other functions) in
your program.

>    they say they have no program that will redirect the output to the
>    disk.
This sounds like you are running "someone elses" program which currently
outputs to the printer port and you want the output to go to disk? There are
programs written by Moshe Braner (sp?) and others which redirect screen dumps
to go to a file on disk. If thats what you want I could dig up one of those
programs for you. For programs that send text and graphics to the printer
directly (ie: not a screen dump) you should be able to write a "shell" to
redirect the printer output to a file. I've never done this, but again I may
be able to come up with some example code if that's what you are looking for.

>    Now we have some really good programmers who have ST's and I lay the
>    challange for someone to write such a routine.
>    Any takers?
If you could explain a little more about what you want, it may be that we can
find something that already exists.

	Ray
955.2There are some decent spoolers aroundBAGELS::FELDMANJerry Feldman DTN 227-3279Tue Sep 04 1990 20:5212
    The spooler found in the Abacus books have some bugs. There are some
    good pd and commercial spoolers that allow for the output to be
    redirected to disk rather that the parallel port. Also, some of the WP
    programs come equipped with a spooler to do the same.
    
    Most pd spoolers for the ST simply buffer the output from the bios to
    the printer port. NEODESK ships with a desk accessory printer queue
    utility which does spool to disk. NEODESK is an excellent alternative
    desk top for the ST, and version 3.0 is currently shipping. 
    
    Jerry
    
955.3ExplanationSUBURB::JAMESHLeft Handed People are SUPER NaturalWed Sep 05 1990 08:0710
    Thanks both for your replies. The program I use is "PCB Designer" whic
    will only allow me to print the PCB design to a HPGL plotter. It's not
    a screen dump as line thicknesses etc are involved and output is of
    course HPGL. What I want to do is to direct the out of the plotter
    driver to a disk in HPGL format instead of to the plotter so that I can
    bring the disk to work, convert to Postscript and print on a LN03R.
    Some drafting programs e.g. later GFA Draft, gives you the choice of
    outputting to disk or printer/plotter. Not so PCB Designer. NEODESK may
    be the answer. Hope this explains better what I want. Thanks.
    ...Howard
955.4BarrelQARRY::BHAMILTONBuzz HamiltonWed Sep 05 1990 11:304
The program refered to in .1 is not limited to handling screen dumps. Barrel
redirects all output destined for the parallel port to a buffer in memory.
There is an option to write that out as-is to a file. Sounds like this will do
what you are looking for. Barrel is PD.
955.5I remembered less about BARREL than there is to remember :-)YNOTME::WALLACEWed Sep 05 1990 13:1114
Buzz was right (thanks for correcting me) about BARREL doing what you
want. Here is an excerpt from BARREL.DOC -

	"You have a printer-driver to print graphics from program X on printer
	A. But you would like to use printer B.  You have the documentation
	for both printers.  You could easily write a "post-processor" program
	that will replace one set of control chars with another.  But first
	you need a method of capturing the output for printer A in a file...

	It is all possible with the program "BARREL"."

You can copy BARREL.ARC from OLDTMR::$1$DUA8:USER2:[WALLACE.PUBLIC.ST]

	Ray
955.6ThanksSUBURB::JAMESHLeft Handed People are SUPER NaturalThu Sep 06 1990 10:395
    Magic..Thanks very much, Barrel seems to be exactly what I need. 
    I've copied (Ray, your disk is incorrectly addressed - second part) 
    and will try it out tonight or over the weekend. Challange discontinued!!!
    Cheers.
    ...Howard
955.7Att: Howard, let me know!SUOSW4::SURAUFThu Sep 06 1990 13:475
    Hi Howard,
    please let me know, if BARREL is a good tool for printing on a file.
    I have the same problems as you, but with another PRG...
    73 de Rolf, DD2FX @ DB0SAO
    
955.8SUBURB::JAMESHLeft Handed People are SUPER NaturalFri Sep 07 1990 08:015
    I tried it last night but got parity errors when reading from disk. I
    think this was my fault and I've re-copied it to a known good disk. I
    certainly sounded better!!!
    OK Rolf, I'll let you know via packet @DB0SAO.
    ...Howard
955.9It works.SUBURB::JAMESHLeft Handed People are SUPER NaturalMon Sep 10 1990 11:2623
    I tried again over the weekend and it appeared to work. I brought a
    disk to work, exported it to my account and all seemed fine. There is
    just one problem in that the prog HP2PS says there's no Postscript
    Translation for the HPGL term IW. Ah well thats another story.
    Did you get my Packet Rolf?
    In case anyones interested this is how I did the whole thing using my
    VAXstation 3100:
    1. Copy file Barrel from net to my account.
    2. Bring in a disk that was formatted using PS2FORM and a time stamp
    before 12.00 a.m. and dd.mm.yy. This is important as PCDISK rejects a
    time of e.g. 13.00 p.m.
    3. Copy from account to disk using PCDISK. (USE B: DUA2: /WRITE).
    4. Take home, de-arc and put on boot disk.
    5. When booting Atari run Barrel and set up buffer size.
    6. Print to parallel port. Nothing will appear to happen as it goes to
    barrel.
    7. Run barrel again and from the menu output to disk.
    8. ARC and UUENCODE file and bring to work, again noting the time
    stamp "feature".
    8. Export using PCDISK, UUDECODE, DE-ARC, HP2PS and print.
    Easy eh?
    ...Howard