Processor Tech Access, Vol One, Num Two Access_v1n2 Access V1n2
User Manual: access_v1n2
Open the PDF directly: View PDF .
Page Count: 38
Download | |
Open PDF In Browser | View PDF |
75¢ per issue Published by Wible/Rampton Advertising, San Francisco, Volume One, Number Two, April 1977 A Letter from the Editor "Everyone should believe in something. I believe I'll have another drink." — Steele's Plagiarism of Somebody's Philosophy Welcome to issue #2 of ACCESS. I hope the first one was able to provide you with something useful, after waiting so patiently for delivery. Wasn't entirely our fault this time, honest; we now know from personal experience that mailing services have their gremlins too. Anyway, issue #2 is now here and filled with goodies we hope you can use on your pet project. One thing issue #2 isn't filled with is feedback from you. No way it could be, since it went to press before most of you ever got your hands on #2. We really do want to facilitate an exchange of ideas, comments, gripes, what have you, so please get those cards and letters into us. Are you more interested in hardware stuff than software stuff? Vice versa? What bugs bug you? What do you do with your Sol anyway? Got any hot tips on interfacing with exotic equipment? Just want to sound off about something? Or maybe even say something nice about us? We definitely want issue #3 to have more of you in it, instead of just us talking to the walls. Speaking of us, you'll be reading this just about the time of the 1st West Coast Computer Faire. Come give us some feedback in person; we'll be there along with all the competition, and we'll have some good stuff to show you. You might even get to see me if you look closely; I'm the one wearing the red suspenders. For those of you who can't make it to San Francisco, we'll have a report in ACCESS #3. Got to sign off now and fix that Sol PCB that just came in for warranty repair. Probably sabotage — whoever heard of a SOL not working?) Aram Attarian II Subscription Information ACCESS is published every six weeks. If you like what you see, we hope you'll send us $4.00 for a year's subscription so we can keep the info coming. Write to us at Processor Technology, 6200 Hollis Street, Emeryville, CA 94608. Inside Emeryville! One to One Communication We're going to make this column a regular feature, under the peerless direction o f our Customer Service Manager, the world renowned Ralph I. Palsson (applause). He'll keep you informed on what's happening in the world of availability, delivery dates, and other such precious tidbits, and do his best to keep the lines of communication open. Good luck, Ralph. (A.A. II, Editor) A Customer Service Department has only one reason for its existence: to fix the responsibility on someone for keeping the communication lines open, so the company doesn't become just another faceless entity, vaguely malevolent to your attempts to pursue the love and lore of computing. The someone's me, Ralph Palsson; I'm here to welcome your telephone and letter inquiries and provide you with immediate, personal service. Whether it be pre-sales information, placing an order, finding the nearest Processor Technology dealer, checking on the availability of existing or forthcoming products-we'll do our best to help. Are you interested in more information about a product than you could glean from the catalog description? How about the VDM-1 kit you ordered way back when and still haven't received? Even the best of us make occasional errors, and letting us know about your problems is the first step towards their solution. Letters are now being sent regularly to advise you, our customers, of anticipated production and delivery schedules. PTC dealers are being kept informed too, so you can call them for on-going status reports. We're trying continually to expand and improve the Customer Service Department with the aim of giving even more efficient, reliable service. Some of the ways we're doing it: Teletroubleshooting. Having a problem with a PTC kit? Is your Sol-20 displaying 0's and 9's and nothing else? Need technical advice on interfacing? One of our applications engineers is available daily for phone consultation and technical assistance. Call (415) 652-8080 between 9:30 am and noon or 1:30 and 4:00 pm Pacific Time. Technically oriented software questions should go to our new division, Software Technology, at (415) 349-8080. (That's right, 8080!) When you make a technical call about a malfunctioning kit, it helps if you take time to think out your questions first, maybe make a few notes. It's also a good idea to have your kit manual handy, and if possible, the recalcitrant piece of equipment. All calls are taken on a first come, first serve basis, so if you do have to hold for a few minutes, please be assured that you're not running up your bill for the benefit of someone who called in later. If you do run into a wait, you can also ask us to call you back collect. We will. Again, let us remind you that if you purchased your PTC product through a dealer, try him/her first. They're all authorized to service the equipment they sell, precisely because they can give you more personalized, faster service than anyone can by mail or phone. Need a defective part replaced? Again, the best way to handle this is through your dealer. If he's out of stock, or if you purchased directly from us, send us the defective part for replacement. Similarly, if you're missing a part from a kit, call your dealer or write to us, giving as complete a description as you can of what's missing. Finally. We are always interested in improving our one-to-one communication, and we're open to your comments, criticisms, and suggestions. Please feel free to contact us if we can be of service in any way. Error, Error, Does Not Compute Errors do appear from time to time in all high class publications. ACCESS is no exception — our score for the first issue was three unfortunate oversights. 1. The instructions for wiring the 3P+S for a keyboard interface (page 3). At Step 5, we told you to connect pin 7 to a point on 3P+S leading to J2 pin 12. Pin 12 is a ground point, and you don't really want to do that. Pin 7 should be connected to a point on the 3P+S leading to IC 14 pin 13. 2. The article on interfacing PT 4KRA memory boards with the Motorola M6800 (page 2). It's all right as far as it goes, but we neglected to give proper credit to the contributor. Our apologies and thanks to J. W. Schook, P O. Box 185, Rocky Point, N.Y. 3. Last, but not least, those ever-present gremlins managed to alter our mailing address to 6800 Hollis St. Now, that's really adding insult to injury. Our correct address is 6200 Hollis St., Emeryville, CA 94608. Introducing Software Technology Corporation We've pulled a protozoan trip and split in two: Software Technology Corp. is a separate new company formed to take over software development from Processor Technology. The idea is to give you more and better software support by not scattering our energies about, randomly. Software Technology is three people with an impressively vast reservoir of experience in operating systems, time sharing, real time systems, compilers, interpreters, simulators, business systems, and software development. Did we leave anything out? During this transitional period, they'll be maintaining, supporting and producing all the current PTC software, plus developing some of their own. Later (not too much later), they'll be coming out with lots of good stuff designed to get the most out of Sol. You should have your first chance to see the caliber of Software Technology developments at the Computer Faire in San Francisco. But we're not going to tell you what, because one fundamental policy of Software Technology is not to announce anything that isn't ready. Nobody likes a tease. Meanwhile, Software is in business and even has a phone. If you have any problems with Processor Technology software you're using now, you can call their 24-hour phone line. When nobody's there, there's an answering machine to take your message, and they will get back to you promptly. The number is (415) 349-8080. You're also welcome to write your questions: PO. Box 5260, San Mateo, CA 94402. For the time being, orders, questions about delivery and of course hardware questions should still be directed to Processor Technology. (See One to One Communication) Read on for your first example of Software Technology software. Announcing the SOL USERS GROUP! The Sol Users Group was recently organized by members of the Homebrew Computer Club in Palo Alto; SUG is not affiliated in any way with Processor Tech-Technology. The purposes of SUG are to exchange software and other applications, and to create standards. If plenty of interest is shown, a Sol Newsletter will be published and sent to members. If you own or have ordered a Sol, send your name, address, phone number and ideas to: Bill Burns 4190 Maybell Way Palo Alto, CA 94306 (Please don't call.) Attention, CONSOL Users All Processor Technology software has recently been modified in a very important way that encourages standardization. If you've been looking forward to having some Sol software for your CONSOL Proms, you'll have to let us reprogram for you. There's no charge. Just mail your CONSOL Proms, suitably packaged, to Processor Technology; we'll take care of the rest. Turn-around time is about 2 weeks, dependent on the vagaries of the U. S. Postal Service, natch. If you're planning to upgrade to SOLOS anyway, don't worry about it. Editor: Aram Attarian II Publisher: Wible/Rampton Advertising, 727 15th Avenue, San Francisco, CA 94118 ACCESS is published approximately every six weeks. Subscription rate: $4 per year, from Processor Technology Corp., 6200 Hollis St., Emeryville, CA 94608. ACCESS Copyright © April 1977 by Processor Technology Corp. All Rights Reserved. Material in this publication may not be reproduced in any form without permission from Processor Technology Corp. Clarkes third law: Any sufficiently advanced technology is indistinguishable from magic. Double Your Pleasure, Double Your Fun, Or, How to Use Both Parallel Ports on the 3P+S You can take maximum advantage of the 3P+S's versatility by making a simple modification that gives you simultaneous access to both parallel ports. Then you'll be able to use one port for a keyboard input, the other for paper tape input/output. The serial port is available for an RS232 or TTY, with status and control available at Port 0 for Processor Technology software compatibility. The change procedure is as follows: 1. Cut the existing trace from IC 22 pin 3 to IC 20 pin 13; at IC 22 pin 3 2. Cut the existing trace from IC 23 pin 12 to IC 21 pins 1 and 2; at IC 23 pin 12 3. Run a jumper from IC 23 pin 12 to IC 20 pin 13 4. Run a jumper from IC 22 pin 3 to IC 21 pins 1 and 2 5. Select area "B" option; jumper from left to right Assuming that area "A" board address options "00" have been selected, the ports will now be set up as follows: Port 0 = Channel C. Control and status Port 1 = Channel A.* Parallel data (keyboard) Port 2 = Channel D. UART (RS232 or TTY) Port 3 = Channel B.* Parallel data (paper tape reader) *The strobe latches for the parallel ports remain with their respective channels. Changing the data available status. The 3P+S interface is laid out to respond to a negative strobe input pulse low active status (i.e., FA, FB). For compatibility with Processor software, you'll want to select a high active data available status. Run a jumper from the !Q output of the respective strobe latch (i.e., AKA, AKB) to the correct status bit input in area "G." In the above configuration, the amounts to jumpering keyboard data available IC 15 pin 7 to area "G" point C6. Osborns Law: Variables won't. Constants aren't. CUTE, CUTEST, CUTER Below is the complete source listing for the control and monitor programs for the CUTS board. This program, CUTER, was made available with the CUTS module in the form of a cassette selling for $11. The CUTER cassette contains object code along with a relocating loader for loading the program in any 256-byte boundary of available RAM. A new version of BASIC-5 for use with CUTER and SOLOS is also on the cassette, followed by the complete source code of CUTER. Not a bad deal for $11. So why buy the cassette now that we're giving you the listing? It's not that we're mercenary, but consider: if you want to use PTC's software packages on cassettes; then CUTER is going to be a tremendous asset in loading those tapes, right? Right-otherwise you could spend 3 or 4 hours toggling it in from the front panel of your A#$%&R or I(*@ I. And now, the VDM-½! Or, Modifying Your VDM-1 for 32-character Display We're pleased to announce that unceasing technical progress has now made possible a reduction in the number of characters per line of the VDM-1 display from 64 to 32! Seriously, the modification is quite handy if you want to work with large type display, or feed RF modulated signals to a TV antenna input. The hardware modifications are shown in the schematic drawing below. One word of caution: since we're tying the low-order address bit to ground, only character locations with bit 0 equal to 0 (i.e., even-numbered addresses), will be displayed. So if you use the modified VDM with unmodified software, you'll end up with only alternate characters on the screen and a rather cryptic message! In the next issue of ACCESS, we'll have some spiffy software routines to use with the "VDM-½." Meanwhile, you can probably come up with some of your own. (Drop us a line if you run across anything interesting.) Just remember that a left shift of a 64-character address will give you the 32-character address, providing that you shift in a 0 to bit 0. Good luck! 1. Cut traces at: A—pin 10 IC 10 B—pin 12 IC 10 C—pin 13 IC 10 D—pin 14 IC 10 E—pin 7 IX 3 F—pin 14 IC 22 2. Add jumpers between: A—IC 24 pin 11 and Ground B—IC 10 pin 10 and IC 3 pin 7 C—IC 10 pin 12 and IC 19 pin 4 D—IC 10 pin 13 and Ground E—IC 10 pin 14 and IC 14 pin 6 FLASH - VDM Access Flicker Eliminated, Part 2 In the last issue, we gave you a hardware modification to take care of the flicker produced whenever the VDM memory is being accessed. We also promised to explore the implications a bit further this time. So here's a subroutine for the VDM driver program that implements the modification via software. One thing to remember: if reads from the screen memory are needed by the driver, they have to be synchronized by a subroutine similar to this. This one only takes care of flickerless access to the memory. Next issue, we'll continue the flicker saga by providing a version of the Processor PATTERN program which contains this routine for flickerless display. 1000 1005 1010 1015 1020 1025 1030 1035 1040 1045 1050 1055 1060 1065 1070 1075 1080 1085 1090 1095 1100 1115 1110 1115 1120 1125 1130 1135 1140 1145 1150 1155 1160 1165 1170 1175 1180 1185 1190 1195 1200 1205 1210 1215 1220 1225 1230 1235 1240 1245 1250 1255 1260 1265 1270 * THIS ROUTINE MOVES A CHAR. IN REGISTER B * TO VDM DISPLAY MEMORY * ***** ASSUMPTIONS: * * 1. THE CALLER HAS SET UP A STACK * * 2. REGISTER PAIR H&L CONTAIN THE * VDM DISPLAY MEMORY ADDRESS * * 3. THE ROUTINE IS RUNNING IN MEMORY * WITH NO (0) WAIT STATES. * * * * START PUSH B MVI C,2 SYNC BIT MASK (BIT 1) * * CATCH FALLING EDGE OF SYNC * HILP IN 0C8H VDM STATUS PORT ANA C ONLY BIT 1 REMAINS JZ HILP UNTIL SYNC IS HI * * SYNC IS HI. NOW WAIT * TILL IT IS LOW * LOLP IN 0C8H VDM STATUS PORT ANA C ONLY BIT 1 REMAINS JNZ LOLP * * DISPLAY SWEEP IS NOW AT LEFT MARGIN * CALL WAIT SO SWEEP CAN MOVE TO * RIGHT MARGIN * * NOW THAT SWEEP IS OFF THE SCREEN: * MOV M,B ACCESS DISPLAY MEMORY * * POP B GIVE IT BACK RET * * THIS ROUTINE DELAYS FOR JUST ENOUGH TIME * TO ALLOW THE SWEEP TO CROSS THE SCREEN * *** ALTER IT WITH CARE *** * WAIT NOP PUSH H POP H PUSH H POP H RET Cann's Axiom: When all else fails, read the instructions. This issue's Bug Squad focuses on the Sol PC board Revision D, the one you have. All the fixes described are aimed at worst case conditions, so hopefully you've never encountered the problems. But we do recommend making the changes now to forestall future headaches that might crop up if you use demanding peripherals such as discs. All the modifications described will be incorporated in the forthcoming Revision E board, so in the future we'll be designing on the assumption that all boards in the field have these fixes. Now, you may wonder where we get the gall to blurt out that our product is not the ultimate in all respects. Quite simply, we have too much experience in product design to let ourselves get away with the attitude that goes, "We're perfect. Something must be wrong with you:" So things can be better, and here's how. 1. Clock Width Fix The bug: Currently the width of the phase 1 (φ φ1) clock pulse is 70 nanoseconds. If you want to bring it into spec with existing 8080 chips, you should increase it to 140 nanoseconds. (8080A or 9080A are OK at 70 nsec.) The squasher: On the top (component) side of the board, cut the trace between jumpers D and E of (U90 and U91) of the clock generator. On the bottom (solder) side of the board, connect the jumper from pin E to the feedthrough which leads to pin 5 of U91. 2. Phantom Glitch Fix The bug: Occasionally a Sol will power up with three "phantom" cycles instead of the necessary four, causing a "crash: These are the cycles which use the "four phase wonder" software in the monitor. The squasher: Connect a jumper on the solder side of the board as shown in Figure B. It goes from pin 4 of U76 to the feedthrough immediately below pin 1 of U76. 3. Ground Noise Fix The bug: The paths from the bus drivers to the bus ground are too long, producing occasional ground noise. The Squasher: Shorten them by connecting jumpers on the solder side of the board as shown in Figure B. They go from pin 8 of IC's U33, U50, U68, and U81 to the ground feedthrough leading to C45. 4. Protect Fix The bug: The protect line is floating, which allows noise pulses to set a memory board "protected" at the most inconvenient times. The squasher: Connect a jumper wire on the solder side as shown in Figure B. It goes from the ground terminal of C 11 to pin 70 of the 100-pin bus connector J11. 5. DMA/Interrupt Unscramble This fix has probably been included in your kit or preassembled board, but better check the connections just to make sure. The bug: PINT (pin 73), PHOLD (pin 74), and PINTS (pin 26) got scrambled at an early stage in development and weren't noticed until too late. The squasher: On the component side of the board, cut the trace leading to pin 73 on J11; on the solder side, cut the trace leading to pin 1 of U45, and also the second trace to the right of U64. (Refer to Figure B). Now connect three jumpers: From pin 73 of J11 to pin 1 of U45. From pin 28 of J11 to the feedthrough indicated (the one that was isolated by the cut on the component side). From the feedthrough directly below pin 1 of U45 to the feedthrough to the right of pin 3 of U64. 6 MWRITE Fix The bug: If you want to operate with DMA devices which write into memory, such as discs, you; need to be able to generate the MWRITE pulse externally. The squasher: You accomplish this by connecting the signals which generate MWRITE directly to the bus. On the solder side of the board, cut the trace which leads to pin 7 of U93. Now connect a jumper from the trace which has been isolated, to the feedthrough leading to pin 9 of U94. Now, still on the solder side, locate the feedthrough immediately below pin 1 of U92 and break the trace leading to it; do NOT break the trace leading to pin 1 of U92. Connect a jumper from that feedthrough to pin 13 of U107. Further Remarks on D and E The other major change between the D and E revision Sol boards involves reversing the order of the parallel input data lines as connected to the parallel connector J2. The schematic is correct for the D board, and the list of signals in the manual is correct for the E board. The change will simplify future connections to J2 by placing the POD lines adjacent to the PID lines; that way, you can create a bidirectional input/output bus with a simple jumpering scheme at the connector. We're planning an adaptor connector to convert Rev. D J2 into Rev. E J2. It will have a 25-pin plug, a PC board which reverses the connections from pins 6 to 13, and a 25-pin socket connector. If you're developing a device which plugs into the Sol J2, reverse the order of pins 6 through 13 and use this adapter (PTC pt. 900011) to ensure that your plug-in device will be compatible with E revision Sol's. 7. Current Loop Fix The bug: R23 and R24 should be connected to +12 volts instead of +5 volts. The squasher: Break the large trace on the solder side of the board which leads to these two resistors. Still on the solder side, connect a jumper from the isolated end of R23 to the +12 volt feedthrough as shown. Be sure that you do not accidentally connect to the -12 volt feedthrough, which is slightly higher than the +12 volt one. Weinberg's Law: If builders built buildings the way programmers wrote programs then the first woodpecker that came along would destroy civilization. And a Bug in 5K(pre-Sol) The bug: Our attention has been called to some problems with the integer function in BASIC-5 — the non-Sol version. The squasher: Page 32 of the 5K BASIC manual (Software #2) should be changed to read as follows: 0BAA 0BAA 0BAB 0BAD 0BAF 0BB2 0A D6 81 16 05 FA BF 0B 00 0BB3 0BB5 0BB6 0BB7 D6 05 D0 57 0B 0BB8 0BB9 0BBA 0BBC 0BBD 0BBE 08 0A E6 F0 02 14 C8 0BBF 0BC0 0BC1 0BC2 0BC5 AF 02 14 C2 B8 0B C9 0000 0001 0002 0003 0004 0005 0006 0007 0008 0009 0010 0011 0012 0013 0014 0015 0016 0017 0018 0019 0020 0021 0022 0023 0024 0025 0026 0027 0028 0029 0030 0031 0032 * * * BASIC-5 INTEGER FIX AINT * * * ORG 0BAAH LDAX SUI MVI JM NOP B 129 D,FPSIZ AINT3 . SPACE FILLER EXP > 0 * AINT2 * AINT3 SUI RNC MOV DCX FPNIB-1 DCX LDAX ANI STAX INR RZ B B 360Q B D XRA STAX INR JNZ RET A B D AINT2 D,A B COUNT * * Your ALS-8 Applications Notes are on the Way! After a seemingly interminable delay, the first batch of Application notes are really and truly in the mail to all you ALS-8 Users' Group members. Once the material is in your hot little hands (in a very fancy binder, no less), you'll be better able to appreciate the power and versatility of your ALS-8, and you should have some very happy hours of computing. If you haven't received your notes by the time you read this, please drop us a note right now, so we can track down whatever clerical or shipping errors crossed you up. Our sincerest apologies for the delay. Ninety-Ninety `Rule of Project Schedules: The first ninety percent of the task takes ninety percent of the time and the last ten percent takes the other ninety percent. ** SOFTWARE TECHNOLOGY CORP. P.O. BOX 5260 SAN MATEO, CA 94402 CUTER (TM) 77-03-27 COPYRIGHT (C) 1977 C000 7F C001 C3 D7 C1 C004 C007 C00A C00D C010 C013 C016 C3 C3 C3 C3 C3 C3 C3 18 DC FF 42 7F C7 7B C2 C5 C5 C6 C6 C6 C7 PROGRAM DEVELOPMENT SYSTEM 9999 0002 0003 0004 0005 0006 0007 0008 0009 0010 0011 0012 0013 0014 0015 0016 0017 0018 0019 0020 0021 0022 0023 0024 0025 0026 0027 0028 0029 0030 0031 0032 0033 0034 0035 0036 0037 0038 0039 0040 0041 0042 0043 0044 0045 0046 0047 0048 0049 0050 0051 0052 0053 0054 0055 0056 0057 0058 0059 0060 0061 0062 0063 0064 0065 0066 0067 0068 0069 0070 0071 0072 0073 0074 0075 0076 0077 0078 COPY CUTER1/1 * * * * CUTER(TM) * * COPYRIGHT (C) 1977 * SOFTWARE TECHNOLOGY CORP. * P.O. BOX 5260 * SAN MATEO, CA 94402 * (415) 349-8080 * * A L L R I G H T S R E S E R V E D ! ! ! * * * VERSION 1.3 * 77-03-27 * * * THIS PROGRAM IS DESIGNED TO BE A STANDALONE CUTS * OPERATING SYSTEM. CUTER IS DESIGNED TO BE READ IN FROM * CASSETTE TAPE OR TO BE RESIDENT IN READ-ONLY-MEMORY. * CUTER SUPPORTS VARIOUS DEVICES INCLUDING SERIAL, * PARALLEL, THE PROCESSOR TECHNOLOGY VDM(TM) AND UP TO * TWO CUTS TAPE DRIVES. * * CUTER(TM) HAS BEEN WRITTEN SO AS TO BE COMPATIBLE WITH * SOLOS(TM). THE FOLLOWING KEYS ARE USED BY CUTER(TM) * IN PLACE OF THE SPECIAL KEYS ON THE SOL KEYBOARD: * * CURSOR UP CTL-W * CURSOR LEFT CTL-A * CURSOR RIGHT CTL-S * CURSOR DOWN CTL-Z * CURSOR HOME CTL-N * CLEAR SCREEN CTL-K * MODE CTL-@ * * * * * * AUTO-STARTUP CODE * START MOV A,A SHOW THIS IS CUTER (SOLOS=00) * THIS BYTE ALLOWS AUTOMATIC POWER ON ENTRY * WHEN IN ROM SUPPORTING THIS HARDWARE FEATURE. INIT JMP STRTA SYSTEM RESTART ENTRY POINT * * THESE JUMP POINTS ARE PROVIDED TO ALLOW COMMON ENTRY * LOCATIONS FOR ALL VERSIONS OF CUTER. THEY ARE USED * EXTENSIVELY BY CUTS SYSTEM PROGRAMS AND IT IS RECOMMENDED * THAT USER ROUTINES ACCESS CUTER ROUTINES THROUGH THESE * POINTS ONLY! * RETRN JMP COMND RETURN TO CUTER COMMAND PROCESSOR FOPEN JMP BOPEN CASSETTE OPEN FILE ENTRY FCLOS JMP PCLOS CASSETTE CLOSE FILE ENTRY RDBYT JMP RTBYT CASSETTE READ BYTE ENTRY WRBYT JMP WTBYT CASSETTE WRITE BYTE ENTRY RDBLK JMP RTAPE CASSETTE READ BLOCK ENTRY WRBLK JMP WTAPE CASSETTE WRITE BLOCK ENTRY * * SYSTEM I/O ENTRY POINTS * * THESE FOUR ENTRY POINTS ARE USED TO EITHER INPUT * OR OUTPUT TO CUTER PSUEDO PORTS. * THESE PSUEDO PORTS ARE AS FOLLOWS: * * PORT INPUT OUTPUT * -------------------- --------------------* 0 KEYBOARD INPUT BUILT-IN VDM DRIVER * ACTUAL PORT 3 PORT C8, MEMORY FROM CC00 * 1 SERIAL PORT SERIAL PORT * ACTUAL PORT 1 ACTUAL PORT 1 * 2 PARALLEL PORT PARALLEL PORT * ACTUAL PORT 2 ACTUAL PORT 2 * 3 USER'S INPUT RTN USER'S OUTPUT ROUTINE C019 3A 07 C8 C01C C3 2E C0 C01F 3A 06 C8 C022 C022 E5 C023 21 09 C3 C026 C028 C029 C02A C02B E6 03 07 85 6F C3 87 C2 C02E C02E E5 C02F 21 01 C3 C032 C3 26 C0 C035 C037 C038 C03A C035 DB 00 2F E6 01 C8 C03B DB 03 C03D C9 C03E 0079 0080 0081 0082 0083 0084 0085 0086 0087 0088 0089 0090 0091 0092 0093 0094 0095 0096 0097 0098 0099 0100 0101 0102 0103 0104 0105 0106 0107 0108 0109 0110 0111 0112 0113 0114 0115 0116 0117 0118 0119 0120 0121 0122 0123 0124 0125 0126 0127 0128 0129 0130 0131 0132 0133 0134 0135 0136 0137 0138 0139 0140 0141 0142 0143 0144 0145 0146 0147 0148 0149 0150 0151 0152 0153 0154 0155 0156 0157 0158 0159 0160 0161 0162 0163 * * STATUS FOR ACTUAL PORTS 1, 2 AND 3 IS VIA ACTUAL * PORT 0. THE BITS OF PORT ZERO ARE DEFINED AS FOLLOWS: * * : : : : : :---- : --- : --- : * : TBE : RDA : : : :PXDR : PDR : KDR : * BIT 7 6 5 4 3 2 1 0 * * WHERE: * TBE 1=TRANSMITTER BUFFER EMPTY (SERIAL) * RDA 1=READER DATA AVAILABLE (SERIAL) * ---* PXDR 0=PARALLEL EXTERNAL DEVICE READY * --* PDR 0=PARALLEL DATA READY * --* KDR 0=KEYBOARD DATA READY * * * * * NOTE: SOUT AND SINP ARE "LDA" INSTRUCTIONS. * THIS FACT IS USED TO ALLOW ACCESS TO THE * BYTES "OPORT" AND "IPORT" DYNAMICALLY. * THESE MUST REMAIN "LDA" INSTRUCTIONS!!!!! * SOUT LDA OPORT OUTPUT VIA STANDARD OUTPUT PSUEDO PORT AOUT JMP OUTPR OUTPUT VIA PSUEDO PORT SPECIFIED IN REG A SINP LDA IPORT INPUT VIA STANDARD INPUT PSUEDO PORT AINP EQU $ INPUT VIA PSUEDO PORT SPECIFIED IN REG A * -----------END OF SYSTEM ENTRY POINTS---------* * * AINP CONTINUES HERE (IT COULD HAVE BEEN A "JMP" THOUGH) PUSH H SAVE HL FM ENTRY LXI H,ITAB * * THIS ROUTINE PROCESSES THE I/O REQUESTS * IOPRC ANI 3 KEEP REGISTER "A" TO FOUR VALUES RLC . COMPUTE ENTRY ADDRESS ADD L MOV L,A WE HAVE ADDRESS JMP DISPT DISPATCH TO IT * * OUTPR EQU $ PROCESS OUTPUT REQUESTS PUSH H SAVE REGS LXI H,OTAB POINT TO OUTPUT DISPATCH TABLE JMP IOPRC DISPATCH FOR PROPER PSUEDO PORT * * * * CUTER SYSTEM I/O ROUTINES * * * THIS ROUTINE IS A MODEL OF ALL INPUT ROUTINES WITHIN * CUTER. THE FIRST ROUTINE "KREA1" PERFORMS THE INPUT * FROM THE STANDARD KEYBOARD ON PARALLEL PORT 3. * ALL STANDARD INPUT DRIVERS RETURN EITHER THE CHARACTER * WITH A NON-ZERO FLAG, OR JUST A ZERO FLAG INDICATING * THAT NO CHARACTER IS AVAILABLE YET. IT WILL BE THE * RESPONSIBILITY OF THE USER TO LOOP WAITING FOR A * CHARACTER, OR TO USE THE INPUT AS A STATUS REQUEST. * WHEN A CHARACTER IS AVAILABLE, IT IS RETURNED IN REG A. * * THE FOLLOWING KEYBOARD ROUTINE MAY BE USED AS A SAMPLE * OF HOW TO WRITE A USER INPUT ROUTINE. * * KEYBOARD INPUT ROUTINE * KREA1 EQU $ KEYBOARD READ ROUTINE IN STAPT GET STATUS WORD CMA . INVERT IT FOR PROPER RETURN ANI KDR TEST NOT KEYBOARD DATA READY RZ . ZERO IF NO CHARACTER RECEIVED * IN KDATA GET CHARACTER RET . GO BACK WITH IT * * * * SERIAL INPUT ROUTINE * SREA1 EQU $ SERIAL INPUT ROUTINE C03E DB 00 C040 E6 40 C042 C8 C043 DB 01 C045 C9 C046 C048 C049 C04C C04D C04F C046 DB 00 17 D2 46 C0 78 D3 01 C9 C050 C052 C053 C055 C056 C058 C050 DB 00 2F E6 02 C8 DB 02 C9 C059 C05B C05D C060 C061 C063 C059 DB 00 E6 04 C2 59 C0 78 D3 02 C9 C064 C064 E5 C065 2A 00 C8 C068 C3 6F C0 C06B C06B E5 C06C 2A 02 C8 C06F C06F 7D C070 B4 C071 C2 8B C2 C074 C3 0F C2 C077 C077 E5 C078 D5 C079 C5 C07A 3A 0C C8 C07D B7 C07E C2 87 C1 C081 C082 C084 C085 78 E6 7F 47 CA 9F C0 C088 21 E2 C2 C08B CD A5 C0 0164 0165 0166 0167 0168 0169 0170 0171 0172 0173 0174 0175 0176 0177 0178 0179 0180 0181 0182 0183 0184 0185 0186 0187 0188 0189 0190 0191 0192 0193 0194 0195 0196 0197 0198 0199 0200 0201 0202 0203 0204 0205 0206 0207 0208 0209 0210 0211 0212 0213 0214 0215 0216 0217 0218 0219 0220 0221 0222 0223 0224 0225 0226 0227 0228 0229 0230 0231 0232 0233 0234 0235 0236 0237 0238 0239 0240 0241 0242 0243 0244 0245 0246 0247 0248 IN ANI RZ STAPT SDR . GET STATUS TEST FOR SERIAL DATA READY FLAGS ARE SET * * IN SDATA GET DATA BYTE IT IS UP TO THE CALLER TO STRIP PARITY IF DESIRED RET . WE HAVE IT * * * SERIAL DATA OUTPUT * SEROT EQU $ SERIAL OUTPUT ROUTINE IN STAPT GET STATUS RAL . PUT HIGH BIT IN CARRY JNC SEROT LOOP UNTIL TRANSMITTER BUFFER IS EMPTY MOV A,B GET THE CHARACTER BACK OUT SDATA SEND IT OUT RET . AND WE'RE DONE * * * PARALLEL DATA INPUT PARIT EQU $ GET CHAR FM PARALLEL PORT IN STAPT STATUS CMA . INVERT FOR PROPER RETURN ANI PDR IS DATA READY? RZ . NO--JUST EXIT IN PDATA YES--GET CHAR THEN RET . THEN EXIT * * * PARALLEL DATA OUTPUT ROUTINE PAROT EQU $ OUTPUT CHAR TO PARALLEL PORT IN STAPT STATUS ANI PXDR IS EXTERNAL DEVICE READY? JNZ PAROT NO--WAIT TIL IT IS MOV A,B GET CHAR OUT PDATA SEND DATA NOW RET . DONE * * * USER DEFINED INPUT/OUTPUT ROUTINES ERRIT EQU $ USER INPUT ROUTINE PUSH H SAVE ORIG HL LHLD UIPRT GET USER'S RTN ADDR JMP ERRO1 MERGE TO VERIFY THE ADDR * ERROT EQU $ USER OUTPUT ROUTINE PUSH H SAVE ORIG HL LHLD UOPRT GET USER'S RTR ADDR ERRO1 EQU $ WE MERGE HERE TO VFY ADDR MOV A,L ZERO=UNDEFINED ORA H IS IT? JNZ DISP1 NO--VALID--OFF TO IT JMP STRTD RESET I/O PORTS AND BACK TO COMMAND MODE * * * * VIDEO DISPLAY ROUTINES * * * THESE ROUTINES ALLOW FOR STANDARD VIDEO TERMINAL * OPERATIONS. ON ENTRY, THE CHARACTER FOR OUTPUT IS IN * REGISTER B AND ALL REGISTERS ARE UNALTERED ON RETURN. * * * VDM01 EQU $ VDM OUTPUT DRIVER PUSH H SAVE HL PUSH D SAVE DE PUSH B * * PROCESS ESC SEQUENCE IF ANY * LDA ESCFL GET ESCAPE FLAG ORA A JNZ ESCS IF NON ZERO GO PROCESS THE REST OF THE SEQUENCE * MOV A,B GET CHAR ANI 7FH CLR HI BIT IN CASE MOV B,A USE CHAR STRIPPED OF HI BIT FOR COMPATABILITY JZ GOBK MAKE A QUICK EXIT FOR A NULL * LXI H,TBL CALL TSRCH GO PROCESS * C08E C091 C092 C094 C095 C098 C099 C09A C09B C09C C09F C0A0 C0A1 C0A2 C08E CD 44 C1 7E F6 80 77 2A 0A C8 2C AF 2B BC C2 9A C0 C1 D1 E1 C9 C0A3 C0A3 23 C0A4 23 C0A5 C0A6 C0A7 C0AA C0AB C0AC C0AF C0B0 C0B3 C0B4 7E B7 CA B8 23 C2 E5 CD E3 C3 B7 C0 A3 C0 5E C1 87 C2 C0B7 C0B7 78 C0B8 FE 7F C0BA C8 C0BB C0BE C0BF C0C2 C0C4 C0C7 C0CA C0CC CD 70 3A FE DA 3A FE C2 C0CF C0D0 C0D3 C0D4 C0D7 C0D8 C0DB C0DE C0DF C0E1 AF 32 4F CD AF CD 3A 3C E6 C3 C0E4 C0E7 C0E8 C0EA C0ED 3A 08 3C E6 3F 32 08 C0 C0EE 3A 09 3C E6 0F 32 09 C9 C0EE C0F1 C0F2 C0F4 C0F7 44 C1 08 3F E4 09 0F E4 C8 C0 C8 C0 08 C8 4B C1 22 C1 0A C8 0F 11 C1 C8 C8 C8 C8 C0F8 21 00 CC C0FB 36 A0 C0FD 23 0249 0250 0251 0252 0253 0254 0255 0256 0257 0258 0259 0260 0261 0262 0263 0264 0265 0266 0267 0268 0269 0270 0271 0272 0273 0274 0275 0276 0277 0278 0279 0280 0281 0282 0283 0284 0285 0286 0287 0288 0289 0290 0291 0292 0293 0294 0295 0296 0297 0298 0299 0300 0301 0302 0303 0304 0305 0306 0307 0308 0309 0310 0311 0312 0313 0314 0315 0316 0317 0318 0319 0320 0321 0322 0323 0324 0325 0326 0327 0328 0329 0330 0331 0332 0333 GOBACK EQU $ RESET CURSOR AND DELAY CALL VDADD GET SCRN ADDR MOV A,M GET CHAR ORI 80H INVERSE VIDEO MOV M,A CURSOR IS NOW THERE LHLD SPEED-1 GET DELAY SPEED INR L MAKE IT DEFINITELY NON-ZERO XRA A DELAY ENDS WHEN H=ZERO TIMER DCX H LOOP FOR DELAY AMNT CMP H IS IT DONE YET JNZ TIMER NO--KEEP DELAYING GOBK POP B POP D RESTORE ALL REGISTERS POP H RET . EXIT FROM VDMOT * * NEXT EQU $ GO TO NEXT CHR INX H INX H * * THIS ROUTINE SEARCHES FOR A MATCH OF THE CHAR IN "B" * TO THE CHAR IN THE TBL POINTED TO BY HL. * TSRCH MOV A,M GET CHR FROM TABLE ORA A SEE IF END OF TBL JZ CHAR ZERO IS THE LAST CMP B TEST THE CHR INX H POINT FORWARD JNZ NEXT PUSH H FOUND ONE...SAVE ADDRESS CALL CREM REMOVE CURSOR XTHL . RESTORE ADDR OF CHAR ENTRY IN TBL JMP DISPT DISPATCH FOR CURSOR CONTROL * * CHAR EQU $ WE HAVE A CHAR MOV A,B GET CHARACTER CPI 7FH IS IT A DEL? RZ . GO BACK IF SO * * * OCHAR CALL VDADD GET SCREEN ADDRESS MOV M,B PUT CHR ON SCREEN LDA NCHAR GET CHARACTER POSITION CPI 63 END OF LINE? JC OK LDA LINE CPI 15 END OF SCREEN? JNZ OK * * END OF SCREEN...ROLL UP ONE LINE * SCROLL XRA A STA NCHAR BACK TO FIRST CHAR POSITION SROL MOV C,A CALL VDAD CALCULATE LINE TO BE BLANKED XRA A CALL CLIN1 CLEAR IT LDA BOT INR A ANI 0FH JMP ERAS3 * * INCREMENT LINE COUNTER IF NECESSARY * OK LDA NCHAR GET CHR POSITION INR A ANI 3FH MOD 64 STA NCHAR STORE THE NEW RNZ . MORE CHARS THIS LINE PDOWN EQU $ MOVE CURSOR DOWN ONE LINE LDA LINE GET THE LINE COUNT INR A CURSC ANI 0FH MOD 15 INCREMENT CUR STA LINE STORE THE NEW RET * * ERASE SCREEN * PERSE LXI H,VDMEM POINT TO SCREEN MVI M,80H+' ' THIS IS THE CURSOR * INX H NEXT CHAR C0FE C100 C101 C102 C104 C107 C0F4 36 20 23 7C FE D0 DA FE C0 37 C108 C10A C10D C110 C108 3E 00 32 09 C8 32 08 C8 D0 C111 D3 C8 C113 32 0A C8 C116 C9 C117 C11A C11B C11C C11F C122 C124 C125 C127 C128 C129 C117 3A 07 B7 C0 CD 44 3A 08 FE 40 D0 36 20 23 3C C3 22 C8 C1 C8 C1 C12C 3A 09 C8 C12F 3D C130 C3 F2 C0 C133 3A 08 C8 C136 3D C137 C137 E6 3F C139 32 08 C8 C13C C9 C13D 3A 08 C8 C140 3C C141 C3 37 C1 C144 C147 C148 C14B C14C C14F C150 C151 C152 C153 C155 C157 C158 C159 C15B C15C C15D 3A 4F 3A 6F 3A 85 0F 0F 6F E6 C6 67 7D E6 81 6F C9 08 C8 09 C8 0A C8 03 CC C0 C15E CD 44 C1 C161 7E C162 E6 7F 0334 0335 0336 0337 0338 0339 0340 0341 0342 0343 0344 0345 0346 0347 0348 0349 0350 0351 0352 0353 0354 0355 0356 0357 0358 0359 0360 0361 0362 0363 0364 0365 0366 0367 0368 0369 0370 0371 0372 0373 0374 0375 0376 0377 0378 0379 0380 0381 0382 0383 0384 0385 0386 0387 0388 0389 0390 0391 0392 0393 0394 0395 0396 0397 0398 0399 0400 0401 0402 0403 0404 0405 0406 0407 0408 0409 0410 0411 0412 0413 0414 0415 0416 0417 0418 ERAS1 * PHOME * ERAS3 * * CLIN2 CLINE CLIN1 EQU MVI INX MOV CPI JC STC $ M,' ' H A,H 0D0H ERAS1 . LOOP TO CLR SCRN BLANK IT OUT NEXT SCRN LOC SEE IF DONE DID IT GO ABOVE VDM NO--MORE SAY WE WANT TO DROP THRU TO ERAS3 EQU MVI STA STA RNC $ A,0 LINE NCHAR . RESET CURSOR CLEAR, LEAVE ZERO LINE LEFT SIDE OF THIS IS JUST OUT STA RET DSTAT BOT RESET SCROLL PARAMETERS BEGINNING OF TEXT OFFSET EQU LDA ORA RNZ CALL LDA CPI RNC MVI INX INR JMP $ OPORT A . VDADD NCHAR 64 . M,' ' H A CLIN1 HERE TO SEE IF VDM OUTPUT GET CRNT OUTPUT PORT LDA MOV LDA MOV LDA ADD RRC RRC MOV ANI ADI MOV MOV ANI ADD MOV RET NCHAR C,A LINE L,A BOT L . . L,A 3' THE PROMPT JMP SOUT PUT IT ON THE SCREEN * CRLF MVI B,LF LINE FEED CALL SOUT MVI B,CR CARRIAGE RETURN CALL SOUT LDA NUCNT GET COUNT OF NULLS TO OUTPUT MOV C,A SAVE COUNT IN C NULOT DCR C RM . COUNTED DOWN PAST ZERO (MAX COUNT IS X'7F') XRA A HERE IS THE NULL CALL OUTH OUTPUT IT JMP NULOT LOOP FOR NUMBER OF NULLS * * * SCAN OVER UP TO 12 CHARACTERS LOOKING FOR A BLANK * SBLK MVI C,12 MAXIMUM COMMAND STRING SBLK1 LDAX D CPI BLANK JZ SCHR GOT A BLANK NOW SCAN PAST IT INX D CPI '=' A EQUAL WILL ALSO STOP US (AT NEXT CHAR) JZ SCHR FOUND, DE PT TO NEXT CHAR DCR C NO MORE THAN TWELVE JNZ SBLK1 RET . GO BACK WITH ZERO FLAG SET * * * SCAN PAST UP TO 10 BLANK POSITIONS LOOKING FOR * A NON BLANK CHARACTER. * SCHR MVI C,10 SCAN TO FIRST NON BLANK CHR WITHIN 10 SCHR1 LDAX D GET NEXT CHARACTER CPI SPACE RNZ . WE'RE PAST THEM INX D NEXT SCAN ADDRESS DCR C RZ . COMMAND ERROR JMP SCHR1 KEEP LOOPING * * THIS ROUTINE SCANS OVER CHARACTERS, PAST BLANKS AND * CONVERTS THE FOLLOWING ADDRESS TO HEX. ERRORS RETURN TO * THE ERROR HANDLER. C378 CD 59 C3 C37B CA 6B C4 C37E C381 C382 C384 C385 C387 C388 C38A 21 1A FE C8 FE C8 FE C8 00 00 C38B C38C C38D C38E C38F C392 C395 C396 C397 C398 29 29 29 29 CD 9B C3 D2 6B C4 85 6F 13 C3 81 C3 C39B C39D C39F C3A0 C3A2 C3A4 D6 FE D8 D6 FE C9 C3A5 C3A8 C3A9 C3AC C3A5 CD 59 C3 C8 CD 7E C3 C9 C3AD C3B0 C3B1 C3B4 C3B5 C3AD CD 78 C3 E5 CD A5 C3 D1 EB C3B6 C3B9 C3BC C3BF CD CD CD 0E C3C1 C3C2 C3C3 C3C6 C3C7 7E C5 CD DE C3 7C BA 20 2F 3A 30 0A 07 10 42 C3 D9 C3 F7 C3 10 0843 0844 0845 0846 0847 0848 0849 0850 0851 0852 0853 0854 0855 0856 0857 0858 0859 0860 0861 0862 0863 0864 0865 0866 0867 0868 0869 0870 0871 0872 0873 0874 0875 0876 0877 0878 0879 0880 0881 0882 0883 0884 0885 0886 0887 0888 0889 0890 0891 0892 0893 0894 0895 0896 0897 0898 0899 0900 0901 0902 0903 0904 0905 0906 0907 0908 0909 0910 0911 0912 0913 0914 0915 0916 0917 0918 0919 0920 0921 0922 0923 0924 0925 0926 0927 * SCONV CALL JZ SBLK ERR1 * * THIS ROUTINE CONVERTS ASCII DIGITS INTO BINARY FOLLOWING * A STANDARD HEX CONVERSION. THE SCAN STOPS WHEN AN ASCII * SPACE IS ENCOUNTERED. PARAMETER ERRORS REPLACE THE ERROR * CHARACTER ON THE SCREEN WITH A QUESTION MARK. * SHEX LXI H,0 CLEAR H & L SHE1 LDAX D GET CHARACTER CPI 20H IS IT A SPACE? RZ . IF SO CPI '/' RZ CPI ':' RZ * HCONV DAD H MAKE ROOM FOR THE NEW ONE DAD H DAD H DAD H CALL HCOV1 DO THE CONVERSION JNC ERR1 NOT VALID HEXIDECIMAL VALUE ADD L MOV L,A MOVE IT IN INX D BUMP THE POINTER JMP SHE1 * HCOV1 SUI 48 REMOVE ASCII BIAS CPI 10 RC . IF LESS THAN 9 SUI 7 IT'S A LATTER?? CPI 10H RET . WITH TEST IN HAND * * * THIS ROUTINE WILL SEE IF A FIELD (OPERAND) IS PRESENT. * IF NOT, THEN HL WILL REMAIN AS THEY WERE ON ENTRY. * IF IT WAS PRESENT, THEN HL=THAT VALUE IN HEX. * PSCAN EQU $ OPTIONAL PIELD SCANNER CALL SBLK SEE IF FIELD IS PRESENT RZ . RETURN LEAVING HL AS THEY WERE ON ENTRY CALL SHEX FIELD IS THERE, GO GET IT RET . HL= EITHER OPTIONAL FIELD (HEX), OR AS IT WAS * * * * * DUMP COMMAND * * THIS ROUTINE DUMPS CHARACTERS FROM MEMORY TO THE * CURRENT OUTPUT DEVICE. * ALL VALUES ARE DESPLAYED AS ASCII HEX. * * THE COMMAND FORM IS AS FOLLOWS: * * DUMP ADDR1 ADDR2 * * THE VALUES FROM ADDR1 TO ADDR2 ARE THEN OUTPUT TO THE * OUTPUT DEVICE. IF ONLY ADDR1 IS SPECIFIED THEN THE * VALUE AT THAT ADDRESS IS OUTPUT. * * IF WHILE DUMPING, THE MODE KEY IS PRESSED, THE DUMP WILL * BE TERMINATED. IF THE SPACE BAR IS PRESSED, THE DUMP * WILL BE TEMPORARILY SUSPENDED UNTIL ANY KEY IS PRESSED. * DUMP EQU $ SET UP REGS TO DUMP SPECIFIED AREA CALL SCONV GET START ADDR (REQUIRED) PUSH H SAVE THE START ADDR CALL PSCAN GET OPTIONAL END ADDR, HL=THIS OR START ADDR POP D DE=START ADDR XCHG . DE=END ADDR, HL=START ADDR NOW * DLOOP CALL CRLF CALL ADOUT OUTPUT ADDRESS CALL BOUT ANOTHER SPACE TO KEEP IT PRETTY MVI C,16 VALUES PER LINE * DLP1 MOV A,M GET THE CHR PUSH B SAVE VALUE COUNT CALL HBOUT SEND IT OUT WITH A BLANK MOV A,H CRNT ADDR CMP D VERSUS ENDING ADDR C3C8 C3CB C3CC C3CD C3D0 C3D1 C3D2 C3D3 C3D6 DA D0 7D BB D2 18 C3D0 C1 23 0D C2 C1 C3 B6 C3 C2 C3 C3 C3D9 7C C3DA CD FC C3 C3DD 7D C3DE C3E1 C3E4 C3E7 C3E9 C3EC C3EE C3F1 C3F4 C3F7 C3F9 CD CD CA E6 CA FE C2 CD CA 06 C3 FC 1F F7 7F 18 20 F7 1F F1 20 19 C3 C0 C3 C3FC C3FD C3FE C3FF C400 C401 C404 4F 0F 0F 0F 0F CD 05 C4 79 C405 C407 C409 C40B C40E C410 C411 E6 C6 FE DA C6 47 C3 C2 C3 C0 C3 C0 0F 30 3A 10 C4 07 19 C0 C414 CD 78 C3 C417 E5 C418 C41B C41D C420 C423 C426 CD 06 CD CD CD EB 42 3A 19 27 AA C3 C0 C2 C2 C427 0E 03 C429 CD 6E C3 C42C CA 18 C4 C42F C431 C434 C437 C439 C43C C43D C43E C43F C440 C441 FE CA CD FE CA 7D E1 77 23 E5 C3 2F 18 C2 7E C3 3A 44 C4 27 C4 C444 E3 C445 13 C446 C3 27 C4 0928 0929 0930 0931 0932 0933 0934 0935 0936 0937 0938 0939 0940 0941 0942 0943 0944 0945 0946 0947 0948 0949 0950 0951 0952 0953 0954 0955 0956 0957 0958 0959 0960 0961 0962 0963 0964 0965 0966 0967 0968 0969 0970 0971 0972 0973 0974 0975 0976 0977 0978 0979 0980 0981 0982 0983 0984 0985 0986 0987 0988 0989 0990 0991 0992 0993 0994 0995 0996 0997 0998 0999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 DLP1A JC MOV CMP JNC EQU POP INX DCR JNZ JMP DLP1A A,L E COMND $ B H C DLP1 DLOOP NOT DONE YET TRY LOW ORDER BYTE ALL DONE WHEN CRNT REACHES ENDING HERE TO KEEP DUMPING VALUES PER LINE BUMP THE LINE COUNT NOT ZERO IF MORE FOR THIS LINE DO A LFCR BEFORE THE NEXT * * OUTPUT HL AS HEX 16 BIT VALUE * ADOUT MOV A,H H FIRST CALL HEOUT MOV A,L THEN L FOLLOWED BY A SPACE * HBOUT CALL HEOUT CALL SINP SEE IF WE SHD ESCAPE FM DUMP JZ BOUT NO--ADD THE SPACE THEN ANI 7FH MAKE SURE ITS CLEAR OF PARITY JZ COMND EITHER MODE (OR CTL-@) CPI ' ' IS IT SPACE JNZ BOUT NO--IGNORE THE CHAR WTLP1 CALL SINP ON SPACE, WAIT FOR ANY OTHER CHAR JZ WTLP1 JUST LOOP AFTER A SPACE UNTIL ANY KEY PRESSED BOUT MVI B,' ' JMP SOUT PUT IT OUT * HEOUT MOV C,A GET THE CHARACTER RRC RRC MOVE THE HIGH FOUR DOWN RRC RRC CALL HEOU1 PUT THEM OUT MOV A,C THIS TIME THE LOW FOUR * HEOU1 ANI 0FH FOUR ON THE FLOOR ADI 48 WE WORK WITH ASCII HERE CPI 58 0-9? JC OUTH YUP! ADI 7 MAKE IT A LETTER OUTH MOV B,A OUTPUT IT FROM REGISTER 'B' JMP SOUT * * * ENTR COMMAND * * THIS ROUTINE GETS VALUES FROM THE KEYBOARD AND ENTERS * THEM INTO MEMORY. THE INPUT VALUES ARE SCANNED FOLLOWING * A STANDARD 'GCLIN' INPUT SO ON-SCREEN EDITING MAY TAKE * PLACE PRIOR TO THE LINE TERMINATOR. A SLASH '/' * ENDS THE ROUTINE AND RETURNS CONTROL TO THE COMMAND MODE. * ENTER CALL SCONV SCAN OVER CHARS AND GET ADDRESS PUSH H SAVE ADDRESS * ENLOP CALL CRLF MVI B,':' CALL SOUT DSPLY THE COLON CALL GCLI0 INIT AND PROCESS A LINE CALL STUP SET UP TO PROCESS INPUT LINE XCHG . ....TO DE * * ENLO1 MVI C,3 NO MORE THAN THREE SPACES BETWEEN VALUES CALL SCHR1 SCAN TO NEXT VALUE JZ ENLOP LAST ENTRY FOUND START NEW LINE * CPI '/' COMMAND TERMINATOR? JZ COMND IF SO... CALL SHEX CONVERT VALUE CPI ':' ADDRESS TERMINATOR? JZ ENLO3 GO PROCESS IF SO MOV A,L GET LOW PART AS CONVERTED POP H GET MEMORY ADDRESS MOV M,A PUT IN THE VALUE INX H PUSH H BACK GOES THE ADDRESS JMP ENLO1 CONTINUE THE SCAN * ENLO3 XTHL . PUT NEW ADDRESS ON STACK INX D MOVE SCAN PAST TERMINATOR JMP ENLO1 * C449 CD 78 C3 C44C C44C E5 C44D 21 00 C0 C450 C9 C451 C451 21 1C C8 C454 CD 59 C3 C457 06 06 C459 C45A C45C C45F C461 C464 C465 C466 C467 C468 1A FE CA FE CA 77 13 23 05 C2 C46B C46C C46E C471 C472 C475 C478 C47A C47D EB 36 3A B7 CA CD 06 CD C3 C480 C482 C483 C484 36 00 23 05 C2 80 C4 C487 C489 C48B C48E C48F C492 FE 3E C2 13 CD D6 C494 C496 C498 C49B C49C C49F C494 E6 01 3E 80 C2 9C C4 1F 32 54 C8 C9 C4A0 3E C4A1 AF C4A2 F5 20 80 C4 2F 80 C4 59 C4 3F 07 C8 18 42 3F 19 18 C2 C3 C0 C2 2F 01 94 C4 6C C3 30 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 * * EXECUTE COMMAND * * THIS ROUTINE GETS THE FOLLOWING PARAMETER AND DOES A * PROGRAM JUMP TO THE LOCATION GIVEN BY IT. IF PROPER * STACK OPERATIONS ARE USED WITHIN THE EXTERNAL PROGRAM * IT CAN DO A STANDARD 'RET'URN TO THE CUTER COMMAND MODE. * * EXEC CALL SCONV SCAN PAST BLANKS AND GET PARAMETER EXEC1 EQU $ HERE TO GO TO HL PUSH H SAVE ON STACK LXI H,START LET USER KNOW WHERE WE ARE RET . AND OFF TO USER * * * * * THIS ROUTINE GETS A NAME OF UP TO 5 CHARACTERS * FROM THE INPUT STRING. IF THE TERMINATOR IS A * SLASH (/) THEN THE CHARACTER FOLLOWING IS TAKEN * AS THE CASSETTE UNIT SPECIFICATION. * * NAME0 EQU $ ENTER HERE TO SET HL TO THEAD LXI H,THEAD PT WHERE TO PUT NAME NAME CALL SBLK SCAN OVER TO FIRST CHRS MVI B,6 * NAME1 LDAX D GET CHARACTER CPI ' ' NO UNIT DELIMITER JZ NFIL CPI '/' UNIT DELIMTTER JZ NFIL MOV M,A INX D BUMP THE SCAN POINTER INX H DCR B JNZ NAME1 NAME IS OK, FALL THRU TO 'ERR1' IF NOT * * CUTER ERROR HANDLER * ERR1 XCHG . GET SCAN ADDRESS ERR2 MVI M,'?' FLAG THE ERROR LDA OPORT SEE IF VIA VDM DRIVER ORA A JZ COMND YES--VDM SCREEN NOW HAS THE ? CALL CRLF MVI B,'?' SET UP THE ???? CALL SOUT INDICATE INPUT NOT VALID JMP COMND NOW READY FOR NEXT INPUT * * * * HERE WE HAVE SCANNED OFF THE NAME. ZERO FILL IN FOR * NAMES LESS THAN FIVE CHARACTERS. * NFIL MVI M,0 PUT IN AT LEAST ONE ZERO INX H DCR B JNZ NFIL LOOP UNTIL B IS ZERO * CPI '/' IS THERE A UNIT SPECIFICATION? MVI A,1 PRETEND NOT JNZ DEFLT INX D MOVE PAST THE TERMINATOR CALL SCHR GO GET IT SUI '0' REMOVE ASCII BIAS * DEFLT EQU $ CNVRT TO INTERNAL BIT FOR TAPE CONTROL ANI 1 JUST BIT ZERO MVI A,TAPE1 ASSUME TAPE ONE JNZ STUNT IF NON ZERO, IT IS ONE RAR . ELSE MAKE IT TAPE TWO STUNT STA FNUMF SET IT IN RET * * * * THIS ROUTINE PROCESSES THE XEQ AND GET COMMANDS * * TXEQ DB 3EH THIS BEGINS "MVI" OF THE "XRA" FOLLOWING TLOAD XRA A A=0 TLOAD, A=AF (#0) THEN XEQ PUSH PSW SAVE FLAG TO SAY WHETHER LOAD OR XEQ C4A3 C4A6 C4A9 C4AC 21 CD 21 CD C4AF C4B0 C4B3 C4B4 C4B5 C4B8 C4BB C4BC C4BF C4C0 C4C3 EB 21 7E B7 C2 21 E5 CD E1 CD DA C4C6 C4C9 C4CA C4CB C4CC C4CF C4D0 C4D3 C4D6 C4D7 C4DA C4DD CD F1 B7 C8 3A B7 FA 3A B7 C2 2A C3 2C 54 00 A5 C8 C4 00 C3 2C C8 BB C4 1C C8 44 C5 C7 C6 10 C5 4C C5 22 C8 10 C5 21 C8 10 C5 27 C8 4C C4 C4E0 C4E3 C4E6 C4E7 C4EA C4EB C4EC C4EF C4F2 C4F3 C4F4 C4F5 C4F6 C4F7 C4F8 C4F9 C4FB C4FC C4FD C4FE C501 C4E0 CD 51 CD 78 E5 CD 78 E3 E5 CD A5 22 25 E1 D1 E5 7B 95 6F 7A DE 00 94 67 23 22 23 E5 C502 C505 C508 C50B C50C C50D CD 21 CD D1 E1 C3 44 C5 1C C8 AB C7 C510 C513 C515 C518 C51B C51E CD 16 21 CD CD C3 42 06 21 66 4C 15 C4 C3 C3 C3 C8 C8 8C C7 C3 C5 C5 C5 C2 C521 45 52 52 4F 52 20 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 * TLOA2 TLOA3 LXI CALL LXI CALL H,DHEAD PLACE DUMMY HDR HERE FOR COMPARES NAME SET IN NAME AND UNIT H,0 ASSUME LOAD ADDR NOT GIVEN PSCAN HL EITHER =0, OR OVERRIDE LOAD ADDR XCHG LXI MOV ORA JNZ LXI PUSH CALL POP CALL JC . PUT ADDRESS IN DE H,DHEAD PT TO NORMAL HDR A,M GET 1ST CHAR OF NAME A IS THERE A NAME? TLOA3 YES--LOOK FOR IT H,THEAD PT TO SAME HDR TO LOAD NEXT FILE H SAVE PTR TO WHICH HDR TO USE ALOAD GET UNIT AND SPEED H RESTORE PTR TO PROPER HDR TO USE RTAPE READ IN THE TAPE TAERR TAPE ERROR? CALL POP ORA RZ LDA ORA JM LDA ORA JNZ LHLD JMP NAOUT PUT OUT THE HEADER PARAMETERS PSW RESTORE FLAG SAYING WHETHER IT WAS LOAD OR XEQ A . AUTO XEQ NOT WANTED HTYPE CHECK TYPE A SET FLAGS TAERR TYPE IS NON XEQ THEAD+5 A TAERR THE BYTE MUST BE ZERO FOR AUTO XEQ XEQAD GET THE TAPE ADDRESS EXEC1 AND GO OFF TO IT * * * * * THIS ROUTINE IS USED TO SAVE PROGRAMS AND DATA ON * THE CASSETTE UNIT. * * TSAVE EQU $ SAVE MEMORY IMAGE TO TAPE CALL NAME0 GET NAME AND UNIT CALL SCONV GET START ADDRESS PUSH H SAVE START ADDR FOR SIZE COMPUTATION LATER CALL SCONV GET END ADDR (REQUIRED) XTHL . HL=START ADDR NOW, STACK=END ADDR PUSH H STACK =START FOLLOWED BY END CALL PSCAN SEE IF RETRIEVE FROM ADDR SHLD LOADR EITHER ACTUAL START, OR OVERRIDE INTO HDR POP H HL=START ADDR POP D DE=END ADDR PUSH H PUT START BACK ONTO STACK MOV A,E SIZE=END-START+1 SUB L MOV L,A MOV A,D SBI 0 THIS EQUALS A SBB H SUB H THIS IS NEEDED MOV H,A INX H SHLD BLOCK STORE THE SIZE PUSH H SAVE AS THE BLOCK SIZE * CALL ALOAD GET UNIT AND SPEED LXI H,THEAD PT TO HEADER TO WRITE CALL WHEAD TURN TAPE ON, THEN WRITE HEADER POP D GET BACK THE SIZE POP H AND GET BACK THE ACTUAL START ADDR JMP WTAP1 WHITE THE BLK (W/EXTRA PUSH) * * OUTPUT ERROR AND HEADER * TAERR CALL CRLF MVI D,6 LXI H,ERRM CALL NLOOP OUTPUT ERROR CALL NAOUT THEN THE HEADER JMP COMN1 * ERRM ASC !ERROR ! * * * * * * * * CAT COMMAND THIS ROUTINE READS HEADERS FROM THE TAPE AND OUTPUTS THEM TO THE OUTPUT DEVICE. IT CONTINUES UNTIL THE MODE KEY IS DEPRESSED. C527 C527 CD 51 C4 C52A CD 42 C3 C52D C530 C532 C535 C538 C53B C53E C541 CD 06 CD CD DA C2 CD C3 44 01 EB 1F 15 35 4C 2D C5 C7 C7 C2 C5 C5 C5 C544 C547 C54A C54B 21 54 C8 3A 0D C8 B6 C9 C54C C54E C551 C554 C557 C55A C55D C560 C563 16 21 CD CD 2A CD 2A CD C3 C566 C567 C568 C56B C56D C570 C571 C572 C575 7E B7 C2 6D C5 3E 20 C56D CD 10 C4 23 15 C2 66 C5 C9 C576 C579 C57C C57D C580 C581 C584 C587 CD CA D5 CD E3 11 CD C3 C58A C58B C58E C590 C593 C58A B7 CA 90 C5 3E 20 32 0D C8 C9 08 1B 66 F7 25 D9 23 D9 42 C8 C5 C3 C8 C3 C8 C3 C3 59 C3 6B C4 78 C3 11 C3 91 C2 82 C2 C594 C594 78 C595 C595 32 0B C8 C598 C9 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 TLIST * * LLIST LIST1 EQU CALL CALL $ NAME0 CRLF CALL MVI CALL CALL JC JNZ CALL JMP ALOAD B,1 TON RHEAD COMN1 LIST1 NAOUT LLIST PRODUCE A LIST OF FILES ON A TAPE GET UNIT IF ANY (NAME IS IGNORED) START ON A FRESH LINE TURN ON THE TAPE TRUN OFF THE TAPE UNIT OUTPUT THE HEADER * * * THIS ROUTINE GETS THE CASSETTE UNIT NUMBER AND * SPEED TO REGISTER "A" FOR THE TAPE CALLS * ALOAD LXI H,FNUMF POINT TO THE UNIT SPECIFICATION LDA TSPD GET THE TAPE SPEED ORA M PUT THEM TOGETHER RET . AND GO BACK * * THIS ROUTINE OUTPUTS THE NAME AND PARAMETERS OF * THEAD TO THE OUTPUT DEVICE. * * NAOUT MVI D,8 LXI H,THEAD-1 POINT TO THE HEADER CALL NLOOP OUTPUT THE HEADER CALL BOUT ANOTHER BLANK LHLD LOADR NOW THE LOAD ADDRESS CALL ADOUT PUT IT OUT LHLD BLOCK AND THE BLOCK SIZE CALL ADOUT JMP CRLF DO THE CRLF AND RETURN * * NLOOP MOV A,M GET CHARACTER ORA A JNZ CHRLI IF IT ISN'T A ZERO MVI A,' ' SPACE OTHERWISE CHRLI EQU $ CHAR IS OK TO SEND CALL OUTH OUTPUT IT FROM A REG INX H DCR D JNZ NLOOP RET * * * * * "SET" COMMAND * * THIS ROUTINE GETS THE ASSOCIATED PARAMETER AND * DISPATCHES TO THE PROPER ROUTINE FOR SETTING * MEMORY VALUES. * SET CALL SBLK SCAN TO SECONDARY COMMAND JZ ERR1 MUST HAVE AT LEAST SOMETHING!! PUSH D SAVE SCAN ADDRESS CALL SCONV CONVERT FOLLOWING VALUE XTHL . HL=SAVED SCAN ADDR AND STACK=VALUE LXI D,SETAB SECONDARY COMMAND TAALF CALL FDCOM TRY TO LOCATE IT JMP DISP0 OFF TO IT OR ERROR IF NOT IN TBL * * * THIS ROUTINE SETS THE TAPE SPEED * TASPD EQU $ GET CONVERTED VALUE ORA A IS IT ZERO? JZ SETSP YES--THAT IS A PROPER SPEED MVI A,32 NO--SET SPEED PROPERLY THEN SETSP STA TSPD RET * * STSPD EQU $ VDM ESCAPE SEQUENCE COMES HERE MOV A,B GET CHAR FOR FOLLOWING DISPD DISPD EQU $ SET DISPLAY SPEED STA SPEED RET * * C599 C599 32 06 C8 C59C C9 C59D C59D 32 07 C8 C5A0 C9 C5A1 C5A1 22 00 C8 C5A4 C9 C5A5 C5A5 22 02 C8 C5A8 C9 C5A9 C5A9 32 22 C8 C5AC C9 C5AD C5AD 22 27 C8 C5B0 C9 C5B1 C5B1 32 10 C8 C5B4 C9 C5B5 C5B5 32 11 C8 C5B8 C9 C5B9 C5BC C5BF C5C2 C5C3 C5C6 C5C9 C5CC C5CD C5CF C5D0 C5D1 C5D2 C5D3 C5D4 C5D5 C5D6 C5D7 C5D8 C5D9 C5DA C5DB C5B9 CD 51 21 18 CD A5 E5 21 1C CD 8E CA CF 1B 36 00 C5CF 7E 12 13 23 7E 12 13 E1 EB 73 23 72 C9 C4 C2 C3 C8 C2 C5 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 9999 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 SETIN * * SETOT * * SETCI * * SETCO * * SETTY * * SETXQ * * SETNU * * SETCR * * CUSET CUSE2 EQU STA RET $ IPORT SET AN INPUT PSUEDO PORT EQU STA RET $ OPORT SET AN OUTPUT PSUEDO PORT EQU SHLD RET $ UIPRT DEFINE USER INPUT RTN ADDR EQU SHLD RET $ UOPRT DEFINE USER OUTPUT RTN ADDR EQU STA RET $ HTYPE SET TAPE HDR TYPE EQU SHLD RET $ XEQAD SET TAPE-EXECUTE ADDDR FOR HDR EQU STA RET $ NUCNT . HERE TO SET NUMBER OF NULLS THIS IS IT EQU STA RET $ IGNCR . SET CRC TO BE NORMAL, OR IGNORE CRC ERRORS FF=IGNORE CRC ERRORS, ELSE=NORMAL EQU CALL LXI CALL PUSH LXI CALL JZ DCX MVI EQU MOV STAX INX INX MOV STAX INX POP XCHG MOV INX MOV RET $ TRY TO SET/CLEAR CUSTOM ROUTINE ADDR NAME0 GET A NAME (S/B 2 CHARS OR MORE) H,COMND PT HERE IN CASE ADDR NOT GIVEN PSCAN GET OPTIONAL OPERAND IF ANY H SAVE THAT VALUE (IF ANY) H,THEAD PT TO NAME FDCOU SEE IF NAME IS KNOWN IN CUST TABLE CUSE2 NO--PROCEED TO KNOW IT D DE PT TO 1ST CHAR OF NAME IN TBL M,0 (HL CAME BACK PT'ING TO THEAD) CLR THIS NAME $ ENTER NEW ONE IN TBL A,M GET 1ST CHAR OF NAME D PUT NAME INTO TABLE D H A,M GET 2ND CHAR OF NAME D NAME IS NOW POSTED D PT TO 1ST BYTE OF ADDR H RESTORE SAVED RTN ADDR . DE=RTN ADDR, HL=THIS CU ENTRY M,E LO BYTE H M,D AND HI BYTE . ALL DONE COPY CUTER3/1 * * * -** * * * * * * * * * * * * * * * * 3 OF 3 THE FOLLOWING ROUTINES PROVIDE "BYTE BY BYTE" ACCESS TO THE CASSETTE TAPES ON EITHER A READ OR WRITE BASIS. THE TAPE IS READ ONE BLOCK AT A TIME AND INDIVIDUAL TRANSFERS OF DATA HANDLED BY MANAGING A BUFFER AREA. THE BUFFER AREA IS CONTROLLED BY A FILE CONTROL BLOCK (FCB) WHOSE STRUCTURE IS: 7 BYTES FOR EACH OR THE TWO FILES STRUCTURED AS FOLLOWS: C5DC C5DD C5E0 C5E3 C5E5 C5E6 C5E7 C5E8 E5 CD 2F C6 C2 F6 C5 36 01 23 77 23 77 C5E9 C5EC C5EF C5F0 11 63 C8 3A 54 C8 82 57 C5F1 C1 C5F2 B7 C5F3 C3 B2 C6 C5F6 C5F7 C5F8 C5F9 C5FA E1 D1 AF 37 C9 C5FB C5FC C5FD C5FE 3D 37 D1 C9 C5FF C602 C603 C604 C605 C607 CD 2F C6 C8 B7 3C 36 00 C8 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 * 1 BYTE - ACCESS CONTROL 00 IF CLOSED * FF IF READING * FE IF WRITING * 1 BYTE - READ COUNTER * 1 BYTE - BUFFER POSITION POINTER * 2 BYTE - CONTROL HEADER ADDRESS * 2 BYTE - BUFFER LOCATION ADDRESS * * * * THIS ROUTINE "OPENS" THE CASSETTE UNIT FOR ACCESS * * ON ENTRY: A - HAS THE TAPE UNIT NUMBER (1 OR 2) * HL - HAS USER SUPPLIED HEADER FOR TAPE FILE * * * NORMAL RETURN: ALL REGISTERS ARE ALTERED * BLOCK TS READY FOR ACCESS * * ERROR RETURN: CARRY BIT IS SET * * ERRORS: BLOCK ALREADY OPEN * * BOPEN PUSH H SAVE HEADER ADDRESS CALL LFCB GET ADDRESS OF FILE CONTROL JNZ TERE2 FILE WAS ALREADY OPEN MVI M,1 NOW IT IS INX H POINT TO READ COUNT MOV M,A ZERO INX H POINT TO BUFFER CURSOR MOV M,A PUT IN THE ZERO COUNT * * ALLOCATE THE BUFFER * LXI D,FBUF1 POINT TO BUFFER AREA LDA FNUMF GET WHICH ONE WE ARE GOING TO USE ADD D MOV D,A 256 BIT ADD * UBUF POP B HEADER ADDRESS ORA A CLEAR CARRY AND RETURN AFTER STORING PARAMS JMP PSTOR STORE THE VALUES * * GENERAL ERROR RETURN POINTS FOR STACK CONTROL * TERE2 POP H TERE1 POP D TERE0 XRA A CLEAR ALL FLAGS STC . SET ERROR RET * * EOFER DCR A SET MINUS FLAGS STC . AND CARRY POP D CLEAR THE STACK RET . THE FLAGS TELL ALL * * * * * THIS ROUTINE CLOSES THE FILE BUFFER TO ALLOW ACCESS * FOR A DIFFERENT CASSETTE OR PROGRAM. IF THE FILE * OPERATIONS WERE "WRITE" THEN THE LAST BLOCK IS WRITTED * OUT AND AN "END OF FILE" WRITTEN TO THE TAPE. IF * THE OPERATIONS WERE "READS" THEN THE FILE IS JUST * MADE READY FOR NEW USE. * * ON ENTRY: A - HAS WHICH UNIT (1 OR 2) * * ERROR RETURNS: FILE WASN'T OPEN * * PCLOS CALL LFCB GET CONTROL BLOCK ADDRESS RZ . WASN'T OPEN, CARRY IS SET FROM LFCB ORA A CLEAR CARRY INR A SET CONDITION FLAGS MVI M,0 CLOSE THE CONTROL BYTE RZ . WE WERE READING...NOTHING MORE TO DO * * THE FILE OPERATIONS WERE "WRITES" * * PUT THE CURRENT BLOCK ON THE TAPE * (EVEN IF ONLY ONE BYTE!!) * THEN WRITE AN END OF FILE TO THE TAPE C608 C609 C60A C60B C60C C60F C610 C613 C614 C615 C618 C619 C61A C61B C61D C61E C61F C620 C621 C622 C623 C626 23 23 7E 7E CD BB C6 C5 21 07 00 09 B7 CA 27 C6 E5 77 23 36 00 23 73 23 72 60 69 CD 78 C7 E1 C627 C628 C629 C62A C62B C62C AF 77 23 77 E1 C3 78 C7 C62F C632 C633 C635 C638 C63B C63E C63F C640 C641 21 55 1F E6 01 32 54 CA 3E 21 5C C63E 7E B7 37 C9 C642 C645 C646 C647 C64A C64C C64D C64E C64F C650 C653 C654 CD C8 3C FA 36 23 7E E5 23 CD E1 B7 C8 C8 C6 C8 2F C6 F8 C5 FF BB C6 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 * * * * * INX INX MOV H H A,M CALL PUSH LXI DAD ORA JZ PLOAD BC GET HEADER ADDRESS, DE BUFFER ADDRESS B HEADER TO STACK H,BLKOF OFFSET TO BLOCK SIZE B A TEST COUNT EOFW NO BYTES...JUST WRITE EOF GET CURSOR POSITION WRITE LAST BLOCK PUSH MOV INX MVI INX MOV INX MOV MOV MOV CALL POP H M,A H M,0 H M,E H M,D H,B L,C WFBLK H SAVE BLOCK SIZE POINTER FOR EOF PUT IN COUNT ZERO THE HIGHER BYTE BUFFER ADDRESS PUT HEADER ADDRESS IN HL GO WRITE IT OUT BLOCK SIZE POINTER * * NOW WRITE END OF FILE TO CASSETTE * EOFW XRA A PUT IN ZEROS FOR SIZE: EOF MARK IS ZERO BYTES MOV M,A INX H MOV M,A POP H HEADER ADDRESS JMP WFBLK WRITE IT OUT AND RETURN * * * * * THIS ROUTINE LOCATES THE FILE CONTROL BLOCK POINTED TO * BY REGISTER "A". ON RETURN HL POINT TO THE CONTROL BYT * AND REGISTER "A" HAS THE CONTROL WORD WITH THE FLAGS * SET FOR IMMEDIATE CONDITION DECISIONS. * * LFCB LXI H,FCBAS POINT TO THE BASE OF IT RAR . MOVE THE 1 & 2 TO 0 & 1 LIKE COMPUTERS LIKE ANI 1 SMALL NUMBERS ARE THE RULE STA FNUMF CURRENT ACCESS FILE NUMBER JZ LFCB1 UNIT ONE (VALUE OF ZERO) LXI H,FCBA2 UNIT TWO--PT TO ITS FCB LFCB1 EQU $ HL PT TO PROPER FCB MOV A,M PICK UP FLAGS FM FCB ORA A SET FLAGS BASED ON CONTROL WORD STC SET CARRY IN CASE OF IMMEDIATE ERROR RETURN RET * * * * * READ TAPE BYTE ROUTINE * * ENTRY: - A - HAS FILE NUMBER * EXIT: NORMAL - A - HAS BYTE * ERROR * CARRY SET - IF FILE NOT OPEN OR * PREVIOUS OPERATIONS WERE WRITE * CARRY & MINUS - END OF FILE ENCOUNTERED * * * * RTBYT CALL LFCB LOCATE THE FILE CONTROL BLOCK RZ . FILE NOT OPEN INR A TEST IF FF JM TERE0 ERROR WAS WRITING MVI M,-1 SET IT AS READ (IN CASE IT WAS JUST OPENED) INX H MOV A,M GET READ COUNT PUSH H SAVE COUNT ADDRESS INX H CALL PLOAD GET THE OTHER PARAMETERS POP H ORA A C655 C2 71 C6 C658 C659 C65A C65B C65E C661 C664 C665 C666 C667 C66A C66B C66C C66E C66F C670 D5 E5 23 CD CD DA E1 7B B2 CA 73 23 36 2B 7B D1 C671 C672 C673 C674 C675 3D 77 23 7E 34 C676 C677 C678 C67B C67C C67D C67E 83 5F D2 7C C6 14 1A B7 C9 C67F C682 C683 C684 C685 C687 C688 C689 C68A C68B CD 2F C6 C8 3C C8 36 FE 23 23 78 F5 E5 C68C C68F C690 C691 C692 C693 C696 C697 C698 C699 C69A C69B CD BB C6 E1 7E 83 5F D2 97 C6 14 F1 12 B7 34 C0 A2 C6 C4 C6 F6 C5 FB C5 00 C69C CD A2 C6 C69F C3 78 C7 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 JNZ GTBYT IF NOT EMPTY GO GET BYTE * * CURSOR POSITION WAS ZERO...READ A NEW BLOCK INTO * THE BUFFER. * RDNBLK PUSH D BUFFER POINTER PUSH H TABLE ADDRESS INX H CALL PHEAD PREPARE THE HEADER FOR READ CALL RFBLK READ IN THE BLOCK JC TERE2 ERROR POP OFF STACK BEFORE RETURN POP H MOV A,E LOW BYTE OF COUNT (WILL BE ZERO IF 256) ORA D SEE IF BOTH ARE ZERO JZ EOFER BYTE COUNT WAS ZERO....END OF FILE MOV M,E NEW COUNT ( ZERO IS 256 AT THIS POINT) INX H BUFFER LOCATION POINTER MVI M,0 DCX H MOV A,E COUNT TO A POP D GET BACK BUFFER ADDRESS * * * * THIS ROUTINE GETS ONE BYTE FROM THE BUFFER * AND RETURNS IT IN REGISTER "A". IF THE END * OF THE BUFFER IS REACHED IT MOVES THE POINTER * TO THE BEGINNING OF THE BUFFER FOR THE NEXT * LOAD. * GTBYT DCR A BUMP THE COUNT MOV M,A RESTORE IT INX H MOV A,M GET BUFFER POSITION INR M BUMP IT * ADD E MOV E,A DE NOW POINT TO CORRECT BUFFER POSITION JNC RT1 INR D RT1 LDAX D GET CHARACTER FROM BUFFER ORA A CLEAR CARRY RET . ALL DONE * * * * * THIS ROUTINE IS USED TO WRITE A BYTE TO THE FILE * * ON ENTRY: A - HAS FILE NUMBER * B - HAS DATA BYTE * * WTBYT CALL LFCB GET CONTROL BLOCK RZ . FILE WASN'T OPEN INR A RZ . FILE WAS READ MVI M,0FEH SET IT TO WRITE INX H INX H MOV A,B GET CHARACTER PUSH PSW PUSH H SAVE CONTROL ADDRESS+2 * * NOW DO THE WRITE * CALL PLOAD BC GETS HEADER ADDR, DE BUFFER ADDRESS POP H MOV A,M COUNT BYTE ADD E MOV E,A JNC WT1 INR D WT1 POP PSW CHARACTER STAX D PUT CHR IN BUFFER ORA A CLEAR FLAGS INR M INCREMENT THE COUNT RNZ . RETURN IF COUNT DIDN'T ROLL OVER * * THE BUFFER IS FULL. WRITE IT TO TAPE AND RESET * CONTROL BLOCK. * CALL PHEAD PREPARE THE HEADER JMP WFBLK WRITE IT OUT AND RETURN * C6A2 C6A5 C6A6 C6A9 C6AA C6AD C6B0 C6B1 CD C5 21 09 01 CD E1 C9 C6B2 C6B3 C6B4 C6B5 C6B6 C6B7 C6B8 C6B9 C6BA 23 71 23 70 23 73 23 72 C9 C6BB C6BC C6BD C6BE C6BF C6C0 C6C1 C6C2 C6C3 23 4E 23 46 23 5E 23 56 C9 BB C6 06 00 00 01 B2 C6 C6C4 CD DA C7 C6C7 C6C8 C6CA C6CD D5 06 03 CD EB C7 DB FB C6CF C6D0 C6D3 C6D4 C6D7 E5 CD 1F C7 E1 DA 02 C7 C2 CF C6 C6DA C6DB C6DE C6E1 C6E2 E5 11 1C C8 CD CE C7 E1 C2 CF C6 C6E5 C6E6 C6E7 C6E8 C6EB D1 7A B3 2A 23 C8 EB C6EC C2 F2 C6 C6EF 2A 25 C8 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 * * * * THIS ROUTINE PUTS THE BLOCK SIZE (256) AND BUFFER * ADDRESS IN THE FILE HEADER. * PHEAD CALL PLOAD GET HEADER AND BUFFER ADDRESSES PUSH B HEADER ADDRESS LXI H,BLKOF-1 PSTOR DOES AN INCREMENT DAD B HL POINT TO BLOCKSIZE ENTRY LXI B,256 CALL PSTOR POP H HL RETURN WITH HEADER ADDRESS RET * * PSTOR INX H MOV M,C INX H MOV M,B INX H MOV M,E INX H MOV M,D RET * * PLOAD INX H MOV C,M INX H MOV B,M INX H MOV E,M INX H MOV D,M RET * * * * * * THIS ROUTINE SETS THE CORRECT UNIT FOR SYSTEM READS RFBLK CALL GTUNT SET UP A=UNTT WITH SPEED * * * * * TAPE READ ROUTINES * * ON-ENTRY: A HAS UNIT AND SPEED * HL POINT TO HEADER BLOCK * DE HAVE OPTIONAL PUT ADDRESS * * ON EXIT: CARRY IS SET IF ERROR OCCURED * TAPE UNITS ARE OFF * * RTAPE PUSH D SAVE OPTIONAL ADDRESS MVI B,3 SHORT DELAY CALL TON IN TDATA CLEAR THE UART FLAGS * PTAP1 PUSH H HEADER ADDRESS CALL RHEAD GO READ HEADER POP H JC TERR IF AN ERROR OR ESC WAS RECEIVED JNZ PTAP1 IF VALID HEADER NOT FOUND * * FOUND A VALID HEADER NOW DO COMPARE * PUSH H GET BACK AND RESAVE ADDRESS LXI D,THEAD CALL DHCMP COMPARE DE-HL HEADERS POP H JNZ PTAP1 * * POP D OPTIONAL "PUT" ADDRESS MOV A,D ORA E SEE IF DE IS ZERO LHLD BLOCK GET BLOCK SIZE XCHG . ...TO DE * DE HAS HBLOCK....HL HAS USER OPTION JNZ RTAP IF DE WAS ZERO GET TAPE LOAD ADDRESS LHLD LOADR GET TAPE LOAD ADDRESS C6F2 D5 C6F3 C6F3 CD 11 C7 C6F6 CA 0C C7 C6F9 CD 40 C7 C6FC DA 02 C7 C6FF CA F3 C6 C702 AF C703 37 C704 C3 0D C7 C707 C709 C70C C70D C70F C710 06 01 CD ED C7 AF D3 FA D1 C9 C711 AF 47 B2 C2 1C C7 B3 C8 43 5A C9 C71C C71C 15 C71D B7 C71E C9 C711 C712 C713 C714 C717 C718 C719 C71A C71B C71F C721 C724 C725 C727 C728 C72B C72C 06 CD D8 DB B7 C2 05 C2 0A 59 C7 C72F C732 C733 C735 C738 CD D8 FE DA C2 6B C7 FB 1F C7 21 C7 01 2F C7 1F C7 C73B 21 1C C8 C73E 06 10 C740 C740 0E 00 C742 C742 CD 6B C7 C745 D8 C746 77 C747 23 C748 CD A4 C7 C74B 05 C74C C2 42 C7 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 * * * THIS ROUTINE READS "DE" BYTES FROM THE TAPE * TO ADDRESS HL. THE BYTES MUST BE FROM ONE * CONTIGUOUS PHYSICAL BLOCK ON THE TAPE. * * HL HAS "PUT" ADDRESS * DE HAS SIZE OF TAPE BLOCK * RTAP PUSH D SAVE SIZE FOR RETURN TO CALLING PROGRAM * RTAP2 EQU $ HERE TO LOOP RDING RLKS CALL DCRCT DROP COUNT, B=LEN THIS BLK JZ RTOFF ZERO=ALL DONE * CALL RHED1 READ THAT MANY BYTES JC TERR IF ERROR OR ESC JZ RTAP2 RD OK--READ SOME MORE * * ERROR RETURN * TERR XRA A STC . SET ERROR FLAGS JMP RTOF1 * * TOFF MVI B,1 CALL DELAY RTOFF XRA A RTOF1 OUT TAPPT POP D RETURN BYTE COUNT RET * * DCRCT EQU $ COMMON RTN TO COUNT DOWN BLK LENGTHS XRA A CLR FOR LATER TESTS MOV B,A SET THIS BLK LEN=256 ORA D IS AMNT LEFT < 256 JNZ DCRC2 NO--REDUCE AMNT BY 256 ORA E IS ENTIRE COUNT ZERO RZ ALL DONE--ZERO THIS CONDITIOL MOV B,E SET THIS BLK LEN TO AMNT REMAININ(', MOV E,D MAKE ENTIRE COUNT ZERO NOW RET . ALL DONE (NON-ZERO FLAG) DCRC2 EQU $ REDUCE COUNT BY 256 DCR D DROP BY 256 ORA A FORCE NON-ZERO FLAG RET NON-ZERO=NOT DONE YET (BLK LEN=256) * * * READ THE HEADER * RHEAD MVI B,10 FIND 10 NULLS RHEA1 CALL STAT RC . IF ESCAPE IN TDATA IGNORE ERROR CONDITIONS ORA A ZERO? JNZ RHEAD DCR B JNZ RHEA1 LOOP UNTIL 10 IN A ROW * * WAIT FOR THE START CHARACTER * SOHL CALL TAPIN RC . ERROR OR ESCAPE CPI 1 ARE WE AT THE 01 YET (START CHAR) JC SOHL NO, BUT STIL ZEROES JNZ RHEAD NO, LOOK FOR ANOTHER 10 NULLS * * WE HAVE 10 (OR MORE) NULLS FOLLOWED IMMEDIATELY * BY AN 01. NOW READ THE HEADER. * LXI H,THEAD POINT TO BUFFER MVI B,HLEN LENGTH TO READ * RHED1 EQU $ RD A BLOCK INTO HL FOR B BYTES MVI C,0 INIT THE CRC RHED2 EQU $ LOOP HERE CALL TAPIN GET A BYTE RC MOV M,A STORE IT INX H INCREMENT ADDRESS CALL DOCRC GO COMPUTE THE CRC DCR B WHOLE HEADER YET? JNZ RHED2 DO ALL THE BYTES C74F C752 C753 C754 C757 CD 6B C7 A9 C8 3A 11 C8 3C C758 C9 C759 C75B C75D C75E C761 C764 C766 C769 C76A DB E6 C0 CD CA E6 C2 37 C9 FA 40 1F C0 59 C7 7F 59 C7 C76B CD 59 C7 C76E D8 C76F C771 C773 C775 C776 C777 DB FA E6 18 DB FB C8 37 C9 C778 CD DA C7 C77B C77C C77F C780 C783 C784 C785 C786 C787 C788 C789 C78A C78B C77B E5 CD AB C7 E1 11 07 00 19 5E 23 56 23 7E 23 66 6F C78C C78C E5 C78D C78D CD 11 C790 CA 07 C793 CD BF C796 C3 8D C799 C79A C79C C79E C7A1 C7 C7 C7 C7 F5 DB FA E6 80 CA 9A C7 F1 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 * * THIS ROUTINE GETS THE NEXT BYTE AND COMPARES IT * TO THE VALUE IN REGISTER C. THE FLAGS ARE SET ON * RETURN. * CALL TAPIN GET CRC BYTE XRA C CLR CARRY AND SET ZERO IF MATCH, ELSE NON-ZERO RZ . CRC IS FINE LDA IGNCR BAD CRC, SHD WE STILL ACCEPT IT INR A SEE IF IT WAS FF, IF FF THEN ZERO SAYS IGN ERR * NOW, CRC ERR DETECTION DEPENDS ON IGNCR. RET * * THIS ROUTINE GETS THE NEXT AVAILABLE BYTE FROM THE * TAPE. WHILE WAITING FOR THE BYTE THE KEYBOARD IS TESTED * FOR AN ESC COMMAND. IF RECEIVED THE TAPE LOAD IS * TERMINATED AND A RETURN TO THE COMMAND MODE IS MADE. * STAT IN TAPPT TAPE STATUS PORT ANI TDR RNZ CALL SINP CHECK INPUT JZ STAT NOTHING THERE YET ANI 7FH CLEAR PARITY 1ST JNZ STAT EITHER MODE OR CTL-@ STC . SET ERROR FLAG RET . AND RETURN * * * TAPIN CALL STAT WAIT UNTIL A CHARACTER IS AVAILABLE RC * TREDY IN TAPPT TAPE STATUS ANI TFE+TOE DATA ERROR? IN TDATA GET THE DATA RZ . IF NO ERRORS STC . SET ERROR FLAG RET * * * THIS ROUTINE GETS THE CORRECT UNIT FOR SYSTEM WRITES WFBLK CALL GTUNT SET UP A WITH UNIT AND SPEED * * * * WRITE TAPE BLOCK ROUTINE * * ON ENTRY: A HAS UNIT AND SPEED * HL HAS POINTER TO HEADER * * WTAPE EQU $ HERE TO WRITE TAPE PUSH H SAVE HEADER ADDRESS CALL WHEAD TURN ON, THEN WRITE HDR POP H LXI D,BLKOF OFFSET TO BLOCK SIZE IN HEADER DAD D HL POINT TO BLOCK SIZE MOV E,M INX H MOV D,M DE HAVE SIZE INX H MOV A,M INX H MOV H,M MOV L,A HL HAVE STARTING ADDRESS * * THIS ROUTINE WRITES ONE PHYSICAL BLOCK ON THE * TAPE "DE" BYTES LONG FROM ADDRESS "HL". * * WTAP1 EQU $ HERE FOR THE EXTRA PUSH PUSH H A DUMMY PUSH FOR LATER EXIT WTAP2 EQU $ LOOP HERE UNTIL ENTIRE AMOUNT READ CALL DCRCT DROP COUNT IN DE AND SET UP B W/LEN THIS BLK JZ TOFF RETURNS ZERO IF ALL DONE CALL WTBL WRITE BLOCK FOR BYTES IN B (256) JMP WTAP2 LOOP UNTIL ALL DONE * * WRTAP PUSH PSW WRWAT IN TAPPT TAPE STATUS ANI TTBE IS TAPE READY FOR A CHAR YET JZ WRWAT NO--WAIT POP PSW YES--RESTORE CHAR TO OUTPUT C7A2 D3 FB C7A4 C7A5 C7A6 C7A7 C7A8 C7A9 C7AA C7A4 91 4F A9 2F 91 4F C9 C7AB C7AE C7B0 C7B1 C7B4 C7B5 C7AB CD E9 C7 16 32 AF CD 99 C7 15 C2 B0 C7 C7B8 3E 01 C7BA CD 99 C7 C7BD 06 10 C7BF C7C1 C7C2 C7C5 C7C6 C7C7 C7CA C7CB 0E 7E CD 05 23 C2 79 C3 00 C7CE C7D0 C7D1 C7D2 C7D3 C7D4 C7D5 C7D6 C7D7 06 05 1A BE C0 05 C8 23 13 C3 D0 C7 C7DA C7DD C7DE C7E1 C7E4 C7E6 C7E8 C7DA 3A 54 C8 B7 3A 0D C8 C2 E6 C7 C6 40 C6 40 C9 99 C7 C1 C7 99 C7 C7E9 06 04 C7EB C7EB D3 FA C7ED C7F0 C7F1 C7F2 C7F3 C7F6 C7F7 C7FA 11 00 00 1B 7A B3 C2 F0 C7 05 C2 ED C7 C9 CC00 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 * DOCRC OUT TDATA SEND CHAR TO TAPE EQU SUB MOV XRA CMA SUB MOV RET $ C C,A C A COMMON CRC COMPUTATION ROUTINE C C,A . ONE BYTE NOW WRITTEN * * * THIS ROUTINE WRITES THE HEADER POINTED TO BY * HL TO THE TAPE. * WHEAD EQU $ HERE TO 1ST TURN ON THE TAPE CALL WTON TURN IT ON, THEN WRITE HEADER MVI D,50 WRITE 50 ZEROS NULOP XRA A CALL WRTAP DCR D JNZ NULOP * MVI A,1 CALL WRTAP MVI B,HLEN LENGTH TO WRITE OUT * WTBL MVI C,0 RESET CRC BYTE WLOOP MOV A,M GET CHARACTER CALL WRTAP WRITE IT TO THE TAPE DCR B INX H JNZ WLOOP MOV A,C GET CRC JMP WRTAP PUT IT ON THE TAPE AND RETURN * * * THIS ROUTINE COMPARES THE HEADER IN THEAD TO * THE USER SUPPLIED HEADER IN ADDRESS HL. * ON RETURN IF ZERO IS SET THE TWO NAMES COMPARED * DHCMP MVI B,5 DHLOP LDAX D CMP M RNZ DCR B RZ . IF ALL FIVE COMPARED INX H INX D JMP DHLOP * GTUNT EQU $ SET A=SPEED + UNIT LDA FNUMF GET UNIT ORA A SEE WHICH UNIT LDA TSPD BUT 1ST GET SPEED JNZ GTUN2 MAKE IT UNIT TWO ADI TAPE2 THIS ONCE=UNIT 2, TWICE=UNIT 1 GTUN2 ADI TAPE2 UNIT AND SPEED NOW SET IN A RET . ALL DONE * WTON MVI B,4 SET LOOP DELAY (BIT LONGER ON A WRITE) TON EQU $ HERE TO TURN A TAPE ON THEN DELAY OUT TAPPT GET TAPE MOVING, THEN DELAY * DELAY LXI D,0 DLOP1 DCX D MOV A,D ORA E JNZ DLOP1 DCR B JNZ DELAY RET * * ***** -- END OF PROGRAM-* * * * * S Y S T E M E Q U A T E S * * * VDM PARAMETERS * VDMEM EQU 0CC00H VDM SCREEN MEMORY 001A 0017 0001 0013 000B 000E 0000 005F 000A 000D 0020 0020 0018 001B 0000 0001 0002 0003 00C8 00FA 00FB 00FF 0001 0002 0004 0008 0010 0020 0040 0080 0001 0002 0004 0008 0010 0040 0080 0001 0080 0040 C800 C800 CBFF C800 C802 C804 C806 C807 C808 C809 C80A C80B C80C C80D C80E 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1962 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 * * * KEYBOARD SPECIAL KEY ASSIGNMENTS * * THESE DEFINITIONS ARE DESIGNED TO ALLOW * COMPATABILITY WITH SOLOS(TM). THESE ARE THE * SAME KEYS WITH BIT 7 (X'80') STRIPPED OFF. * DOWN EQU 1AH CTL Z UP EQU 17H CIL W LEFT EQU 01H CTL A RIGHT EQU 13H CTL S CLEAR EQU 0BH CTL K HOME EQU 0EH CTL N MODE EQU D0H CTL-@ BACKS EQU 5FH BACKSPACE LF EQU 10 CR EQU 13 BLANK EQU ' ' SPACE EQU BLANK CX EQU 'X'-40H ESC EQU 1BH * * PORT ASSIGNMENTS * STAPT EQU 0 STATUS PORT GENERAL SDATA EQU 1 SERIAL DATA PDATA EQU 2 PARALLEL DATA KDATA EQU 3 KEYBOARD DATA DSTAT EQU 0C8H VDM CONTROL PORT TAPPT EQU 0FAH TAPE STATUS PORT TDATA EQU 0FBH TAPE DATA PORT SENSE EQU 0FFH SENSE SWITCHES * * * * BIT ASSIGNMENT MASKS * SCD EQU 1 SERIAL CARRIER DETECT SDSR EQU 2 SERIAL DATA SET READY SPE EQU 4 SERIAL PARITY ERROR SFE EQU 8 SERIAL FRAMING ERROR SOE EQU 16 SERIAL OVERRUN ERROR SCTS EQU 32 SERIAL CLEAR TO SEND SDR EQU 64 SERIAL DATA READY STBE EQU 128 SERIAL TRANSMITTER BUFFER EMPTY * KDR EQU 1 KEYBOARD DATA READY PDR EQU 2 PARALLEL DATA READY PXDR EQU 4 PARALLEL DEVICE READY TFE EQU 8 TAPE FRAMING ERROR TOE EQU 16 TAPE OVERFLOW ERROR TDR EQU 64 TAPE DATA READY TTBE EQU 128 TAPE TRANSMITTER BUFFER EMPTY * SOK EQU 1 SCROLL OK FLAG * TAPE1 EQU 80H 1=TURN TAPE ONE ON TAPE2 EQU 40H 1=TURN TAPE TWO ON * * * * * S Y S T E M G L O B A L A R E A * ORG START+0800H RAM STARTS JUST AFTER ROM * SYSRAM EQU $ START OF SYSTEM RAM SYSTP EQU SYSRAM+3FFH STACK WORKS FM TOP DOWN * * * PARAMETERS STORED IN RAM * UIPRT DS 2 USER DEFINED INPUT RTN IF NON ZERO UOPRT DS 2 USER DEFINED OUTPUT RTN IF NON ZERO DFLTS DS 2 DEFAULT PSUEDO I/O PORTS IPORT DS 1 CRNT INPUT PSUEDO PORT OPORT DS 1 CRNT OUTPUT PSUEDO PORT NCHAR DS 1 CURRENT CHARACTER POSITION LINE DS 1 CURRENT LINE POSITION BOT DS 1 BEGINNING OF TEXT DISPLACEMENT SPEED DS 1 SPEED CONTROL BYTE ESCFL DS 1 ESCAPE FLAG CONTROL BYTE TSPD DS 1 CURRENT TAPE SPEED INPTR DS 2 PTR TO NEXT CHAR POSITION IN INLIN C810 C811 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 C812 C81C C821 C822 C823 C825 C827 C829 0010 0007 C82C C83C C854 C855 C85C C863 CA63 CA64 CAB4 ADOUT ARET BLANK BOT CLEAR CLINE CONT CRLF CUSE2 DCRC2 DFLTS DISP0 DLOOP DOCRC ENLO1 EOFER ERR1 ERRO1 ESCS FBUF1 FDCOM GCLI0 GCLIN GTUN2 HCOV1 HOME INIT IPORT KREA1 LFCB1 LOADR NAME1 NEXT NULOP OPORT PARIT PCR PDR PHOME PRIT PTAP1 RDBYT RHEA1 RIGHT RTAPE SBLK SCHR1 C3D9 C1C3 0020 C80A 000B C11C C264 C342 C5CF C71C C804 C282 C3B6 C7A4 C427 C5FB C46B C06F C187 C863 C291 C227 C239 C7E6 C39B 000E C001 C806 C035 C63E C825 C459 C0A3 C7B0 C807 C050 C16F 0002 C108 C13D C6CF C00D C721 0013 C6C7 C359 C36E AINP ARET1 BLKOF BOUT CLERA COMN1 COPRC CUR CUSET DCRCT DHCMP DISP1 DLOP1 DOWN ENLO3 EOFW ERR2 ERROT ESCSP FCBA2 FDCOU GCLI1 GOBAC GTUNT HEOU1 HSPR INLIN ITAB LEFT LINE MODE NAOUT NFIL NULOT OTAB PAROT PCUR PERSE PLEFT PROMP PUP RDNBL RHEAD RT1 RTBYT SBLK1 SCONV NUCNT IGNCR * DS DS 1 1 NUMBER OF NULLS AFTER CRLF IGN CRC ERR FLAG, FF=IGN CRC ERRS, ELSE=NORMAL DS 10 ROOM FOR FUTURE EXPANSION * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * T H I S I S T H E R E A D E R L A Y O U T * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * THEAD DS 5 NAME DS 1 THIS BYTE MUST BE ZERO HTYPE DS 1 TYPE BLOCK DS 2 BLOCK SIZE LOADR DS 2 LOAD ADDRESS XEQAD DS 2 AUTO EXECUTE ADDRESS HSPR DS 3 SPARES * HLEN EQU $-THEAD LENGTH OF HEADER BLKOF EQU BLOCK-THEAD OFFSET TO BLOCK SIZE DHEAD DS HLEN A DUMMY HDR FOR COMPARES WHILE RD'ING * * CUTAB DS 6*4 ROOM FOR UP TO 6 CUSTOM USER COMMANDS * * FNUMF DS 1 FOR CURRENT FILE OPERATIONS FCBAS DS 7 1ST FILE CONTROL BLOCK FCBA2 DS 7 2ND FILE CONTROL BLOCK FBUF1 DS 2*256 SYSTEM FILE BUFFER BASE DS 1 "BELL" (X'07') FLAGS START OF INPUT BFR INLIN DS 80 ROOM FOR THE INPUT LINE USARE EQU $ START OF USER AREA * * REMEMBER THAT THE STACK WORKS ITS WAY DOWN-FROM * THE END OF THIS 1K RAM AREA. * * -*- C022 C1C5 0007 C3F7 C1DC C215 C26A C0F4 C5B9 C711 C7CE C28B C7F0 001A C444 C627 C46C C06B C190 C85C C28E C232 C08E C7DA C405 C829 CA64 C309 0001 C809 0000 C54C C480 C350 C301 C059 C137 C0F8 C133 C33A C12C C658 C71F C67C C642 C35B C378 ALOAD ARET2 BLOCK CHAR CLIN1 COMND CR CURET CUTAB DEFLT DHEAD DISPD DLP1 DSTAT ENLOP ERAS1 ERRIT ESC EXEC FCBAS FNUMF GCLI2 GORK HBOUT HEOUT HTYPE INPTR KDATA LF LIST1 NAME NCHAR NLOOP OCHAR OUTH PBACK PDATA PFSC PLF PSCAN PXDR RETRN RHED1 RTAP RTOF1 SCD SCROL C544 C1CA C823 C0B7 C122 C218 000D C1CE C83C C494 C82C C595 C3C1 00CB C418 C0FE C064 001B C449 C855 C854 C25F C09F C3DE C3FC C822 C80E 0003 000A C535 C454 C808 C566 C0BB C410 C166 0002 C181 C175 C3A5 0004 C004 C740 C6F2 C70D 0001 C0CF AOUT BACKS BOPEN CHRLI CLIN2 COMTA CREM CURSC CX DELAY DHLOP DISPT DLP1A DUMP ENTER ERAS3 ERRM ESCFL EXEC1 FCLOS FOPEN GCLI3 GTBYT HCONV HLEN IGNCR IOPRC KDR LFCB LLIST NAME0 NCOM NUCNT OK OUTPR PCLOS PDOWN PHEAD PLOAD PSTOR RDSLK RFBLK RHED2 RTAP2 RTOFF SCHR SCTS C01C 005F C5DC C56D C117 C2BD C15E C0F2 0018 C7ED C7D0 C287 C3D0 C3AD C414 C111 C521 C80C C44C C00A C007 C261 C671 C38B 0010 C811 C026 0001 C62F C52D C451 C2A3 C810 C0E4 C02E C5FF C0EE C6A2 C6BB C6B2 C013 C6C4 C742 C6F3 C70C C36C 0020 SDATA SENSE SETCI SETNU SETX SHE1 SOHL SPE STAPT STRTA STSPD SYSTP TAPIN TDATA TERE2 TIMER TLOAD TREDY TTBE UOPRT VDAD2 WFBLK WRBYT WTAP1 WTBYT 0001 00FF C5A1 C5B1 C1B0 C381 C72F 0004 0000 C1D7 C594 CBFF C76B 00FB C5F6 C09A C4A1 C76F 0080 C802 C148 C778 C010 C78C C67F SDR SEROT SETCO SETOT SETXQ SHEX SOK SPEED START STRTB STUNT TAERR TAPPT TDR TERR TLIST TOE TSAVE TXEQ UP VDADD WHEAD WRTAP WTAP2 WTLP1 0040 C046 C5A5 C59D C5AD C37E 0001 C80B C000 C1F4 C49C C510 00FA 0040 C702 C527 0010 C4E0 C4A0 0017 C144 C7AB C799 C78D C3F1 SDSR SET SETCR SETSP SETY SINP SOUT SREA1 STAT STRTC STUP TAPE1 TASPD TERE0 TEE TLOA2 TOFF TSPD UBUF USARE VDM01 WLOOP WRWAT WTAPE WTON 0002 C576 C5B5 C590 C1B4 C01F C019 C03E C759 C1FF C2AA 0080 C58A C5F8 0008 C4AF C707 C80D C5F1 CAB4 C077 C7C1 C79A C77B C7E9 SECON SETAB SETIN SETTY SFE SOE SPACE SROL STBE STRTD SYSRA TAPE2 TBL TERE1 THEAD TLOA3 TON TSRCH UIPRT VDAD VDMEM WRBLK WT1 WTBL XEQAD C1B8 C311 C599 C5A9 0008 0010 0020 C0D3 0080 C20F C800 0040 C2E2 C5F7 C81C C4BB C7EB C0A5 C800 C14B CC00 C016 C697 C7BF C827 Waiting for BASIC-5 A lot of people have asked why Sol BASIC-5 took so long to be released. The main reason is Processor's policy concerning the release of new products: we don't ship 'til we have the finalized version, and that means product PLUS documentation. We feel that our reputation is based on selling products that live up to the advertising claims, and we intend to live up to our reputation. (Note: we've never been forced to recall a product.) We could have provided you with a version of our original BASIC-5 a long time ago, with a modification of only 12 instructions. But that wasn't what we advertised Sol BASIC-5 to be. And in getting it to be what we wanted, we kept thinking it would be neat to add just a couple more nifty features and then just one more and one more and . . . So as with all fanatics, one thing led to another 'til somebody remembered that this is a business and there are customers out there who could only stand so much "neat stuff" (especially if they had to wait until the year 2000). Anyway, by now you will have received said BASIC-5, so load it in and run it for a while. We think you'll agree that it was almost worth the wait. Computer of the Future Drawing by Brian Marsh, Age 6. Contributions Welcome!
Source Exif Data:
File Type : PDF File Type Extension : pdf MIME Type : application/pdf PDF Version : 1.2 Linearized : No Page Count : 38 Creator : Microsoft Word Create Date : Sunday, January 16, 2000 5:20:35 PM Title : Processor Tech Access, Vol One, Num Two Author : OCR'd and formatted by Jim Battle Producer : Acrobat PDFWriter 3.02 for Windows Subject :EXIF Metadata provided by EXIF.tools