CPM2 HLP CPM2 HLP !CPM2 HLP#"#$%&EBASIC HLP['()*+,-./012FORTRAN HLP73456789HELP COM:;HELP HLP5<=>?@ABMAC HLP=CDEFGHIJties 2. ED: A Context Editor for the CP/M Disk System 3. ASM: CP/M Assembler User's Manual 4 DDT CP/ Dynami Debuggin Too User' Manual 5. CP/M 1.4 Interface Guide 6. CP/M 1.4 System AlterLOAD Command The UNLOAD Command CP/M DDT Command The ZDT Command CP/M SYSGEN Command CP/M SUBMIT and XSUB Commands CP/M BDOS -- Basic I/O Operations CP/M BDOS -- Basic Disk Operations CP/M File Types CP/M BIOS Jump Vector :General Information on system Th fil subsyste support name fil structure allowin dynami allocatio o fil spac a wel a sequentia an rando fil access Usin thi fil system u t 12 distinc program ca b store i bot sourc anMASM HLP=KLMNOPQRMBASIC HLPSTUVWXYZ[\]^_`abMBASIC HLP&cdefgPASCAL HLPMhijklmnopqSIG/M IB rsUGFORM IBtuvwoprocessor CP/ provide genera environmen fo progra construction storage an editing alon wit assembl an progra debu facilities A importan featur o CP/ i tha i ca b easil altere t execut wit an compute configCP/M CP/͠ i monito contro progra fo microcompute softwar developmen whic use IBM-compatibl flexibl disk (flopp disks fo mas storage Usin microcompute mainfram base o Intel' 808 o Zilog' Z8 micr machine-executabl form. Digita Research th designe o CP/M ha provide se o nin manual whic describ th us an operatio o CP/ i detail. These manuals are: 1 A Introductio t CP/ Feature an FaciliGeneral Information on CP/M CP/M File References CP/M Line Editing and Output Control CP/M Built-In Commands CP/M Transient Commands Physical Device Assignments for ARIES-1 CP/M STAT Command CP/M PIP Command CP/M ED Command CP/M ASM Command CP/M uratio whic use a Inte 808 o Zilo Z8 Microprocesso an ha a leas 20 byte o mai memor wit u t eight IBM-compatabl diskett drives. Th CP/ monito provide acces t program throug comprehensiv fil managemen ation Guide 7. CP/M 2.0 User's Guide 8. CP/M 2.0 Interface Guide 9. CP/M 2.0 System Alteration Guide A th reade ca see CP/ support contex editor a assemble (Intel-compatable) an debugge sycontinue when the next character is typed at the console. Typing Ctrl-C returns control to CP/M. Inpu line ca generall b u t 25 character i length The ar not acted upon until the carriage return key is typed. e Editing and Output Control The following are the line editing functions supported by CP/M -- rubout Delete and echo the last character typed at the console. Ctrl-Ƞ Delet th las charactetin system an accountin systems). Thi HEL Fil addresse itsel specificall t th CP/ 2. Operatin Systems. :CP/M File References fil referenc identifie particula fil o grou o file o particula dis attachearm start). Ctrl-Z End input from the console (used in PIP and ED). Other control functions affect console output -- Ctrl-P Copy all subsequent console output to the currently- assigned list devicguou fil referenc i simila t a unambiguou reference excep th symbo '? ma b intersperse throughou th fil reference I variou command throughou CP/M th '? symbo matche an characte o fil nam i th '? positiostem Thes ar availabl i th basi CP/ package Ther i larg variet o othe softwar availabl whic ca ru unde CP/ wit littl o n modification Suc softwar include severa assembler (bot 808 an Z80) symbolth curren line; CRT-oriented. Ctrl-R Retype current command line: types a "clean line" following character deletion with rubouts. Ctrl-E Physical end of line: carriage is returned, but typed Backspac on character; CRT-oriented Ctrl-U Delete the entire line typed at the console. Ctrl- Delet th entir lin type a th console Backspac t th beginnin o t CP/M Thes fil reference ca b eithe unambiguou (ufn o ambiguou (afn) A unambiguou fil referenc uniquel identifie singl file whil a ambiguou fil referenc ma b satisfied by a number of different files. e (LST:). Output is sent to both the list device and the console device until the next Ctrl-P is typed. Ctrl-S Stop the console output temporarily. Program execution and output n Fo example X?Y.C?͠ wil matc XZY.CO an X3Y.CEM Th '* symbo i use t matc al character o fil nam o fil type Fo example *.CO wil matc XZY.COM and HELP.COM, while HELP.* will match HELP.COM and HELP.HLP. :CP/M Lini debugger severa high-leve language (includin FORTRAΠ I֠ {compiler} BASIC- {translator} CBASI {translator} man interpretiv BASICs ALGOL FOCAL an C) an severa special-purpos application program (suc a tex format line is not sent until the carriage return key is depressed. Ctrl-M Terminates input (carriage return). Ctrl-J Terminates current input (line feed); CRT-oriented Ctrl-C CP/M system reboot (w Th character use i specifyin a unambiguou fil referenc ma not contain any of -- < > . , ; : = ? * [ ] A ambiguou fil referenc i use fo director searc an patter matching Th for o a ambi A unambiguou fil referenc i a exac nam o th specifie file I consist o u t eigh character i th fil nam an thre character in the file type. An unambiguous file reference is of the form -- pppppppp.sss :CP/M Built-In Commands ER af -- Th ER (erase comman remove file fro th currently logged-in disk. DIҠ af -- Th DI (directory comman cause th name o al file whic satisf Calculat th storag remainin o al activ drive an prin message like x: R/W, SPACE: nnnK -- if disk is Read/Write x: R/O, SPACE: nnnK -- if disk is Read Only STAT x: Calculate the storage rem machin cod forma an produc fil i machin executabl for whic ca b loade int th TP (thi loade progra become ne command under the CCP). DDT Locomman display th content o th ASCI sourc fil uf o th currentl logged-i dis a th console device. USE -- Upo col boot th use i automaticall logge i t Use Ar UR2: CRT and Modem PUN: TTY: Model 43 Teletype PTP: Modem UP1: CRT and Modem UP2: CRT and Modem LST: TTY: disk file and peripheral transfer operations. ED Load and execute the CP/M text editor program. SUBMIT Submit a file of commands for batch processing. XSU Use i conjunctio wit SUBMIT tr th ambiguou fil nam af t b liste o th consol device Al file ar liste i n af i given. REΠ ufn1=ufn -- Th RE (rename comman allow th use t chang th name size. :Physical Device Assignments for ARIES-1 Logical Device Physical Device CON: TTY: Model 43 Teletype CRT: Hazeltine 1500 CRT BAT: CRT ad the CP/M debugger into the TPA and execute it. DUMP Dump the contents of a file in hex. SYSGEN Create a new CP/M system diskette. MOVCP͠ Regenerat th CP/ syste fo particula memor e 0 whic i compatabl wit CP/ 1. directories Th USE comman allow th use t mov t anothe logica are withi th sam directory area ar numbere 0-15 Th ERA DIR REN SAVE Model 43 Teletype CRT: Hazeltine 1500 CRT LPT: Modem UL1: CRT and Modem :CP/M STAT Command The STAT Command takes any of the following forms -- STAansfer al buffere console input from CON: to the SUBMIT File. AS͠ Loa th CP/ assemble an assembl th specifie program from disk. LOAĠ Loa th fil i Inte "hexo file o disk Th fil satisfyin ufn is changed to ufn1. SAVŠ uf -- Th SAV comman place page (256-byt blocks onto disk from the TPA and names this file ufn. TYPŠ uf -- Th TYP and Modem UC1: In=CRT, Out=CRT and Modem RDR: TTY: Model 43 Teletype PTR: Modem UR1: CRT and Modem w/CRT Output l logged-i disk provid堠 statistica informatio abou particula files an displa o alter device assignment. PI Loa th Periphera Interchang Progra fo subsequen an TYP command appl t th current User Area. :CP/M Transient Commands The CP/M standard transient commands are -- STAԠ Lis th numbe o byte o storag and data o th currentaining on the specified drive and print BYTES REMAINING ON x: nnnK STAT x:afn [$S] Sca th specifie file o th specifie driv (x i optional) an lis al file whic satisf th unambiguou referenc i STAT USR: Lis th Use Numbe th use i currentl i an th Use Number whic hav file o th currentl addresse disk sampl listing: Active User : 0 Active Files: 0 1 3 :CP/M Pdevic pd1 etc Th vali logical device names are -- CON: The system console device RDR: The paper tape reader device PUN: The paper tape punch device LST: ted to the file ee -- number of 16K extensions a/b -- access mode of file; R/O or R/W d:pppppppp.sss -- drive name (d may be A, B, C, D) and file name STAT x:=R/O Se Lis th characteristic o th dis name "d:" i "d: i no specified, list the characteristics of all active disks. A sample listing: d: Drive Characteristics 65536: 128 Byte Record Capacity 819t physica devic mapping Fo example, the list may appear as -- CON: = CRT: PUN: = PTP: RDR: = UR1: LST: = TTY: STAT d:afn [$R/O or $R/W or $SYS or $DIR] Se th variou alphabetica orde wit storag requirements tabl lik th following is generated -- Size Recs Bytes Ext Acc sssss rrrr nnnk ee a/b d:pppppppp.sss where sssss (CON inpu i RDR: CON outpu is LST:) UC1: User-defined console PTR: Paper tape reader PTP: Paper tape punch UR1: User-defined reader #1 The output list device The valid physical device names are -- TTY: Slow speed output device (teletype) CRT: High speed output device (cathode ray tube) BAT Batc processinth specifie driv t Rea Only Thi i cleare b war boot. When a disk is Read Only, the message BDOS ERR ON x: READ ONLY will appear if there is an attempt to write to it. STAT VAL: Summarize th2: Kilobyte Drive Capacity 128: 32 Byte Directory Entries 0: Checked Directory Entries 1024: Records/ Extent 128: Records/ Block 58: Sectors/ Track 2: Reserved Trackspermanen fil indicators R/O=Read/Only R/W=Read/Write, SYS=System, DIR=Non-System STAT ld1=pd1, ld2=pd2, ... Chang th logica t physica devic assignments Logica devic ld i assigne t physica -- number of virtual 128-byte records in file This field is display if the optional $S is given rrrr -- number of 128-byte records in each extent of the file nnnK -- number of bytes (in K, K=1024) alloca UR2: User-defined reader #2 UP1: User-defined punch #1 UP2: User-defined punch #2 LPT: Line printer UL1: User-defined list device #1 STAT d:DSK: Iobyte Assign: CON: = TTY: CRT: BAT: UC1: RDR: = TTY: PTR: UR1: UR2: PUN: = TTY: PTP: UP1: UP2: LST: = TTY: CRT: LPT: UL1: STAT DEV: Displa th curren logica e status commands. STAT VAL: will print the list -- Temp R/O Disk: d:=R/O Set Indicator: d:filename.typ $R/O $R/W $SYS $DIR Disk Status : DSK: d:DSK: User Status : USR: IP Command PIР (Periphera Interchang Program i th CP/͠ transien whic implement th basi medi conversio operation necessar t load print punch copy an combin dis files PI i initiate b on o th followine file when the string s is seen. Tn Expand tabs to every nth column. U Translate lower case to upper case alphabetics. V Verify that data has been copied correctly. W Write over R/O files without console interrogation tpu destinatio t b patche (se manual). PRN Sam a LST: bu tab ar expande a ever eight characte position line ar numbered an pag eject are inse The form of each command line in PIP is -- destination = source#1, source#2, source#3, ..., source#n The general forms of PIP command lines are -- x:=y:af Cop al file satisfyin af fro driv t Ignore ':00' records in the transfer of Intel hex format file. L Translate upper case to lower case alphabetics. N Add line numbers to each line transferred to the destination. O Object file (non-ASCII) transfer. Ignore End oN:, LST: Valid physical devices are -- TTY:, CRT:, UC1:, PTR:, PTP:, UR1:, UR2:, UP1:, UP2:, LPT:, UL1: Additional device names which may be used in PIP commg forms -- PIР Engag PIP promp th use wit '*' an rea comman line directl fro th console PI use i thi wa i exite b eithe typin a empt b PI unti a ASCI X- Off character (Ctrl-S) is received from the source device. D Delet character whic exten pas colum i th transfe o data to the destination from the character source. E Echo all trted every 60 lines with an initial eject. Th use ca als specif on o mor PIР parameter enclose i square brackets separated by zero or more blanks. These parameters are --   Bloc mod transfer Dat i buffere driv x 'y ma b omitted and i so th currently logged-in drive is selected. x:ufn=y Cop th fil give b uf fro t x 'x ma b omittedf File. Pn Include page ejects at every n lines. Qs^ڠQui copyin fro th sourc devic o fil whe th strin (terminated by Ctrl-Z) is encountered. R Read system files Ss^Z Start copying from the sourcands are -- NUL: Send 40 Nulls (ASCII 0) to the device. EOF: Send a CP/M End of File character (ASCII Ctrl-Z). INP: Special PIP input source to be patched (see manual). OUT Specia PIР ou comman lin (jus carriag return o Ctrl- as the first character of the line. PIР cmn Engag PIP execut th specifie command an return to CP/M. ransfer operations to the console. F Filter (remove) form feeds from the file. Gn Get File from User Number n (n in the range 0 - 15) He dat transfer Al dat i checke fo prope Inte he fil format. I drive(s). ld=p Cop fro th specifie physica devic t th specifie logica device Vali logica device are -- CON:, RDR:, PU and i so th currentl logged-i drive is selected. x:afn=y:af Lik th above bu and/o ma b omitted th defaul driv i selecte fo th堠 omitte Z Zero the parity bit on input for each ASCII character. :CP/M ED Command Th EĠ Progra i th CP/͠ syste contex editor whic allow creatio an alteratio o ASCI files Complet detail ar give i th user's manual. . It is invoked by -- DDT DDT filename.HEX DDT filename.COM where 'filename' is the name of the program to be loaded or tested. DDT responds to the normal CP/M input line editing characters. DDT respo +/- n Move and type (+/- nLT) n: Move to absolute line (V engaged) :n Process from current line to specified line (V engaged) :CP/M ASM Command Th AS Comman load an execute th CP/ 808 assemble ^J New line (line feed) ^L Logical in search and substitute strings ^M New line (carriage return) ^U Line delete ^X Line delete and backspace ^Z nverts .HEX to .COM files). It is of the form -- LOAD filename where filename is the name of the file 'filename.HEX'. :The UNLOAD Command Th UNLOA Comman doe th revers o th LOA Comman -- i convert COM files to HEX fi with no file changes R Read library file nSs1^Zs2^Z Substitute s2 for s1 +/- nT Type lines +/- U Translate lower to upper case if U; none if -U +/- V Engage/ The following are the error indicators given by ED -- ? Unrecognized Command > Memory buffer full # Cannot apply command the number of times specified O Cannot open LIB file in R command the disk name to contain the hex file (y=Z suppresses generation of the hex file) z ... designates the disk name to contain the print file (y=X lists on CON:, y=Z suppresses listing) r I i o the form -- ASM filename.xyz where filename ... is the name of the file 'filename.ASM' to assemble x ... designates the disk name which contains the source y ... designates String terminator Rubout Character delete Break Discontinue command The following are the commands recognized by ED -- nA Append lines +/- B Beginning/Bottom of buffer les. It is of the form -- UNLOAD filename where filename is the name of the file 'filename.COM'. :CP/M DDT Command Th DDԠ Progra allow dynami interactiv testin an debuggin o programs generated in the CP/M environmentdisengage line numbers (verify) 0V Print memory buffer info (free/total usage) nW Write lines nX Transfer n lines to X$$$$$$$.LIB 0X Empty X$$$$$$$.LIB nZ Sleep The following are the control characters recognized by ED -- ^C System reboot ^E Physical (not entered in command) ^H Character delete (backspace) ^I Logical tab Refer to the ASM Manual for further details. :CP/M LOAD Command Th LOA Comman read th fil specified whic i assume t contai Inte he forma machin cod an produce memor imag fil whic ca b subsequently executed (costrings in juxtaposition +/- nK Kill (delete) lines +/- nL Move down/up lines nM Macro definition O Return to original file +/- nP Move and print pages Q Quit +/- nC Move character positions +/- nD Delete characters E Exit nFs^Z Find string H End edit, close and reopen files Is^Z Insert characters nJ Place nds to the following commands -- As Perform inline assembly starting at the specified address s. D Display memory from the current address for 16 display lines. Ds Display memory from address s for 16 display lines. Ds,f Diadvances pointer, or backs pointer. Q bbbb eeee Dumps from bbbb to eeee in ASCII. R n ll tt ss bbbb Rea bloc o dat fro dis o lengt l (256-byt pages starting at cters. The commands recognized by ZDT are -- A bbbb Ente ASCI character int memor fro keyboar startin a address bbbb. B Warm Boot -- Return to CP/M. C b Same as above with breakpoints at b and c. If Insert a file name f into the default FCB. L List 12 lines of disassembled code from the current address. Ls List 12 lines from the specified address s. Ls,f List Jump to and execute at location nnnn. K Keyboard echo. L filename.typ nnnn Loads specified disk file into location nnnn. M bbbb eeee nnnn Move block from bbbb to ee B BC Reg pair D DE Reg pair H HL Reg pair S Stack pointer P PC :The ZDT Command ZDT is a Z80 version of DDT. It is invoked by typing -- ZDTsplay memory from address s to address f. Fs,f,c Fill memory from start address s to final address f with byte c. G Start execution at the current value of the PC. Gs Start execution at the specified address s. Gs, fo ASCI strin fro bbb t eeee Strin i a most 16 characters. String is terminated by . F bbbb eeee Searc fo he strin fro bbb t eeee Strin i terbbb eeee nnnn Compar memor fro addres bbb t addres eee t bloc starting at nnnn. D bbbb eeee Dump memory from bbbb to eeee. E bbbb eeee Searclines of disassembled code from s to f. Ms,f,d Move the block from address s to f to destination at address d. R Read file in FCB into memory at 100H. Rb Read file in FCB into memory with offset b from 100H. Ssee-1 to nnnn. N aaaa Enter offset aaaa for loading. O nn dd Output byte dd to port nn. P bbbb Inpu he int memor fro keyboar startin a bbbb . G Go to next breakpoint. H aaaa nnnn Hex add and subtract. Computes aaaa+nnnn and aaaa-nnnn. I nn Input. Prints value at port nn. J nnnn and flags. Xr Examine specified registers or flag, where r may be -- C Carry flag Z Zero flag M Minus (sign) flag I Interdigit Carry flag A Accumulator Set (examine and alter) memory starting at address s. T Trace the next instruction. Tn Trace the next n instructions. U Untrace -- like Trace, but intermediate steps are not displayed. X Examine all registers track tt and sector ss placing the data at bbbb. S bbbb eeee Disassembly (symbolic dump) from bbbb to eeee. T bbbb eeee Destructive memory test from bbbb to eeee-1. U bbbb Set H=0 CP/M, H=1 MP/M L=00 CP/M 1.x, 2x 2.x Init BDOS 13 None None Log-In Disk 14 Value in Reg E None A=0, B=1,n E None Read Reader 3 None ASCII Char in A Write Punch 4 ASCII Char in E None Write List 5 ASCII Char in E None Direct Con I/O 6 ASCII Char in E I/O Status inontaining the CP/M Operating System. It is invoked by typing SYSGEN Onc invoked th use i prompte throug th session Refe t th CP/M Manual for further details. :CP/M SUBMIT and XSUB Commands Th SUBMIԠ 10 BAT: UR1: UP1: LPT: 11 UC1: UR2: UP2: UL1: Read Buffer -- Byte Function 1 Maximum Buffer Length 2 Current Buffer Length (returned value) 3 print th messag "(xsu active) o eac war boot A exampl o th use of XSUB to display memory from 100H to 1FFH is -- XSUB DDT D100,1FF G0 :CP/M BDOS -- Ba breakpoint at bbbb. V Display all currently-set breakpoints. W n ll tt ss bbbb Writ o dis th dat a bbb fo lengt o l startin at track tt, sector ss. ll is in 256-byt in DE Read Buffer 10 Address of Read Read Buffer is filled Buffer in DE Console Ready 11 None LSB of A is 1 if char A if E=0FFH Get I/O Status 7 None I/O Status in A Put I/O Status 8 I/O Status in E None Print Buffer 9 Address of string None terminated by $ comman allow CP/ command t b batche togethe fo automatic processing. The form of this command is SUBMIT ufn parm1 parm2 ... parmn Th uf give i th SUBMI comman mus b th filenam (no type o fil whic exis-n Data (returned values) :CP/M BIOS -- Basic Disk Operations Function and Number Input Parameters Output Parameters Return Version # 12 None Version Info in HL sic I/O Operations Function and Number Input Parameters Output Parameters System Reset 0 None None Read Console 1 None ASCII Char in A Write Console 2 ASCII Char ie pages. X Display registers. Z bbbb eeee dd Zero or set memory from bbbb to eeee-1 with byte dd. :CP/M SYSGEN Command Th SYSGE transien comman allow generatio o a initialize dis c ready *All function numbers are passed in Reg C. I/O Status Byte -- Value Bits 6&7 Bits 4&5 Bits 2&3 Bits 0&1 00 CON:=TTY: RDR:=TTY: PUN:=TTY: LST:=TTY: 01 CRT: PTR: PTP: CRT: f-relocate directl belo th CCP Al subsequen SUBMI comman line ar processe b XSUB s tha program whic rea buffere consol inpu (BDOӠ Functio 10 receiv inpu directl fro th SUBMI File Whil XSU i i memory i t o th currentl logged-i dis wit a assume fil type of '.SUB'. Refer to the CP/M Manual for further details. Th XSU  comman extend th powe o th SUBMIԠ facility Whe specifie a th firs lin o SUBMI File i sel C=2, D=3 Open File 15 Address of FCB Byte address of FCB in DE if found or 0FFH if not Close File 16 Address of FCB Byte address of om Rec Field set *All function numbers are passed in Reg C :CP/M File Types AIN ALGOL 60 Intermediate ALG ALGOL 60 Source File ASM Assembler Source File BAK Backup File BAS BASIC Source File C C Source File/O Vect Val Set File Attrib 30 Ptr to FCB in DE Dir code in A Get Disk Parms 31 None HL=DPB Address Set/Get Usr Code 32 E=0FFH (get)/Code A=Current code (get)/no (set) if found or 0FFH if not Function and Number Input Parameters Output Parameters Read Next Record 20 Address of FCB 0=successful read in DE 1=read past EOF 2=(not used) 3=can't close curr ext 4=seek to unwritten ext 5=dir overflow logged-in drive (A=0, B=1, C=2, D=3) Set DMA Address 26 Address of 128 None byte buffer in DE Function and Number Input Parameters Output PFCB in DE if found or 0FFH if not Search for File 17 Address of FCB Byte address of FCB (0-3) in DE if found or 0FFH if not Search for Next 3=can't close curr ext 4=seek to unwritten ext 5=(not used) 6=seek past end o value (set) Read Random 33 DE=FCB addr A=return code 1=reading unwritten data 2=(not used) 2=reading random data Write Next Rec 21 Address of FCB 0=successful write in DE 1=error in extending 2=end of d 6=seek past end of disk Compute File Siz 35 DE=FCB addr Random Rec Field set to file size Set Random Rec 36 DE=FCB addr Randarameters GeAllo Vec 2 Non Allocatio Vec Add i HL Write Prot Disk 28 None None Get R/O Vect 29 None HL=R18 Address of FCB Byte address of next FCB in DE if found or 0FFH if not Delete File 19 Address of FCB Byte address of FCB (0-3) in DE f disk Function and Number Input Parameters Output Parameters Write Random 34 DE=FCB addr A=return code 1=reading unwritten data 23 Address of FCB Byte Address of Dir entry in DE or 255 if no match Return Log Code 24 None Login vector in HL Read Drive No 25 None Number of isk data 255=no more dir space Make File 22 Address of FCB Byte address of FCB or in DE 255 if no more dir space Rename FCB COB COBOL Source File COM "Command" File FOR FORTRAN IV Source File HEX Intel "hex" code file HLP HELP File INT BASIC Intermediate File LST Listing File MAC MACRO-80 Source File E Generate line number code; normally OFF After compilation, the program may then be executed by -- ERUN filename where 'filename' is the name of the intermediate code file 'filename.INT'. :BASIC-E Statements Th number returned in Reg L  i Re à usin tabl pointe t b DE physica secto 00H Cold Start WBOOT 03H Warm Start CONST 06H Console Status Reg A = 00 if no char ready Reg A = FF if char ring BASIC-E BASIC-E is invoked by typing the following -- EBASIC filename $o wher 'filename i th nam o th sourc fil 'filename.BAS t b compiled and 'o' is one or more of the following options -- A List address (RP B&C) READ 27H Read track/sector (block) WRITE 2AH Write track/sector (block) LISTST 2DH List Device Status Reg A = 00 if no char PAS PASCAL Source File PRN Assembler Listing File REL Relocatable Module SRC PASCAL/MT Source File SUB SUBMIT File SYM Symbol File TC Tiny-C Source File TFS TFS Source File TXT Text Fileady CONIN 09H Console char in (Reg A) CONOUT 0CH Console char out (Reg C) LIST 0FH List out (Reg C) PUNCH 12H Punch out (Reg C) READER 15 Productions (for compiler debugging); normally OFF B List only source statements with errors; normally OFF C Check syntax only; don't create .INT file; normally OFF D Convert lowercase to uppercase; normally ON ready Reg A = FF if char ready SECTRAΠ 30 Translat secto numbe i Re à usin tabl pointe t b DE physica secto e $$$ Temporary File :CP/M BIOS Jump Vector Th followin i tabl representin th entr point int th CP/ BIOS of the major routines accessable to the user -- Routine Relative Offset Comment BOOT Invoking BASIC-E BASIC-E Statements BASIC-E Functions Differences between BASIC-E and CBASIC BASIC-E Error Messages CBASIC: Compiler Error Messages CBASIC: Run-Time Error Messages -- Warnings CBASIC: Run-Time Error Messages -- Error Codes :Invok addres give b Re (0...76) SETSEà 21Ƞ Se secto addres give b Re (1...26) SETDMA 24H Set subsequent DMAH Reader in (Reg A) Routine Relative Offset Comment HOME 18H Move to track 00 SELDSK 1BH Select disk given by Reg C (A=0,B=1,...) SETTRˠ 1EȠ Se trace following statements are valid in BASIC-E -- FOR NEXT FILE GOTO LET CLOSE GOSUB INPUT ON PRINT READ RESTORE RETURN OUT RANDOMIZE STOP DATA Drequired. MM -- Mixed Mode Variable o typ strin an typ numeri ar combine i th sam expression. NI -- NEXT Index variabl reference b NEX statemen doe no matc th variabl referenced by the associated FOR sta Othe compile error ma caus D erro messag t b printe eve i duplicat lin numbers do not exist. DP -- Defined Previously A variable in a DIM statement was previously defined. EF -- Exponential Format numbe i e ar no availabl i BASIC-E bu the ar available in CBASIC -- 1. PEEK or POKE 2. PRINT USING 3. CALL to machine code programs 4. LPRINT :BASIC-E Error Messages Sinc BASIC- i "sustring. Only type numeric is permitted. IF -- In File variabl use i FIL statemen i o typ numeri wher typ string is required. IP -- Input Prompt An input prompt string is not surrounded by quotes. IS -- Invalid Sute is ignored by the compiler, and a question mark is printed in its place. 2-Letter Error Codes CE -- Close Error The intermediate (.INT) file could not be closed. DE -- Disk Error A disk error occurEF DIM END IF REM ELSE THEN :BASIC-E Functions The following built-in functions are valid in BASIC-E -- ABS ASC ATN CHR$ COS COSH FRE INP INe numeri variabl i bein used as a FOR loop index. FN -- Function parameter Number A function reference contains an incorrect number of parameters. FP -- Function Parameter type functio referenc paramete typ doe no matc thexponentia forma wa inpu wit n digit followin th E. FD -- Function Definition functio nam tha ha bee previousl define i bein redefine i a DEF statement. FI -- FOR Index A expressio whic i no a unsubscriptbset o CBASIC refe t th CBASI hel fil for information on the BASIC-E error messages. Most bu no all BASIC- erro message ar covere i thi hel file. :CBASIC: Compiler Error Messages Texbscript A subscripted variable was referenced before it was dimensioned. IU -- Invalid Use A variable defined as an array is used with no subscripts. MF -- Mixed Format An expression evaluates to type string when type numeric is red while trying to read the .BAS file. DF -- Disk Full Ther wa n spac o th dis o th dis director wa full Th .INT file was not created. DL -- Duplicate Line number Th sam lin numbe wa use o tw differen linesT LEFT$ LEN LOG MID$ POS RIGHT$ RND SGN SIN SINH STR$ SQR TAB TAN VAL EXP :Differences between BASIC-E and CBASIC Th followin featur paramete typ used in the function's DEF statement. FU -- Function Undefined A function has been referenced before it has been defined. IE -- IF Expression A expressio use immediatel followin a IƠ evaluate t typ could not be found. PROGRAM CONTAINS n UNMATCHED WHILE STATEMENT(S) There are n WHILE statements for which a WEND could not be found. WARNING: INVALID CHARACTER IGNORED Th previou lin contain a invali ASCI character thi charact Messages NO SOURCE FILE: .BAS Th compile coul no locat sourc fil use i eithe CBASI command or an INCLUDE directive. PROGRAM CONTAINS n UNMATCHED FOR STATEMENT(S) There are n FOR statements for which a NEXTtement. NU -- NEXT Unexpected A NEXT statement occurs without an associated FOR statement. OO -- ON Overflow More than 25 ON statements were used in the program. SE -- Syntax Error The source line contains a syntax error. S IR -- Invalid Record number A record number less than one was specified. LW -- Line Width lin widt les tha o greate tha 13 wa specifie i a LPRINTE WIDT statement. ME -- MAKE Error A erro occurre whilwin th rais t powe operato (^) Th absolut valu i use i th calculation. OF -- OverFlow calculatio produce numbe to large Th resul i se o th larges vali CBASI number. SQ -- SQuare root error ted by a carriage return rather than quotes. VO -- Variable Overflow Variable names are too long for one statement. This should not occur. WE -- WHILE Error The expression immediately following a WHILE statement is not numeric. EF -- End of File rea pas th en o fil occurre o fil fo whic n IƠ EN statemen ha bee executed. ER -- Error in Record A attemp wa mad t writ recor o lengt greate tha th maximu recor siz specer Warning Codes DZ -- Divide by Zero numbe wa divide b zero Th resul i se t th larges vali CBASI number. FL -- Field Length fiel lengt greate tha 25 byte wa encountere durin REA LINE Onl th firsN -- Subscript Number A subscripted variable contains an incorrect number of subscripts. SO -- Syntax Overflow Th expressio i to comple an shoul b simplifie an place o more than one line. TO -- Table Overflow Th prlose Error An error occurred upon closing a file. CU -- Close Undefined file clos statemen specifie fil numbe tha wa no active. DF -- Defined File A OPE o CREAT wa specifie wit fil numbe tha wa alread negativ numbe wa specifie i th SQ function Th absolut valu i used. :CBASIC: Run-Time Error Messages -- Error Codes AC -- AsCii error Th strin use a th argumen i a AS functio evaluate t nul string. CE -- C WU -- WHILE Undefined A WEND statement occurs without an associated WHILE statement. :CBASIC: Run-Time Error Messages -- Warnings Tw textua run-tim erro message ar presente b CRUN: NO INTERMEDIATE FILE fil nam wa noifie i th associate OPEN CREATE o FIL statement. FR -- File Rename A attemp wa mad t renam fil t a existin fil name. FU -- File Undefined A attemp wa mad t rea o writ t fil tha wa no active. 25 character o th recor ar retained. LN -- Logarithm error Th argumen give i th LO functio wa zer o negative Th valu o th argumen i returned. NE -- NEgative number negativ numbe wa specifie folloogra i to larg fo th system Th progra mus b simplified or the system size increased. UL -- Undefined Line number A line number that does not exist has been referenced. US -- Undefined String A string has been termina active. DU -- Delete Undefined file DELET statemen specifie fil numbe tha wa no active. DW -- Disk Write error A erro occurre whil writin t file Thi occur whe eithe th director o th dis i full. U statement Thi ca occu whe fiel type d no matc o th numbe o field entere i differen fro th numbe o field specified Al field specifie b th INPU statemen mus b reentered. 2-Lett specifie wit th CRU command o n fil o typ .IN an th specifie fil nam wa foun o disk. IMPROPER INPUT - REENTER Thi messag occur whe th field entere fro th consol d no matc th fiel specifie i th INP creatin o extendin fil becaus th dis director wa full. MP -- MATCH Parameter Th thir paramete i MATC functio wa zer o negative. NF -- Number of FILE Th fil numbe specifie wa les tha o greate tha 20. listing is written. source-dev Th devic fro whic th sourc progra inpu t FORTRAN-80 or MACRO-80 is obtained. filename.ext Th filenam an filenam extensio o th objec progra file th listin file an th i ha bee rea t th en o th file.  nul edi string. WR -- WRite error A attemp wa mad t writ t fil afte i ha bee read bu befor wa mad t OPE fil tha didn' exis an fo whic n I EN statemen ha bee previousl executed. OI -- ON Index Th expressio specifie i a O .. GOSU o a OΠ .. GOT statemen evaluate t numbe les tha AN-8 compile an th MACRO-8 assembler name F8 an M8 respectively ar invoke i simila fashion I bot cases th nam o th progra i give followe b a argumen list Thi argumen lis i of the general form -- ob SubString error Th secon paramete o MID functio wa zer o negative. TF -- Too many Files A attemp wa mad t hav mor tha 2 activ file simultaneously. TL -- TAB Length TA statemen containe paramete les NM -- No Memory There was insufficient memory to load the program. NN -- No Number field A attemp wa mad t prin numbe wit PRIN USIN statemen bu ther wa no numeri dat fiel i th USIN string. NS -- No Stringo greate tha th numbe o lin number containe i th statement. OM -- Overflow Memory The program ran out of memory during execution. QE -- Quote Error A attemp wa mad t PRIN t fil strin containin quotatio marj-dev:filename.ext,list-dev:filename.ext= source-dev:filename.ext These symbols are defined as follows -- obj-dev: The device on which the object program is to be written. list-dev: The device on which the program tha o greate tha th curren lin width. UN -- UNdefined edit string PRIN USIN statemen wa execute wit nul edi string. WR -- WRite error A attemp wa mad t writ t fil afte i ha bee read bu befor field A attemp wa mad t prin strin wit PRIN USIN statemen bu ther wa no strin fiel i th USIN string. OD -- Overflow Data REAĠ statemen wa execute wit n DAT available. OE -- OPEN Error A attempInvoking FORTRAN-80 and MACRO-80 FORTRAN-80 Compilation Switches FORTRAN-80 Library Subroutines FORTRAN-80 Logical Device Assignments Invoking LINK-80 LINK-80 Switches Creating a FORTRAN-80 .COM File :Invoking FORTRAN-80 and MACRO-80 Th FORTR othe tha fixe file. SB -- SuBscript A arra subscrip wa use whic exceede th boundarie fo whic th arra wa defined. SL -- String Length concatenatio operatio resulte i strin o mor tha 25 bytes. SS --k. RE -- READ Error A attemp wa mad t rea pas th en o recor i fixe file. RG -- RETURN with no GOSUB A RETURN occurred for which there was no GOSUB. RU -- Random Undefined rando rea o prin wa attempte tsourc progra file Th defaul extensions are -- FOR FORTRAN-80 Source File MAC MACRO-80 Source File PRN Print (Listing) File REL Relocatable Object File COM ollowe b a asterisk LINK-8 i invoke b th progra nam 'L80'. LINK-8 ca b use t generat .CO fil o FORTRAN-8 program This can be done by typing -- L80 program/E LINK-80 will respond with a string of the form generate cod shoul b i a form which can be loaded into ROM. :FORTRAN-80: FORTRAN-80 Library Subroutines Th standar librar (FORLIB.REL include th followin subroutine and functions -- ABS IABS DABS eed Reader LST: Line Printer TTY: Teletype or CRT Examples -- A>F80 *=TEST Compile the program TEST.FOR and place the object in TEST.REL *,TTY:=TEST Compil th progra80: Invoking LINK-80 Eac comman t LINK-8 consist o numbe o filename an switche separated by commas -- obj-dev1:filename.ext/sw1,obj-dev2:filename.ext, ... I th inpu devic fo fil i omitted th defaulan strin tha wil affec th forma o th listin file Eac switc shoul b precede by a slash (/): Switch Function ------ -------- O Print all listing addresses in octal H Print all listing addresses in hexadecimal Absolute Object File ORGed to 100H Th specification fo eithe th objec file th listin file o bot ma b omitted I neithe listin fil no a objec fil i desired plac onl comm t th lef o th equa sign I DEXP ALOG DLOG ALOG10 DLOG10 SIN DSIN COS DCOS TANH SQRT DSQRT ATAN DATAN ATAN2 DATAN2 DMOD PEEK POKE INP OUT :FORTRAN-80: FORTRAN-80 Logical Device Ass AINT INT IDINT AMOD MOD AMAX0 AMAX1 MAX0 MAX1 DMAX1 AMIN0 AMIN1 MIN0 MIN1 DMIN1 FLOAT IFIX SIGN ISIGN DSIGN DIM IDIM SNGL DBLE EXP TEST.FOҠ an lis th progra o th terminal. No object is generated. *TESTOBJ=TEST.FOR Compile the program TEST.FOR and put object in TESTOBJ.REL *TEST,TEST=TEST Compil TEST.FOR an pu objec i TEST.RE i th currentl logge disk I th extensio o fil i omitted th defaul i .REL Afte eac lin i typed LINK-8 wil loa o searc th specifie files and whe finished i wil lis al symbol tha remai undefine f(default) N Do not list generated code R Force generation of an object file L Force generation of a listing file P Each /P allocates an extra 100 bytes of runtime stack space ͠ Specifie t th compile tha th th name o th objec fil an th listin fil ar omitted th defaul i th nam of the source file. Logical CP/M devices may be specified as follows -- A:, B: Disk Drives (Only A: or B:) HSR: High Spignments LUN* Device ---- ------ 1,3,4,5 Preassigned to CON: 2 Preassigned to LST: 6-10 Preassigned to Disk Files (Reassignable) 11-255 User-Assignable * LUN = Logical Unit Number :LINK- performe b typin 'F80 followe b th option like 'F80 =TEST'. Refer to the 'FORTRAN-80 User's Manual', Copyright 1977, by Microsoft. :FORTRAN-80: FORTRAN-80 Compilation Switches numbe o differen switche ma b give i th comm an listin i TEST.PRN *,=TEST.FOR Compil TEST.FO bu produc n objec o listin file Usefu for checking for errors. I al cases th i th promp fro FORTRAN-80 Th indicate operation ma als b -- [aaaa bbbb nn] The user may then create the .COM file by typing -- SAVE nn program.COM :LINK-80: LINK-80 Switches Th followin ar th switche fo LINK-80 A fo FORTRAN-80 thes switches are preceeded by a slash "d:" is the disk the HELP File resides on (optional) and "topic" is the name of the HELP File (topic.HLP, like CPM.HLP). Please refer to the HELP File "HELP.HLP" for more information. ͊_ ~#)\*)"~ a b#O##͊:=2An}͕͊> > >2!͕>A2}l~:} :}<2}>.> Oî"~͕O~: :Gcreference an thei values al undefine references are followed by an asterisk. Search Searc th fil specifie befor thi switc t satisf references. I filename/ i specified th progra wil bh as the language systems he is using and certain subsystems available to him. When the user types 'HELP', a search is done for the file 'HELP.HLP'. If found, the contents of this HELP File is displayed to the user; if not found, the HELP Infor LINK-80 Switch F80 =PROG L80 PROG/E,PROG/N  =PROG L80 PROG/E [aaaa bbbb nn] -- response from LINK-80 (necessary data) SAVE nn PROG.COM II. Using /N(/). Switch Function ------ -------- R Reset. Initialize loader. E,E:nam Exi LINK-80 FORLIB.RE wil b searche t satisf existin undefine references I 'name i specified th valu o thi symbid Response $ HELP ERROR -- EOF on HELP File $ Type CTRL-C to return to CP/M, "*" to select all, or enter selection - $ections are -- $HELP HLP Type "A"=Abort, CTRL-C=CP/M, =Cont -$ HELP FATAL ERR:The HELP Subsystem for Online Documentati͊:=2-}͕HELP V1.1 $ ++ EOI ++ Type CTRL-C to return to CP/M, to continue -$ HELP File Selections are -- $HELP HLP Type "A"=Abort, CTRL-C=CP/M, =Cont -$ HELP FATAL ERROR -- File not Found$ HELP ERROR -- Inval save o dis under the selected name with a default extension of .COM. P and D See Addenda to Section 2 of documentation. Thre number ar specifie afte th / an / switche ar executed They are given in the form -- mation you are now reading is displayed. If the user desires information on a specific topic and he has a HELP File of that name (ie, CPM.HLP is a HELP File on CP/M), he may issue of HELP Command of the form -- HELP d:topic where!9"2!!]~ 0+ )>2F!e~ =F)\a:n!"4g1!~:‚*͛1}*͊@GʨұÂ Ҩ*~#Â~#  #~:ʹÂ*~͕#~nol is used as the start address of the program. G,G:nam Go Star executio o program FORLIB.RE wil b searche t satisfy any existing undefined references. U List all undefined references. Map Lis al define on This is HELP, the Online Documentation Subsystem. The purpose of HELP is to allow the user to interactively query the *.HLP files of the system in order to receive information summaries on various aspects of the user's working environment, sucgram Fo example t generat PROG.CO fro PROG.FOR procee i on of the following ways -- I. Using SAVE F80 =PROG L80 PROG/E [aaaa bbbb nn] -- response from LINK-80 (necessary data) SAVE nn PROG.COM II. Using /N [aaaa bbbb nn] aaaa - start address of program bbbb - address of next available byte nn - number of 256-byte pages used :Creating a FORTRAN-80 .COM File Ther ar tw basi way t creat .CO͠ fil o FORTRAN-8 proWelcome to the HELP Command How to use the HELP Command How to write .HLP Files Help on CP/M in general :HELP: Welcome to the HELP Command Welcom t th HEL Command Th HEL Comman i designe t assis you th CP/͠ user i th us Indexed .HLP Files Indexe .HLР file ar simpl ASCI file whic d no star wit colo (: a th firs characte o th file Thi typ o .HLР fil consist o on o mor norma ASCI tex ll (no bein displaye t you) Fo al othe form o th HEL command th use wil se th specifie hel fil information Generall speaking th nam o th hel fil shoul b indicativ o it subject lik CPM.HL shoul contai heallow hi t selec entrie fro it Th use ma selec a man entrie a h desire i an orde h desire b simpl typin th lette o hi selection Onc th use ha mad hi selection hel wil loo u th bod o tex h selecte ot pass between screen displays. Non-Indexed .HLP Files Non-indexe .HL file ar simpl ASCI file whic star wit colo (: a th firs characte o th fil an consis o ASCI tex (wit eac lin term Richard Conn :HELP: How to use the HELP Command Th HEL Comman i execute i on o thre ways: (1) by just typing 'HELP' (2) by typing 'HELP FILENAME', where FILENAME is the name of a dis o CP/ i genera an specifi CP/ command i particular I i designe a a interactive on-lin assistanc system. HEL pull i file name .HL fro dis an display thes t th use i page mode Thes above ar o tw basi types indexe an non-indexed an eac typ i relate t th othe an i o th sam basi format Grouping of Information Informatio displaye t th use i groupe b th indel informatio o CP/M. :HELP: How to write .HLP files File use b th HEL progra ar eithe simpl CP/M-standar file o栠 ASCIɠ tex o ASCIɠ file generate b th Wor䠠 Sta tex editor/formatter Thes files a mentionean displa i t hi i page mode Whe th use ha finishe readin hi selection HELР the return hi t th inde menu Typin Control- wil retur th use t CP/M. Non-indexe file ar thos .HL file whic d no sinate b carriag return/lin fee characte combination) Th informatio i suc hel fil consist o al tex afte th leadin colo u t eithe th terminatin end-of-fil mar (control-Z o ne lin whic start wit colon.k file named FILENAME.HLP (3) by typing 'HELP FILENAME.EXT', where FILENAME.EXT is the name of a file created in the format of a help file I th use type jus 'HELP' h wil receiv th HELP.HL hel fifile ar o tw basi type -- indexe an non-indexed. Indexe file ar thos .HL file whic star wit a index Thi i a exampl o a indexe file Whe HEL load a indexe file i display thi inde t th use an i indexe HLР file an ma als b groupe b line beginnin wit For Fee (^L characters Groupin i a effectiv wa t logicall organiz informatio s tha meanin wil b mor clea t th use an unit o informatio will ne a an give tim ar displaye t him HEL ca b ver usefu too fo on-lin referenc t th user It i conjunctio wit th man HL file no available ha alread prove t be of significant value. tar wit a index I suc cases HEL wil immediatel displa th content o th fil t th use and whe th use ha finishe lookin a it HEL wil retur t CP/M. HEL i menu-driven an al th command availabl t th usine a th firs line o th fil followe b informatio section whic begi wit lin whos firs characte i colo an en wit eithe th firs lin o th nex informatio sectio o th en o th file. :HELP: General Informwing command -- MAC d:filename $parms Onl 'filename i required an i represent fil name 'filename.ASM' MAà ma the generat u t othe file -- filename.HE (th Inte He Forma File) filename.PR (th PI {translator} man interpretiv BASICs ALGOL FOCAL an C) an severa special-purpos application program (suc a tex formattin system an accountin systems). Refe t th indicate manual and/o th CP/ hel fil fo furte configuratio whic use a Inte 808 o Zilo Z8 Microprocesso an ha a leas 16 byte o mai memor wit u t fou IBM-compatabl diskett drives. Th CP/ monito provide acces t program throug comprehensiv fil manler Th facilitie o MA includ assembl o栠 Inte젠 808 microcompute mnemonics alon砠 wit蠠 assembly-tim expressions conditiona assembly pag formattin features an macr processo whic i compatabl wit th standar stem Alteration Guide A th reade ca see CP/ support contex editor a assemble (Intel-compatable) an debugge system Thes ar availabl i th basi CP/ package Ther i larg variet o othe softwar availablation on CP/M CP/ i monito contro progra fo microcompute syste developmen whic use IBM-compatibl flexibl disk (flopp disks fo mas storage Usin microcompute mainfram base o Intel' 808 o Zilog' Z8 microphe information.  tex formattin system an accountin systems). Refe t th indicate manual and/o th CP/ hel fil fo furtagemen system Th fil subsyste support name fil structure allowin dynami allocatio o fil spac a wel a sequentia an rando fil access Usin thi fil system u t 6 distinc program ca b store i bot Inte definitio (MA implements the mid-1977 revision of Intel's definition). MA require approximatel 12 o machin cod an tabl space alon with an additional 2.5K of I/O buffer space. :Executing MAC MAC is invoked by the follo whic ca ru unde CP/ wit littl o n modification Suc softwar include severa assembler (bot 808 an Z80) symboli debugger severa high-leve language (includin FORTRAΠ I֠ {compiler} BASIC- {translator} CBASrocessor CP/͠ provide genera environmen fo progra construction storage an editing alon wit assembl an progra debu facilities A importan featur o CP/ i tha i ca b easil altere t execut wit an computIntroduction Executing MAC XMAC Assembly Control Parameters Assembler Pseudo-Ops Inline Error Messages Console Error Messages :Introduction MA i th CP/ Standar Macr Assembler i i upward-compatabl wit ASM th CP/ Standar Assembeature an Facilities 2. ED: A Context Editor for the CP/M Disk System 3. ASM: CP/M Assembler User's Manual 4 DDT CP/ Dynami Debuggin Too User' Manual 5. CP/M Interface Guide 6. CP/M Sysourc an machine-executabl form. Digita Research th designe o CP/M ha provide se o si manual whic describ th us an operatio o CP/ i detail. These manuals are: 1 A Introductio t CP/ Frin o Listin file) an filename.SY (a file containing a sorted list of the symbols used in the program). MACR Librar file ma b reference b th program thes file ar named 'filename.LIB'. $parm represent th optiona assDB defines data bytes or strings of data DS reserves storage areas DW defines words of storage ELSE alternate to IF END terminates the physical program ENDIF marks t- designates that particular drive P -- designates the LST: device X -- designates the user console (CON:) Z -- designates a null file (no output) For example, $PB AA HB SX send th .PR fnde t b use fo Cross- Assembl usin .LI file whic contai th assemble mnemonic fo th targe machine XMA i invoke i exactl th sam wa MAà i (excep tha n SUBMI fil i available) an i recognize th sam pseudo- suppress all LOCAL symbols in the symbol list (default) +1 - produce a listing file on the first pass (for MACRO debugging) -1 - suppress listing on pass 1 (default) Th programme ca interspers control throughou th asse L - controls the source disk for the .LIB files M - controls MACRO listing in the .PRN file P - controls the destination of the .PRN listing file Q - controls the listing of LOCAL symbols S - controls the generembl contro parameter whic ar discussed in the next section. MAà ma b execute b employin th SUBMIԠ fil MAC.SUB MAC.SU assemble th specifie MA .AS file convert i int .CO fil vi LOAD, and erases the .HEX file +L - list the input lines read from the MACRO library -L - suppress listing of the MACRO library (default) +S - append the .SYM output to the end of the .PRN file (default) -S - suppress the generation of the sorted symbol table il t driv B: get th .AS fil fro driv A: send the .HEX file to drive B:, and sends the .SYM file to CON:. Th parameter L S M Q an ma b precede b eithe o - t enable or disable their respective functions -- op an contro parameters. Th patc fil XMAC.AS contain th patche use t conver MAà int XMAC. Th堠 librar file MAC40.LI  an XMAC40.LI  contai th macro necessar t assembl cod fo th Inte 404 microprocessormbl languag sourc o librar files Intersperse control ar denote b "$ i th firs colum o th inpu lin followe immediatel b parameter. :Assembler Pseudo-Ops The following Pseudo-Ops are supported -- ation and destination of the .SYM file 1 - controls pass 1 listing I th cas o th A H L P an parameters the ma b followe b th driv nam fro whic t obtai o t whic t sen data wher -- A,B,C,D -. MAC.SUB is invoked by -- SUBMIT MAC filename where 'filename' is the name of the MAC file 'filename.ASM'. :XMAC XMAà i versio o MA whic doe NO recogniz th intrinsi Inte 808 assemble languag mnemonics XMA i inte +M - list all MACRO lines as they are processed (default) -M - suppress all MACRO lines as they are processed *M - list only HEX code generated by macro expansions in listing +Q - list all LOCAL symbols in the symbol list -Q -arameters Th contro paramete lis i precede b $ an ma contai an o the following in any order -- A - controls the source disk for the .ASM file H - controls the destination of the .HEX machine code file fo example MAC40.LI rename th 404 mnemonic fo ADD SUB etc. t ADD4 SUB4 etc. s tha i wil no conflic wit MAC XMAC40.LI doe no renam these, since XMAC does not recognize these in the first place. :Assembly Control Phe end of conditional assembly ENDM marks the end of a MACRO EQU performs a numeric "equate" EXITM abort expansion of the current MACRO level IF begins conditional assembly IRP n hexadecimal R Force generation of an object file L Force generation of a listing file C Force generation of a cross reference file Z Assemble Zilog (Z80) mnemonics I Assemble IntelFILE WRITE ERROR - Error in writing output file CANNOT CLOSE FILE - An output file cannot be closed. UNBALANCED MACRO LIBRARY - No ENDM encountered for a MACRO definition INVALIĠ PARAMETE - Invali assembl paramete wa foun i th inment TITLE enables page titles and options :Inline Error Messages   - Balanc error MACR doesn' terminat properl o conditiona assembly is ill-formed à - Comm error expressio wa encountere bu no delim :Invoking MACRO-80 MACRO-80 is invoked by the following command -- M80 obj:fn1.ext,lst:fn2.ext=src:fn3.ext where obj:fn1.ext is the device/filename for the object program lst:fn2.ext is the device/filename for the liatabl with op code S - Statement/Syntax error: statement is ill-formed V - Value error: operand is improperly formed or out of range :Console Error Messages NO SOURCE FILE PRESENT - .ASM file not found NO DIRECTORY SPACE - Dir INLINE MACRO with string substitution IRPC INLINE MACRO with character substitution LOCAL define LOCAL variables unique to each MACRO repetition MACLIB specify MACRO Library to load MACRO defipu line. O LIBRARY - No ENDM encountered for a MACRO definition INVALIĠ PARAMETE - Invali assembl paramete wa foun i th inite properly from the next item by a comma - Dat error elemen i dat statemen (DB,DW canno b place in the specified data area E - Expression error: expression is ill-formed and cannot be computed I - Invalid charactersting src:fn3.ext is the device/filename for the source :MACRO-80 Switches The following switches may be specified in the command line -- O Print all listing addresses in octal H Print all listing addresses iectory is full SOURCŠ FIL NAM ERRO - Th for o th sourc fil nam i invalid not tha MA i invoke b 'MA filename' an th .AS fil typ i NO specified. SOURCE FILE READ ERROR - Error in reading source file OUTPUT nes beginning of a MACRO ORG sets the program or data origin PAGE defines the listing page size for output REPT defines the beginning of a INLINE MACRO SET performs a numeric "set" or assignInvoking MACRO-80 MACRO-80 Switches MACRO-80 Pseudo-Ops MACRO-80 In-Line Error Messages MACRO-80 Console Error Messages Invoking LINK-80 LINK-80 Switches Invoking LIB-80 LIB-80 Switches Invoking CREF-80 Debugging MACRO-80 Programs Using DEBUG.MAC error expressio i to complicate o th numbe o LOCAL labels has exceeded 9999 Р - Phas error label doe no hav sam valu o bot passe (multiple label) - Registe error valu specifie fo registe i no comp: a non-graphic character has been found L - Label error: label cannot appear in this context M - MACRO overflow error: internal MACRO expansion table overflow N - Not implemented error: unimplemented feature used Ϡ - Overflo (8080) mnemonics Р Eac / allocate a extr 25 byte o stac spac fo us during assembly. Use /P if stack overflow errors occur during assembly. :MACRO-80 Pseudo-Ops The following are the pseudo-ops recognized by MACRO-8 angl bracket an separate b commas I n module ar selecte fro file the al modules are selected. :LIB-80 Switches /O Set listing radix to Octal /H Set listing radix to Hexadecimal /U List undefineds Star executio o th program Again i /G:Nam i specified, Name defines the start address of execution. /N Save the binary on disk under the name 'filename.COM'. /P:adr and /D:adr IRPC EXITM LOCAL COND ENDC *EJECT DEFB DEFS DEFW DEFM DEFL GLOBAL EXTERNAL INCLUDE MACLIB ELSE .LALL .SALL .XALL :MACRO-80 In-Line Error Messages or use with SID or ZSID. :Invoking LIB-80 To invoke LIB-80, type -- LIB Command t LIB-8 consis o a optiona destinatio filenam whic set th nam o th librar bein created followe b a equa sign fol80 is invoked by typing -- L80 obj1:filename.ext/sw1,obj2:filename.ext/sw2,... wher objn:filename.ex denote .RE fil t b linke an sw denote switches which control the linking process. :LINK-80 Switches /R Re0 -- ASEG COMMON CSEG DB DC DS DSEG DW END ENTRY PUBLIC EQU EXT EXTRN NAME ORG PAGE SET SUBTTL TITLE .COMMENT .PRIn o th progra an dat area al define global an thei values an al undefine global followe b a asterisk. /S Search 'filename.REL' to satisfy references. / I filename/ wa specifi Se th Progra an Dat are origin fo th nex progra to be loaded. /U Lis th origi an en o th progra an dat are a wel as all undefined globals. /M Lis th origi an eA Argument Error O Bad opcode or objectionable syntax C Conditional nesting err P Phase error D Double Defined Symbol Q Questionable E External error R Relocation M Multiply Definedlowe b modul name separate b comma o filename wit modul name enclosed in angle brackets separated by commas. T selec give modul fro file us th nam o th fil followe b th module(s specifie enclose iset -- put loader back in initial state /E or /E:Name Exi LINK-8 an retur t CP/M Searc th syste librar fo an undefine references /E:Nam use Nam fo th star addres o the program. /G or /G:Name NTX .RADIX .REQUEST .Z80 .8080 IF IFT IFE IFF IF1 IF2 IFDEF IFNDEF IFB IFNB ENDIF .LIST .XLIST .CREF .XCREF REPT ENDM MACRO IRP ed / wil caus th fil t b saved in Intel HEX format with a extension of .HEX. / I filename/ wa specified / wil creat filename.SY fil whe / i entered Thi fil contain th name an addresse o al globals fone conditional is unterminated Unterminated REPT/IRP/IRPC/MACRO -- at least one block is unterminated [xx] [No] Fatal error(s) [,xx warnings] -- the number of fatal errors and warnings :Invoking LINK-80 LINK- Symbol U Undefined symbol N Number error V Value error :MACRO-80 Console Error Messages No end statement encountered in input file -- no END statement Unterminated conditional -- at least /L List cross reference /C Create -- start LIB over /E Exit -- rename .LIB to .REL and exit /R Rename -- rename .LIB to .REL :Invoking CREF-80 CREF-80 is invoked by typing -- CREF80 listing=source wf BASIC ther ar mino difference betwee th two however an thes ar discusse i th fil under the Compiler Introduction. The MBASIC (Microsoft BASIC) Interpreter is invoked as follows -- MBASIC [][/F:<# at this point -- code -- PRINT ; got to check point 1 -- code -- EXIT ; should not have taken this path -- code -- PRINT ; got to check point I al cases these MACROs have no net affect on any register. DEBUG.MA i use b firs specifyin i a MACR Librar withi th user's program. This is accomplished by the statement -- MACLIB DEBUG.MAC a a assembltions String Functions I/O and Special Functions Interpreter Error Codes Introduction to the Microsoft BASIC Compiler Compiler Commands and Switches Compiler Error Messages :Introduction to the Microsoft BASIC Interpreter Thi HEL Fil i of REGS all registers on CON: Note Th afte siz indicate tha on mus ad t th indicate siz the number of characters specified in the parameter. Note Message specifie fo EXI an PRIN shoul noher 'listing i th nam o th fil 'listing.LST generate an 'source th nam o th fil 'source.CRF generate b MACRO-80 'listing i optional and i omitted th listin fil generate i name 'source.LST'. :Debugg 2 -- code -- EXIT ; normal exit -- code --  ; should not have taken this path -- code -- PRINT ; got to check pointy-languag instructio a th beginnin o hi program Thi statemen load th librar DEBUG.MA an make it MACRO availabl fo use. These MACROs are -- Name # Args Size (Bytes) Function Example ---- ------ --derive fro th "Microsof BASI Referenc Book" an i i divide int tw part -- on coverin th Interprete an th othe coverin th Compiler Thes program proces program writte i almos exactl th sam languag -- Microso contai restricte MACRO-80 symbols (such as !) or an error message will result. An example of the use of these MACROs follows -- MACLIB DEBUG.MAC -- code -- REGS ; print all register valuesing MACRO-80 Programs Using DEBUG.MAC DEBUG.MAà i packag o MACRO whic th use ma emplo t ai himsel i debuggin MACRO-8 programs Thi packag contain tw prin MACROs on registe displa MACRO an on exi MACROIntroduction to the Microsoft BASIC Interpreter Special Characters Variable Type Declaration Chars Commands Edit Mode Subcommands Program Statements (except I/O) PRINT USING Format Field Specifiers Input/Output Statements Operators Arithmetic Func boot CP/M PRINT 1 19+ Print a message on CON: PRINT PRINTC 1 17+ Print a char string on PRINTC <'M1',0DH> CON: REGS 0 241 Print the contents ---------- -------- ------- EXIT 0/1 275 or 263+ Print an exit message, EXIT print the contents of EXIT all registers, and warm files>][/M:] I Goto the end of the line and insert string Backspace over chars; in insert modne(s) on printer LOAD LOAD filename[,R] Load program; ,R means RUN MERGE MERGE filename Merge prog on disk with that in mem NAME NAME old AS new Change the name of a disk file NEW NEW Halts/resumes program output ^R Retypes the line currently being typed ^S Suspends program execution ^Q Resumes execution after ^S ^U,^X Deletes line being typed Ends every line being typed in Breaks a n WIDT WIDT [LPRINT ex Se ter o printe carriag width default is 80 (term) and 132 (prin) :Edit Mode Subcommands A Abort -- restore original line and restart Edit nCc Changes Exp set en o memor an Exp set amoun of stack space CONT CONT Continue program execution DELETE DELETE [[start][-[end]]] at file tha ma b ope a an on tim durin th executio o program Th defaul her i 3 Th /M:s after each line RENUM RENUM [[new][,[old][,inc]]] Renumber program lines RESET RESET Init CP/M; use after disklogical line into physical lines Deletes last char typed Escapes Edit Mode Subcommands . Current line for EDIT, RENUM, DELETE, LIST, LLIST commands &O,& Prefix for Octal Constant &H Prefix for Hex Constant : e n characters nD Delete n characters E End edit and save changes; don't type rest of line Hstr Delete rest of line and insert string Istr Insert string at current pos nKc Kill all chars up to the nth occurrance of c L Delete program lines EDIT EDIT line Edit a program line FILES FILES [filename] Directory LIST LIST [line[-[line]]] List program line(s) LLIST LLIST [line[-[line]]] List program li. :Special Characters ^A Enters Edit Mode on line being typed or last line typed ^C Interrupts program execution and returns to MBASIC ^G Rings at terminal ^H Deletes last char typed ^I Tab (every 8) ^O sk , save pro in ASCII and ,P protects file SYSTEM SYSTEM Return to CP/M TROFF TROFF Turn trace off TRON TRON Turn trace oloating point # Double Precision 17.8 digit floating point :Commands Command Syntax Function AUTO AUTO [line][,inc] Generate line numbers CLEA CLEA [,[exp1][,exp2] Clea progra variabl Separates statements typed on the same line ? Equivalent to PRINT statement :Variable Type Declaration Characters $ String 0 to 255 chars % Integer -32768 to 32767 ! Single Precision 7.1 digit fe, delete chars End edit and save changes :Program Statements (except I/O) Statement Syntax Function CALL CALL variable [(arg list)] Call assembly or FORTRAN routine CHAIN CHAIN [MERGE] filename [,[line exp 1 Use comma every three digits ^^^^ 0 4 Exponential format _ 0 1 Next character is literal String Specifiers Specifier Definition ! Single cction OPTION OPTION BASE n Min val for subscripts (n=0,1) BASE OUT OUT port,byte Output byte to port POKE POKE address,byte Memory put RANDOMIZE RANDOMIZE [exp] Reseed random nuadr for nth assembly routine DEFINT range(s) of letters Define default var type INTeger DEFSNG " " " " " " " Single DEFDBL " " " " " " " Double gits Chars Definition # 1 1 Numeric field . 0 1 Decimal point + 0 1 Print leading or trailing sign - 0 1 Trailing sign (- if neg, otherwise) <> 0 then ... else ... LET [LET] var=exp Assignment MID MID$(string,n[,m])=string Replac portio o strin wit string2; start at pos n for m chars NEXT NEXT var[,var][,ALL][,DELETE range]] Cal progra an pas variable t it MERG wit ASCI file allow overlays star a lin ex i given AL mean al variable wil b passe (otherwis COMMO only) DELETmt after error line RESUME line Return to specified line RETURN RETURN Return from subroutine STOP STOP Stop prog and print BREAK msg WAI WAI prot,mask[,select mber generator REM REM any text Remark -- comment RESTORE RESTORE [line] Reset DATA pointer RESUME RESUME or RESUME 0 Return from ON ERROR GOTO RESUME NEXT Return to st DEFSTR " " " " " " " String DIM DIM list of subscripted vars Allocate arrays END END Stop prog and close files ERASE ERASE var [,var ... ] Release space and var names** 2 2 Leading asterisk $ Floatin dolla sign place i fron o leading digit **$ 2 3 Asterisk fill and floating dollar sign , 1 ... ] End FOR ON ERROR ON ERROR GOTO line Error trap subroutine GOTO ON/GOSUB ON exp GOSUB line[,line] Computed GOSUB ON/GOTO ON exp GOTO line[,line] Computed GOTO Statement Syntax Fun allows deletion of an overlay before CHAIN is executed COMMON COMMON list of vars Pass vars to a CHAINed prog DEF DEF FNx[(arg list)]=exp Arith or String Function DEF USRn=address Define Paus unti inpu por [XO select AND mask <> 0 WHILE/ WHILE exp stmts ... WEND Execute stmts as long as exp is T WEND :PRINT USING Format Field Specifiers Numeric Specifiers Specifier Dine number Branch to specified line IF/GOTO IF exp GOTO line [ELSE stmt ... ] IF exp <> 0 then GOTO IF/THEN IF exp THEN stmt[:stmt] [ELSE stmt ... ] IF exp ERROR ERROR code Generate error code/message FOR FOR var=exp TO exp [STEP exp] FOR loop Statement Syntax Function GOSUB GOSUB line number Call BASIC subroutine GOTO GOTO liharacter // Character field; width=2+number of & Variable length field :Input/Output Statements Statement Syntax/Function CLOSE CLOSE [[#]f[,[#]f ... ]] Close disk filesCSNG(exp) Convert the expression to a single precision number EXP(exp) Raises the constant E to the power of the expression FIX(exp) Returns truncated integer of expression FRE(exp) Gives memory free space not used by MBASIC INT(disk string in a given field WRITE WRITE [list of exps] Output data to the terminal WRITE #f, list of exps Output data to a sequential file or a random field buffer :Operators Symbol Function = Assigno afte promp strin cause questio mar afte promp whil comm afte promp suppresse questio mark Statement Syntax/Function KILL KILL filename Delete a disk file LINE LINE INPUT [;] [promp0. AND 4. *,/ 11. OR 5. \ 12. XOR 6. MOD 13. IMP 7. +,- 14. EQV :Arithmetic Functions Function Action ABS(exp) Absol[USING format string;] exp [,exp ...] Write data to a disk file LPRINT [USING format string;] var [,var ...] Write data to a line printer PUT PUT [#] f [,record number] Write data from a random buffer t; if no arg, close all DATA DATA constant list List data for READ statement FIELD FIELD [#]f,n AS string var [,n AS string var ...] Define fields in random file buffer GET GET [#]f[,record number] Reaeger modulus (integer result) NOT One's complement (integer) AND Bitwise AND (integer) OR Bitwise OR (integer) XOR Bitwise exclusive OR (integer) EQV Bitwise equivalence (integer) IMP Bitwise implication (integer)ment or equality test - Negation or subtraction + Addition or string concatenation * Multiplication / Division (floating point result) ^ Exponentiation \ Integer division (integer result) MOD Intt string;] string var INPU Rea a entir lin fro terminal leadin semicolo suppresse echo of / LINE INPUT #f,string var Read an entire line from a disk file LSET LSET field var=string exp ute value of expression ATN(exp) Arctangent of expression (in radians) CDBL(exp) Convert the expression to a double precision number CINT(exp) Convert the expression to an integer COS(exp) Cosine of the expression (in radians) o a data file READ READ var [,var ...] Read data from a DATA statement into the specified vars RSET RSET field var = string exp Stor dat i rando fil buffe righ justifie o righ justify a non-d a record from a random disk file INPUT INPUT [;] [prompt string;] var [,var ...] INPUT [;] [prompt string,] var [,var ...] Rea dat fro th terminal leadin semicolo suppresse ech o /,<, Relational tests (TRUE=-1, FALSE=0) <=,=<, >=,=>, <> The precedence of operators is -- 1. Expressions in parentheses 8. Relational Operators 2. Exponentiation 9. NOT 3. Negation (Unary -) 1 O = sequential output file R = random input/output file Statement Syntax/Function PRINT PRINT [USING format string;] exp [,exp ...] Print data at the terminal using the format specified PRINT #f, Stor dat i rando fil buffe left-justifie o left-justif a non-disk string in a given field OPEN OPEN mode,[#] f,filename Open a disk file; mode must be one of -- I = sequential input file exp) Evaluates the expression for the largest integer LOG(exp) Gives the natural log of the expression RND[(exp)] Generates a random number exp <0 seeds new sequence exp =0 returns previous number f data 17 Can't continue 5 Illegal function call 18 Undefined user function 6 Overflow 19 No RESUME 7 Out of memory 20 RESUME without error 8 Undefined line sion number CVD(str) Converts an 8-char string to a double precision number EOF(f) Returns TRUE (-1) if file is positioned at its end ERL Error Line Number ERR Error Code Number INP(port) Inputs a byte from a Returns remaining memory free space HEX$(exp) Converts a number to a hexadecimal string INPUT$(length [,[#]f]) Return strin o lengt char rea fro consol o fro disk file; characters are not echoed INage subroutine with the arg VARPTR(var Return addres o va i memor o zer i va ha no bee assigned a value VARPTR(#f Return th addres o th dis I/ buffe assigne t fil number :Interpreter ength,str) Return strin lengt lon containin th firs cha o the str STRING$(length,exp) Return strin lengt lon containin char wit numeri value exp VAL(str Co exp >0 or omitted returns new random number Function Action SGN(exp) 1 if exp >0 0 if exp =0 -1 if exp <0 SIN(exp) Sine of the expression (in radians) SQR(exp) Square root of e an integer to a 2-char string MKS$(value) Converts a single precision values to a 4-char string MKD$(value) Converts a double precision value to an 8-char string Function Action PEEK(exp) Reads a byte from memory location specin input port LOC(f Return nex recor numbe t rea o writ (rando file o number of sectors read or written (sequential file) LPOS(n) Returns carriage position of line printer (n is dummy) MKI$(value) ConvertsSTR([exp,]str1,str2) Return th firs positio o th firs occurrenc o str in str1 starting at position exp LEFT$(str,len) Returns leftmost length chars of the string expression LEN(str) Returns the length ofError Codes Code Error Code Error 1 NEXT without FOR 14 Out of string space 2 Syntax error 15 String too long 3 RETURN without GOSUB 16 String formula too complex 4 Out onvert th strin representatio o numbe t it numeric value :I/O and Special Functions Function Action CVI(str) Converts a 2-char string to an integer CVS(str) Converts a 4-char string to a single precixpression TAN(exp) Tangent of the expression (in radians) :String Functions Function Action ASC(str) Returns ASCII value of first char in string CHR$(exp) Returns a 1-char string whose char has ASCII code of exp FRE(str) fied by exp POS(n) Returns carriage position of terminal (n is dummy) SPC(exp) Used in PRINT statements to print spaces TAB(exp) Used in PRINT statements to tab to specified position USR[n](arg) Calls the user's machine languexp) Converts an expression to an Octal string RIGHT$(str,len) Returns rightmost length chars of the string expression SPACE$(exp) Returns a string of exp spaces STR$(exp) Converts a numeric expression to a string STRING$(l a string MID$(string,start[,length]) Return char fro th middl o th strin startin a th positio specifie t th en o th strin o fo lengt characters Function Action OCT$( 21 Unprintable error 9 Subscript out of range 22 Missing operand 10 Redimensioned array 23 Line buffer overflow 11 Division by zero 26 FOR without NEXT 12 Illegal direct 29 WHILE withou Rela lin numberin constraints line nee no b numbere sequentially; /4 and /C may not be used together /Z Use Z80 opcodes :BASIC Compiler Error Messages Compile-Time Fatal Errors SN Syntax error OM Ou 67 Too many files :Introduction to the Microsoft BASIC Compiler Th followin direc mod command ar NO implemente o th compile and will generate an error message -- AUTO CLEAR CLOAD CSAVE C mode 5 Illegal function call 55 File already open 6 Floating/Integer ovfl 57 Disk I/O error 9 Subscript out of range 58 File already exists 11 Division by zero 61 Disk full 14 Out of strth use wil b prompte wit a asterisk after which he should enter the command line. Switches -- /E Use this switch if ON ERROR GOTO with RESUME is used / Us thi switc i O ERRO GOT wit RESUME RESUM 0 o RESUMt WEND 13 Type mismatch 30 WEND without WHILE Disk Errors -- Code Error Code Error 50 Field overflow 58 File already exists 51 Internal error 61 Disk full 52 B Array already dim'ed FN FOR/NEXT error FD Function already def UF Function not defined WE WHILE/WEND error /E Missing /E switch /X Missing /X switch Compile-Time Warning Errorst of memory SQ Sequence error TM Type mismatch TC Too complex BS Bad subscript LL Line too long UC Unrecognizable command OV Math overflow /0 Division by zero DD ONT DELETE EDIT LIST LLIST RENUM COMMON SAVE LOAD MERGE NEW ERASE Th followin statement ar use differentl wit th compile tha with the interpreter (refer to theing space 62 Input past end 20 RESUME without error 63 Bad record number 21 Unprintable error 64 Bad filename 50 Field overflow 67 Too many files 51 Internal error  NEX is used /N Do not list generated object code /D Generate debug/checking code at runtime /S Write quoted strings of more than 4 chars as they are encountered /4 Recognize Microsoft 4.51 BASIC Interpreter conventions /à ad file number 62 Input past end 53 File not found 63 Bad record number 54 Bad file mode 64 Bad file name 55 File already open 66 Direct statement in file 57 Disk I/O error ND Array not dimensioned SI Statement ignored Run-Time Error Messages 2 Syntax error 52 Bad file number 3 RETURN without GOSUB 53 File not found 4 Out of data 54 Bad file compiler is invoked by the BASCOM command; it may be called by -- BASCOM or BASCOM command line where "command line" is -- [dev:][obj file][,[dev:][lst file]]=[dev:]source file[/switch ...] I jus BASCO i used manual for details) -- CALL DEFINT DEFSNG DEFDBL DEFSTR DIM ERASE END ON ERROR GOTO RESUME STOP TRON TROFF USRn :BASIC Compiler Commands and Switches TheCompiler Operation Invoking Pascal Compilation Switches File Input/Output Special Functions and Procedures Pascal/MT Symbolic Debugger Pascal/MT Reserved Words Notes :Compiler Operation Th Pascal/M compile exist i tw versions eac c CREATE(fcbname,title,result); DELETE(fcbname); BLOCKREAD(fcbname,buffer,result{,relativeblock}); BLOCKWRITE(fcbname,buffer,result{,relativeblock}); where fcbname : a variable of type TEXT (array 0..32 of CHAR) o specia comments Th for o thes comment is (*$o info*) or {$o info} wher 'o i th lette o th optio an 'info i informatio particular to that option. These options are -- $I Include .SRC into source stream $L+ or $L- Turn listing on (default) or Turn listing off $P Insert form feed into .PRN file $D+ or $D- Turn debug code on (default) or Turn debug code off $C+ mus hav th extensio '.SRC o '.PAS indicatin tha i i sourc progra file Ther mus b carriag return/lin fee sequenc a th en o eac inpu lin an a inpu lin ma no b longe tha 8 characters. :Invoking Pascal list device (like, WRITE(PRINTER,'Hello')). The following extensions are implemented to handle files -- OPEN(fcbname,title,result{,extent_number}); (extent_number defaults to 0) CLOSE(fcbname,result); th BC versio o th compiler th command ar similar except that 'PASCAL' is replaced by 'BCDCOMP'. :Compilation Switches Compile-tim option ma b specifie t th compile fro withi th sourc file Suc option tak th for sio i whic REA number ar implemente a BCĠ value internally Thes file ar Pas an Pas o th Pascal/M compiler respectively Als require b th compile ar th followin file -- P1ERRORS.TXT - Pass 1 Error M Set run-time size to $cc 256-byte pages $X $dddd Set run-time stack space to $dddd (default $200) $S+ or $S- Turn recursion or or Turn recursion off (default) $Q+ or $Q- Enable verbose output (default) ot b compiled i o Π t indicat whethe t includ th debugge i th resultan .CO͠ file an ̠ i o t indicat whethe t produc .PRΠ fil (listing) PASCA default t n debugge an n listing Th fou invocatio opt Th Pascal/MԠ compile i invoke o ARIES- b usin th followin comman -- PASCAL filename.DL wher 'filename i th nam o th fil wit th extensio '.SRC o '.PAS containin th Pascal/M sourc statement title : ARRAY [0..11] of CHAR with title[0]=dis렠 selec byt (0=logge i disk 1=A,...) title[1..8]=filename and title[9..11]=filetype result : integer to contain retuENABLE MOVE RECORD VAR BEGIN END NIL REPEAT WAIT BLOCKREAD EXIT NOT RIM85 WHILE BLOCKWRITE EXTERNAL ODD ROUND WRITE Execute one or more lines of the program. Debugger Command: E - Procedure/Function Display Toggle Syntax: {-}E Š engage displa o th name o procedures/function entered - disengage it. Debugger Command: S -#bits):16-bit-result; {Shift Left} FUNC LO(16-bit-var):16-bit-result; FUNC HI(16-bit-var):16-bit-result; FUNC SWAP(16-bit-var):16-bit-result; FUNC ADDR(variable reference):16-bit result; PROC WAIT(port Debugger Commands: +,-,* - Variable Display Syntax: * -- display last value requested (using D or some other) +n -- display variable n bytes forward from last -n -- display variable n bytes backward from last :Pail displa th nam o eac procedure/functio o th consol a th procedur o function is entered. These commands are discussed briefly on the following displays -- Debugger Command: G - Go with optional breakpoint Syntax: rned value buffer : ARRAY [0..127] of CHAR relativeblock : optional integer 0..255 :Special Functions and Procedures Pascal/MT supports the following special routines -- PROC MOVE(source,dest,length-in-bytes); (* Clears breakpoint *) P P P sets the permanent breakpoint; -P clears it. Debugger Command: B - Display Permanent Breakpoint Syntax: B Displays line the permanent Set/Clear Slow Execution Mode Syntax: {-}S Ӡ allow th use t selec Fast Medium o Slo executio speed; -S causes the program to run at full speed. Debugger Command: P - Set/Clear Permanent Breakpoint Syntax: -Pnum:constant; mask:constant; polarity:boolean); FUNC SIZEOF(variable or type name):integer; Please refer to pp 32-33 of "Pascal/MT 3.0 Guide" for further info. :Pascal/MT Symbolic Debugger Th debuggin facilitie availabl t tscal/MT Reserved Words ABS DO LO READ TSTBIT ADDR DOWNTO MAXINT READLN TYPE AND ELSE MOD REAL UNTIL ARRAY G{,} G{,} G resume executio wher th progra las stopped Breakpoin may be optionally set at a specific line or function/procedure. Debugger Command: T - Trace Syntax: T{} PROC EXIT; FUNC TSTBIT(16-bit-var,bit#):BOOLEAN; PROC SETBIT(VAR 16-bit-var,bit#); PROC CLRBIT(VAR 16-bit-var,bit#); FUNC SHR(16-bit-var,#bits):16-bit-result; {Shift Right} FUNC SHL(16-bit-var,breakpoint is set for. Debugger Command: D - Variable Display Syntax: D D : D D ^ The D command is used as indicated. command provide i th symboli debugge allo th use t debu th Pascal/M progra a th Pasca sourc statemen level Include ar go/continu (wit optiona breakpoint) trace set/clear/displa permanen breakpoin an mod whic wh use whe usin th debugge fal int tw catagorie -- progra flo contro an variabl display. I th use wishe t se th command durin th executio o the debugger, type a '?' followed by a return. Th progra flo BOOLEAN FALSE OF SETBIT WRITELN CASE FILE OPEN SHL CHAIN FOR OR SHR CHAR FUNCTION ORD SIM85 CHR .... NAME OF PROGRAM, PROCEDURE, OR MODULE (CIRCLE ONE) SOURCE LANGUAGE ...........SYSTEM REQUIRED ....... MEMORY REQUIRED .........OTHER ................... DESCRIPTION OF WHAT IT DOES: HOW TO USE IT: PLEASE A 2 Al standar Pasca typ definition excep ARRA ar supported Th堠 standar䠠 for ARRAY...OƠ ARRAY.. mus b堠 specifie䠠 a ARRAY[...,...,...], and a maximum of three dimensions may be used. 3. Type TEXT is ARRAY [0..35........ DATE.................................. SIG/M USER GROUP C/O AMATEUR COMPUTER GROUP OF NEW JERSEY UCTI 1776 RARITAN ROAD SCOTCH PLAINS, NJ 07076  GOTO OUTPUT SIZEOF CLOSE HI PACKED SQR CLRBIT IF PRED SQRT CONST INLINE PRINTER SUCC CREATE INPUT PROCEDURE .BAS, .Z80, .FOR, .COB, ETC .DOC .DOCUMENTATION .COM .OBJECT CODE THE SUBMITTED FILES ARE IN THEIR PRESENT REVISION LEVEL, .... TO THE BEST OF MY KNOWLEDGE CURRENTLY IN PUBLIC DOMAIN .... UNDER MYTTACH ALL RELEVANT DOCUMENTATION AND A DISKETTE CONTAINING THE SOURCE, ASSEMBLY/COMPILATION/LINKAGE COMMAND FILES, OBJECT CODE, AND ANY OTHER MACHINE READABLE DOCUMENTATION. PLEASE USE THE FOLLOWING FILE EXTENSIONS: .ASM .SOURCE FILE OR] OF CHAR. 4 Interrup Procedures declare a "PROCEDUR INTERRUPT[i proc;" are supported, where i is the restart vector number (0..7). 5 CP/͠ V rando fil acces i supporte b RANDOMREAĠ an RANDOMWRITE. 6 Mach CONTRIBUTION FORM FOR SIG/M LIBRARY NAME ...........................DATE..../..../.... ADDRESS .......................................... CITY .......................STATE .....ZIP ....... PHONE .....................AFFILIATION ....... SWAP DELETE INTEGER PROGRAM THEN DISABLE INTERRUPT RANDOMREAD TO DIV LABEL RANDOMWRITE TRUE :Notes 1. Hexadecimal values may be specified as $hhhh, like $1A = 1AH. DIRECT CONTROL HEREBY PLACED INTO PUBLIC DOMAIN. PERMISSION IS HEREBY GRANTED TO SIG/M TO DISTRIBUTE THE FILES FREELY FOR NON-COMMERCIAL PERSONAL USE. SIGNED........................43). e"). 7. Chaining is supported by CHAIN, whose usage is "CHAIN(filename)". 8. Redirected