background image

Содержание Z80-RIO

Страница 1: ...t_ Zilog Operating System User s Mannal...

Страница 2: ...stored in a retrieval system or transmitted in any form or by any means electronic mechanical photocopying recording or otherwise without the prior written permission of Zilog Zilog assumes no respons...

Страница 3: ...zaO RIO Operating System User s Manual September 1978...

Страница 4: ......

Страница 5: ...on 3 3 3 6 7 1 2 4 1 2 5 Commands I O 7 CHAPTER 2 RIO EXECUTIVE 2 1 SYSTEM INITIALIZATION 2 2 2 3 2 4 2 5 2 6 FILE NAME CONVENTIONS MEMORY MANAGEMENT 2 3 1 MEMMGR COMMAND STRING INTERPRETATION ERROR H...

Страница 6: ...ING ADDRESS 4 3 PROGRAM STACK SPACE 21 21 21 21 22 27 27 27 28 28 29 29 4 4 PROGRAM TERMINATION ERROR HANDLING 29 4 5 SYSTEM CALLS SYSTEM ENTRY POINT 30 4 6 4 7 4 8 INTERRUPT STATUS I O UNIT UTILIZATI...

Страница 7: ...5 14 DEFINE 60 5 15 DELETE 63 5 16 DISK FORMAT 67 5 17 DISK REPAIR 70 5 18 DISK STATUS 72 5 19 DISPLAY 74 5 20 DO 75 5 21 DUMP 79 5 22 ECHO 80 5 23 ERROR 81 5 24 ERRORS 82 5 25 EXTRACT 83 5 26 FORCE 8...

Страница 8: ...TABS SAVE TABS SET STATUS VERBOSE XEQ EXPRESSION EVALUATION CHAPTER 6 ZDOS 6 0 ZDOS OPERATION INITIALIZE ASSIGN OPEN 92 93 98 99 100 102 103 104 109 III 112 113 6 1 6 2 6 3 6 4 6 5 6 6 6 7 6 8 6 9 CLO...

Страница 9: ...TO END 157 6 19 RENAME 158 6 20 UPDATE 160 6 21 SET ATTRIBUTES 162 6 22 QUERY ATTRIBUTES 164 CHAPTER 7 DFS 166 7 1 ZILOG DISK CONTROLLER 166 7 2 DFS OPERATION 168 7 3 SOFTWARE ORGANIZATION 171 7 4 DFS...

Страница 10: ...NDIX D Converting Files to RIO Format APPENDIX E Altering Default RIO APPENDIX F I O Request Vector Format and I O Request Codes APPENDIX G Program Examples APPENDIX H Internal Command Table Contents...

Страница 11: ...nual zaO ZDS PROM User s Manual zaO RIO Relocating Assembler and Linker User s Manual zaO RIO Text Editor User s Manual This manual makes use of the following conventions of notation Optional portions...

Страница 12: ...d constants referring to memory allocation are given in hexadecimal Unless so specified other constants are given in decimal Hexadecimal constants are also indicated by an H immediately following the...

Страница 13: ...S and the Zilog Hard Disk File System DFS In the modest environment the user has access to 3K lK 1024 bytes of dedicated read only memory which contains a program debugger with file manipulation capab...

Страница 14: ...velopment minimizing assembly time with relocatable modules while allowing com plex memory overlay structures In addition a console driver is provided which allows user definition of character delete...

Страница 15: ...DOS controls the organization and allocation of the sectors on a diskette While the basic unit of disk allocation is the sector the fundamental structure within ZDOS is the file A file consists of zer...

Страница 16: ...uded in the file s descriptor record see below 4 random file is in a format for random access secret file is not normally found in directory searches see below When a file is created the user specifie...

Страница 17: ...therefore always read or written as a single disk access ZDOS maintains a bit map to keep track of allocated vs unallocated disk sectors This map resides on three sectors of the diskette which are pre...

Страница 18: ...the standard disk search sequence of drive 1 drive 2 drive O The PROM monitor then may communicate directly with the controller to load the file OS again using the standard drive search sequence When...

Страница 19: ...mmands are noted as such in the command description Chapter 5 1 2 5 I O The I O structure of RIO is designed to facilitate program development independent of physical device characteristics To this en...

Страница 20: ...Units 1 2 and 3 have the mnemonics CONIN CONOUT and SYSLST respectively which can be used interchangeably with the literal unit designations where applicable I O requests are made with a standard vect...

Страница 21: ...e assigns default values to the line delete LINDEL and character delete CHRDEL symbols and the number of null characters NULLCT and line feeds LFCNT to be inserted after every carriage return These va...

Страница 22: ...ut 2 2 FILE NAME CONVENTIONS In the most general case file names in RIO consist of three parts 1 the device name specifying which device to search for the named file e g ZDOS 2 the drive designation r...

Страница 23: ...tes a standard search sequence of drives 1 2 7 0 Device names are essentially file names prefixed with the character This character merely serves as a delimiter and is not really part of the name itse...

Страница 24: ...h of drive a is unsuccessful All qualified file names those with device or drive designations or the prefix I are treated as external commands Thus IDEBUG is not the same as the internal command DEBUG...

Страница 25: ...mmand but does not terminate command input Thus as many commands may be entered at one time as can be contained in the 256 byte command string buffer Several characters have special significance to th...

Страница 26: ...e record is required to contain the file If the allocating request is successful the file is loaded into memory After loading the file two things may inhibit its execution If it has a null entry point...

Страница 27: ...deallocated Note that in the event a file is loaded but not executed the space it occupies will be allocated until either explicitly deallocated see the RELEASE command section 5 35 or a return to OS...

Страница 28: ...includes the device name and entry point Devices are made known to the system via the ACTIVATE command see section 5 1 or they may be removed from the ADT by the DEACTIVATE command see section 5 11 T...

Страница 29: ...quests are accomplished by making a subroutine call to the RIO entry point SYSTEM see Appendix C The IY register must hold the address of a request vector of the following format IY Byte o 1 2 3 4 5 6...

Страница 30: ...tine i e it must preserve all registers However an RETI instruction should not be executed since lower level interrupts are enabled by the interrupt handler If immediate return is desired care must be...

Страница 31: ...ode 02 the request is trapped by RIO for possible unit definition or supplemental parameter vector manipulation The exact sequence is controlled by a set of flags in the first byte of the supplemental...

Страница 32: ...mats the rest of the supplemental parameter vector in the same wa as before If bit 7 of the flag byte is set 1 the vector and supplemental parameter vector is assumed to be in a correct format i e all...

Страница 33: ...ler Null device PROM console driver System console driver ZOOS is the file system for RIO on floppy disk based systems It distinguishes between logical units and supports named files Consult Chapter 6...

Страница 34: ...t of the file as which is loaded during system bootstrap It allows the user to define the line and character delete symbols and supports arbitrary tab settings within a 134 character line length The s...

Страница 35: ...ho If in AUTOLF ON mode default and the value of LFCNT is nonzero then LFCNT linefeeds are output to the console following every carriage return After ljne feed insertion if any and if the value of NU...

Страница 36: ...ault tatus area Null operation returns operation complete If data length 0 null operation Otherwise up to 20 bytes can be requested from the default set of attributes including Type Record Count Recor...

Страница 37: ...umber of characters written A maximum of data length characters is sent to the console up to and including the first carriage return Data length is reset to the actual number of characters written Tra...

Страница 38: ...s area see above DEACTIVATE 44H Null operation returns operation complete READ ABSOLUTE 46H Data length bytes are received from the console device Byte data is ac cepted exactly as trans mitted Data l...

Страница 39: ...units Refer to the MCZ or ZDS PROM User s Manual for full details 3 4 6 FLOPPY The PROM floppy disk driver is used by ZOOS as the access primitive for the floppy disk drives Refer to the MCZ or ZDS P...

Страница 40: ...y loaded into the low range of the program space for execution Entry points and file sizes can be obtained using the EXTRACT or CAT commands see Chapter 5 The minimum requirement for program execution...

Страница 41: ...Before execution the system stack pointer is saved a user stack is allocated if the requested stack size is not equal to zero and the parameter string address and return address in RIO are pushed Disp...

Страница 42: ...on code Address of the first byte of command input string This string is of indefinite length but must terminate with a carriage return The format for the command string is the same as if entered on t...

Страница 43: ...upt service routine starting address Zilog support devices can be programmed to supply appropriate interrupt vectors using this space If program constraints make it necessary to alter the interrupt mo...

Страница 44: ...are sample programs which the user is encouraged to edit assemble link and execute They illustrate some of the concepts introduced in previous sections of the chapter including console I C parameter...

Страница 45: ...conventions In all syntax descriptions the following notation is used Optional parts of a parameter list are enclosed in brackets The symbol for logical or I I is used if either parameter separated by...

Страница 46: ...The logical units that the command uses for a particular function I O error messages generally refer to the unit on which the error occurred EXAMPLES Illustrative examples of command invocation where...

Страница 47: ...s not overlay protected memory The amount of memory allocated as a result of loading the file is kept as the SIZE field of the ADT entry for possible later use by the DEACTIVATE command If the optiona...

Страница 48: ...equest An entry is created in the Active Device Table ACTIVATE MYDOS 4 MY VIDEO DRIVER locates file MY VIDEO DRIVER on device MYDOS drive 4 It is then loaded an Initialize request sent and an Active D...

Страница 49: ...d up to the next multiple of 80H 1 is marked as allocated in the system memory map If allocation is not possible the message INSUFFICIENT MEMORY is given I O UNIT UTILIZATION None EXAMPLES ALLOCATE 0...

Страница 50: ...ALLOCATE ALLOCATE ALLOCATE 8EOO 9535 9535 8EOO use the expression evaluator to determine the blocksize to be allocated 780H bytes 38...

Страница 51: ...BRIEF Internal Command Enters console Brief mode Commands are not echoed on the console output device as interpreted and some command files suppress execution messages See Verbose command I O UNIT UT...

Страница 52: ...ed is used match_string Fully or partially specified file names may be given in which case only those directory entries which are identical to one of the fully specified file names or match one of the...

Страница 53: ...ne or more properties may be concatenated in which case only files with exactly or at least if is included the specified properties will be listed D drive Only files from the specified drive will be l...

Страница 54: ...urn to the Executive The I and ESCape features apply only to MCZ systems CDATE DATE reI date where reI is one of the relational operators or and date is up to 6 digits or representing a date to be com...

Страница 55: ...T D DFS 2 P W SYS Lists all files short format on drive 2 on the device DFS if it is ready which are write protected only and whose names start with SYS CAT F L S L P E L CAT LIST Lists all files long...

Страница 56: ...es a Close 06 I O request for hexadecimal logical unit u or all logical units Error returns are ignored I O UNIT UTILIZATION As noted above EXAMPLES CLOSE 5 generates a Close I O request for logical u...

Страница 57: ...E OlFC RECORD 0003 B6 FILE2 BYTE OlFC RECORD 0003 A6 is given Pressing the escape key will terminate command execution File 1 and file 2 may not be the same physical file though they can be the same n...

Страница 58: ...ARE AFILE BFILE I O ERROR C9 ON UNIT 7 an end of file was reached on BFILE before the corresponding end of file on AFILE COMPARE Q MYFILE l MYFILE the two files have the same name but they reside on d...

Страница 59: ...es See Chapter 6 for details The default record length and type of file 2 will be the same as file 1 These attributes can be overridden by specifying one of 80 100 200 400 800 or 1000 for record lengt...

Страница 60: ...THE FILE on drive 2 of ZDOS to THE FILE on device MYDOS default drive search The record length of the destination file is 400H and its previous contents if any will be erased COpy ANOTHER FILE CON Co...

Страница 61: ...track at a time thus the previous contents if any are overwritt2D It is not necessary that the destination disk be formatted After the copy operation a verification pass is made during which a track b...

Страница 62: ...interaction console interaction console interaction DRIVES READY Y VERIFICATION COMPLETE COPY DISK copies disk in drive 0 onto disk in drive 2 for MCZ or 1 for ZDS COPY DISK 3 TO 7 V DRIVES READY Y V...

Страница 63: ...ERT DESTINATION DISK TYPE ANY KEY TO CONTINUE ESCAPE TO ABORT is sent to the console device the user must place the source or destination diskette as specified in the prompt into the drive If the user...

Страница 64: ...PYSD DATA FILE INSERT SOURCE DISK TYPE ANY KEY TO CONTINUE ESCAPE TO ABORT G INSERT DESTINATION DISK TYPE ANY KEY TO CONTINUE ESCAPE TO ABORT copies the file DATA FILE from the source diskette to the...

Страница 65: ...ternal initialization command file OS INIT Editing the file manually is required to change the date set at system initialization Users are encouraged to maintain the DATE consistent with the actual da...

Страница 66: ...evice handler is deallocated Deactivation is inhibited for the last active device since there would be no source for further external commands and therefore no method to activate other device files Li...

Страница 67: ...previously allocated the message MEMORY PROTECTION is given Block address will be rounded down and block size will be rounded up to a multiple of 80 bytes I O UNIT UTILIZATION None EXAMPLE DEALLOCATE...

Страница 68: ...ry image into memory and stores its starting execution address in the user PC A memory image file file type Procedure can be created by the SAVE command or by the IMAGE or LINK commands The files cont...

Страница 69: ...ecified they must be specified in the syntactical order specified above If the system encounters a syntax error in the command line it displays a Question Mark character and returns to Debug Such synt...

Страница 70: ...both before and after the SAVE operationo 1 If Debug was invoked via a breakpoint and ZDOS is being accessed by the program in question do not issue a SAVE command unless you can verify that all ZDOS...

Страница 71: ...This Change Page has been left blank intentionally E3 0072 01 Rev A 59 02 13 79...

Страница 72: ...ed a close request is generated A file name may optionally be associated with the unit Assign and Open requests may be generated for the unit Unit file name The unit is linked to the specified device...

Страница 73: ...U open type Update I open type Input NF open type Newfile NO Generate No Open request I O UNIT UTILIZATION Unit 2 error messages parameter dependent Others EXAMPLES DEFINE SYSLST LPR Defines the syste...

Страница 74: ...tialization after bootstrap All defined units are closed prior to being redefined as their defaults DEFINE 12 YOUR DOS YOURFILE NO Links unit 12 to the device YOUR DOS which must be active An Assign I...

Страница 75: ...an match strings are specified more than once the last entered is used As matches are made if in query mode a prompt is made to the console of the form DELETE drive filename Y N A Q One character is a...

Страница 76: ...ualified file names i e no device or drive name may be given see the 0 option below T type Only files of the given type will be deleted Type must be one of 0 directory A ASCII B binary or P procedure...

Страница 77: ...ion specifies that that digit will be considered equal to anything A date expressed with less than 6 digits is treated as being filled on the right with s DATE refers to the date of last modification...

Страница 78: ...drives which end in OLD backup files are normally produced by the text editor DELETE T A CDATE 773112 Deletes after prompting all ASCII type files created before December 31 1977 DELETE D 2 P R BASIC...

Страница 79: ...within the superblock If the S option is given in order to format a system disk the file BOOTSTRAP is copied from the master device This file implements the file system and is read into memory when t...

Страница 80: ...ormats the disk in drive 0 as a system disk with an initial directory size of 15 blockso The format program writes sector 0 so that the sector interlace map which maps logical records to disk addresse...

Страница 81: ...constructed If the S option was specified then the format program will attempt to copy the file BOOTSTRAP onto the drive I O UNIT UTILIZATION Unit Unit Unit 0 1 2 DISK interaction console interaction...

Страница 82: ...the issues the following prompt Drive Valid response 0 1 2 3 4 L level The attempted repair level if specified for this option the issues the following prompt Level Valid response 1 2 or c EXAMPLES OI...

Страница 83: ...allocated but are on the free chain and not in the unallocated sector list Level 2 repair takes about seven minutes to run Level C Repair Level C checks the free chain of unallocated sectors on the di...

Страница 84: ...ISK 6638 SECTORS USED 3105 SECTORS AVAILABLE USAGE Entering the command keyword without a qualifying drive number causes the system to respond by listing statistics for all ready drives For example DI...

Страница 85: ...ee sectors and allocated sectors does not equal the total of sectors on the disk the system issues the following message WARNING DISK STATISTICS ARE INCONSISTENT If the total number of sectors marked...

Страница 86: ...tem console The memory allocation display is a matrix with one horizontal row for each 1000H bytes of memory The point corresponding to each 80H byte segment of memory is either marked with lA if the...

Страница 87: ...For each lin the nth parameter string from the parameter list is substituted A maximum of 64 parameter strings may be passed in this manner Parameters which are present but not referenced are ignored...

Страница 88: ...to allocate buffer space For short command files a few records in a 32K system this depth is approximately 15 depending on memory requirements for other command executions WARNING Due to the force all...

Страница 89: ...TR Command DO PRINT MYFILE Result ACTIVATE LPTR COpy MYFILE LPTR DEACTIVATE LPTR Simple parameter substitution is performed for as many strings enclosed within brackets as there are parameters given O...

Страница 90: ...rameters were given indicating conditional expansion of four levels In the second command only two were given limiting expansion to two levels The characters A L and X could have been any character st...

Страница 91: ...dump starts with record m and continues through record n If m and or n are unspecified the dump starts with the first and continues through the last respectively While output is active at the console...

Страница 92: ...O UNIT UTILIZATION unit 2 string output EXAMPLES ASM MYFILEiLINK 4400 MYFILEiECHO control G This would send a control G bell to the console output device after completion of the assembly and link ECHO...

Страница 93: ...code when returned by RIO or a device as a completion code If the optional error code is all error code meanings are displayed If error code is omitted this description of the ERROR command is printed...

Страница 94: ...INCE SYSTEM RESTART 0000 SEEK ERRORS 0000 SECTOR ADDRESS ERRORS 0000 DATA TRANSFER ERRORS Reference the Z80 MCZ PROM User s Manual for a detailed explanation of these errors I O UNIT UTILIZATION Unit...

Страница 95: ...es created by IMAGE the segment addresses are those given in the parameter list However LINK provides an optimizing algorithm for segment allocation dependent on program memory utilization and file re...

Страница 96: ...rogram calls are two examples As an alternative to using the Force command the properties of a file can include F force memory allocation which has the same effect as the Force command but only for th...

Страница 97: ...nes whether or not the disk is to be formatted as a system disk Systems disks have dedicated areas for the bootstrap and GET SAVE overlays When the S option is given and the disk is being formatted on...

Страница 98: ...I is to be part of the new name it must be immediately preceded by a percent sign These are written on the disk and used by ZDOS to determine disk allocation map validity If this option is not given t...

Страница 99: ...e a file is loaded but no external file is executed for example after examination with the Debugger it may be necessary to deallocate the space it occupies This command deallocates any memory allocate...

Страница 100: ...or DISK for hard disks no pseudonyms for these devices may be used The new disk name may be up to 24 characters for FLOPPY or 100 characters for DISK and may include any character except carriage ret...

Страница 101: ...ems FLOPPY is part of ZOOS and has an entry point two greater than the entry address for ZOOS It must be activated separately For example if the ZOOS 60 is being used on a 64K system has been renamed...

Страница 102: ...ent is omitted a general of the preceding modifying key_words I O UNIT UTILIZATION EXAMPLES Unit 2 Help message Unit 4 File I O HELP HELP If the final argument can be used as further is displayed If t...

Страница 103: ...ore than 16 segments may be specified When writing the file the exact memory locations including first location and last location are copied for each segme t The lowest ana highest memory addresses re...

Страница 104: ...ce which must be active Result is device dependent The supplemental parameter address of the vector points to the delimiter after the command or d vice_narne if given I O UNIT UTILIZATION Unit 0 I O r...

Страница 105: ...mplies that the device is in PROM or was activated with a preloaded entry point given In either case no memory is deallocated upon deactivation I O UNIT UTILIZATION Unit 3 listing output EXAMPLE LADT...

Страница 106: ...ault source for unqualified files This provides the user with the potential to easily utilize multiple file systems concurrently without the burden of always fully specifying file names I O UNIT UTILI...

Страница 107: ...the defaults are drive I and drive 0 respectively match_string Fully or partially specified file names may be given in which case only those directory entries which are identical to one of the fully...

Страница 108: ...1 Use of the will allow any file with at least the specified properties to be moved One or more properties may be concatenated in which case only files with exactly or at lea t if is included the spec...

Страница 109: ...to the specified device or file will be buffered i e several lines will be transferred at one time While output is active at the console entering a character will cause output to stop until another c...

Страница 110: ...example CDATE 7805 refers to all files created with dates in May of 1978 or later This is equivalent to CDATE 7805 If the referenced date field of the file descriptor has a character which is not a d...

Страница 111: ...S 2 D O CDATE 780915 Will copy all procedure files whose names start with SYS that were created before September 15 1978 from the master device drive 2 to the master device drive O The listing will b...

Страница 112: ...mands in the command string are ignored I O UNIT UTILIZATION Unit 1 read request EXAMPLE The content of the command file MOVE IT is MOVE iECHO INSERT DISKETTESiPAUSEiIiX 4400 This command file will re...

Страница 113: ...eter Description file name The name of the user file an alphanumeric character string excluding special characters upper or lower case the command keyword must be in upper case characters EXAMPLE PRIN...

Страница 114: ...This Change Page has been left blank intenti nal1y E3 0072 01 t Rev A 9ab CD 02 13 79...

Страница 115: ...e a file is loaded but no external file is executed for example after examination with the Debugger it may be necessary to deallocate the space it occupies This command deallocates any memory allocate...

Страница 116: ...r diskettes or DISK for hard disks no psuedonyms for these devices may be used The new disk name may be up to 24 characters for FLOPPY or 100 characters for OISK and may include any character except c...

Страница 117: ...RENAME EXAMPLES RENAME MYDOS FILE X FILE Y generates Assign and Rename requests for device MYDOS changing name of FILE X to FILE Y RENAME FLOPPY 2 ID MY NEWEST RIO DISK renames the diskette in drive...

Страница 118: ...in the specified file The file name may be fully or partially qualified The referenced file must have been previously created by the SAVE TABS command I O UNIT UTILIZATION EXAMPLES Unit 2 error messa...

Страница 119: ...for possible later retrieval by the RESTORE TABS command The file name may be fully or partially qualified If the file all ready exists it is deleted and recreated I O UNIT UTILIZATION EXAMPLE Unit 2...

Страница 120: ...n be given in any order with each command entry CHRDEL c Sets the console driver single character delete symbol to char acter c For example typing SET CHRDEL control H will cause all control His to be...

Страница 121: ...value given as nne This port typically is used for terminal I O Any value from 20 baud to 4800 baud which is an even divisor of 4800 or 110 9600 19200 or 38400 can be selected TABSIZE n Redefines all...

Страница 122: ...me TO nn Sets to nn the lower boundary of the memory space which must be allocatable before a file name can be loaded HIGH_ADDRESS OF file_name TO nn Sets to nn the high boundary of the memory space w...

Страница 123: ...null count to 2 SET PROPERTIES OF OS TO SWEL Would give file OS the properties secret write protect erase protect and locked Therefore it could never be altered or deleted without reformatting the di...

Страница 124: ...he serial communication port baud rate to 9600 SET ENTRY POINT OF STAR TREK TO 4419 BYTE COUNT OF STAR TREK S TO 38 Sets the entry point of STAR TREK to 4419H and the number of bytes in the last recor...

Страница 125: ...Non existent Command Illegal File Type Program Abort Insufficient Memory Missing or Invalid File Properties I O Error IY Vector Meaning Operation Complete Directory Format Error Scratch File Created...

Страница 126: ...s Disk Is Full File Not Found in Proper Directory Record Beginning of File Error File Already Open on Other Unit Invalid Rename to Scratch File File Locked Attempt to Change Attributes Invalid Open Re...

Страница 127: ...message WARNING DISK STATISTICS ARE INCONSISTENT is printed If the total number of sectors marked as unallocated in the sector map do not equal the free sector count then the following message is pri...

Страница 128: ...STATUS EXAMPLES STATUS 0 DRIVE 0 RIO MCZ SYSTEM DISK 659 SECTORS USED 1805 SECTORS AVAILABLE o 110 STATUS...

Страница 129: ...X Verbose DESCRIPTION VERBOSE Internal Command Enter Verbose mode Echo command strings as interpreted Some commands test this mode before printing non essential messages See Brief command I O UNIT UTI...

Страница 130: ...ameter list or begin execution at location nn with optional parameter list I O UNIT UTILIZATION None EXAMPLES XEQ X Jumps to entry point of last loaded file X 5600 pI p2 Jumps to address 5600B with IN...

Страница 131: ...expression DESCRIPTION EXPRESSION EVALUATION Internal Command Evaluates hex constant expressions left to right and prints result Allowable operators are and Overflow is not detected EXAMPLES FDOO 440...

Страница 132: ...rds All data records in a file are of the same length and the length must be an integral number of sectors of the diskette media and an integral power of two valid record sizes are 128 256 512 1024 20...

Страница 133: ...names can be from I to 32 characters in length The last entry in a sector is followed by a byte of 1 OFFH Directory entries do not span sector boundaries so that if a new entry will not fit completel...

Страница 134: ...from the System Global Variable DATE at the appropriate times Thus if DATE is maintained to indicate the current date then the descriptor record can give some historical information about the file The...

Страница 135: ...cifically indicated equivalent to specifying the drives are searched in order starting with drive 1 and continuing through the highest disk which is attached and ready and finally if still unsuccessfu...

Страница 136: ...is to begin If no data transfer is expected for a given request this field should be zero Length 2 bytes gives the length of the operation For most operations this is the number of bytes to transfer b...

Страница 137: ...ing the nature of the difficulty or error A normal completion will thus contain a code of SO Supplemental parameter information some requests require special information which does not fit into the ge...

Страница 138: ...t open unit already active Assign buffer full Invalid disk drive Logical unit table full Duplicate file Diskette ID error Invalid attributes Disk full File not in proper directory record Beginning of...

Страница 139: ...write protected or a request which would remove records from a file which is erase protected A SECTOR error code C4 is always a media or hardware problem indicating that the sector header information...

Страница 140: ...ged as not openG The logical unit map is cleared Memory is allocated at the top of the available space for each map and the maps are read in from the disk A flag word is constructed indicating which d...

Страница 141: ...physical disk drive either 0 through 7 or 3rd byte of area length in bytes of file name A 0 length name indicates a scratch file The maximum length name is 32 characters 4th and following bytes the fi...

Страница 142: ...drive is specified other than or 0 7 ASSIGN BUFFER FULL code CD the buffer used for storing filenames after assignment prior to files being opened is too full to hold the name assigned The assignment...

Страница 143: ...is zero or less than the minimum set of attributes for a new file and the file needs to be created the balance will be supplied from defaults See below for a detailed description of attributes Comple...

Страница 144: ...e 128 bytes are used by the system leaving the remainder for possible use by the user When a file is created the organization etc must be specified by the user either explicitly or by default Similarl...

Страница 145: ...on nothing can be removed from the file Write protection implies erase protection but not vice versa Locked No attributes can be changed Secret the file will not appear in normal directory listings Ra...

Страница 146: ...ve ways that the cases of file not found file found may be handled These are specified in the bottom 3 bits of this word They are as follows Open for input 0 if the file exists it will be activated wi...

Страница 147: ...do not match and no other unit has a file open on the same physical drive a new map and ID will be read into memory If another unit is open on that drive a WRONG DISKETTE error will be returned and t...

Страница 148: ...has overwritten the maps in memory The file is not opened FILE NOT FOUND code C7 the open request was for input and the file designated does not exist POINTER ERROR code CAl could occur if the pointer...

Страница 149: ...n is taken INSUFFICIENT MEMORY code DA if additional disks have been inserted prior to the open request and insufficient memory is available for additional allocation maps this error will be returned...

Страница 150: ...6 decimal bytes Completion return address Error return address Completion code Supplemental parameter information none Action If the logical unit is a scratch file the file is erased If there have bee...

Страница 151: ...02 if attributes are specified for replacement and the type is invalid this error will result The type is left unchanged but everything else is done All DISK ERRORS are possible POINTER ERROR code CAl...

Страница 152: ...tion none Action The file pointer is positioned at the descriptor record with the first record as the next record This is the position the file pointer assumes when the file is opened for other than a...

Страница 153: ...l parameter information if the file is open for random I O this field should contain the address of a three byte area where the disk address of the first record read will be returned Otherwise it is u...

Страница 154: ...E code C9 the last record of the file was read and the given length had not yet been fulfilled The length returned reflects the number of bytes actually read POINTER ERROR code CA a pointer mismatch o...

Страница 155: ...upplemental parameter information if the file is open for random I O this field should contain the address of a three byte area where the disk address of the first record written will be returned If n...

Страница 156: ...ogical unit being accessed is not active No action is taken DISK FULL code D3 there is no room on the disk to allocate a new record Records which will fit are written The length returned reflects the...

Страница 157: ...ntal parameter information if the unit is open for random I O this field should Actio contain the address of a three byte area where the disk address of the record will be returned Otherwise it is unu...

Страница 158: ...e file and the space taken up by them deallocated made available until the given number of bytes have been removed The current record pointer is left on the record preceding those deleted The next rec...

Страница 159: ...including the last record The pointer is left at the record preceding the first one deleted with the next record pointer being null POINTER ERROR code CA a pointer mismatch occurred while traversing t...

Страница 160: ...er is left on the record preceding those deleted The next record pointer is null If the pointer is on the descriptor before the operation it is moved forward before deletion begins Possible errors All...

Страница 161: ...cated and the directory entry for the file is removed from the directory thus rendering the file completely inaccessible The file does not have to be open but it must have been assigned Possible error...

Страница 162: ...s been changed or that a program has overwritten the ZDOS map area The file is not erased FILE NOT FOUND IN DIRECTORY code D4 this error indicates that no directory entry for the file could be found i...

Страница 163: ...om I O this field should contain the address of a three byte area where the disk address of the first record read will Action be returned This request is useful when a block of data is to be read modi...

Страница 164: ...t exhausting the length specification The number of bytes read is returned in the length field and the next record pointer is null POINTER ERROR code CA a pointer mismatch occurred in going from one r...

Страница 165: ...n code Supplemental parameter information if the file is open for random I O this field should contain the address of a three byte area where the address of the current record will be returned Otherwi...

Страница 166: ...code CB the logical unit being accessed is not active No action is taken BEGINNING OF FILE code D5 the pointer is on the descriptor record which cannot be read No data is transferred and a null addres...

Страница 167: ...this field should contain the address of a three byte area where the disk address of the previous record will be returned Otherwise it is unused Action Unless the length is zero the record preceding t...

Страница 168: ...ot active No action is taken BEGINNING OF FILE code D5 if the record indicated is the descriptor record of the file the pointer is positioned at the beginning and a previous record is meaningless No a...

Страница 169: ...ntal parameter information a pointer Action to a three byte area containing the disk address of the first record to be read The third byte of this area should be zero It is the calling program s respo...

Страница 170: ...possible errors INVALID REQUEST code Cl if the file is not open for random I O the read direct request will be rejected with this error All the errors of the READ BINARY request apply for the READ DIR...

Страница 171: ...sk address of the first record skipped will be returned Otherwise none Action The current record pointer is advanced through the file by the number of records indicated No data is transferred Possible...

Страница 172: ...SKIP FORWARD SKIP FORWARD FILE NOT OPEN code CB the logical unit being accessed is not active No action is taken 154...

Страница 173: ...address of a three byte area where the Action disk address of the record preceding the current one will be reported Otherwise none The current record pointer is moved backward through the file by the...

Страница 174: ...IP BACKWARD BEGINNING OF FILE code 05 the beginning of the file was reached without exhausting the given record count The pointer is left positioned on the descriptor with the first record of the file...

Страница 175: ...ess of a three byte area where the disk address of the last record in the file will be returned Otherwise it is unused Action The file is positioned with the current pointer indicating the last record...

Страница 176: ...re must be a pending assignment for it so that it can be opened If it is not already open it will be activated then its directory entry removed from the directory and a new one created An open scratch...

Страница 177: ...t or too full to allow creation of the descriptor record if renaming a scratch file FILE NOT IN PROPER DIRECTORY RECORD code 04 no directory entry for the file exists in the directory record indicated...

Страница 178: ...there have been any changes to the file or if there are attributes to be updated the descriptor is read updated and rewritten and the allocation map is rewritten The attributes of the file can be chan...

Страница 179: ...maps No action is taken INVALID ATTRIBUTES code D2 one or more of the attributes being supplied either is or was invalid The attributes checked are type there should be exactly one of the most signifi...

Страница 180: ...rn address Error return address Completion code Supplemental parameter information none Action The descriptor record is read and updated from the current information and the attributes supplied and re...

Страница 181: ...ttributes checked are type there should be exactly one of the most significant bits on and record length The attribute which was wrong is left as it was and the remainder of the process is carried on...

Страница 182: ...bute information such as the record count while a file is open The descriptor record is read the current information merged into it and as many bytes of attribute information as have been requested ar...

Страница 183: ...ERY ATTRIBUTES ATTRIBUTE LIST TRUNCATED code 84 this code is a warning and will not cause an error branch It indicates that more than 116 bytes of attribute information were requested Only 116 bytes w...

Страница 184: ...her file system functionally identical to the ZDOS file system which exists for the floppy disks The Disk File System DFS software is capable of running in two versions On the MCZ 1 20 the system is b...

Страница 185: ...use with optional floppy disk drives and is linked to run at the top of memory There is a separate entry point for the FLOPPY driver at two greater than the entry point for ZOOS When activating ZOOS...

Страница 186: ...unt Record length Block length currently unused and set to be same as record length File properties Starting execution address for procedure type files entry point Number of bytes in last record Date...

Страница 187: ...should be familiar with the disk manufacturer s recommended operations pro cedures provided in separate manuals These paragraphs are not intended to substitute for those documents Nevertheless we wil...

Страница 188: ...cked except when the stop light is on Also a cartridge must be in place and the oor closed to spin the disk up Any time there is a change in disks or a change in the ready status give an Initialize I...

Страница 189: ...ncludes the initial start up and serial message interface logic the bare disk controller which gives access to the disk by sector number for reads and writes and the self bootstrapping logic to read t...

Страница 190: ...tor address MAXID bytes 104 107 the current highest file ID This is incremented every time a new file is created ROOTPT bytes 108 110 the pointer to the root directory descriptor for the unit TFREE by...

Страница 191: ...y search The remainder of the sector is reserved for future use 7 4 2 DFS ALLOCATION ALGORITHM FREE O is a pointer to a sector whose contents are addresses of the next 100 elements of the free chain T...

Страница 192: ...varies most rapidly then the surface then the cylinder On drives which have one or more fixed platters and one removable platter the removable platter is considered to be a different physical drive th...

Страница 193: ...der o READ BINARY OAH transfers data from the disk starting at the requested sector until the byte count is satisfied then continues to the end of the sector The sector headers are not transferred WRI...

Страница 194: ...der address high order byte 4 surface byte 5 sector byte 6 8 backward pointer byte 9 11 forward pointer byte 12 13 data length always 200H byte 14 17 file ID byte 18 19 header CRC byte 20 24 zero WRIT...

Страница 195: ...causing them to be repeated until they are acknowledged The first step in reading the bootstrap is tQ read sector 0 of drive 1 the removable cartridge into a buffer If an error occurs at any point in...

Страница 196: ...son disk error or failure of a required condition the entire process will be repeated on drive O Should it also fail on drive 0 it will again try drive 1 continuing to alternate between drives until t...

Страница 197: ...apping consists of issuing I O requests to DFS as follows 1 Initialize 2 Open named file OS for input returning all attributes 3 For each segment issuing read binary requests for the data address and...

Страница 198: ......

Страница 199: ...on existent Command Illegal File Type Program Abort Insufficient Memory Missing or Invalid File Properties I O Error IY Vector Meaning Operation Complete Directory Format Error Scratch File Created Fi...

Страница 200: ...nvalid Attributes Disk Is Full File Not Found in Proper Directory Record Beginning of File Error File Already Open on Other unit Invalid Rename to Scratch File File Locked Attempt to Change Attr ibute...

Страница 201: ...P props 5 4 D drive I F format I L listing disposition I DATE rel date I CDATE reI date ul 5 5 file 1 file 2 5 6 file 1 file 2 A I U I 0 I 5 7 RL record length I T type s_d rive TO d_d r i ve V 5 8 fi...

Страница 202: ...ame command parameter_list S I D drive I ID disk name Q query key_wordl filename first location last location E entry point RL record length ST stack size device_name parameter list 1 dev ice_name mat...

Страница 203: ...n I ECHO ON I ECHO OFF I AUTOLF ON I AUTOLF OFF I PROPERTIES OF file name TO plist TYPE OF file name TO type I SUBTYPE OF fIle name TO subtype I ENTRY POINT OF file name TO nn I LOW ADDRESS OF file na...

Страница 204: ......

Страница 205: ...ddress BRKFLG 13CD OFC4 BRKRTN 13CE OFC5 CHRDEL 13CC OFC3 CONIBF 1189 OD8A CONIVC 1293 OECE CONOBF 1103 OD04 CONOVC 1288 OEC3 DATE 13AB OFA2 DEBUG OBFA OBFA DISK OBFD OBFD ENTRY 17DE 13DE ERCODE 13BD...

Страница 206: ......

Страница 207: ...file or files to be converted is inserted in one drive and the formatted RIO diskette on which the converted file is to reside is inserted in another For this example drive 2 has the RIO diskette and...

Страница 208: ...ERT DISKS OLD DISK IN DRIVE 2 FORMATTED RIO DISK IN DRIVE 0 TYPE RETURN OR Q TO TERMINATE The as 2 1 diskette is inserted into drive 2 and the RIO diskette is inserted into drive 0 after which carriag...

Страница 209: ...Monitor Debugger load file OS from drive 0 display and modify SYSFLG turn off EXTERNAL INITIALIZATION FLAG SAV O OS 1400 2BFF E 17DE RL 400 save new OS OS bootstrap new OS RIO SET PROPERTIES OF O OS...

Страница 210: ...l8E4 4F OD Q carriage return and quit SAV O OS 1400 2BFF E 17DE RL 400 OS E 2 save new as bootstrapping at this point will result in execution of the file BASIC...

Страница 211: ...equest Code Data Transfer Address Data Length Completion Address Error Return Address Completion Code Supplemental Parameter Vector Address ZDOS DFS Supplemental Parameter Vector o 1 2 3 I O Request C...

Страница 212: ...ine write Binary write Line write Current write Direct Delete Delete Remaining Erase File Read and Delete Read Current Read Previous Read Direct Skip Forward Skip Backward Skip to End Rename Update Se...

Страница 213: ...llowing commands may be used to edit assemble and link the example program EDIT filename S EDIT 1 6 NEW FILE INPUT QUIT ASM filename X ASM 5 7 PASS 1 COMPLETE o ASSEMBLY ERRORS ASSEMBLY COMPLETE LINK...

Страница 214: ...EFW LMSG BYTE COUNT OOOE 0000 16 AVCRA DEFW 0 COMPLETION RETURN 17 ADDRESS 0010 0000 18 AVERA DEFW 0 ERROR RETURN ADDRESS 0012 00 19 AVCC DEFB 0 COMPLETION CODE 20 21 EQUATES AND CONSTANTS 22 23 SYSTE...

Страница 215: ...SYMBOL VAL M DEFN REFS AVLUN 0008 R 11 AVREQ 0009 R 12 CONOUT 0002 24 11 LMSG 0024 30 15 MSG 0013 R 28 13 30 SYSTEM 1403 23 6 WRTLIN 0010 25 12 G 3...

Страница 216: ...O 16 LDI MOVE CHARACTER AND INC 17 POINTERS 0014 18F3 18 JR SCAN 19 0016 EB 20 ADDCHR EX DE HL 0017 360D 21 LD HL ODH COULD HAVE BEEN A I I 0019 OB 22 DEC BC 23 OOIA 79 24 LD A e GET STRING LENGTH 001...

Страница 217: ...EQU 10H iWRITE LINE REQUEST 53 CODE 54 INPTR EQU 13C4H PARAMETER LIST POINTER 55 0037 56 BUFFER DEFS 80 57 END CROSS REFERENCE EXAMPLE2 MCZ SYMBOL VAL M DEFN REFS ADDCHR 0016 R 20 13 15 AVCC 0036 R 4...

Страница 218: ...j SUPPLEMENTAL 20 jPARAMETER VECTOR 0017 225A01 R 21 LD AVSVP HL 001A 210000 22 LD HL O jCLEAR ERROR RETURN 23 jADDRESS 0010 225701 R 24 LD AVERA HL jFOR NORMAL ERROR 25 iRETURN 0020 FD214F01 R 26 LD...

Страница 219: ...AL FILE TYPE 0060 32BD13 62 LD ERCODE A 0063 C3F900 R 63 JP CLOSEF 64 65 66 iFILE IS OF TYPE ASCII 67 68 69 PRT100 0066 3EOO 70 LD A O iALLOCATE 0068 210000 71 LD HL O 006B 11FFFF 72 LD DE l iLOCATE L...

Страница 220: ...LD A AVCC READ ERROR OOAB CB77 110 BIT 6 A OOAD 280B III JR Z WRITE OOAF FEC9 112 CP EOF iYES HAS IT AN END 113 OF FILE OOBI 2024 114 JR NZ ERROR 00B3 2A5301 R 115 LD HL AVDL 00B6 7C 116 LD A H YES AN...

Страница 221: ...UTPUT UNIT OODE 324F01 R 159 LD AVLUN A 00E1 214801 R 160 LD HL EMSGN CONVERT ERROR CODE TO 161 ASCII 00E4 3A5901 R 162 LD A AVCC 00E7 CD2401 R 163 CALL BTOHEX 164 OOEA 213E01 R 165 LD HL EMSG PRINT M...

Страница 222: ...F 204 RRA 0129 CD3201 R 205 CALL HBTHEX iCONVERT HIGH ORDER 206 i4 BITS 012C F1 207 POP AF RESTORE A 012D 23 208 INC HL 012E CD3201 R 209 CALL HBTHEX iCONVERT LOW ORDER 4 210 BITS 0131 C9 211 RET 212...

Страница 223: ...ERCODE EQU 13BDH ERROR CODE LOCATION 256 SYSTEM EQU 1403H SYSTEM CALL ADDRESS 257 MEMMGR EQU 1409H MEMORY MANAGER ADDRESS 258 013E 492F4F20 259 EMSG DEFM I I O ERROR I 0148 260 EMSGN DEFS 2 014A OD 2...

Страница 224: ...EFN REFS ASCII 0020 248 59 ASSIGN 0002 237 10 ASVFT 017F R 292 43 57 293 AVCC 0159 R 275 28 49 109 129 146 162 AVCRA 0155 R 272 AVDL 0153 R 271 47 97 115 168 179 AVDTA 0151 R 270 18 45 95 166 177 AVEC...

Страница 225: ...09 257 74 90 191 OPEN 0004 238 36 OPNINP 0000 241 38 PRT100 0066 R 69 60 ROBIN OOOA 234 103 REAO 0097 R 103 149 SPV 015C R 279 19 SPVORV 0150 R 284 SPVFB 015C R 282 15 SPVFN 015F R 286 SPVFNL 015E R 2...

Страница 226: ......

Страница 227: ...APPENDIX H INTERNAL COMMAND TABLE CONTENTS Debug Initialize Brief Verbose Xeq Allocate DEAllocate Release Force Close expression evaluation H l...

Страница 228: ......

Страница 229: ...upper address BC required size After MEMMGR CALL boundary boundary bytes A 80 operation complete HL beginning address of hole DE ending address of hole BC size of hole bytes A 4A insufficient memory...

Страница 230: ......

Страница 231: ...ry for this file Pointer to first data record of file Pointer to last data record of file Type of file see description under the OPEN request Record count Record length Block length currently unused a...

Страница 232: ...s are the starting address of the segment and the second 2 bytes are the length of the segment in bytes After the the last segment descriptor is a null descriptor where each of the 4 bytes are zero Lo...

Страница 233: ...ECT READ PREVIOUS RENAME REWIND SET ATTRIBUTES SKIP BACKWARD SKIP FORWARD SKIP TO END UPDATE vRITE BINARY WRITE CURRENT Request Code K l 02 03 06 07w 16 17 18 19 lA lB 00 01 04 05 30 31 1C lD OA OB 1E...

Страница 234: ......

Страница 235: ...O ECHO PAUSE IMAGE The command files RELINK MCZ COMMAND and RELINK ZDS COMMAND are on the MCZ and ZDS system disks respectively These command files use the specified object file and link the command a...

Страница 236: ...EXAMPLES DO RELINK MCZ COMMAND DO OCOOO DO RELINK ZDS COMMAND IMAGE OFOOO RL 400 L 2...

Страница 237: ...t Number ____________________________ Your Hardware Model and Memory Size ____________________ Describe your likes dislikes concerning this document Technical Information Supporting Diagrams Ease of U...

Страница 238: ...REPLY MAIL FIRST CLASS PERMIT NO 475 CUPERTINO CA POSTAGE WILL BE PAID BY ADDRESSEE Zilog Manager Systems Publications 10460 Bubb Road Cupertino California 95014 NO POSTAGE NECESSARY IF MAILED IN THE...

Страница 239: ...provides changed pages for the publication specified above These changed pages will remain in effect for subsequent releases unless specifically amended by another DCN or superseded by a publication r...

Страница 240: ...ove T taese ch ange pages will rema in tt effect for subseq uent rel C1A es lnless sp cifi ally amended y another DeN 0 supers e d by a put lJp ation visioq The following page J e to be t r e at d as...

Страница 241: ...Zilog Inc 10460 Bubb Road Cupertino California 95014 Telephone 408 446 4666 TWX 910 338 7621 Printed in USA...

Отзывы: