; FLCF.Z80 ; ; ZCNFG configuration module for FL.COM. The assembled version of ; this file must be named FLxx.CFG, where xx is the version number ; of FL, to be automatically recognized by ZCNFG. ; ; Version 1.0 -- January 12, 1992 -- Gene Pizzetta ; For FL 1.0. ; ; Patch locations . . . ; SysFlg equ 015h ; system files FOFlg equ 016h ; file output PagFlg equ 017h ; screen paging QtFlag equ 018h ; quiet mode FLdu equ 019h ; include DU's FLDir equ 01Ah ; file output directory CasFlg equ 01Bh ; case flag AbtFlg equ 01Ch ; abort error flag ConDiv equ 01Dh ; console column divider OutFn equ 01Fh ; filename for listfile ; ; ZCNFG function definitions . . . ; Switch equ 0 ; toggle bit n in a byte (n is specified) Text equ 1 ; edit text with UC conversion DUSpec equ 2 ; replace a ZCPR style DU spec (NOT DIR:!) HexRad equ 3 ; edit byte/word using HEX radix DecRad equ 4 ; edit byte/word using DECIMAL radix TextLC equ 5 ; edit text, both UC and LC FileSp equ 6 ; edit a Z3 filespec or filespec fragment Togl3 equ 7 ; toggle one of three options: 001B, 010B, 100B ToglTF equ 8 ; toggle a byte between 0ffh and 0 ASCIIC equ 9 ; replace any ASCII byte with a keystroke ; ; ASCII characters . . . ; HON equ 1 ; highlight on HOF equ 2 ; highlight off TAB equ 9 ; tab LF equ 10 ; linefeed CR equ 13 ; carriage return ; ; Macro definitions ; C = character to identify menu item ; OFFSET = offset in program's configuration block ; FUNC = ZCNFG function ; SCRN = screen location for data ; DATA = function data address (if required) ; CASE macro c,func,offset,bytes,scrn,data db '&C' dw func, offset db bytes dw scrn, data endm ; ; Code . . . ; rst 0 ; for safety, so .CFG file won't execute ; dw MenuA ; for relocation of addresses, this ; ..points to the NEXT location. ; ; Menu list section . . . ; MenuA: dw MenuA, MenuA, ScrnA, CaseA, HelpA ; single menu ; ; Case table section . . . ; CaseA: db (CaseAX-CaseA1)/(CaseA2-CaseA1) ; number of cases db CaseA2-CaseA1 ; length of each record ; ; Macro name ; | Single char menu selector ; | | Function (see above) ; | | | Offset in config block ; | | | | Number of bytes ; | | | | | Screen location ; | | | | | | ;Case1: CASE 0, ToglTF, Loc1, 1, ScrnA1, NoYes ; | ; Address of data used by function ; ; The first two entries in table are labeled for calculation at CaseA:. ; CaseA1: CASE O, ToglTF, FOFlg, 1, ScrnA1, YesNo CaseA2: CASE D, ToglTF, FLdu, 1, ScrnA2, YesNo CASE S, ToglTF, SysFlg, 1, ScrnA3, YesNo CASE P, ToglTF, PagFlg, 1, ScrnA4, NoYes CASE Q, ToglTF, QtFlag, 1, ScrnA5, YesNo CASE F, ToglTF, FLDir, 1, ScrnA6, DftTgt CASE C, ToglTF, CasFlg, 1, ScrnA7, UpLow CASE X, ToglTF, AbtFlg, 1, ScrnA8, YesNo CASE 1, HexRad, ConDiv, 1, ScrnA9, DivRge CASE 2, FileSp, OutFn, 0, ScrnA0, 0 CaseAX: ; for calculation of list length ; ; Case table support . . . ; YesNo: db 'Yes',0 ; displayed if value is FFh (ToglTF) NoYes: db ' No',0 ; displayed if value is 00h (ToglTF) db 'Yes',0 DftTgt: db 'Target',0 db 'Logged',0 UpLow: db 'Lower',0 db 'Upper',0 DivRge: dw 20h,0FFh ; ; Screen image section . . . ; ScrnA: db cr,lf,lf,tab,tab,tab,' FL Configuration Menu' db cr,lf,lf,lf ; db tab,' (O) ',1,'Output to disk file by default? . . . . ',2 ScrnA1: db ' ' ; current value db cr,lf ; db tab,' (D) ',1,'Include DU''s in output file? . . . . . . ',2 ScrnA2: db ' ' ; current value db cr,lf ; db tab,' (S) ',1,'Include system files by default? . . . . ',2 ScrnA3: db ' ' ; current value db cr,lf ; db tab,' (P) ',1,'Page screen by default? . . . . . . . . ',2 ScrnA4: db ' ' ; current value db cr,lf ; db tab,' (Q) ',1,'Quiet mode by default? . . . . . . . . . ',2 ScrnA5: db ' ' ; current value db cr,lf ; db tab,' (F) ',1,'File output directory . . . . . . . ',2 ScrnA6: db ' ' ; current value db cr,lf ; db tab,' (C) ',1,'Case for filename screen display . . . ',2 ScrnA7: db ' ' ; current value db cr,lf ; db tab,' (X) ',1,'Invoke error handler for user abort? . . ',2 ScrnA8: db ' ' ; current value db cr,lf ; db tab,' (1) ',1,'Column divider character for console . . ',2 ScrnA9: db ' h' ; current value db cr,lf ; db tab,' (2) ',1,'Filename for file list . . . . .',2 ScrnA0: db ' ' ; current value db cr,lf ; db lf,lf,lf ; fill rest of screen ; db 0 ; terminator ; ; Help screen section . . . ; ; Sample help screen for Menu A. The following, up to the terminating ; binary 00, appears as-is when the user types "?" or "/" for help while ; ZCNFG is displaying the initial patch menu. ; HelpA: db CR,LF ; db HON,'Option O -- File list disk output.',HOF,' If you ' db 'would prefer that FL default to',CR,LF db 'screen display only, choose "No" for this option. The ' db 'default chosen here',CR,LF db 'can be toggled with the command line "O" option.' db CR,LF,LF ; db HON,'Option D -- Include DU specifications.',HOF,' ' db 'FL can include DU specifications',CR,LF db 'with each filename in the FILELIST file. Choosing "Yes" ' db 'will make that the',CR,LF db 'default. The default here can be toggled with the ' db ' "D" option on the',CR,LF db 'command line.' db CR,LF,LF ; db HON,'Option S -- Include system files.',HOF,' As distribut' db 'ed FL defaults to finding',CR,LF db 'only non-system (directory) files. A "Yes" allows FL ' db ' to always find all',CR,LF db 'files, including system files. The default set here ' db 'can be toggled with',CR,LF db 'the command line "S" option.' db CR,LF,LF ; db HON,'Option P -- Screen paging.',HOF,' FL pauses, waiting ' db ' for a keypress, each time',CR,LF db 'the screen fills, if "Yes" is selected. "No" makes the ' db ' default continuous',CR,LF db 'scrolling, which can be paused with ^S. The number of ' db 'lines on the console',CR,LF db 'screen is obtained from the environment. The chosen ' db 'default can be toggled',CR,LF db 'with the command line "P" option.' db CR,LF ; db ':',CR,LF db HON,'Option Q -- Quiet mode.',HOF,' The screen display ' db 'is not necessary for writing a',CR,LF db 'FILELIST to disk. If you prefer no display, choose "Yes". ' db ' The default can',CR,LF db 'be toggled with the command line "Q" option.' db CR,LF,LF ; db HON,'Option F -- File output directory.',HOF,' FL will ' db 'write its FILELIST file to the',CR,LF db 'currently logged (default) directory or to the target ' db 'directory (the first',CR,LF db 'one given on the command line), depending on what ' db 'you select here. Make',CR,LF db 'your choice based on your usual working habits.' db CR,LF,LF ; db HON,'Option C -- Case of filename display.',HOF,' FL ' db 'can display filenames in upper-',CR,LF db 'or lower-case, whichever you prefer. (Actually, if ' db 'lower-case is chosen,',CR,LF db 'the case of filenames is actually reversed and any lower-case' db ' filename will',CR,LF db 'be displayed in upper-case. This selection does ' db 'not affect the case of',CR,LF db 'files in the FILELIST.' db CR,LF,LF ; db HON,'Option X -- Error for user abort.',HOF,' Select ' db ' "Yes" if you want the error',CR,LF db 'handler invoked when FL is aborted with ^C. This will ' db 'allow also aborting',CR,LF db 'a ZEX or SUB batch operation. While that can be very ' db 'useful, some people',CR,LF db 'might find the feature irritating.' db CR,LF ; db ':',CR,LF db HON,'Option 1 -- Console column divider.',HOF,' By ' db ' default FL uses a vertical bar',CR,LF db '("|", 7Ch) between each column of the filename display. ' db ' You can change the',CR,LF db 'column divider to any printable character, such as a ' db 'space (20h) or even a',CR,LF db 'graphic character if your terminal uses 8-bit business ' db 'graphics.' db CR,LF,LF ; db HON,'Option 2 -- Filename for file list.',HOF,' As distribute' db 'd, FL names the file list',CR,LF db 'FILELIST (with no filetype, making it easy to spot in ' db 'a directory display).',CR,LF db 'If you would prefer another name, you can enter it here.' db CR,LF ; db 0 ; terminator ; end