operatlng system command summary ...planemo.org/retro/downloads/z100/manuals/cpm86/cpm-86...command...

27
CP/M-86® OPERATlNG SYSTEM COMMAND SUMMARY Copyright © 1982 Digital Research P.O. Box 579 160 Central Avenue Pacific Grove, CA 93950 TWX 910 360 5001 (408) 649-3896 All Rights Reserved

Upload: vonhan

Post on 09-Mar-2018

222 views

Category:

Documents


4 download

TRANSCRIPT

Page 1: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86®OPERATlNG SYSTEM

COMMAND SUMMARY

Copyright © 1982

Digital ResearchP.O. Box 579

160 Central AvenuePacific Grove, CA 93950

TWX 910 360 5001(408) 649-3896

All Rights Reserved

Page 2: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

TABLE OF CONTENTS

Copyright © 1982 by Digital Research. Allrights reserved. No part of this publicationmay be reproduced, transmitted, transcribed,stored in a retrieval system, or translatedinto any language or computer language, in anyform or by any means, electronic, mechanical,magnetic, optical, chemical, manual orotherwise, without the prior written permissionof Digital Research, Post Office Box 579,Pacific Grove, California, 93950.

DISCLAIMER

COPYRIGHT

E

How to enter a CP/N-86 Command . . . . . 1

CP/N-86 File Specifications .. . . . . . 1

Command Summary Conventions .

ASN86

COPYDISK . . . . .. . . . . . . . . . •

DDT86

DIR • • • • • • • • •• • • • •

DIRS , . •

D • • • • • • • • •• • • • •

ERA 12Digital Research makes no representations orwarranties with respect to the contents hereofand specifically disclaims any impliedwarranties of merchantability or fitness forany particular purpose. Further, DigitalResearch reserves the right to revise thispublication and to make changes from time totime in the content hereof without obligationof Digital Research to notify any person ofsuch revision or changes.

GENCND

HELP

PIP • • • • • • •• • • • • • •

REN • • • • • • •• • • • • • •

STAT

SUBNIT

TOD • • • • • •• • • • • • • •

TYPETRADEMARKS

• • • • • • • • • • •

• • • • • • 20

21

14

15

17

18

13

22CP/M and CP/M-86 are registered trademarks ofDigital Research. ASN-86, CBASIC-86, CP/M-80,and DDT-86 are trademarks of Digital Research.Intel is a registered trademark of IntelCorporation.

USER

CP/N-86 Control Character Summary .

CP/N-86 Filetypes .

CP/N-86 Nessages

CP/N-86 BDOS Function Summary .

CP/N-86 File Control Block . • . . . . • 47

CP/N-86 Base Page Values

26

24

25

23

The CP M-86 0 eratin S stem Command Summarwas prepared using the Dzgxtal Research TEXText Formatter and printed in the United Statesof America by Commercial Press/Monterey.

k*k*k* * k k kkkkkkk* * k k kkk* * k k kk*

First Revision: Nay 1982 *First Printing: Nay 1982

* kk* k * k k k k k k k k k k k k k k k k k k k * k* kk

111

Page 3: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary

HOW TO ENTER A CP/M-86 COMMAND

To give CP/N-86e a command, you must typea complete command line following theCP/N-86 system prompt. A CP/N-86 commandline is composed of a command, an optionalcosland tail, and a carriage return. Thecommand identifies a command (program) tobe executed. The optional command tailcan consist of a drive specification, oneor more file specifications, and someoptions or parameters, To complete thecommand, you must press the carriagereturn key.

CP/M-86 FILE SPECIFICATIONS

CP/N-86 identi f i e s e v ery f i l e by i t sunique f i l e spe c i f i c a t i o n . A f i l especification can have three parts: adrive specif icat ion, a pr imary f i l ename,and a filetype, all separated by theirappropriate de'imiters. A drive lettermust be followed by a colon. A fi letypemust be preceded by a period. The termfi l espec i s a n a b brevia t ion fo r f i l especif icat ion, and i ndicates any val i dcombination of the d r ive speci f i cat ion,the filename and the filetype. Thissummary uses the following symbols todesignate the parts of a filespec.

d: represents the optional drivespecification, which can be asingle alphabetical characteri n t h e r a nge A t hr o ugh Pfollowed by a colon.

filename represents the required primaryfilename, which can be 1 to 8alphabetic or numericcharacters.

represents the optionalfiletype, which can be 0 to 3alphabetic or numericcharacters separated from theprimary filename by a period.

Valid combinations of the elements of afilespec are shown below:

• filename• d:filename• filename.typ• d:filename.typ

Page 4: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/N-86 Command Summary

Certain CP/N-86 commands can select andprocess several files when wildcardcharacters are included in the primaryfilename or filetype. The two wildcardcharacters are ?, which matches any singleletter in the same position, and *, whichmatches any character at that position andany other characters remaining in thefilename or filetype. The command summaryindicates which commands can acceptwildcard characters (» or ?) in a f i l enameor filetype.

Syntax:

ASM86

A - source file drived - logical drives A-P

H - hex fi le d r i v e .H86d - logical drives A-P, X,Y,2

P - print file drive .LSTd - logical drives A-P, X,Y,2

S - symbol file drive .SYNd - logical dr i ves A-P, X,Y,2

F - format of hex file .H86 ®d - D Digital Research, I=Intel®

COMMAND SUMMARY CONVENTIONS

ASN86 filespec ($Ad Hd Pd Sd Fdj

.A86

The command summary lists each CP/N-86command in alphabetical order using thefollowing special symbols to definecommand syntax:

SymbolPurpose:

Neaning

0 RW

R0SYSDIR

n<cr>

indicate an optional item.separates choices.indicates a number.indicates a carriage returnkeystroke.indicates a control keystroke.indicates an option or option list.means Read Write.means Read Only.means System attribute,means Directory attribute.preceding element can be repeatedas many times as desired.wildcard- replaces all or part ofa filename and/or filetype.wildcard- replaces any singlecharacter in the same positionof a filename or filetype,

Bxamples:

Assembles assembly language statements,producing an object file in hexadecimalformat, a print file, and a symbol tablefile. The assumed filetype of source andincluded files is A86. The specialcharacters X, Y, and 2 indicate output tothe console, output to the printer, andzero output respectively. If no format isspecified, Digital Research format (FD) isassumed.

A>ASN86 PR0GA>ASN86 PR0G $S2 PXA>ASN86 PROG $HB PY AC

Page 5: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/N-86 Command Summary

DDT86COPYDISK

Syntax sSyntax s

DDT86{filespecjCOPYDISK

PurposesPurpose:

Aids debugging of 8086 and 8088 programs.Assumes filetype of CMD if only a filenameis specified. Use GENCND to converthexadecimal (H86) files to command (CND)files before using DDT-86™.

Copies all information on one disk toanother disk, including the CP/M-86 systemtracks if they are present on the sourcedisk. COPYDISK prompts you for the sourceand destination drives.

Examples Examples:

A>DDT86A>DDT86 PROGRAN1A>DDT86 PROGRAN2.CNDA>DDT86 BsPROGRAN3.CND

A>COPYDISK

DDT-86 Camand Sugary

The command character can be followed byone or more arguments, which can behexadecimal values, file specifications,or other information, depending on thecommand. Arguments are separated fromeach other by commas or spaces. No spacesare allowed between the command characterand the first argument.

Action

As (Assemble)

Command

Enter Assembly Language Statements

Bs,f,sl (Block Compare)Compare Blocks of Memory

D{W)(s(,f)) (Dis p lay)Display Memory in Hex and ASCII

Efilespec (Execution)Load Program for Execution

ts,f,bc (Fill )Pill Memory Block - Byte

tNs,f,wc (Pi l l )

G{sj(,bl(,b2I j (Go)Begin Execution

Fill Memory Block - Word

Page 6: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command SummaryCP/M-86 Command Summary

DIRDDT-86 Camand Sugary (continued)

Command Action

Hwcl,wc2 (Hex) Syntax'Hexadecimal Sum and Difference

DIR (filespec}Icommamd tail (Input)

L(s( f }} (Li st )

Set Up Input Command Line

Purpose:

List Memory in Mnemonic Form Displays the names of nonsystem (DIR)files in the directory of an on-line disk.Accepts wildcards in the filename andfiletype.

Ns,f,d (Move)Move Memory Block

Rfilespec (Read)

S{W}s (Set)Set Memory Values

T(n} (Trace)

TS(n} ( Trace)

V(n} (Untrace)

VS(n} (Unt rac e )

Trace Program Execution

Read Disk File to Memory

Trace and Show All Registers

Examples:

A>DIRA>DIR B:A>DIR C:NYFILE.DATA>DIR e,CNDA>DIR Ae.A86A>DIR PRDG?2?.H86A>DIR PROGRAM.e

Monitor Execution without Trace

Monitor and Show All Registers

(Verify)

Wfilespec{,s,f} (Write)

X(r} (Examine)

Show Memory Layout after Disk Read

Write Content of Block to Disk

Examine and Modify CPU Registers

d f

n

Symbol

bcblb2

Meaning

byte constantbreakpoint onebreakpoint twodestination for datafinal addressnumber of instructionsto executeregister or flag namestarting addresssecond starting addressword 16-bitword constant

rsslWwc

Page 7: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/N-86 Command Summary

EDDIRS

Syntax:Syntax~

DIRS (filespec)BD input-filespec(d:~output-filespec)

Purpose:Purpose:

Displays the names of system (SYS) filesin the directory of an on-line disk.Accepts wildcards in the filename andfiletype.

Bdits source program or text files.Redirect or rename the new version of thefile by specifying the destination driveor destination filespec.

Bxamples:

A>DIRSA>DIRS B:A>DIES C:NYPILE.CNDA>DIRS *.CNDA>DIN Ae.CNDA>DIN PRDG?2?.CNDA>DIES PRDGRM.*

Examples:

A>BD TEST.MTA>BD TEST.MT B:A>BD TEST.MT TEST2.MTA>BD TEST.MT Bi TBST2.MT

BD Cmaand Summary

Command Action

append n lines from originalfile to memory buffer

OAappend file until buffer isone half full

append file until buffer isfull or come to end of file

B( -B move CP to the beginning (B)

or bottom (-B) of buffer

nCg nCmove CP n characters forward(C) or back (-C) through buffer

nD, -nDdelete n characters before (-D)or from (D) the CP

save new file and return toCP/M-86

tstring('f5)find character string

Page 8: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/M-86 Command Summary

BD Cmaand Sugary (continued)BD Command Sugary (continued)

Command Command

nT, -nT, OT

ActionAction

type n linessave the new file, then reedit,using the new file as theoriginal file U) -U upper-case translation

Vg -V, OV

insert string at CP

enter insert mode;use f8 to exit insert mode

lstring(fa)

Jsearch strfsins strfsdkl to str(fX)write n lines to new file

line numbering on/off, displayfree buffer space

juxtapose strings

nK, -nKwrite n lines to X$$$$$$$.LIB

nZf ilespec( f X)delete (kill) n lines from the CPwrite n lines to filespec

nL, -nL, OLOXmove CP n lines

nNcmmandsdelete file X$$$$$$$.LIB

OXf ilespec( f 8)delete filespec

execute commands n times

n, -n move CP n lines and display

that line wait n seconds

n:move to line n Note: CP refers to the character pointer.

VP points to the current character beingreferenced in the edit buffer.:naaaand

execute command through line n

Nstring(fS)extended find string

return to original file

nP, -nPmove CP 23 lines forward anddisplay 23 lines at console

abandon new file, return toCP/M-86

read X$$$$$$$.LIB file intobuffer

Rfilespec()S)

Sdelete stringfKinsert string(fS)

read filespec into buffer

substitute string

1110

Page 9: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/N-86 Command Summary

GENCMD

Syntax: Syntax~

ERA filespec GENCND filespec(8080

Purpose:

CODE[An,Bn,Nn,Xn]DATA[An,Bn,Mn,Xn]

STACK[An,Bn,Nn,Xn]EXTRA[An,Bn,Mn,XnJ)Erases a file or group of files. Accepts

wildcards in the filename and filetype.

Bxamplesiin .886 file

A - Absolute memory locationB - Beginning address of group

N - Minimum memory requiredX - Maximum memory required

A>BRA DRAPT,BARA>BRA $!LSTTM.MTA>ma C:LRT%m.eA>ERA D>e.BARA>BRA Bte,e

Purpose:

Converts hexadecimal object file (filetypeassumed to be .886) into executable file(of type .CND). Switches controlling thetype of memory model and group addressescan be included. All addresses areparagraph addresses, All values must bein hexadecimal.

Examplesi

A>GBNCND PRDGB>GBNCND PROG1 8080B>GBNCND PNG2 DATA[N20]A>MICND PRDG3 MTA [B4CiN260,XPPP]A>GBNCND PRDG4 CODB[h40] MTA[N30]

12 13

Page 10: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/M-86 Command Summary

PIPMELP

Syntax:Syntax<

HELP(topic)(,subtopic) ...( [P] i Destination Source

Purpose:PIP d: ([Gn]jIf i leypec([Gn]=filespec([o]jPIP filespec[[Gn]) d:I[Gn] IPIP (d:ifilename(.typI*filespecl filespec2(,...iPIP filespec( [Gn] I I dev: filespecI [o] i I dev: I [o] )Supplies information on hoW to use CPM-86

ommands. HBLP with no command tail liststhe available topics. HELP with a list oftopics and subtopics displays informationabout that command on your screen. HELPallows up to 8 levels of subtopics. Whenthe P option is used, the HELP displaydoes not pause every 23 lines.

Purpose:

Copies files, combines files, andtransfers files between disks andperipheral devices. The first filespec isthe destination. The second filespec isthe source. The source or destination canbe any CP/M-86 logical device. PIP withno command tail displays an * prompt andawaits your series of commands, enteredand executed one line at a time. Sourcefilespecs with options can be repeated,separated by commas, to combine two ormore files into one file. The [o] is anycombination of the available options. The[Gn] option in the destination designatesUSER number n.

Bxamples:

A>BBLPA>BBLP dirA>BBLP stat options [P]HELP>help

Bxamples:

Co from one disk to another:

A>PIP B:~htDRAPT.TXTA>PIP B:DRAPT.TZ1+h:A>PIP B:[GS]~NBNDRAPT.TXTA>PIP NBNDRAPT.TXT B:[G5]

Co a file and rename it:

A>PIP B:NBNDRAPT.~ h r OLDDRAPT. TXTA>PIP NBNDRAPT. TXT&LDDRAPT. TXT

C o mult i l e f i l e s :

A>PIP <cr>A>PIP B:~e.TXT[V]A>PIP B:~+.CMD[R]A>PIP B:K:DRAPT.e[N]A>PIP B:~e.>A>PIP B:K:~.~

Combine multi le files:

A>PIP B:NBN.DAT PILEl.DAT,FILB2.DAT

1514

Page 11: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/N-86 Command Summary

RENPIP (continued)

Co rename and lace in user 1:

A>PIP NENDRAtT. TXT [Gl] &LDDRAtT. TXT Syntax:

REN(d:)newname(.typj~oldname(.typjCo rename and et from user 1:

A >PIP NENDRAPT. TXPOLDDRAPT. TXT [Gl] Puf poses

Changes the name of the existing filespecified by oldname to the name specifiedby newname. You cannot specify twodifferent drives.

Co to from 1 ical devices:

A>PIP BstONtILE.NEKXSsA>PIP LSTs~sA>PIP LST s os DRAtT. TIT [TS]A>PIP PRNs~BsDRAtT.TXT Examples:

A>REN NENtILE. M~LDFILE. MTA>REN BsNENtILB.M~LDFILB.MTA>REN BsNENLI~LDLIST

Options:

Option Description

Gn

Pngsfs

case.

Delete any characters pastcolumn n.Echo transfer to console.Filter form-feeds from sourcedata.Get from or go to user code n.(default n current user num.)Test for valid Hex format.Ignore :00 Hex data recordsand test for valid Hexformat.Kill display of filenames onconsole.Translate upper-case to lower­

Number output linesObject file transfer; f8ignored.Insert form-feeds every n lines.guit copying from source atstring s.Read files that have beenset to SYStem.Start copying from thesource at the string s.Expand tabs to n spaces.Translate lower-case toupper-case.Verify that data has beenwritten correctly.Write over Read Only fileswithout console query.lero the parity bit .

SsfX

All options except G,K,O,R,V, and W forcean ASCII file transfer (character bycharacter, terminated by a f2).

16 17

Page 12: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/M-86 Command Summary

STAT STAT (continued)

Syntax:

STATSTAT d:s'ROsTAT

Ill~specIR0

[Rw)RYRQDYR/RYRR)

Examples:

A>STATA>STATA>STATA>STATA>STATA>STATA>STATA>STAT

B: WARDmyf ile. txtC:letter .egenledgr.dat RO,SYS'.cmd ROe.bakBc% *

STAT logical device: physical device:

Purpose:

Supplies information about the diskdr ives, files, and peripheral devicesattached to the computer. STAT alsochanges attributes of files and devices.STAT with no command tail returns theamount of free storage space in kilobytes(1024 bytes or 1K) for all logged-in diskssince CP/M-86 was started or reloaded. Italso indicates whether the drive is set toRead Only (RO) or Read Write (RW) . Drivesare in a RW state by default, and becomeRO when you change a disk and do not entera fC. Use STAT to set the drive to RO andfC to set it to RW. STAT with a filespecified in the command tail returns thenumber of kilobytes used by that file.STAT with a filespec can also set a fileor group of files to RO, RW, SYS, or DIR.STAT DSK: shows the characteristics of thedefault or specified drive. STAT USR:shows which user numbers contain files ona g iven d i sk . ST A T VAL: shows thepossible external devices that can beassigned to your computer. STAT acceptswildcards in the command tail.

Note that STAT accepts a dollar sign $,square bracket [, or no delimiter beforethe RO, RW, SYS, DIR, and SIKE settings.

Options:

RWROSYSDIRSIKE

VAL:USR:

DSK:

Read WriteRead OnlySystem attributeNO System attributeShow the size of thefile or filesShows possible devicesShows USER numberscontaining filesShows characteristicsof the default driveShows current physical tological device assignments

DN:

18 19

Page 13: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/N-86 Command Summary

TODSLIBMIT

Syntax s Syntax s

TODImm/dd/yy hh:mm:ss ~ PjSUBNIT filespec{actual parameters)

Purposes purposes

Submits a batch process consisting of afile of CP/N-86 commands (one command perline in file). The SUBNIT file must havea filetype of SUB. Any optionalparameters (for example a drive or filespecification) following the filespecification in the command line aresubstituted for their corresponding formalparameters ($1,$2,$3...) in the file oftype SUB.

Examples s

Display or set the date and time. TODwith no command tail displays the systemdate and time. Time is represented as atwenty-four hour clock, with hour valuesfrom 00 to 11 for the morning, and 12 to23 for the afternoon and evening. TODwith the P option displays the date andtime continuously, until you press anykey, TOD sets the date and time to thatwhich is specified in the command tail.When you start CP/N-86, these values areinitially set to zero. Use TOD to set thecurrent date and time. Supply a two-digitrepresentation of the month, day, and yearfor mm, dd, and yy respectively. Supply atwo-digit representation of the hours,minutes, and seconds for hh, mm, and ssrespectively. When the time specifiedcorresponds to the correct time, strike akey, and TOD seta the current date andtime.

A>SUBNIT STARTA>SUBNIT B: STARTA>SUBMIT START Cs LETTER

A>TODA>TOD PA>TOD 01/ll/81 11:00!00

2120

Page 14: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command Summary CP/M-86 Command Summary

USER

Syntax: Syntax r

USER nn • 0-15

TYPE filespec

Purpose:Purpose~

Displays contents of an ASCII file on thescreen. Press any key to discontinue thedisplay. TYPE does not accept wildcardfilespecs. Entering atP prior to thetype command causes the output to beechoed to the printer until you enteranother tP.

Displays and changes the current usernumber. USER with no command taildisplays the current user number. USERwith a number from 0 to 15 changes thecurrent user number to the numberspecified by n. CP/M-86 assumes a defaultuser number of 0. Files set to SYStem onUSER 0 are available to all USER areas asRead Only.Bxamples:

A>TYPE letter.datB>TYPB ardocuaent. lawC>TYPE program.basD>TYPE program.a86

Bxamples:

A>USERB>USBR 2A>USER 7

22 23

Page 15: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command Summary CP/M-86 Command Summary

CP/M-86 CONTROL CHARACTER SUMMARY CP/M-86 FILETYPES

Keystroke

BACKSPACE moves cursor back one space;

fc

Action

erases previous character.

prompts to abort a programcurrently running at a givenconsole.

same as RUB •

forces a physical carriagereturn, bu t d oes not sendcommand to CP/M-86.

same ae BACKSPACE.

line-feed, terminates input atthe console.

same ae carriage return.

echoes all console activity atthe printert a secondfP endsprinter echo. This only worksif your system is connected toa printer.

retypes current command line~useful after using RUB or DELkey.

fafJ

fM

tp

CP/M-86 identifies every file by a uniquefile specification, which consists of adrive speci f i e r , a f i l e name,and afiletype. The filetype is an optionalthree character ending separated from thefilename by a period. The filetypegenerally indicates a special kind offile. The common filetypes and theirmeanings are listed below.

Piletype

A86

fR

RUB

RETURa car r i a ge return.

deletes character to the left ofcursor; e c hoes characterdeleted - cursor moves right.

stops console listingtemporarily~ fS resumee thel is t i ng.

cancels line, displays f, cursormoves down one line and awaitsa new command.

deletes all characters incommand line.

string or field separator.

Indication

a86

Assembly language source file;ASM-86™ , t he C P/ M- 8 6assembler, assembles ortranslates a file of type .A86into machine language.

Back-up file created by a texteditor; an editor renames thesource file with this filetypeto indicate that the originalfi le has been processed. Theoriginal file stays on the diskae the back-up file, so you canrefer to it.

CBASIC-86 ™ program sourcef i le .

Command file that containsinstructions in machineexecutable code.

8080 executable file.

Program file in hexadecimal

fz

SUB

format.

CBASIC-86 program intermediatelanguage file.

Printable file that can bed isplayed on a co n sole o rprinter.

Printable file that can bedisplayed on a co n sole o rprinter.

Filetype required for SUBMITinput file containing one ormore CP/M-86 commands. TheSUBMIT program executes thecommands in the file of typeSUB providing a batch mode forCP/M-86.

Symbol table file.

Temporary file created by PIP.$$$

24 25

Page 16: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/N-86 Command Summary

CP/N-86 Messages (continued)

CP/M-86 MESSACiESBDOS err on d: file R/0

Message

Ambiguous operand

MeaningAn erase, rename, or set fileattributes operation was attemptedon a Read Only file. The fileshould first be set to Read Write(RW) with the command: STATfilespec RW.DDT-86. An attempt was made to

assemble a command with an ambiguousoperand. Precede the operand withthe prefix BYTE or WORD. NOS err on d: select

Bad Directory on d~Space Allocation Conflict:User n d:filename.typ

CP/N-86 has r e ce ived a r e questspecifying a nonexistent drive, ordisk in drive is improperlyformatted. CP/M-86 terminates thecurrent program as soon as you pressany key.STAT. This message is followed by a

list of one or more filespecs. Thefiles listed contain data blocksthat are already allocated toanother file on the disk. The errorcan be caused by a hardware orsoftware failure. Correct the errorby erasing the files displayed andrebooting CP/N-86. Note that ifCP/N-86 is not rebooted aftererasing the files, the problemreappears.

BDOS err on d: R/0

Drive has been assigned Read Onlystatus with a STAT command, or thedisk in the drive has been changedwithout being initialized with a fC.CP/N-86 terminates the currentprogram as soon as you press anykey.

Break 'x' at cBDOS err on d:

NOS err on d: bad sector

CP/N-86 replaces d: with the drivespecification of the drive where theerror o c c u r r ed . Th i s m e ssageappears when CP/N-86 finds no diskin the the drive, when the disk isimproperly formatted, when the drivelatch is open, or when power to thedrive is off. Check for one ofthese situations and retry.

ED. x is o ne of the symbolsdescribed below and c is the commandletter being executed when the erroroccur led o

Search failure. ED cannot findthe string specified in an F, S,or N command.

? Unrecognized command letter c.ED does no t r eco g n i z e t heindicated command letter, or anE, B, ( ) , o r 0 command is notalone on its command line.

0 The f i l e spec i f i ed i n an Rcommand cannot be found.

Buffer full. ED cannot put anymore characters in the memorybuffer, or the string specifiedin an F, N, or S command is toolong.

This could indicate a hardwareproblem or a worn or improperlyformatted disk. Press tC toterminate the program and return toCP/N-86, or press the return key toignore the error.

2726

Page 17: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command SummaryCP/N-86 Command Summary

CP/N-86 Messages (continued)CP/N-86 Messages (continued)

Cannot open sourceE Command aborted, A keystroke atthe console aborted commandexecution.

F Disk or directory full. Thiserror is followed by either thedisk or directory full message.Refer to the recovery procedureslisted under these messages

GEMCMD. The hex file specified inthe GENCND command line cannot befound. The hex file must have thefiletype H86. Check to see that thecorrect disk was specified and tryagain.

C~and Buffer Overflow

Cannot closeCannot close file SUBNIT. The SUBMIT buffer allows up

to 2048 characters in the inputf i le .ASN-86. An output file cannot be

closed. This is a fatal error thatterminates ASN-86 execution. Youshould take appropriate action afterchecking to see if the correct diskis in the drive and that the disk isnot write-protected.

Command too long

SUBMIT. A command in the SUBMITfile cannot exceed 125 characters.

Checksum errorDDT-86. The disk file written by aW cmeand cannot be closed. This isa fatal error that terminates DDT-86execution. You should takeappropriate action after checking tosee if the correct disk is in thedrive and that the disk is notwrite-protected.

GENCND. A hex record checksum errorwas encountered. The hex recordthat produced the error must becorrected, probably by recreatingthe hex file.

Command name?GENCND. The CMD file written by a Wcommand cannot be closed. This is afatal error that terminates GENCNDexecution. You should takeappropriate action after checking tosee if the correct disk is in thedrive and that the disk is notwrite-protected.

SUBNIT. This error can occur duringSUBMIT file processing. Check tosee if the correct system disk is inthe A drive and that the disk is notwrite-protected. The SUBMIT job canbe restarted after rebooting CP/M­86.

If CP/M-86 cannot find the commandyou specified, it returns thecommand name you entered followed bya question mark. Check that youhave typed the command namecorrectly, or that the command yourequested exists as a .CND file onthe default or specified disk.

GENCND. An invalid GENCMD commandline was entered. If the commandwas mistyped then try again.

DNTINATIN IS B/0, DELBTE (Y/N) 2

PIP. The destination file specifiedin a PIP command already exists andit is Read Only. If you type Y, thedestination file is deleted beforethe file copy is done.

2928

Page 18: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command SummaryCP/M-86 Command Summary

CP/M-86 Messages (continued)CP/M-86 Messages (continued)

Directory fullDDT-86. The disk file specified ina n R c ommand cannot b e readproperly. This is usually theresult of an unexpected end-of-file.Correct the problem in your file.

ASN-86. The r e i s not enoughdirectory space for the outputfiles. You should either erase someunnecessary files or get anotherdisk with more directory space andexecute ASN-86 again.

GENCMD. The specified hex filecannot be read properly. This isusually the result of an unexpectedend-of-file. Correct the problem byregenerating the H86 file.

ED. There is not enough directoryspace for the file being written,You can use the OXfilespec commandto erase any unnecessary files onthe disk without leaving the editor.Alternatively, you can save thecontents of the memory buffer onanother disk with the commandB)Xfilespec, where filespec is afile on a different drive. You canthen quit the edit. If you reeditthe file, the output should be placedon a different drive with thecommand ED filespec d:, where d: isa valid drive name other than thedrive containing the source f i l e .You can read the file saved with theRfilespec command. Caution, part ofthe file might not be in the memorybuffer when you save it if you havenot appended the whole file, or ifyou have issued any W commands,

Disk write error ­ {filespec)

PIP. The input disk file specifiedin a PIP command cannot be readproperly. This is usually theresult of an unexpected end-of-file.Correct the problem in your file.

DDT-86. A disk write operationcannot be successfully performedduring a W command, probably due toa full disk. You should ei thererase some unnecessary files or getanother disk with more space andexecute ASN-86 again.

Disk full

PIP. A disk write operation cannotbe successfully performed during aPIP command, probably due to a fulldisk. You should either erase someunnecessary files or get anotherdisk with more space and execute PIPagain.

ASN-86 • There is n ot e nough diskspace for the output files (LST, H86,and SYN). You should ei ther erasesome unnecessary files or getanother disk with more space andexecute ASN-86 again.

SUBMIT. The SUBMIT program cannotwrite the $$$ .SUB file to the disk .Erase some files, or select a newdisk and try again.

Error on line nnn message

ED. There is not enough disk spacefor the output file. This error canoccur on the W, E, H, or X commands.If it occurs with X command you canrepeat the command prefixing thefilename with a different drive.Otherwise, you can try the recoverymethods described above under theDirectory full message.

Disk read error ­ {filespec)

SUBMIT. The SUBMIT program displaysits messages in the format shownabove, where nnn represents the linenumber of the SUBMIT file. Referto the message following the linenumber

ASM-86. A source or include filecannot be read properly. This isusually the result of an unexpectedend-of-file. Correct the problem inyour source f i l e .

ERROR: BAD PARAMETER

PIP. An illegal parameter has beenentered in a PIP command. Retypethe entry correctly.

3031

Page 19: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/N-86 Command Summary

CP/N-86 Messages {continued) CP/N-86 Messages (continued)

ERROR: CLOSE FILE ­ (filespec) ERROR! INVALID BEK DIGIT ­(filespec)

PIP. An output file cannot beclosed. You should take appropriateaction after checking to see if thecorrect disk is in the drive andthat the disk is not write­protected.

GBNCND and PIP. An invalid hexdigit has been encountered whilereading a hex file. The hex filewith the invalid hex digit should becorrected, probably by recreatingthe hex file.

ERROR: DISK READ ­ {filespec} BRROR: INVALID SEPARATOR

PIP. The input disk file specifiedin a PIP command cannot be readproperly. This is usually theresult of an unexpected end-of-file.Correct the problem in your file.

PIP. You have placed an invalidcharacter for a separator betweentwo input filenames.

ERROR! INVALID SOURCE

ERROR: DISK NRITB ­ {filespec) PIP. The source specified in yourPIP command is illegal. You haveprobably specified an output devicePIP. A disk write operation cannot

be successfully performed during aPIP command, probably due to a fulldisk. You should either erase someunnecessary files or get anotherdisk with more space and execute PIPagain.

as a source.

ERROR: INVALID USBR NUNBBR

ERROR> FILE NOT FOUND ­ (filespec)

ERROR: HEX RECORD CEECKNN ­ (f ilespec)

PIP. An input file that you havespecified does not exist.

PIP. You have specified a UserNumber greater t han 15 . U s erNumbers are in the range 0 to 15.

ERROR: NO DIRECTORY SPACE ­ (filespec)

PIP. There is not enough directoryspace for the output file. Youshould either erase some unnecessaryfiles or get another disk with moredirectory space and execute PIPagain.

PIP. A hex r ecord checksum wasencountered during the transfer of ahex file. The hex file with thechecksum error should be corrected,probably by recreating the hex file. BRROR: GUIT NOT FOOND

PIP. The string argument to a {}parameter was not found in yourinput file.

ERROR! INVALID DESTINATION

PIP. The destination specified inyour PIP command is illegal. Youhave probably specified an inputdevice as a destination.

ERROR RBADING HELP.BLP INDBZ

ERROR: INVALID FORNAT

HELP. The HELP.HLP file used by theHELP command is invalid. This canbe caused by an unexpected end-of­file. The drstributed HELP.HLP fileshould be copied to the disk fromthe CP/N-86 system disk.

PIP. The format of your PIP commandis illegal. See the description ofthe PIP command.

32 33

Page 20: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/M-86 Command Summary

CP/N-86 Messages (continued) CP/N-86 Messages (continued)

ERROR: START NOT POUND » ERROR R: 3 » Double defined variable

ASM-86. An identifier used as thename of a variable is used elsewherein the program as the name of avariable or label. Example:

PIP, The string argument to an Sparameter cannot be found in thesource file.

ERROR: UNEXPECTED END OF HEX PILE{filespec)

X DB 5• • •

DB 123HPIP. An end-of file was encounteredprior to a termination hex record.The hex file without a terminationrecord should be corrected, probablyby recreating the hex file.

" ERROR NOr 4» Double defined label

ASN-86. An identifier used as alabel is used elsewhere in theprogram as a label or variable name.Example:ERROR: USER ABORTED

PIP. You aborted a PIP operation bypressing a key.

LAB3: NOV BX(5

LAB 3: CALL M OVE• • •

ERROR: VERIFY ­ {filespec)ee ERROR lS: 5 » Undefined instruction

ASN-86. The item following a labelon a source line is not a validinstruction. Example:

PIP. When copying with the Voption, PIP found a difference whenrereading the data just written andcomparing it to the data in itsmemory buffer • Usually thisindicates a failure of either thedestination disk or drive.

D ONE: BAD I NS T R

» ERROR N: 6 » Garbage at end of line­ignored~~ ERROR N: 0 » Illegal first item

ASM-86. The first item on a sourceline is not a valid identifier,'directive, or mnemonic. Example:

ASN-86. Additional items wereencountered on a l i n e when ASN-86was expecting an end-of-line.Examples:

1234HNOLIST 4MOV A X ,4 RET

ERROR 10: 1 « Missing pseudoinstruction

» ERROR NO: 7» Operand(s) mismatchinstructionASN-86. The first item on a source

line is a valid identifier, and thesecond item is not a valid directivet hat c a n b e p r e ceded by a nidentifier. Example:

ASN-86. Either an instruction hasthe wrong number of operands, or thetypes of the operands do not match.Examples:

THIS IS A MISTAKE

X DB 0M OV C X (1,2

N OV A X , X*e ERROR NO: 2 « Illegal pseudo

instr uction

ASM-86. Ei ther a requiredidentifier in front of a pseudoinstruction is missing, or anidentifier appears before a pseudoinstruction that does not allow an

34 35

Page 21: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/M-86 Command Summary

CP/N-86 Nessages (continued)CP/N-86 Messages (continued)

• e ERMR lS: 14 » No matching 'It' forZENDIK

ee ERROR M: 8 » I l l ega l i n structionoperands

ASN-86. An ENDIP statement wasencountered without a matching IFstatement.

MOV [BP+SP],1234

An instruction operand is improperlyformed. Examples:

CALL BX(1» ERROR EO< 15 ee Symbol illegallyforward referenced - neglected

ee ERMR NO: 9 ee Missing instruction

ASM-86. A prefix on a source lineis not followed by an instruction.Example:

ASN-86. The indicated symbol wasillegally forward referenced in anORG, RS, EQU, or IF statement.

» ERMR l©i 16 » Double defined symbol- treated as undefined

REPNX

ASM-86. The identifier used as thename of an EQU directive is used asa name elsewhere in the program.

ee ERMR M: 10» Undefined element ofexpression

ASN-86. An identifier used as anoperand is not defined or has beenillegally forward referenced.Examples:

» ERMR NO> 17 ee Instruction not in codesegment

ASN-86. An instruction appears in asegment other than a CSEG.

J MP XA EQU BB EQU 5

M OV A L, Bee ERMR M: 18 » tile name syntax error

ASM-86. The filespec in an INCLUDEdirect ive i s i m p roperly f o r med.Example:

ERMR N: ll Illegal pseudo operand

ASM-86 • The operand in a directiveis invalid. Examples:

X EQU OAG HINCLUDE PILE.A86X

» ERMR NO< 19 » Nested INCLUDE notallowed

TITLE UNQUOTED STRING

e* ERMR NOi 12 » Nested 'It' illegal­'It' ignored

ASM-86. An INCLUDE directive wasencountered within a file alreadybeing included.

ASN-86. The maximum nesting levelfor IP statements has been exceeded.

» ERMR NO 20 » Illegal expressioneleaent

e ERMR M: 13» Illegal 'It' operand­'It ' i gnored ASN-86. An expression is improperly

formed. Examples:ASM-86. Either the expression in anIF statement is not numeric, or itcontains a forward reference.

X DB 12XDW (4~)

3736

Page 22: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command SummaryCP/M-86 Command Summary

CP/M-86 Messages (continued)CP/N-86 Messages (continued)

*e BRROR NO: 21 ee Missing typeinformation in operand(s) REM. You have tried to rename a

file to a name already assigned toanother file. Either delete theexisting file or rename the file toa different name.

ASN-86. Neither instruction operandcontains sufficient typeinformation. Example:

NOV [BX],10file is Read Only

» ERROR NO: 22 » Label out of range ED. A Read Only file cannot beedited with the ED command: EDfilespec. Use the command EDinputfilespec outputfilespecinstead.

ASN-86. The label referred to in acall, jump, or loop instruction isout of range. The label can bedefined in a segment other than thesegment containing the instruction.In the case of short instructions(JMPS, conditional jumps and loops),the label is more than 128 bytesfrom the location of the followinginstruction.

Pile not found

CP/N-86 cannot find the specifiedfile. Check that you have enteredthe correct drive specification orthat you have the correct disk inthe drive.

BRROR NO: 23 » Missing segmentinformation in operand

ED. ED cannot find the specifiedfile. Check that you have enteredthe correct drive specification orthat you have the correct disk inthe drive.

ASN-86. The operand in a CALLF orJNPF instruction (or an expressionin a DD directive) does not containsegment information. The requiredsegment information can be suppliedby including a numeric field in thesegment directive as shown:

CSEG 1000H

STAT. STAT cannot find thespecified file. Check to see if thecorrect disk is in the drive.

• • •

Filename requiredJNPF XDD X

ED. You typed the ED commandwithout a filename. Reenter the EDcommand followed by the name of thefile you want to edit or create.

e' ERROR $0: 2i ee Brror in codemacrobuilding

ASN-86. Either a codemacro containsinvalid statements, or a codemacrodirective was encountered outside acodemacro.

HELP.HLP read error

Pile exists

HELP. An error occurred in readingthe HELP.HLP file. Usually thiserror i s c a used by an unexpectedend-of-file. A new copy of theHELP.HLP file should be copied fromthe CP/M-86 system disk.You have asked CP/M-86 to create a

new file using a file specificationthat is already assigned to anotherfile. Either delete the existingfile or use another filespecification.

Illegal disk drive

COPYDISK. An invalid or nonexistentdrive was specified.

38 39

Page 23: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command Summary CP/M-86 Command Summary

CP/N-86 Messages (continued) CP/N-86 Messages (continued)

Insufficient memory Memory request denied

DDT-86. There is not enough memoryto load the file specified in an Ror E command.

DDT-86. A request for memory duringan R command cannot be fulfilled.Up to eight blocks of memory can beallocated at a given time.

Insufficient memory available for copy

COPYDISK. There is not enoughmemory available to copy a trackfrom the specified disk.

No file

DIR, ERA, REN. CP/M-86 cannot findthe specified file, or no filesexist.

Insufficient memory to create CND file

GENCND. There is not enough memoryto create a CND file from the H86file specified.

ASM-86. The indicated source orinclude file cannot be found on theindicated drive.

DDT-86. The file specified in an Ror E command cannot be found on thedisk.

Invalid Assignment

STAT. An invalid drive or fileassignment was attempted. Thiserror message might be followed by alist of the valid file assignmentsthat can follow a filename. If aninvalid drive assignment wasattempted the message Use: d:~ROis displayed showing the propersyntax for drive assignments.

No .HLP file on the default drive

HELP. The HELP.HLP file was notfound on the default drive. Itshould be copied from the CP/M-86system disk.

No more directory spaceInvalid control character

GENCMD. There is insufficientdirectory space for creating theoutput file. A new disk should beselected or unnecessary fileserased.

SUBMIT. The only valid controlcharacters in the SUBMIT files oft ype SUB are "A through "K. N o t ethat in a SUBMIT file, the controlcharacter is represented by typingthe circumflex, , not by pressingthe Control key. lo space

Is this what you want to do (Y/N)?DDT-86. There i s no space in t hedirectory for the file being writtenby a W command.

COPYDISK. If the displayed COPYDISKfunction is what you want performed,type Y. No SOB file present

Memory not availableSUBMIT. F o r S UBMIT to o perateproperly, you must create a filewith filetype of SUB. The SUB filecontains normal CP/M-86 commands.Use one command per line.

CP/N-86. There is not enough memoryavailable for loading the programspecified.

40

Page 24: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/N-86 Command Summary

CP/M-86 Messages (continued)CP/N-86 Messages (continued)

Source amd destination disks must be thesame type

Output file exists, erase it

ED, The destination filenamealready exists when you are placingthe destination file on a differentdisk than the source. It should beerased or another disk selected toreceive the output file.

COPYDISK. Both the source anddestination disks must have the samecharacteristics. (The STAT DSK:command displays the diskcharacteristics.)

Symbol table overflowParameter error

ASN-86. A parameter in the commandtail of the ASN-86 command wasspecified incorrectly. Example:

ASM-86. There is not enough memoryfor the symbol table. Either reducethe length and/or number of symbols,or reassemble on a system with morememory.ASN86 TEST $S;

Too many filesToo many entries in index table

SUBNIT. Within the SUBMIT file oftype SUB, valid parameters are $0through $9.

Permanent error on track nPermanent error, sector n

HELP. There is not enough memoryavailable to run the HELP utility.

STAT. There is not enough memoryfor STAT to sort the files specifiedor more than 512 files werespecif ied.

COPYDISK. n is the track or sectornumber. A bad sector exists on thesource disk if the error occurredduring a track read. Otherwise, thebad sector is on the destinationdisk. If the destination disk hasthe error, reformat. If the errorpersists, discard the disk.

Topic not found

HELP. The topic requested does notexist in the HELP.HLP file. A topicshould be selected from the menudisplayed.

Read error

Unable to find file HELP.HLPTYPE. An e r ro r o ccurred whenreading the file specified in theTYPE command. Check the disk andtry again. The STAT filespeccommand can diagnose trouble.

HELP. The HELP.HLP file cannot befound on the default drive. Copy itto the default drive from the CP/M­86 system disk.

Source and destination cannot be the same

COPYDISK. T he s o ur ce an ddestination drives must bedifferent, although drives A, B, C,and D can all be mapped to the samephysical drive. The system promptsyou to change disks when the drivechanges.

Use: [sixe] [ro] [rw] [sys] or [dir]

STAT. This message results from aninvalid set file attributes command.These are the only options valid ina STAT filespec [optron] command.

43

Page 25: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command SummaryCP/M-86 Command Summary

CP/M-86 Messages (continued) CP/M-86 BDOS FUNCTION SUMMARY

Use: STAT d:~RO

STAT. An invalid STAT drive commandwas given. The only valid driveassignment in STAT is STAT d:~RO.

Verify error at s: o

4 5

1 2 3

DDT-86 • The value placed in memoryby a Fill, Set, Move, or Assemblec ommand cannot be r ead ba c kcorrectly, indicating bad usermemory or an attempt to write to ROMor nonexistent memory at theindicated location.

7s S

9

No.

248

Hex

00801802803H04H058068

Function Name

System ResetConsole InputConsole OutputAXI: I nputAXO: OutputList OutputDirect Con I/O

Get I/O ByteSet I/O BytePrint StringRead Con BufferGet Con StatusReturn Vers No.Reset Disk Sys.Select DiskOpen FileClose PileSearch Por PirstSearch Por NextDelete FileRead SequentialWrite SequentialMake FileRename PileRtn Login VectorRtn Current DiskSet DMA AddressGet Addr (Alloc)

Write Protect DskGet Read/Only VecSet File AttribGet Adr(Dsk Farm)

Set/Get User Code

Read RandomWrite RandomCompute File Size

Set Random Record

078088098

10 OAH11 OBH12 OQA13 ODH14 OEH15 OPH16 10H17 11818 12H19 13820 14821 15H22 16H23 17824 18825 19826 1AH27» 1BH

28 1CH29 1DH30 1EH31* 1PH

32 208

33 21H34 22835 238

36

37» 258 Reset Drive DX~Drive Vect40 28H Write Ran/0 Fill DX FCB Offset47 2FH Chain to Program DMA Buf:Cmd Ln49 318 Get Sysdat Addr. None

Input

DL=Abort CodeNoneDL CharNoneDLKharDL~CharDL~OFFHDL~OFEHDL~CharNoneDL>IOBYTEDX=Str OffsetDX Buf OffsetNoneNoneNoneDL>DiskDX PCB OffsetDX*PCB OffsetDX~PCB OffsetNoneDX FCB OffsetDX~FCB OffsetDX~PCB OffsetDX>FCB OffsetDX PCB OffsetBX*Login VectNoneDX DMA OffsetNone

NoneNoneDX~FCB OffsetNone

DL OFPH(get)DL User $(set)DX~PCB OffsetDX~FCB OffsetDX~FCB Offset

DX~FCB Offset

Output

NoneCharNoneAL~CharNoneNoneAL~Char/StatNoneAL=IOBYTENoneNoneCharsAL Con StatBX~Vers No.NoneNoneAL Rtn CodeAL~Rtn CodeAL~Dir CodeAL=Dir CodeAL~Rtn CodeAL~Rtn CodeAL Rtn CodeAL~Rtn CodeAL~Rtn CodeBX~Login VectAL Curr DskNoneBX~Alloc OfstES~Seg BaseNoneBX*RO VectorAL~Rtn CodeBX~DPB OfstES~Seg BaseAL~Curr CodeNoneAL~Rtn CodeAL~Rtn CodeRandom RecField Set

Random RecField Set

AL~008AL~Rtn CodeNoneBX~SysdatAddr OfstES*SysdatAddr SegNoneNoneBX>DMA OfstES~DMA Seg

50» 328 Direct BIOS Call DX BIOS Dscptr51* 338 Set DMA Seg Base DX*Base Addr52' 348 Get DMA Seg Base None

45

Page 26: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/N-86 Command SummaryCP/N-86 Command Summary

CP/M-86 FILE CONTROL BLOCKCP/M-86 BDOS Function Summary (continued)

No. Hex Function Name

53» 35H54» 36H55» 37H56» 38H57» 39H58* 3AH59* 3BH

Input

DX=MCB OffsetDX=MCB Offset

DX NCB OffsetDX NCB OffsetDX~NCB OffsetNoneDX*FCB Offset

Get Nax MemoryGet Max Nem AbsAllocate MemoryAlloc Abs MemoryFree MemoryFree All MemoryProgram Load

* Function differs from or has been added to set ofCP/M® 2.2 functions,

Output

AL*Rtn CodeAL=Rtn CodeAL=Rtn CodeAL=Rtn CodeNoneNoneAX*Rtn Code/Base Pg AddrBX*Base Pg Addr

The File Control Block (FCB) data areais a sequence of 33 bytes for sequentialaccess, or a sequence of 36 bytes if RandomA ccess Functions 33, 34, 35 , 36 , o r 4 0 a r eused. The default File Control Block normallylocated at offset 005CH from the DS registercan be used for random access files becausebytes 006DH, 007EH, 007FH are available forthis purpose. Here is the FCB format, followedby definitions of each of its fields.

r fl f2 / / f8 tl t2 t3 ex sl s2 rc dO / / dn cr rO rl r2

00 01 02 ... 08 09 10 11 12 13 14 15 16 ... 31 32 33 34 35

where:dr

sl

S2

ex

• • •

drive code (0 - 16)0 • > use default drive for file1 • > auto disk select drive A,2 ~> auto disk select drive B,

16 • > auto disk select drive P.

fl...f8 contain the file name in ASCIIupper case, with high bit * 0

tl,t2,t3 contain the file type in ASCIIupper case, with high bit 0tl', t2', and t3' denote the highbit of these positions,tl' ~ 1 ~> Read/Only file,t2' ~ 1 => SYS file, no DIR list

contains the current extent number,normally set to 00 by the user, butin range 0 - 31 during file I/O

reserved for internal system use

reserved for internal system use, setto zero on call to OPEN, NAKE, SEARCH

record count for extent "ex,"takes on values from 0 - 128

dO...dn filled in by CP/N, reserved for

rc

system use

current record to read or write ina sequential file operation, normallyset to zero by user

cr

r0,rl,r2 optional random record number in therange 0-65535, with overflow to r2,rO,rl constitute a 16-bit value withlow byte r0, and high byte rl

Both CP/M Version 2 and CP/M-86 performdirectory operations in a reserved area ofmemory that does not affect write buffercontent. Write buffer content is only affectedin the case of Search and Search Next, wherethe directory record is copied to the currentDMA address.

46 47

Page 27: OPERATlNG SYSTEM COMMAND SUMMARY ...planemo.org/retro/downloads/z100/manuals/cpm86/CPM-86...command identifies a command (program) to be executed. The optional command tail can consist

CP/M-86 Command Summary

CP/M-86 BASE PAGE VALUES

The CP/M-86 base page contains defaultvalues and locations initialized by the CCP andused by the transient program, The base pageoccupies the regions from offset 0000H through00FFH relative to the DS register. The valuesin the base page for CP/M-86 include those ofCP/M-80'™ and appear in the same relativepositions, as shown in the following figure.

os + 0000:

DS + 0003:

os + 0006:

oS + 0009;

DS + OOOC:

DS + OOOF:

DS + 0012:

DS + 0015:

DS + 0018;

DS + 001B:

DS + 001E:

DS + 0021:

os + 0024:

os + 0027:

DS + 002A:

Ds + 002D:

oS + 0030:

DS + 005B:

Ds i 005C:

os + 0080:

Ds + 0100:

LCO

BCO

LDO

BDO

LEO

BEO

LSO

BSO

LXO

BXO

LXO

BXO

LXO

BXO

LXO

BXO

Lcl

Bcl

LD1

BD1

LE1

BE1

Lsl

Bsl

Lxl

Bxl

Lxl

BX1

LX1

BX1

LX1

BX1

NotCurrentlyUsed

Default FCB

Default Buffer

Begin User Data

XXX

LX2

xxx

LX2

XXX

IX2

XXX

XXX

LX2

LC2

M80

LD2

xxx

LE2

XXX

LS2

• • •

E ach byte i s i n dexed by 0, 1 , and 2 ,corresponding to the standard Intel storageconvention of low-, middle-, and high-order(most significant) byte. Unused bytes aremarked by xxx. LC is the length of the codegroup location (24 bits, where the 4 high-orderbits equal zero).

48