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 / ZSYS / ZNODE-12 / I / ITOZ14.LBR / ITOZCF.ZZ0 / ITOZCF.Z80
Text File  |  1992-04-05  |  6KB  |  188 lines

  1. ; ITOZCF.Z80
  2. ;
  3. ; ZCNFG configuration module for ITOZ.COM.  The assembled version of
  4. ; this file must be named ITOZxx.CFG, where xx is the version number
  5. ; of ITOZ, to be automatically recognized by ZCNFG.
  6. ;
  7. ; Version 1.0 -- April 5, 1992 -- Gene Pizzetta
  8. ;    For ITOZ 1.4.
  9. ;
  10. ; Patch locations . . .
  11. ;
  12. AstFlg    equ    018h        ; replace asterisks
  13. ClnFlg    equ    019h        ; add colons
  14. DbFlag    equ    01Ah        ; pseudo-op flag
  15. QtFlag    equ    01Bh        ; quiet mode
  16. AbtFlg    equ    01Ch        ; abort error flag
  17. ;
  18. ; ZCNFG function definitions . . .
  19. ;
  20. Switch    equ    0        ; toggle bit n in a byte (n is specified)
  21. Text    equ    1        ; edit text with UC conversion
  22. DUSpec    equ    2        ; replace a ZCPR style DU spec (NOT DIR:!)
  23. HexRad    equ    3        ; edit byte/word using HEX radix
  24. DecRad    equ    4        ; edit byte/word using DECIMAL radix
  25. TextLC    equ    5        ; edit text, both UC and LC
  26. FileSp    equ    6        ; edit a Z3 filespec or filespec fragment
  27. Togl3    equ    7        ; toggle one of three options: 001B, 010B, 100B
  28. ToglTF    equ    8        ; toggle a byte between 0ffh and 0
  29. ASCIIC    equ    9        ; replace any ASCII byte with a keystroke
  30.  
  31. ;
  32. ; ASCII characters . . .
  33. ;
  34. HON    equ    1        ; highlight on
  35. HOF    equ    2        ; highlight off
  36. TAB    equ    9        ; tab
  37. LF    equ    10        ; linefeed
  38. CR    equ    13        ; carriage return
  39. ;
  40. ; Macro definitions
  41. ;    C    = character to identify menu item
  42. ;    OFFSET    = offset in program's configuration block
  43. ;    FUNC    = ZCNFG function
  44. ;    SCRN    = screen location for data
  45. ;    DATA    = function data address (if required)
  46. ;
  47. CASE    macro    c,func,offset,bytes,scrn,data
  48.     db    '&C'
  49.     dw    func, offset
  50.     db    bytes
  51.     dw    scrn, data
  52.     endm
  53. ;
  54. ; Code . . .
  55. ;
  56.     rst    0        ; for safety, so .CFG file won't execute
  57. ;
  58.     dw    MenuA        ; for relocation of addresses, this
  59.                 ; ..points to the NEXT location.
  60. ;
  61. ; Menu list section . . .
  62. ;
  63. MenuA:    dw    MenuA, MenuA, ScrnA, CaseA, HelpA    ; single menu
  64. ;
  65. ; Case table section . . .
  66. ;
  67. CaseA:    db    (CaseAX-CaseA1)/(CaseA2-CaseA1)    ; number of cases
  68.     db    CaseA2-CaseA1    ; length of each record
  69. ;
  70. ;    Macro name
  71. ;    |    Single char menu selector
  72. ;    |    |    Function (see above)
  73. ;    |    |    |    Offset in config block
  74. ;    |    |    |    |    Number of bytes
  75. ;    |    |    |    |    |    Screen location
  76. ;    |    |    |    |    |    |
  77. ;Case1:    CASE    0,    ToglTF,    Loc1,    1,    ScrnA1,    NoYes
  78. ;                            |
  79. ;             Address of data used by function
  80. ;
  81. ; The first two entries in table are labeled for calculation at CaseA:.
  82. ;
  83. CaseA1:    CASE    A,    ToglTF,    AstFlg,    1,    ScrnA1,    YesNo
  84. CaseA2:    CASE    C,    ToglTF,    ClnFlg,    1,    ScrnA2,    YesNo
  85.     CASE    P,    ToglTF,    DbFlag,    1,    ScrnA3,    YesNo
  86.     CASE    Q,    ToglTF,    QtFlag,    1,    ScrnA4,    YesNo
  87.     CASE    X,    ToglTF,    AbtFlg,    1,    ScrnA5,    YesNo
  88. CaseAX:                ; for calculation of list length
  89. ;
  90. ; Case table support . . .
  91. ;
  92. YesNo:    db    'Yes',0        ; displayed if value is FFh (ToglTF)
  93.     db    ' No',0        ; displayed if value is 00h (ToglTF)
  94. ;
  95. ; Screen image section . . .
  96. ;
  97. ScrnA:    db    cr,lf,lf,tab,tab,tab,' ITOZ Configuration Menu'
  98.     db    cr,lf,lf,lf
  99. ;
  100.     db    tab,'     (A) ',1,'Replace asterisks with semi-colons?  . . ',2
  101. ScrnA1:    db    '   '        ; current value
  102.     db    cr,lf,lf
  103. ;
  104.     db    tab,'     (C) ',1,'Add colons after labels? . . . . . . . . ',2
  105. ScrnA2:    db    '   '        ; current value
  106.     db    cr,lf,lf
  107. ;
  108.     db    tab,'     (P) ',1,'Pseudo-ops: DB instead of DEFB, etc.?  . ',2
  109. ScrnA3:    db    '   '        ; current value
  110.     db    cr,lf,lf
  111. ;
  112.     db    tab,'     (Q) ',1,'Quiet mode by default? . . . . . . . . . ',2
  113. ScrnA4:    db    '   '        ; current value
  114.     db    cr,lf,lf
  115. ;
  116.     db    tab,'     (X) ',1,'Invoke error handler for user abort? . . ',2
  117. ScrnA5:    db    '   '        ; current value
  118.     db    cr,lf
  119. ;
  120.     db    lf,lf,lf,lf    ; fill rest of screen
  121. ;
  122.     db    0        ; terminator
  123. ;
  124. ; Help screen section . . .
  125. ;
  126. ; Sample help screen for Menu A.  The following, up to the terminating
  127. ;  binary 00, appears as-is when the user types "?" or "/" for help while
  128. ;  ZCNFG is displaying the initial patch menu.
  129. ;
  130. HelpA:    db    CR,LF
  131. ;
  132.     db    HON,'Option A  --  Replace  asterisks  with  semi-colons.',HOF
  133.     db    '  Asterisks  delimiting',CR,LF
  134.     db    'comments will be replaced with semi-colons by default '
  135.     db    'if "Yes" is selected.',CR,LF
  136.     db    'Otherwise, asterisks  will  be left where they are found. '
  137.     db    ' The command line',CR,LF
  138.     db    '"A" option will toggle the default chosen here.'
  139.     db    CR,LF,LF
  140. ;
  141.     db    HON,'Option C -- Add colons after labels.',HOF,'  Select '
  142.     db    ' "Yes" if you want ITOZ to add',CR,LF
  143.     db    'a colon after labels which don''t already have one.  '
  144.     db    'If want  the  labels to',CR,LF
  145.     db    'remain the  way  they  are  found,  choose "No".  The '
  146.     db    'default can always be',CR,LF
  147.     db    'toggled by using the "C"  option  on  the command line. '
  148.     db    ' Labels for equates',CR,LF
  149.     db    'and macros never have colons and are not affected by '
  150.     db    'this option.'
  151.     db    CR,LF,LF
  152. ;
  153.     db    HON,'Option P -- Pseudo-ops.',HOF,'  "No" here forces '
  154.     db    'ITOZ to output the standard Zilog',CR,LF
  155.     db    'pseudo-ops for data (DEFB,  DEFW,  DEFS,  and DEFL), '
  156.     db    'for conditionals (COND',CR,LF
  157.     db    'and ENDC), and for included files (INCLUDE).  If "Yes" '
  158.     db    'is chosen,  the more',CR,LF
  159.     db    'common Intel  pseudo-ops  (DB, DW, DS, ASET, IF, ENDIF, '
  160.     db    'and MACLIB) will be',CR,LF
  161.     db    'used.'
  162.     db    CR,LF
  163. ;
  164.     db    ':',CR,LF
  165.     db    HON,'Option Q -- Quiet mode.',HOF,'  If the  ZCPR3  quiet '
  166.     db    'flag is set, ITOZ defaults to',CR,LF
  167.     db    'quiet mode.  With the quiet flag  off  the  default  '
  168.     db    'ordinarily  is verbose',CR,LF
  169.     db    'operation.  If "Yes"  is  selected  here,  the default '
  170.     db    'will always be quiet',CR,LF
  171.     db    'mode, regardless  of  the  quiet  flag.  Whatever  the '
  172.     db    ' default,  it can be',CR,LF
  173.     db    'toggled with the command line "Q" option.'
  174.     db    CR,LF,LF
  175. ;
  176.     db    HON,'Option X -- Error  for  user  abort.',HOF,'  Select '
  177.     db    ' "Yes"  if  you want the error',CR,LF
  178.     db    'handler invoked when ITOZ is  aborted  with  ^C.  This '
  179.     db    ' setting  will allow',CR,LF
  180.     db    'aborting an  active  ZEX  or  SUB  batch operation.  '
  181.     db    'While that can be very',CR,LF
  182.     db    'useful, some people might find the feature irritating.'
  183.     db    CR,LF
  184. ;
  185.     db    0        ; terminator
  186. ;
  187.     end
  188.