home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / PASCAL / BONUS40.ZIP / TPSPL.ZIP / TPSPOOL.DOC next >
Encoding:
Text File  |  1987-12-23  |  2.6 KB  |  66 lines

  1. TPSPOOL - Simple Spooler written in Turbo Pascal 4.0
  2.  
  3. Copyright (c) 1987, Richard Sadowsky
  4.  
  5. Released to the Public Domain AS IS!
  6.  
  7. Written on or about 12/5/87
  8.  
  9. ALPHA TEST VERSION 0.6!!!  You get what you pay for.
  10.  
  11. Uses TurboPower's Turbo Professional 4.0.
  12.  
  13. This program captures printer output and saves it in a file.  The printer
  14. output is captured by trapping the BIOS interrupt 17h and hijacking the
  15. characters.
  16.  
  17. If you do not specify a number on the command line, TPSPOOL will use a large
  18. buffer.  The buffer should be large enough to store the most characters that
  19. will be written at once.  Future versions may not impose these requirements.
  20. In practice, I believe 16K, 32K, or the default of about 64K should work in
  21. most cases.  The next version will use EMS for the big buffers, freeing
  22. valuable main RAM.
  23.  
  24. In keeping with the Turbo Pascal tradition, Hex numbers may be passed on the
  25. command line by preceeding them with a $.
  26.  
  27. The program will display some text, then terminate and stay resident.  To
  28. activate, hit Alt-Tab (Alt key and Tab key at the same time).  This "hot key"
  29. toggles the spooler on and off.  When the spooler is off (the default), hitting
  30. Alt-Tab will beep and turn it on.  When the spooler is already on, typing
  31. Alt-Tab will disable the spooler and dump the buffers to the spool file.
  32.  
  33. All printer output is spooled (stored) in the disk file SPOOL01.TMP.  If a
  34. file by this name exists, it is appended, if not, it is created.  Future
  35. versions will allow other file names.
  36.  
  37. Some examples of command line options:
  38.  
  39. TPSPOOL<cr>
  40.   This would use the default (biggest possible) buffer size.
  41.  
  42. TPSPOOL $4000
  43.   This would use a 16K buffer
  44.  
  45. TPSPOOL $8000
  46.   This would use a 32K buffer
  47.  
  48. TPSPOOL 1024
  49.   This would use a 1K buffer.  This is probably too small unless you can
  50.   guarentee that only Int 17h will be used to send output to the printer.
  51.   See technical notes.
  52.  
  53.  
  54. TECHNICAL NOTES
  55.  
  56.   The most common problem experienced with this program is running
  57. it but forgetting to enable the spooler by pressing Alt-Tab.  This will
  58. cause output to go to a printer if one is attached just like normal.  If a
  59. printer isn't attached, YOU MUST ENABLE THE SPOOLER BEFORE TRYING TO PRINT.
  60.  
  61.   If a single write to the PRN device via a DOS Write Handle or Device call is
  62. larger than the specified buffer size, this program will hang.  This is why
  63. the default is almost a full 64K.  In reality, most programs send small chunks
  64. of 1K or less to the PRN device.  If the program uses Int 17h directly (like
  65. most Word Processors), any buffer size of 1K or more will work safely.  I
  66. recommend 4-16K if memory is tight, or 16-32K if it's not.