]> cloudbase.mooo.com Git - kermit-80.git/blame - cpxtyp.asm
Convert line endings to CP/M format (cr/lf).
[kermit-80.git] / cpxtyp.asm
CommitLineData
e58a7a25
L
1; CPXTYP.ASM\r
2; KERMIT - (Celtic for "FREE")\r
3;\r
4; This is the CP/M-80 implementation of the Columbia University\r
5; KERMIT file transfer protocol.\r
6;\r
7; Version 4.0\r
8;\r
9; Copyright June 1981,1982,1983,1984,1985\r
10; Columbia University\r
11;\r
12; Originally written by Bill Catchings of the Columbia University Center for\r
13; Computing Activities, 612 W. 115th St., New York, NY 10025.\r
14;\r
15; Contributions by Frank da Cruz, Daphne Tzoar, Bernie Eiben,\r
16; Bruce Tanner, Nick Bush, Greg Small, Kimmo Laaksonen, Jeff Damens, and many\r
17; others.\r
18;\r
19; This is the header file for building the system-dependent overlay\r
20; for KERMIT. It contains the definitions used to select the target\r
21; system, and collects (via INCLUDE or LINK directives) the remaining\r
22; code. If the target system is one of the supported systems\r
23; described below, then this is the only file that needs to be\r
24; edited.\r
25;\r
26; revision history:\r
27;\r
28;edit 34, 10-Jan-1991 by MF. Put in "terminal required" notation for\r
29; more machines that need terminals.\r
30;edit 33, 9-Jan-1991 by MF. Put in "terminal required" notation for Access\r
31; Matrix and eliminated an extra "sysfam set FALSE" when torfam set TRUE\r
32;edit 32, 7-Jan-1991 by MF. Added code by Jay. S. Rouman to support the\r
33; Ampro Little Board (see CPXBBI.ASM).\r
34; Also put in a couple of missing .printx's\r
35;edit 31, 2-Nov-1990 by MF. Moved overlay address to 7000H.\r
36;edit 30, 14-Sep-1990 by MF. Added INCOMPLETE-FILE flag for SET\r
37; INCOMPLETE-FILE\r
38;edit 29, 11-Sep-1990 by MF. Moved overlay address for version 4.10.\r
39; to 6C00H.\r
40; edit 28, 1st September 1990 by Russell Lang, rjl@monu1.cc.monash.edu.au\r
41; Added support for MicroBee (CPXBEE.ASM).\r
42;\r
43; edit 27, 28-Aug-89 by Mike Freeman, Bonneville Power Administration,\r
44; P.O. Box 491, Vancouver WA 98666 USA: add support for Hewlett-\r
45; Packard HP-125 "Business Assistant" computer using a HP-modified\r
46 ;CP/M Version 2.2.\r
47;\r
48; edit 26, 2 December, by OBSchou. Added code for CP/M-80 Kermit to\r
49; run on an IBM-PC under Z80MU. Perverse?? No, its to allow testing\r
50; of independent code on a PC running CP/M kermit.\r
51;\r
52; edit 25, 27 October, 1987 by OBSchou. Merged in Sanyo, CompuPro, Genie\r
53; and TRS Model 4 code, and added four new families.\r
54; CPXSYO.ASM for the Sanyo, CPXPRO.ASM for the Compupro,\r
55; CPXTRS.ASM for the TRS-80 Model 4, CPXGNI.ASM for the Genie.\r
56; Many thanks to G. Smith for these latter two systems. Also\r
57; added the WYSE 100 Terminal type to the VDU table.\r
58;\r
59; edit 24, 17 July, 1987 by OBSchou. Added (hopefully) code from\r
60; CP/M Kermit 3.5 (WOW) for the Heath 8. (h8quad) The actual code\r
61; has been put into the CPXHEA.ASM family file, but I do not actually\r
62; *KNOW* if this new version works. Anyone willing to test it out??\r
63;\r
64; edit 23 16 July, 1987 for for Will Rose:\r
65; edit of 15 Jan 1987 by C W Rose\r
66; Added code for Micromint SB180 and Ampro 230 terminal.\r
67;\r
68; edit of 10 Apr 87 by C W Rose\r
69; Amended code for pci2651 to handle Telecom Merlin M2215.\r
70; (8085 at 5 MHz, 2651 USART, port TTY1:, Ampro 230 terminal equivalent).\r
71; \r
72; edit of 13 Jul 1987 by C W Rose\r
73; Added Micromint SB180 with 6/9 MHz. option.\r
74;\r
75; edit 22, 15th July, 1987 by OBSchou for David Moore. \r
76; David submitted a paper copy of Kermit 4.05 overlay for a Teletek\r
77; system: I have (hopefully) correctly appended his code. He also\r
78; send in the code for ADM 22 terminals.\r
79;\r
80; edit 21, 14 July, 1986 by OBSchou for John Shearwood of Birmingham \r
81; University. His edits:\r
82; edit of Apr 7th, 1987 by JA Shearwood. Added entry for Cifer Aux port\r
83; edit of Mar 24 1987 by JA Shearwood, Birmingham. Added code for Cifer\r
84; 1886 with CP/M Plus\r
85;\r
86; Also added in code from Chris Miles:\r
87; edit of 19 May 26, 1987 by C.J.MILES@UMRCC.\r
88; Kaypro II, Xerox 820 and Big Board II code seperated\r
89; from CPXSYS.ASM and put in a new family file called\r
90; CPXBBI.ASM.\r
91;\r
92; Finally added code from MJ Carter of Nottingham University:\r
93; edit 16a of 5th Mar 1987 by M J Carter, Nottingham Uni [majoc], to add\r
94; entry for OEM ScreenTyper (scntpr). See also CPXFRK.ASM ("fork"),\r
95; the tail end of CPXLNK.ASM, and the Heath-Zenith family file\r
96; CPXHEA.ASM (heath, z100, telcon, and scntpr).\r
97;\r
98; [Note: Martins CPXFRK is another version of CPXSWT.ASM]\r
99;\r
100;\r
101; edit 20, 21 May 1987 by OBSchou for Colin Burns of the Institute \r
102; of Neurological Sciences, Glasgow. Added flag for Hazeltine 1500\r
103; VDU (h1500)\r
104;\r
105; edit 19, 6th April, 1987 by OBSchou.\r
106; Added in EQUs for Amstrad 664 and 6128 machines (CPC) and NCR\r
107; Decsision mate V, bot sets of code submitted by Chris Miles of\r
108; Manchester University. NCR code is similar to the PCI2651 code, so\r
109; NCRDMV chains to CPXTOR.ASM. CPC cahins to the modified CPXPCW file\r
110; as submitted by Chris. *** NOTE *** All Amstrad versions require\r
111; CP/M 3, so the 664 version must both have the system upgraded to \r
112; CP/M 3 and have an aditional RAM pack. All Amstrad systems require\r
113; a serial interface.\r
114;\r
115; edit 18, 30 March, 1986. OBSchou.\r
116; * * * Here Begineth kermit-80 Version 4.09 * * *\r
117;\r
118; Biggest change is the overlay address has been moved (again) to 6000h\r
119; and the files have all been diced into families. M80 (almost) back \r
120; in, though I have found some bugs. Will worry about those later.\r
121; CPXSYS.ASM (CP4SYS.ASM in V4.05) now is a family file as well. \r
122;\r
123; Comments and all that would be much appreciated.\r
124;\r
125; Bertil Schou,\r
126; The Computer Centre,\r
127; Loughborough University of Technology, \r
128; Loughborough\r
129; Leicestershire, LE11 3TU\r
130; Great Britain\r
131;\r
132; tel (0509) 222313\r
133; E-Mail (Janet) OBSchou at LOUGHBOROUGH.MULTICS\r
134;\r
135;\r
136; edit 17, March 15, by OBSchou to add in support for M80 Macro Assembler.\r
137; Now its a little messy using the M80 Assembler,asn we have family files\r
138; and how are we gonna tell M80 what files to use?\r
139; Sort of Simple: we generate a set of EQUs that only INCLUDE the family\r
140; file being assembled. I hope.\r
141;\r
142; edit 16 Dec 1st, 1986 by OBSchou. Added entry for Amstrad PCW range (PCW)\r
143; Code in Family file CPXPCW.ASM, submitted by Ian Young of Lattice \r
144; Logic Systems.\r
145;\r
146; Edit 15 June 20 1986. Had to chand org address to 5000h to give room for\r
147; multi-fcb space for DIR command and other additions in the system\r
148; indepentent part. This starts Kermit-80 version 4.08...\r
149;\r
150; Edit 14: March 20, 1986 by OBSchou Loughborough University for \r
151; B Robertson, Aberdeen Univ. Computing Centre.\r
152; Add support for APPLE II with serial cards based on the 6850 ACIA.\r
153; Mod 380Z support to allow both MDS (5 1/4" discs) and FDS (8" discs)\r
154; configurations. Any mistakes on this merge all my fault (OBSchou)\r
155;\r
156; edit 13 22 April, 1986 by OBSchou Loughborough University\r
157; Changed org address to 4000h to allow for mods to the system\r
158; independent part for kermit version 4.06\r
159;\r
160; edit 12 5 Febuary, 1986 by OBSchou\r
161; merged in conditionals for Epson PX8 (px8). Code from Tony Addyman\r
162; Salford University, England.\r
163; Added code from other contibutors for Basic Northstar (basicns), \r
164; Access-Matrix (access), US Micro Sales s1008 (s1008),\r
165; Micro Mate (mmate), A.C.E. Discovery (disc). \r
166; These I cannot test: please send comments back if these are buggy.\r
167;\r
168; edit 11 29 January 1985 by OBSchou @ multics.lut.ac.uk\r
169; added in code for 2651 USART for use with CP/M and a VDU\r
170;\r
171; edit 10: 21 November, 1985 by ajcole @ leeds.ai\r
172; Merged in support for the following:\r
173; North Star Horizon without SIO-4 (horizon)\r
174; Comart Communicator (comart)\r
175; Cromemco TU-ART interface (cmemco)\r
176; TVI912/920 VDUs (tvi912)\r
177;\r
178; edit 9 24 October by OBSchou. Merged code from B Robertson from\r
179; Aberdeen University. He writes:\r
180; September 20, 1985 by B Robertson, Aberdeen Univ. Computing Centre.\r
181; Add support for Research Machines 380Z, North Star Advantage, Acorn\r
182; BBC with Z80 co-processor and APPLE II with Mountain Computers CPS\r
183; Multifunction card.\r
184;\r
185; edit 8: 11 October, 1985 by OBSchou\r
186; tidied up code around Superbrain main/aux port business\r
187;\r
188; edit 7: 11 June, 1985 by O B Schou, Loughborough University of Tech.\r
189; Loughborough, Leics, England.\r
190; Added code for Torch (Second processor to BBC-B) and Cifer 1886\r
191; Hopefully this code will work with Torchpacks, and Cifer 26xx\r
192; and 28xx series computers. Edits marked by OBS\r
193;\r
194; edit 6: 9-Feb-85 by CJC\r
195; Merge Northstar Horizon, Lobo MAX, and Xerox 820 changes:\r
196; 13-Dec-84 Add Northstar Horizon with SIO-4 board, port 5 at 1200 [CSM]\r
197; 13-Jan-85 by Vanya J.Cooper Pima Commun. College Tel: 602-884-6809\r
198;\r
199;pcc001 27-Dec-84 vjc modules: cp4sys,cp4typ\r
200; Add conditional for Xerox 820. I thought at first I could\r
201; live with the kaypro conditional, but it's enough of a pain\r
202; that I added it back in. The clear-to-end-of-screen char\r
203; is different, breaking many programs in VT52 mode, and the\r
204; default escape char control-\, is not at all obvious how\r
205; to type on the 820 keyboard. If you muddle through the\r
206; key translation table, it turns out to be control-comma.\r
207; Rather than OR xer820 all the occurances of kpII conditionals\r
208; I added a bbI conditional for all common code for the big\r
209; board I based machines that is automatically turned on by\r
210; either kpII or xer820. This will also make it easier in\r
211; the future if another flavor of bigboard is added.\r
212;\r
213;pcc010 2-Jan-85 vjc modules:cp4pkt,cp4typ\r
214; Control-C during send or recieve clobbers some of the screen\r
215; and doesn't look nice. Position the cursor to end of screen\r
216; before returning to main loop.\r
217;\r
218;pcc013 8-Jan-85 vjc modules:cp4mit,cp4utl,cp4typ\r
219; Replace CLOSE command to cancel session logging to SET\r
220; LOGGING ON/OFF. This seems to fit in with the command\r
221; structure better. Default the log file to KERMIT.LOG\r
222; incase no previous LOG command. Logging is also enabled\r
223; by LOG command, as before.\r
224;\r
225; edit 5: October 13, 1984 by L M Jones, JCC, for New York Botanical Garden\r
226; Add support for CPT-85xx series of word processors when running CP/M.\r
227;\r
228; edit 4: August 29, 1984 by Bdale Garbee @ CMU\r
229; Add support for Digicomp Delphi 100 and Netronics Smartvid terminal.\r
230;\r
231; edit 3: July 27, 1984 (CJC)\r
232; Shuffle files around for easier assembly by both M80 and LASM.\r
233;\r
234; edit 2: June 4, 1984 [Toad Hall]\r
235; Added Morrow Decision I (the big S100 bus sucker, not the\r
236; little single motherboard one); added Toad Hall TACTrap to deal\r
237; with those working through a TAC and its intercept character.\r
238;\r
239; edit 1: May, 1984 (CJC)\r
240; extracted from CPMBASE.M80 version 3.9; modifications are described\r
241; in the accompanying .UPD file.\r
242;\r
243\r
244FALSE EQU 0\r
245TRUE EQU NOT FALSE\r
246\r
247;\r
248; Assembler type. Define the appropriate one TRUE, the rest FALSE. (We can't\r
249; use ASM, because it cannot handle multiple input files)\r
250mac80 EQU FALSE ; For assembly via MAC80 cross-assembler.\r
251m80 EQU FALSE ; For assembly via Microsoft's M80.\r
252lasm EQU TRUE ; For assembly via LASM, a public-domain\r
253 ; assembler.\r
254;\r
255; Address at which the overlay should be loaded. This will not\r
256; change often (no more than once per version of KERMIT); it should\r
257; be updated when a new version of KERMIT is released.\r
258;\r
259\r
260ovladr EQU 7000H ; [18] address = 6c00h for Kermit v4.10\r
261 ;[MF]...\r
262\r
263cpsker EQU FALSE ; building the system-dependent part...\r
264\r
265; SET some options to FALSE, then SET them TRUE if needed\r
266iobyt SET FALSE ;assume we dont want IOBYTE..\r
267inout SET FALSE ;... or IN/OUT code\r
268termin SET FALSE ; we are not using a terminal\r
269; Also set the CPU speed to a default 2.0 Mhz\r
270cpuspd SET 20 ; default to 2 Mhz, in case we dont know\r
271; Assume kit is Z80 based, and set z80 false for non z80 systems.\r
272;z80 SET TRUE\r
273\r
274;Which CP/M system hardware are we building KERMIT-80 for?\r
275;One of the following should be TRUE, the rest FALSE:\r
276;\r
277;We have basically three "classes" of systems:\r
278\r
279;Systems supporting the IO-redirection via I/O-Byte\r
280\r
281bbc EQU FALSE ;[9] Acorn BBC model B\r
282;added code by JAS\r
283cifer2 EQU FALSE ; Cifer 1886 using io byte flipping [OBS]\r
284cifer3 EQU FALSE ; Cifer 1886 with CP/M Plus [JAS]\r
285 ; (Not IOBYTE but easier to keep together)\r
286cifaux EQU FALSE ; One of above Cifers using AUX port else VL port\r
287dmII EQU FALSE ;"Generic" KERMIT-80 for DECMATE II.\r
288gener EQU FALSE ;"Generic" Kermit-80, CP/M calls only.\r
289 ; (terminal required)\r
290mikko EQU FALSE ;"Generic" KERMIT-80 for MikroMikko\r
291robin EQU FALSE ;DEC VT180 = Generic + VT100 screen control\r
292\r
293;.. \and Systems supporting direct IN / OUT handling of ports\r
294advant EQU FALSE ;[10] North Star Advantage\r
295access EQU FALSE ; Access Matrix .. uses port J5 [12]\r
296 ; (terminal required) [MF]\r
297ampro EQU FALSE ; Ampro Little Board (terminal required)\r
298basicns EQU FALSE ; Basic Northstar using printer port (CRT req.)\r
299bbII EQU FALSE ;BigBoard II (terminal required)\r
300brainm EQU FALSE ;Select Superbrain Main port **[obs]\r
301braina EQU FALSE ;Select Superbrain AUX port **[obs]\r
302comart EQU FALSE ;[10] Comart Communicator\r
303 ; (terminal required)\r
304compro EQU FALSE ;Compupro Interfacer 4 (or 3) [gv]\r
305 ; (terminal required) [MF]\r
306cpt85xx EQU FALSE ;CPT-85xx word processor w/CPM (set ADM3A TRUE)\r
307cmemco EQU FALSE ;[10] Cromemco (TU-ART) (terminal required)\r
308delphi EQU FALSE ;Digicomp Delphi 100 (terminal required)\r
309disc EQU FALSE ; Action Computer Enterprises "Discovery"\r
310 ; Port B on an 83U user board (CRT required)\r
311genie EQU FALSE ;Eaca Genie III\r
312h8quad EQU FALSE ;[24] Entry for heath-8. NOT same as H-89\r
313heath EQU FALSE ;For Heath/Zenith H89.\r
314kpII EQU FALSE ;Kaypro-II\r
315horizon EQU FALSE ;[10] North Star Horizon (mother-board)\r
316 ; (terminal required)\r
317m2215 EQU FALSE ; BT Merlin [23] - uses 2651, Terminal rqd\r
318mmate EQU FALSE ; PMC - 101 MicroMate (Crt required)\r
319mmdI EQU FALSE ;Morrow Micro Decision I (terminal required)\r
320mdI EQU FALSE ;Morrow Decision I (the big sucker)\r
321 ; (terminal required) [Toad Hall]\r
322ncrdmv EQU FALSE ; NCR Desision Mate V. (2651 USART) (Term rqd.)\r
323norths EQU FALSE ;[CSM] NorthStar Horizon with HSIO-4 board\r
324 ; (terminal required)\r
325pci2651 EQU FALSE ; CP/M with 2651 USART. Needs VDU. [11]\r
326rm380zm EQU FALSE ;[14] Research Machines 380Z MDS (5.25" discs)\r
327rm380zf EQU FALSE ;[14] Research Machines 380Z FDS (8" discs)\r
328s1008 EQU FALSE ; US Micro Sales s1008 (Terminal required)\r
329sb6 EQU FALSE ; SB180 6/9 MHz cpu speed conditionals -\r
330sb9 EQU FALSE ; set one of these to TRUE, - it will\r
331 ; automatically set sb180 TRUE\r
332 ; (terminal reqd for Sb-180 systems)\r
333scntpr EQU FALSE ; [majoc 870305] For OEM ScreenTyper\r
334sanyo EQU FALSE ;For sanyo mbc-1100 series\r
335telcon EQU FALSE ;For TELCON Zorba portable\r
336teletek EQU FALSE ; Teletek SYSTEMASTER (terminal rqd)\r
337trs80lb EQU FALSE ;For Lifeboat 2.25C CP/M Display\r
338trs80pt EQU FALSE ;For Pickles + Trout CP/M Display\r
339trsm4 EQU FALSE ;TRS80 Model 4 under Montezuma Micro CPM 2.2\r
340vector EQU FALSE ;For Vector Graphics.\r
341xer820 EQU FALSE ;[pcc001] Xerox 820\r
342z100 EQU FALSE ;For Z-100 under CP/M-85.\r
343\r
344;.. and Systems doing neither...\r
345apmmdm EQU FALSE ;jb Micromodem II in slot 2\r
346ap6551 EQU FALSE ;jb apple with 6551 ACIA in serial interface\r
347ap6850 EQU FALSE ;[14] Apple with 6850 ACIA in serial interface\r
348 ;[14] e.g PACT, SSM AIO, Aristocard\r
349apcps EQU FALSE ;[9] Apple with CP multifunction card\r
350cpc EQU FALSE ; Amstrad CPC CP/M Plus computers\r
351cpm3 EQU FALSE ;"Generic" Kermit-80 for CP/M 3.0 (CP/M Plus)\r
352 ; (terminal required)\r
353lobo EQU FALSE ;Lobo Max-80\r
354osi EQU FALSE ;For Ohio Scientific.\r
355osbrn1 EQU FALSE ;For Osborne 1\r
356pcw EQU FALSE ; Amstrad PCW 8256/8512 computers\r
357px8 EQU FALSE ;[12] For Epson PX-8\r
358torch EQU FALSE ;[obs] Torch does comms via Beeb as IO processor\r
359z80mu EQU FALSE ; CP/M-80 Kermit under z80mu emulator on PC\r
360hp125 EQU FALSE ;[MF]HP-125 Business Assistant, 8-bit data\r
361 ; path thru Data Comm 1, 7-bit data path\r
362 ; thru Data Comm 2 (requires 8th-bit quoting\r
363 ; for binary transfers on Data Comm 2)\r
364 ; set VT52 TRUE\r
365mbee EQU FALSE ; Microbee Systems - Microbee \r
366\r
367;.. and for Micros, like the MDI, which have "terminals of choice", you must\r
368;select one of these in addition to selecting the micro itself.\r
369;Also select a terminal for "gener" and "cpm3": use "crt" for the TRUE generic.\r
370crt EQU FALSE ;Basic CRT, no cursor positioning\r
371adm3a EQU FALSE ;Adm3a Display (or CPT built-in display)\r
372adm22 EQU FALSE ;ADM 22 terminal\r
373h1500 EQU FALSE ;Hazeltine 1500\r
374smrtvd EQU FALSE ;Netronics Smartvid terminal.\r
375soroq EQU FALSE ;Soroq IQ-120.. this a guess [OBS]\r
376am230 EQU FALSE ;Ampro 230 [13]\r
377tvi912 EQU FALSE ;[10] TVI912/920\r
378tvi925 EQU FALSE ;TVI925 Display\r
379 ; (works for Freedom 100 also) [Toad Hall]\r
380vt52 EQU FALSE ;VT52 or equivalent (or H19)\r
381vt100 EQU FALSE ;VT100 or equivalent\r
382wyse EQU FALSE ;Wyse 100 terminal\r
383;\r
384; Several systems are basically the same, with very slight variations,\r
385; so use common code. List these sysems below\r
386;\r
387cifer EQU cifer2 OR cifer3 ; DO NOT TOUCH THIS LINE\r
388brain EQU brainm OR braina ;For Intertec SuperBrain. **[obs]\r
389;\r
390; flag 380Z system if either selected\r
391;\r
392rm380z EQU rm380zm OR rm380zf ;[14]\r
393;\r
394trs80 EQU trs80lb OR trs80pt ; if either, flag TRS-80 system.\r
395bbI EQU kpII OR xer820 ;[pcc001] flag for bigboard I\r
396sb180 EQU sb6 OR sb9 ; Micromint SB180 (BYTE Oct 85)\r
397;\r
398; flag apple system if either selected\r
399;\r
400apple EQU apmmdm OR ap6551 OR ap6850 OR apcps\r
401;\r
402; also set termin(al) TRUE if any terminal selected (crt included)\r
403termin SET crt OR adm3a OR adm22 OR h1500 OR smrtvd OR am230\r
404termin SET termin OR tvi912 OR tvi925 OR vt52 OR vt100\r
405termin SET termin OR wyse OR soroq\r
406\r
407; Now set iobyt or inout TRUE for those systems doing so\r
408; IOBYTE systems...\r
409IF robin OR dmII OR gener OR mikko OR cifer2 OR bbc;[**obs]\r
410iobyt SET TRUE ;Short conditional for above\r
411ENDIF;robin OR dmII OR gener OR cifer2 OR bbc\r
412\r
413; INOUT systems...\r
414IF brain OR vector OR sanyo or compro\r
415inout SET TRUE ;Short conditional for above\r
416ENDIF;brain OR vector OR sanyo OR compro\r
417\r
418IF heath OR h8quad OR z100 OR trs80 OR telcon OR bbI\r
419inout SET TRUE ;Short conditional for above\r
420ENDIF;heath OR h8quad OR z100 OR trs80 OR telcon OR bbI\r
421\r
422IF bbII OR mmdI OR mdI OR delphi OR cpt85xx OR norths ;running out of room\r
423inout SET TRUE ;Short conditional for above\r
424ENDIF;bbII OR mmdI OR mdI OR delphi OR cpt85xx OR norths\r
425\r
426IF advant OR rm380z OR comart OR horizon OR cmemco ;[9] [10] more room here\r
427inout SET TRUE ;Short conditional for above\r
428ENDIF;advant OR rm380z OR comart OR horizon OR cmemco\r
429\r
430IF pci2651 OR m2215 OR sb180 OR ncrdmv OR teletek;[11] and even more room\r
431inout SET TRUE ;Short conditional for above\r
432ENDIF ;pci2651 OR m2215 OR sb180 OR ncrdmv OR teletek [11]\r
433\r
434IF access OR basicns OR s1008 OR mmate OR disc ; [12]\r
435inout SET TRUE ;Short conditional for above\r
436ENDIF ; access OR basicns OR s1008 OR mmate OR disc [12]\r
437\r
438IF genie OR trsm4 OR ampro\r
439inout SET TRUE ;Short conditional for above\r
440ENDIF ; genie OR trsm4 OR ampro\r
441\r
442\r
443; Toad Hall TAC Trap: If you're going through a TAC, it will\r
444; cough on its Intercept Character (usually a @ (* - 40H)). Sending it\r
445; twice forces the TAC to recognize it as a valid ASCII character,\r
446; and it'll send only one on to the host. If you've SET the TACTrap\r
447; to OFF, it will be a null character, and nothing will happen. If you\r
448; set it on, it will be your selected TAC intercept character (or will\r
449; default to the common intercept char, '@'.\r
450; If you never expect to have to work through such a beastie, just set\r
451; TAC to false and forget all this mess. [Toad Hall]\r
452\r
453tac EQU FALSE ; gonna work through a TAC?\r
454tacval EQU '@' ;Typical TAC intercept character\r
455\r
456; Processor speed in units of 100KHz\r
457; for bbII, kpII, cpt85xx, advance, apple,bbc,px8 & rm380z timing loop [12]\r
458; We have to set these before CPXCOM to make sure we update the CPU speed.\r
459\r
460; The following systems I have no idea of cpu speed. Can anyone oblige??\r
461; robin, dmII, mikko, vector, heath, h8quad, z100, scntpr\r
462; trs80 (both), telcon, mmdI, mdI, delphi, ncrdmv,\r
463; cromemco, teletek, osi, lobo\r
464\r
465IF z80mu\r
466cpuspd SET 2 ; a PC is about 200khz Z80 equivalent\r
467ENDIF; z80mu\r
468\r
469IF apple OR cpt85xx OR px8 OR heath OR h8quad ;[9] [12] What rate is heath?\r
470cpuspd SET 20 ; Apple Softcard, CPT-85xx: 2.0 MHz\r
471 ; ('cause of integral video?)\r
472ENDIF; apple OR cpt85xx OR px8 OR heath OR h8quad [12]\r
473\r
474IF kpII OR xer820 OR scntpr OR osbrn1 ;[9] What speed is scntpr??\r
475cpuspd SET 25 ; original Kaypro II,Xerox 820: 2.5 MHz\r
476ENDIF;kpII OR xer820 OR scntpr OR osbrn1\r
477\r
478IF PCW or CPC\r
479cpuspd SET 33 ; all 4MHz but insterted wait states\r
480 ; reduce to an effective 3.3 MHz.\r
481ENDIF ;pcw OR cpc\r
482\r
483IF brain OR advant OR bbII OR torch OR z100 OR genie OR trsm4\r
484cpuspd SET 40 ; 4.0 MHz CPU\r
485ENDIF; brain OR advant OR bbII OR torch OR z100 OR genie OR trsm4\r
486\r
487IF cifer OR rm380z OR comart OR horizon OR norths\r
488cpuspd SET 40 ; 4.0 MHz CPU\r
489ENDIF; cifer OR rm380z OR comart OR horizon OR norths\r
490\r
491IF disc OR mmate OR s1008 OR access OR basicns ;[29] This is a guess.. Most are 4Mhz\r
492cpuspd SET 40 ; 4.0 MHz CPU\r
493ENDIF ;disc OR mmate OR s1008 OR access OR basicns [29]\r
494\r
495IF m2215\r
496cpuspd SET 50 ; BT Merlin Rair Black Box is 8085 at 5 Mhz\r
497ENDIF ;m2215\r
498\r
499IF bbc or sb6\r
500cpuspd SET 60 ; BBC or SB-180 with 6Mhz Z80/61480\r
501ENDIF;bbc OR sb6\r
502\r
503IF sb9\r
504cpuspd SET 90 ; SB-180 with 9 Mhz clock\r
505ENDIF;sb9\r
506\r
507IF hp125 OR telcon\r
508cpuspd SET 40 ;[MF]HP125 or TELCON\r
509ENDIF;hp125 OR telcon \r
510\r
511IF mbee\r
512cpuspd SET 33 ; Microbee has 3.375MHz Z80\r
513ENDIF; mbee\r
514\r
515; Set Z80 flag FALSE for non Z80 or unknown CPU systems\r
516IF FALSE ; assume all systems are not z80 based\r
517;z80 SET FALSE\r
518ENDIF ;FALSE\r
519\r
520; Now, lets see what family we are assembling for. Reset all \r
521; family file to FALSE\r
522\r
523torfam SET FALSE ; not Torch family file\r
524ciffam SET FALSE ; not Cifer kit\r
525appfam SET FALSE ; not Apples\r
526norfam SET FALSE ; not North Star kit\r
527pcwfam SET FALSE ; not Amstrad PCW kit\r
528bbifam SET FALSE ; not the BBI family\r
529heafam SET FALSE ; not Heath, Z100, telcon,or screentyper\r
530sbfam SET FALSE ; not an SB180 system\r
531merfam SET FALSE ; not a BT Merlin system\r
532sanfam SET FALSE ; not a Sanyo\r
533comfam SET FALSE ; not a compupro\r
534genfam SET FALSE ; not a genie\r
535trsfam SET FALSE ; not a trs-80 Model 4\r
536z80fam SET FALSE ; not z80mu system\r
537beefam SET FALSE ; not a Microbee system\r
538sysfam SET TRUE ; ... but assume the worst, and its in\r
539 ; the CPXSYS.ASM file\r
540\r
541\r
542IF (torch OR pci2651 OR ncrdmv OR brain) ;[15]\r
543torfam SET TRUE ; we are to use the Torch family file\r
544.printx * torfam set TRUE *\r
545;(Yeah, I know, there are more than Torch systems in it)\r
546ENDIF ;(torch OR pci2651 OR ncrdmv OR brain) [15]\r
547\r
548IF (cifer)\r
549ciffam SET TRUE ; we are to use the cifer family file\r
550.printx * ciffam set TRUE *\r
551ENDIF ;cifer\r
552\r
553IF apple ;[15]\r
554appfam SET TRUE ; apples\r
555.printx * appfam set TRUE *\r
556ENDIF ;apple [15]\r
557\r
558IF (horizon OR basicns OR norths OR advant OR comart) ;[15]\r
559norfam SET TRUE ; north star kit\r
560.printx * norfam set TRUE *\r
561ENDIF ;(horizon OR basicns OR norths OR advant OR comart) [15]\r
562\r
563IF (pcw OR cpc) ;[15]\r
564pcwfam SET TRUE ; Amstrad PCW kit\r
565.printx * pcwfam set TRUE *\r
566ENDIF ;pcw OR cpc [15]\r
567\r
568IF (kpII OR xer820 OR bbII OR ampro)\r
569bbifam SET TRUE ; The Bigboard, Kaypro, Xerox and Ampro family\r
570.printx * bbifam set TRUE *\r
571ENDIF ;(kpII or xer820 OR bbII OR ampro)\r
572\r
573IF (heath OR h8quad OR telcon OR z100 OR scntpr)\r
574heafam SET TRUE ; Doing Heath, z100, telcon, or screentyper\r
575.printx * heafam set TRUE *\r
576ENDIF ;(heath OR h8quad OR telcon OR z100 OR scntpr)\r
577\r
578IF sb180\r
579sbfam SET TRUE ; doing an SB180 system\r
580.printx * sbfam set TRUE *\r
581ENDIF ; sb180\r
582\r
583IF m2215\r
584merfam SET TRUE ; doing a BT Merlin system\r
585.printx * merfam set TRUE *\r
586ENDIF ; m2215\r
587\r
588IF sanyo\r
589sanfam SET TRUE ; doing a Sanyo MBC-1100 system\r
590.printx * sanfam set TRUE *\r
591ENDIF ; sanyo\r
592\r
593IF compro\r
594comfam SET TRUE ; doing a Compupro system\r
595.printx * comfam set TRUE *\r
596ENDIF ; compro\r
597\r
598IF genie\r
599genfam SET TRUE ; doing a Genie system\r
600.printx * genfam set TRUE *\r
601ENDIF ; genie\r
602\r
603IF trsm4\r
604trsfam SET TRUE ; doing a TRS-80 M4 system\r
605.printx * trsfam set TRUE *\r
606ENDIF ; trs4m\r
607\r
608IF z80mu\r
609z80fam SET TRUE ; doing a z80mu emulation\r
610.printx * z80fam set TRUE *\r
611ENDIF ; z80mu\r
612\r
613IF mbee\r
614beefam SET TRUE ; doing a Microbee system\r
615.printx * beefam set TRUE *\r
616ENDIF ; mbee\r
617\r
618; Now, if none of the above, then its the older CPXSYS.ASM file we want\r
619\r
620IF (torfam OR ciffam OR appfam OR norfam OR sanfam OR comfam) AND sysfam\r
621sysfam SET FALSE ; Were not doing the CPXSYS.ASM file\r
622.printx * sysfam set FALSE *\r
623ENDIF ; (torfam OR ciffam OR appfam OR norfam OR sanfam OR comfam) AND sysfam\r
624\r
625IF (pcwfam OR bbifam OR heafam OR sbfam OR merfam) AND sysfam\r
626sysfam SET FALSE ; Were not doing the CPXSYS.ASM file\r
627.printx * sysfam set FALSE *\r
628ENDIF ; (pcwfam OR bbifam OR heafam OR sbfam OR merfam) AND sysfam\r
629\r
630IF (genfam OR trsfam OR z80fam OR beefam) AND sysfam\r
631sysfam SET FALSE ; Were not doing the CPXSYS.ASM file\r
632.printx * sysfam set FALSE *\r
633ENDIF ; (genfam OR trsfam OR z80fam OR mbeefam) AND sysfam\r
634\r
635IF sysfam\r
636.printx * sysfam set TRUE *\r
637ENDIF\r
638\r
639IF lasm\r
640 LINK CPSDEF ; Use the system independent declares\r
641ENDIF;lasm [Toad Hall]\r
642\r
643; If we're still here, must be M80 or MAC80. Collect the rest of\r
644; the sources.\r
645.sfcond\r
646\r
647\r
648 INCLUDE CPSDEF.ASM ; common definitions\r
649 INCLUDE CPXLNK.ASM ; linkage area description\r
650 INCLUDE CPXCOM.ASM ; include common code\r
651 INCLUDE CPXSWT.ASM ; this wont do much, but will announce machine\r
652\r
653IF torfam ;[15]\r
654 INCLUDE CPXTOR.ASM ; we are assembling for Torch, Cifer etc\r
655ENDIF ;torfam [15]\r
656\r
657IF ciffam\r
658 INCLUDE CPXCIF.ASM ; we are assembling for a Cifer\r
659ENDIF ;ciffam\r
660\r
661IF appfam ;[15]\r
662 INCLUDE CPXAPP.ASM ; we are assembling for an apple\r
663ENDIF ;appfam [15]\r
664\r
665IF norfam ;[15]\r
666 INCLUDE CPXNOR.ASM ; we are assembling a NortStar machine\r
667ENDIF ;norfam [15]\r
668\r
669IF pcwfam ;[15]\r
670 INCLUDE CPXPCW.ASM ; we are assembling for the Amstrad PCW machine\r
671ENDIF ;pcwfam [15]\r
672\r
673IF bbifam\r
674 INCLUDE CPXBBI.ASM ; assembling for BigBoard, Kaypro, Xerox\r
675 ; & Ampro Little Board\r
676ENDIF ;bbifam\r
677\r
678IF sysfam ;[15]\r
679 INCLUDE CPXSYS.ASM ; system-dependent code and tables (Part 1)\r
680 INCLUDE CPXSY2.ASM ; system-dependent code and tables (Part 2)\r
681ENDIF ;sysfam [15]\r
682\r
683IF heafam\r
684 INCLUDE CPXHEA.ASM\r
685ENDIF ;heafam\r
686\r
687IF m2215\r
688 INCLUDE CPXMRL.ASM\r
689ENDIF ;m2215\r
690\r
691IF sbfam\r
692 INCLUDE CPXSB.ASM\r
693ENDIF ;sbfam\r
694\r
695IF sanfam\r
696 INCLUDE CPXSYO.ASM\r
697ENDIF ;sanfam\r
698\r
699IF comfam\r
700 INCLUDE CPXPRO.ASM\r
701ENDIF ;comfam\r
702\r
703IF genfam\r
704 INCLUDE CPXGNI.ASM\r
705ENDIF ;genfam\r
706\r
707IF trsfam\r
708 INCLUDE CPXTM4.ASM\r
709ENDIF ;trsfam\r
710\r
711IF z80fam\r
712 INCLUDE CPXZ80.ASM\r
713ENDIF ;z80fam\r
714\r
715IF beefam\r
716 INCLUDE CPXBEE.ASM\r
717ENDIF ;beefam\r
718\r
719IF termin ; any terminal selected?\r
720 INCLUDE CPXVDU.ASM ;[15] Just in case we need a VDU...\r
721ENDIF ;termin\r
722 END\r