home *** CD-ROM | disk | FTP | other *** search
/ ftp.barnyard.co.uk / 2015.02.ftp.barnyard.co.uk.tar / ftp.barnyard.co.uk / cpm / walnut-creek-CDROM / DEMON / ZCPR-D-J.COM / ZCPR.DOC next >
Text File  |  1979-11-30  |  30KB  |  764 lines

  1. A Personal Note
  2. ===============
  3.  
  4. Somehow, I've managed to get by for the last 14 years using just ZCPR.
  5. But like some of you, I have fiddled with the standard ZCPR and
  6. modified it to suit my tastes.  As I added new commands or enriched old
  7. ones, I've always remained compatible with existing programs, all the
  8. BDOS replacements, and, most important of all, stayed within the 800H
  9. space allocation of the original Digital Research CCP.  Here are the
  10. fruits of my labors, I hope you enjoy this CCP replacement as much as I
  11. do.
  12.  
  13.         Don Kirkpatrick
  14.         17595 S.W. Pheasant Lane
  15.         Beaverton, Oregon 97006
  16.         <Donald.C.Kirkpatrick@tek.com>
  17.  
  18.  
  19. Introduction
  20. ============
  21.  
  22. This console replacement is designed to run under CP/M 2.2 or any of
  23. the 2.2 BDOS replacements.  It requires a Z80 or better.  If you are
  24. running DRI's CCP or older versions of ZCPR1, this program is a
  25. significant improvement.  If you are running ZCPR3, CP/M 3.0, CP/M
  26. Plus, or MP/M, this will probably be a disappointment.
  27.  
  28. If you are familiar with ZCPR3, you will recognize many of the
  29. enhancements here: comments on a command line, search path for the .com
  30. file, drive/user change with simple du:, CLEVEL3 command processing,
  31. proper SUBMIT file facility, and so on.  Nothing has been removed from
  32. DRI's CCP, only new features added.  AND IT ALL STILL FITS IN THE
  33. ORIGINAL 800H, THE SAME SPACE AS THE DIGITAL RESEARCH FIVE COMMAND
  34. CCP.
  35.  
  36. Many of the standard commands have been enhanced.  For example, TYPE
  37. and LIST now have options to turn on or off page breaks.  Moreover, the
  38. console check for abort has been improved.
  39.  
  40. Two commands have been added for use in submit files - SAK and BELL.
  41. These commands allow you to pause or ring the bell during submit file
  42. execution.
  43.  
  44. Before you install this version of ZCPR onto your boot disks, try it by
  45. running it as a .com file.  Just edit the few customizing options and
  46. assemble the source.  After you decide it really is better, load it
  47. onto your boot track and make it your standard.  Complete instructions
  48. are located at the end of this document.
  49.  
  50. The complete built-in command list is:
  51.  
  52.     DIR - directory command enhanced to list optionally all user areas
  53.     REN - standard rename command
  54.     USER- move to new user number area on same drive
  55.     SAVE- save specified number of TPA pages or records in a file
  56.     TYPE- display a file on the console with optional page break pauses
  57.     LIST- print command plus optional form feed insertion
  58.     PAGE- send form feed to list device
  59.     ERA - standard file erase command
  60.     ERAQ- file erase with confirmation query at each file
  61.     DFU - set default user number for .com search path
  62.     BELL- send a bell character to the console
  63.     SAK - pause until a key is struck on the console (Strike Any Key)
  64.     SCL - toggle multiple commands per line (Single Command on a Line)
  65.     GET - load a file into the TPA at any specified location
  66.     JUMP- process command tail and execute program at specified address
  67.     GO  - process command tail and execute program loaded at 100H
  68.     PEEK- display hexadecimal byte string starting with specified address
  69.     POKE- load hexadecimal byte string starting with specified address
  70.     BOOT- execute BIOS cold boot routine
  71.  
  72.  
  73. Filename Processing
  74. ===================
  75.  
  76. The standard ZCPR3 du: drive/user file specification has been
  77. implemented.  Any filename can be in the du:fn.ft form.  For example:
  78.  
  79.        A>era c4:junk*.*
  80.  
  81. erases files on the C drive, user area 4 without leaving drive A user
  82. 0.  When a user number is found in a filename, that user number is
  83. placed in S1 of the default FCB.  Bit 7 of S1 is set to inform the
  84. program using the FCB a user number was found.
  85.  
  86. The * in an ambiguous file name has been improved.  Now a trailing *
  87. causes the remainder of the ambiguous name to be filled with '?', not
  88. just the fn field.  For example:
  89.  
  90.        A>era c4:junk*
  91.  
  92. is the same as the example above.  Previously, junk* was defined as
  93. 'junk????.   '.  If you need the ft field blank, type 'junk*.'.  The
  94. question mark still works as a single character wild card.
  95.  
  96.  
  97. Command Line Processing
  98. =======================
  99.  
  100. The  current user number is included as part of the command prompt for
  101. all non-zero user numbers.  The prompt is of the form du>, for example
  102. A2> or B10>.  If the SUPRES equate is true, the user number is
  103. suppressed for user 0 only.
  104.  
  105. Multiple commands are typed on a single line separated by a command
  106. separator character.  Occasionally, you need to type the separator
  107. character in a command tail.  The SCL command toggles the multiple
  108. command enable.  The CMDCHR equate determines the command separator
  109. character.  A ';' has been chosen as the separator character in this
  110. distribution version.
  111.  
  112. Comments are allowed on a command line.  When the comment separator
  113. character is encountered as the first character of a command, the
  114. remainder of the line is ignored.  The COMCHR equate determines the
  115. comment separator character.  A ';' has been chosen as the separator
  116. character in this distribution version.  Here is an example containing
  117. comments and multiple commands on a single line:
  118.  
  119.    A>get 100 junk;peek 100;;this is a comment.
  120.    A>;this is also a comment.
  121.  
  122. There exists a built-in search path for transient commands.  First, the
  123. current drive/user is searched.  Next, the current drive/default user
  124. is searched.  Last, drive A/default user is searched.  The DEFUSR
  125. equate determines the default user number, currently set to user 0 in
  126. this distribution version.  The default user is temporarily changed
  127. with the DFU command.  If a drive is specified in the transient
  128. command, the current and default user areas on the specified drive are
  129. searched.  If a user number is specified, that user area on the current
  130. and default drive are searched.  If both the drive and user number are
  131. specified, no search is performed.  The same drive/user area is never
  132. searched twice.
  133.  
  134. Transient commands are always "called."  If a program terminates via a
  135. return rather than a warm boot, subsequent multiple commands on the
  136. command line are executed.  Any program exiting by a warm boot reloads
  137. ZCPR and the subsequent commands lost.
  138.  
  139. A default command can be placed in the command buffer and control
  140. passed to ZCPR for processing.  The only thing required, besides
  141. placing the command in the buffer and jumping to CPRLOC, is to
  142. initialize the command character counter at the start of the buffer.
  143. The procedure is compatible with the original DRI CCP default command
  144. processing.  If ZCPR is entered at CPRLOC+3 jump, default command
  145. processing is suppressed.  Either way, register C must contain a valid
  146. drive/user, just like the original CCP.
  147.  
  148.  
  149. Submit File Processing
  150. ======================
  151.  
  152. A basic design choice had to be made in the design of ZCPR concerning
  153. the execution of submit files. The original CCP had a problem.  It
  154. ALWAYS looked for the $$$.SUB file on drive A and the submit program
  155. would place it on the current default drive.  When the you were logged
  156. onto drive B and you issued a submit command, the $$$.SUB was placed on
  157. drive B and not executed.
  158.  
  159. After much debate it was decided to have ZCPR perform the same type of
  160. function as CCP (look for the $$$.SUB file on drive A), but the problem
  161. with SUBMIT.COM still exists.  Hence, RGF designed SuperSUB and RLC
  162. took his SuperSUB and designed SUB from it; both programs are set up to
  163. allow the selection at assembly time of creating the $$$.SUB on the
  164. default drive or on drive A.  If you don't have one of these newer
  165. submit programs, a procedure for patching the standard SUBMIT.COM has
  166. been included at the end.
  167.  
  168. The fixed drive choice permits a submit file to contain a series of
  169. commands exactly as they would be entered from a CP/M console.  This
  170. permits things like:
  171.  
  172.     A>dir
  173.     A>b:
  174.     B>dir
  175.  
  176. to be executed, even though the currently default drive is changed
  177. during execution. If the $$$.SUB file were present on the default
  178. drive, the above series of commands would not work.  ZCPR would be
  179. looking for $$$.SUB on the default drive, and switching default drives
  180. without moving the $$$.SUB file would cause processing to abort.  Note
  181. that the same problem occurs if the user number of the $$$.SUB file is
  182. not predefined. ZCPR assumes that the $$$.SUB file is located on user 0
  183. of drive A.
  184.  
  185. The trick of using the $ flag returned by the BDOS disk reset is used
  186. to speed the search for a $*.* file on drive A. This trick will not
  187. work if the $$$.SUB file were located on another drive.
  188.  
  189. The '>' prompt character is replaced by a special character while a
  190. submit file is in execution.  The SPRMPT equate defines this special
  191. character, currently set to '$' in this distribution version.
  192.  
  193.  
  194. Command Syntax
  195. ==============
  196.  
  197. Multiple commands can be placed on one line.  If the comment character
  198. is encountered where a command should start, the rest of the line is
  199. ignored.  Any command can be renamed by editing the command table.
  200. Command names can be up to eight characters long and are terminated by
  201. bit 7 high.  If there is a conflict between an internal ZCPR command
  202. and a transient program of the same name, the internal command is
  203. executed.  Type the command with the du: included if the external
  204. transient command is the one desired.  Here is a complete alphabetized
  205. list of all the resident commands with their syntax:
  206.  
  207. =============================================================================
  208.  
  209. Command:  BELL
  210.  
  211. Function: To ring terminal bell.
  212.  
  213. Forms:    BELL
  214.  
  215. Options:  None.
  216.  
  217. Uses:     This command is designed to be placed in a submit file to
  218.           ring the bell to indicate significant checkpoints.
  219.  
  220. =============================================================================
  221.  
  222. Command:  BOOT
  223.  
  224. Function: To execute BIOS cold boot routine.
  225.  
  226. Forms:    BOOT
  227.  
  228. Options:  REBOOT equate controls the inclusion/exclusion of this command.
  229.  
  230. Uses:     Reboots the system without pushing the reset button.  The
  231.           cold boot entry point in the BIOS must be supported for this
  232.           command to work.
  233.  
  234. =============================================================================
  235.  
  236. Command:  DFU
  237.  
  238. Function: To set the Default User Number for transient commands.
  239.  
  240. Forms:    DFU <usrnum>
  241.  
  242. Options:  DEFUSR equate defines the default user choice until this
  243.           command is entered.
  244.  
  245.           NUMBASE equate defines the character that specifies a
  246.           hexadecimal number.  The distribution version is set to 'H'.
  247.  
  248. Uses:     The default user area is searched after a transient command
  249.       cannot be found in the current user area.  If the transient
  250.       command still has not been found, the default user on the
  251.       default drive is searched last.  The new default user number
  252.       is in decimal, but hexadecimal numbers are entered by
  253.       appending an 'H'.  The next warm boot will restore the
  254.       original default user number.
  255.  
  256. =============================================================================
  257.  
  258. Command:  DIR
  259.  
  260. Function: To display a directory listing of the files on a drive.
  261.  
  262. Forms:    DIR <afn>       Display the DIR files
  263.           DIR <afn> S     Display the SYS files
  264.           DIR <afn> B     Display both DIR and SYS files
  265.           DIR <afn> A     Display both DIR and SYS files for all user areas
  266.  
  267. Options:  TWOCOL equate controls the number of columns in the display.
  268.           Forty-column terminals are limited to two-column displays.
  269.  
  270.           WIDE equate controls the spacing between the columns and
  271.           change the horizontal width of a directory display.
  272.  
  273.           FENCE equate specifies the character separator between the
  274.           directory columns.
  275.  
  276.           USRDLM equate specifies the character between the user number
  277.           and the filename.
  278.  
  279.           USRFLG, SYSFLG, and SOFLG equates specify the command line
  280.           tail character that control the display of system and
  281.           non-system files.
  282.  
  283. Uses:     Displays a directory listing of files in specific drive/user
  284.           area.
  285.  
  286. =============================================================================
  287.  
  288. Command:  ERA
  289.  
  290. Function: To erase files.
  291.  
  292. Forms:    ERA <afn>
  293.  
  294. Options:  None.
  295.  
  296. Uses:     Deletes files.  Names of erased files are displayed.
  297.  
  298. =============================================================================
  299.  
  300. Command:  ERAQ
  301.  
  302. Function: To erase files with individual query.
  303.  
  304. Forms:    ERAQ <afn>
  305.           <afn>? y          File erased
  306.           <afn>? <CR>       File not erased
  307.  
  308. Options:  None.
  309.  
  310. Uses:     Deletes a subset of a set of ambiguously specified files.
  311.           Any answer other than 'Y' (either case) will cause the file
  312.           to be skipped and not erased.
  313.  
  314. =============================================================================
  315.  
  316. Command:  GET
  317.  
  318. Function: To load the specified file from disk to the specified address.
  319.  
  320. Forms:    GET <hexadr> <ufn>
  321.  
  322. Options:  None.
  323.  
  324. Uses:     Loads a file into the TPA for patching purposes.  This command
  325.           searches for the specified file along the same search path as
  326.           the transient command loader.
  327.  
  328.  
  329. =============================================================================
  330.  
  331. Command:  GO
  332.  
  333. Function: To call the program in the TPA without loading from disk.
  334.  
  335. Forms:    GO <command tail>
  336.  
  337. Options:  None.
  338.  
  339. Uses:     Most useful to rerun a program already loaded into the TPA.
  340.           Saves time and wear on disk drives.  The command tail is
  341.           entered exactly as it would appear if GO were replaced by the
  342.           program name.  Same as JUMP 100H, but more convenient,
  343.           especially when used with parameters for programs like STAT.
  344.  
  345. =============================================================================
  346.  
  347. Command:  JUMP
  348.  
  349. Function: To call the program at a specified address.
  350.  
  351. Forms:    JUMP <hexadr> <command tail>
  352.  
  353. Options:  None.
  354.  
  355. Uses:     Executes code not located at 100H.  For example, JUMP 0
  356.           warm boots.  The code must already reside at the specified
  357.           address.
  358.  
  359. =============================================================================
  360.  
  361. Command:  LIST
  362.  
  363. Function: To print specified file on list device.
  364. -
  365. Forms:    LIST <ufn>      Print file
  366.           LIST <ufn> P    Print file without default paging
  367.  
  368. Options:  NLINEP equate determines the number of lines per page.
  369.  
  370.           FFKILL equate controls the suppression of form feeds before
  371.           printable text.
  372.  
  373.           PGDFLG equate determines the command line tail character that
  374.           toggles the default form feed insertion every NLINEP lines.
  375.  
  376.           NOSTAT equate controls the use of the BIOS list status call.
  377.  
  378. Uses:     Prints files with/without pagination on LST: device.  A
  379.           listing is aborted by a console ^C.  Any submit file in
  380.           process is terminated and control is returned gracefully to
  381.           the console prompt.
  382.  
  383. =============================================================================
  384.  
  385. Command:  PAGE
  386.  
  387. Function: To eject a page on list device via a form feed.
  388.  
  389. Forms:    PAGE
  390.  
  391. Options:  NOSTAT equate controls the use of the BIOS list status call.
  392.  
  393. Uses:     Sends a form feed to the LST: device.  The page eject can
  394.       be aborted by a console ^C if the system hangs because the
  395.       printer is not ready.  If aborted, any submit file in process
  396.       is terminated and control is returned gracefully to the
  397.       console prompt.
  398.  
  399. =============================================================================
  400.  
  401. Command:  PEEK
  402.  
  403. Function: To display hex values beginning at a specified address.
  404.  
  405. Forms:    PEEK <hexadr> [<hexcnt>]
  406.  
  407. Options:  None.
  408.  
  409. Uses:     Displays hexadecimal values anywhere in the entire address
  410.           space.  The maximum value for <hexcnt> is 0FFH, but the
  411.           default <hexcnt> is 256.
  412.  
  413. =============================================================================
  414.  
  415. Command:  POKE
  416.  
  417. Function: To poke a string of hex values into a set of consecutive
  418.           addresses.
  419.  
  420. Forms:    POKE <hexadr> <hexval> [...<hexval>]
  421.  
  422. Options:  None.
  423.  
  424. Uses:     Modifies values anywhere in the entire address space.  Each
  425.           <hexval> represents one byte and is separated from the next
  426.           by a space.  The number of <hexval> are limited only by the
  427.           size of the command line buffer. The address is incremented
  428.           for each <hexval>.  Excellent for hand patching code.
  429.  
  430. =============================================================================
  431.  
  432. Command:  REN
  433.  
  434. Function: To change the name of an existing file.
  435.  
  436. Forms:    REN <newufn>=<oldufn>
  437.           REN <newufn>=<oldufn>     Existing <newufn>
  438.           Delete? y                 File deleted
  439.  
  440. Options:  None.
  441.  
  442. Uses:     Changes the names of files.  Any du: on <oldufn> is ignored;
  443.           the optional du: is on <newufn>.  If there already exists a
  444.           <newufn>, the console is queried for conformation.  Any
  445.           response except 'Y' (either case) aborts the command, kills
  446.           any submit file in process, and returns gracefully to the
  447.           command prompt.
  448.  
  449. =============================================================================
  450.  
  451. Command:  SAK
  452.  
  453. Function: To pause until a key is struck.
  454.  
  455. Forms:    SAK
  456.           ? <any key>
  457.  
  458. Options:  None.
  459.  
  460. Uses:     Pauses a submit file until a keystroke is entered.  Any
  461.       character other than a ^C will resume execution.  A ^C kills
  462.       the submit file, any commands remaining on the command the
  463.       line are ignored, and control returns gracefully to the
  464.       prompt.
  465.  
  466. =============================================================================
  467.  
  468. Command:  SAVE
  469.  
  470. Function: To save the contents of TPA onto disk as a file.
  471.  
  472. Forms:    SAVE <Number of Pages> <ufn>
  473.           SAVE <Number of Records> <ufn> R
  474.  
  475. Options:  RECFLG equate determines the command tail character that
  476.           specifies records rather than pages.
  477.  
  478.           NUMBASE equate defines the character that specifies a
  479.           hexadecimal number.  The distribution version is set to 'H'.
  480.  
  481. Uses:     Saves the TPA to a file.  Records are 128 bytes long, pages
  482.       are 256 bytes long.  Number of pages or records is in
  483.       decimal, but a hexadecimal number is entered by appending an
  484.       'H'.  Saved area begins at 100H.
  485.  
  486. =============================================================================
  487.  
  488. Command:  SCL
  489.  
  490. Function: To force ZCPR to parse only a single command per line.
  491.  
  492. Forms:    SCL
  493.  
  494. Options:  MULTPL equate determines the inclusion/exclusion of this
  495.           command and whether or not multiple commands are allowed.
  496.  
  497.           CMDCHR equate determines the character separating multiple
  498.           commands.
  499.  
  500. Uses:     Some transient commands require the command separator in the
  501.           command tail.  This command turns off multiple command
  502.           parsing so the entire command tail is sent to the transient
  503.           program.  Multiple command format is reset at the next warm
  504.           boot. SCL toggles.
  505.  
  506. =============================================================================
  507.  
  508. Command:  TYPE
  509.  
  510. Function: To display specified file on console.
  511.  
  512. Forms:    TYPE <ufn>      Display file
  513.           TYPE <ufn> P    Display file without default paging
  514.  
  515. Options:  NLINES equate determines the number of lines per screen.
  516.  
  517.           FFKILL equate controls the suppression of form feeds before
  518.           printable text.
  519.  
  520.           PGDFLG equate determines the command line tail character that
  521.           toggles the default form feed insertion every NLINEP lines.
  522.  
  523. Uses:     Displays files with/without pagination on CON: device.  A
  524.           display is aborted by a console ^C.  If aborted, any submit
  525.           file in process terminates and control returns gracefully to
  526.           the console prompt.  When page breaks are enabled, any
  527.           console character except ^C will display the next page of
  528.           text.
  529.  
  530. =============================================================================
  531.  
  532. Command:  USER
  533.  
  534. Function: To change current user number.
  535.  
  536. Forms:    USER <usrnum>
  537.  
  538. Options:  SUPRES equate controls the display of the user number in the
  539.           prompt when the user number is zero.
  540.  
  541.           MAXUSR equate controls the maximum allowable user number.
  542.  
  543.           NUMBASE equate defines the character that specifies a
  544.           hexadecimal number.  The distribution version is set to 'H'.
  545.  
  546. Uses:     This command changes the current user number.  The new user
  547.           number is in decimal, but a hexadecimal number is entered by
  548.           appending an 'H'.  This command has been retained for
  549.           compatibility purposes only.  It is far easier to change
  550.           disk/user by typing du:.
  551.  
  552. =============================================================================
  553.  
  554.  
  555. Error Messages
  556. ==============
  557.  
  558. If any error is encountered as a command line is being parsed, a
  559. message will be printed and, for serious errors, the remainder of the
  560. line is ignored.  Below is a complete list of all ZCPR error messages.
  561. Any error message encountered that is not on this list came from some
  562. program other than ZCPR.
  563.  
  564. "?"
  565.  
  566.    An error was detected in the command.  The an item on the command
  567.    line was not what was expected.  The command line is echoed up to
  568.    the position where the error was detected, as close as can be
  569.    determined, and the "?" printed.  Any commands remaining on the
  570.    command the line are ignored and any $$$.SUB file erased.
  571.  
  572. "Full"
  573.  
  574.    If ZCPR was attempting to load a transient program, one of two
  575.    things has gone wrong: either the program is so large that it won't
  576.    fit into the TPA or a read error was returned from the BDOS.  If
  577.    ZCPR was attempting to save a file, the BDOS write call returned
  578.    failure. Either the disk or the directory is full.  Any commands
  579.    remaining on the command line are ignored and any $$$.SUB file
  580.    erased.
  581.  
  582. "No File"
  583.  
  584.    No file could be found matching the filename specified in the
  585.    command.  This message is also be printed if the BDOS read command
  586.    returns failure.  If ZCPR was looking for a transient command, any
  587.    commands remaining on the command line are ignored and any $$$.SUB
  588.    file erased.
  589.  
  590. "Name Error"
  591.  
  592.    The specified filename has a user number larger than the allowable
  593.    maximum or an ambiguous filename was entered where only an
  594.    unambiguous filename is permitted.  Any commands remaining on the
  595.    command line are ignored and any $$$.SUB file erased.
  596.  
  597. "Delete?"
  598.  
  599.    Not really an error, but there already exists a file with the same
  600.    name as the requested new name in the REN command.  Any response
  601.    except 'Y' (either case) aborts the command, any commands remaining
  602.    on the command line are ignored, and any $$$.SUB file erased.
  603.  
  604. "All?"
  605.  
  606.    Not really an error, but a check to verify that all files on the
  607.    drive/user area are to be erased.  Any response except 'Y' (either
  608.    case) aborts the command and any commands remaining on the command
  609.    line are ignored.
  610.  
  611.  
  612. Installation Instructions
  613. =========================
  614.  
  615. 1) The first task is to determine the location of your BDOS because you
  616.    MUST set the P2DOS equate to this value.  If you do not know the
  617.    location of your BDOS, use ZCPRDEMO to find it.  If you do not
  618.    already have ZCPRDEMO.COM, assemble ZCPR with the TEST equate true
  619.    to make it.  A bootstrap loader will be included and you can run the
  620.    .com file.  This program assembles without errors using Microsoft's
  621.    M80/L80:
  622.  
  623.    A>m80 =zcpr
  624.    A>l80 zcpr,zcprdemo/n/e
  625.  
  626.    Other assemblers can be used, but ZCPR.MAC will probably require
  627.    editing to convert it to a form compatible.  The major decision in
  628.    converting is to determine how the .PHASE pseudo is to be handled.
  629.    Probably the best solution to the .PHASE is to generate a .hex
  630.    file and load it with an offset using DDT/SID/ZSID.  Consult the
  631.    "r" command in the DDT/SID/ZSID manaul.
  632.  
  633.    Run ZCPRDEMO and peek at low memory:
  634.  
  635.    A>zcprdemo
  636.    A<peek 0 10
  637.    0000 C3 03 F2 00 00 C3 06 E4 00 00 00 00 00 00 00 00
  638.    A<^C
  639.  
  640.    Notice the prompt character has changed from a '>' to a '<'.  This
  641.    tells you the special debug version of ZCPR is running.  See the
  642.    debug section at the end for details.  Address 0 contains a jump 3
  643.    beyond the start of the BIOS and address 5 contains a jump 6 beyond
  644.    the start of the BDOS.
  645.  
  646.    Be careful if you attempt to execute a transient program from
  647.    ZCPRDEMO.  Some transient programs, like NSWP, return rather than
  648.    warm boot when done. These programs don't know that ZCPRDEMO is at
  649.    address 8000H rather than just under the BDOS.  If they overwrite
  650.    ZCPRDEMO, then the return is to random code. Of course, this is not
  651.    a problem when ZCPR is installed just under the BDOS.
  652.  
  653. 2) You MUST edit the code to place your BDOS/P2DOS/Z80DOS/ZRDOS start
  654.    address in the P2DOS equate.  Set COMLD true (and TEST false if you
  655.    set it true in step 1 above) and make ZCPR.COM.  A bootstrap loader
  656.    will be included.
  657.  
  658.    Assuming you successfully assemble it, just type "zcpr" to run it.
  659.    However, every time there is a warm boot, it will be  replaced by
  660.    the boot track CCP.  If you like what you see, place a copy on the
  661.    boot track to make it available all the time.
  662.  
  663. 3) Reassemble, this time with COMLD false to make ZCPRNBLD.COM (ZCPR
  664.    No Boot LoaDer).  
  665.  
  666. 4) Run SYSGEN to load a copy of the boot track into memory.
  667.  
  668.    B>; Sample terminal session for integrating ZCPR
  669.    B>sysgen
  670.    SYSGEN VER 2.2
  671.    SOURCE DRIVE NAME (OR RETURN TO SKIP)a
  672.    SOURCE ON A, THEN TYPE RETURN  <cr>
  673.    FUNCTION COMPLETE
  674.    DESTINATION DRIVE NAME (OR RETURN TO REBOOT)  <cr>
  675.  
  676.  
  677. 5) Run SAVE to save a track image to a file (eg: SAVE 32 BOOTFILE).
  678.    The number on the save command depends on the size of your boot
  679.    track loader; it can be as small as 31 and as large as 44.  If you
  680.    have extra disk space or are not sure, play it safe and use 44.
  681.  
  682.    B>save 44 cpm56.com      <-- We now have a SYSGEN image of CP/M
  683.  
  684. 6) Find the location of the stock CCP by peeking at the boot file. It
  685.    is normally located at address 980H in the file. Using ZCPR:
  686.  
  687.    B>zcpr                   <-- Reload zcpr.com version
  688.    B>get 100 cpm56.com
  689.  
  690.    and search for the start of the console processor:
  691.  
  692.    B>peek 980
  693.    0980 C3 xx xx C3 xx xx 7F 00 43 4F 50 59 52 49 47 48
  694.    0990 54 20 ...
  695.  
  696.    If you don't find the start of the CCP at 980H, don't be
  697.    discouraged. It is there, but at a higher address.  Keep looking.
  698.  
  699. 7) When you find the location of the CCP, patch it with the new ZCPR
  700.    image.
  701.  
  702.    B>get 980 zcprnbld.com
  703.  
  704. 8) Place the new file onto the boot track of a test disk, not your
  705.    original, using SYSGEN, and try it out.
  706.  
  707.    B>sysgen
  708.    SYSGEN VER 2.2
  709.    SOURCE DRIVE NAME (OR RETURN TO SKIP) <cr>      <-- Use memory image
  710.    DESTINATION DRIVE NAME (OR RETURN TO REBOOT)b   <-- Load onto drive B
  711.    DESTINATION ON B, THEN TYPE RETURN <cr>
  712.    FUNCTION COMPLETE
  713.    DESTINATION DRIVE NAME (OR RETURN TO REBOOT) <cr>
  714.  
  715.    You should now have a ZCPR system boot disk.  Notice you did all
  716.    your work on drive B so you wouldn't destroy the original.
  717.  
  718.  
  719.  
  720. This may seem like a great number of steps, but each is only a single
  721. CP/M command line, total time is only 5 minutes or so after you get
  722. ZCPR to run as a .com file.
  723.  
  724.  
  725. Debugging ZCPR
  726. ==============
  727.  
  728. Special provisions have been make to ease the debugging of ZCPR.
  729. Setting the TEST equate true causes the assembler to build a version of
  730. ZCPR that executes in the TPA.  This allows the use of a debugger like
  731. DDT, ZSID, or Z8E to load and monitor execution.  To identify the debug
  732. version, the prompt character is changed from '>' to '<' when it runs.
  733.  
  734. CPRLOC for the test version is 8000H.  A bootstrap loader is included
  735. at the beginning to move the image to this address.  Do not try to set
  736. a breakpoint until after the loader has moved ZCPR.  The easiest way to
  737. accomplish this is to single-step through the loader and then set your
  738. breakpoints.  Change the execution address to something lower if 8000H
  739. does not leave enough space for the debugger.
  740.  
  741. A small amount of code is also added at the end of the debug version to
  742. compute the BIOS list status and cold boot entry points at run time.
  743. This permits the demo version to execute properly without setting the
  744. BDOS location equate.
  745.  
  746. Patching SUBMIT.COM
  747. ===================
  748.  
  749. SUBMIT.COM is patched to run with ZCPR by the following procedure.
  750. This is recommended if the user does not have one of the newer public
  751. domain versions of submit.  This patch simply makes SUBMIT.COM always
  752. place the $$$.SUB file on drive A.  Illustrative terminal session
  753. follows:
  754.  
  755.   A>get 100 submit.com;peek 5bb 2
  756.   05BB 00 24              <-- Patch is at 5BB Hex
  757.   A>poke 5bb 1            <-- Change 0 (default drive) to 1 (drive A)
  758.   A>peek 5b0 20           <-- Let's check just to make sure
  759.   05B0 00 00 00 00 00 00 30 30 31 20 24 01 24 24 24 20
  760.   05C0 20 20 20 20 53 55 42 00 00 00 1A 1A 1A 1A 1A 1A
  761.   A>save 5 newsubmt.com   <-- Save new SUBMIT.COM file
  762.  
  763. Pretty simple, huh?
  764.