home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1992 March / Source_Code_CD-ROM_Walnut_Creek_March_1992.iso / usenet / altsrcs / 2 / 2037 / README.upm < prev    next >
Text File  |  1990-12-28  |  2KB  |  50 lines

  1. The BIOS is implemented like this:
  2.  
  3. xx00: 76 C9 00 76 C9 00 76 C9 00......
  4.  
  5. For the non-z80-literate, that is a series of HALT and RETurn from
  6. subroutine statements. HALT instructions return control to the calling
  7. (c program) routine that started the Z-80 running in the first place.
  8. By dividing the low 8 bits of the PC by 3, we can find out what BIOS
  9. routine the caller wanted, do it in C, then return.
  10.  
  11. upm takes various paramaters either on the command line or in
  12. ~/.upmrc. If specified, command line paramaters take precedence over
  13. .upmrc options. Options are in the form of dev:file, where dev is
  14. A-O, for disk devices, or TY, LP, PT, U1 or U2, for alternate physical
  15. devices. The files specified are attached to the coresponding disks or
  16. physical devices. The above identifiers corespond to these CP/M physical
  17. devices:
  18.  
  19. TY    TTY:
  20. LP    LPT:
  21. PT    PTP: PTR:
  22. U1    UC1: UL1: UP1: UR1:
  23. U2    UP2: UR2:
  24.  
  25. The CRT: device is permanently assigned to stdin/stdout. stdin/stdout
  26. are set to RAW mode, to make all keys work. The last BIOS jump table
  27. entry is non-standard, and causes the CP/M system to halt and control
  28. return to unix. The CP/M program EXIT.COM will do this.
  29.  
  30. As usual, the BAT: device is a combination of CRT: and LPT:
  31.  
  32. The default I/O byte assigns as follows:
  33.  
  34. CON:=CRT:
  35. RDR:=PTP:
  36. PUN:=PTR:
  37. LST:=LPT:
  38.  
  39. A typical command line might say:
  40.  
  41. % upm a:cpm.adrive lp:printer_file pt:copy_file
  42.  
  43. The device identifiers may be in upper-case, but the files, of course,
  44. will be literal-cased.
  45.  
  46. All device files except LP: will be fopen()ed "r+". LP: will be
  47. fopen()ed "w".
  48.  
  49. Any device not specifically assigned will act like /dev/null.
  50.