OS-9 Technical User Manual Is Designed for You to Use in Conjunction with the OS-9 Technical I/O User Manual
Total Page:16
File Type:pdf, Size:1020Kb
OS-9 Technical User Manual Copyright and Revision Copyright 1991 Microware Systems Corporation. All Rights Reserved. History Reproduction of this document, in part or whole, by any means, electrical, mechanical, magnetic, optical, chemical, manual, or otherwise is prohib- ited, without written permission from Microware Systems Corporation. Publication Editors: Walden Miller, Kathleen Flood, Debbie Baier Contributing Writers: Warren Brown, Richard Yeates Revision: J Publication date: March 1991 Product Number: OST68NA68MO Disclaimer The software described in this document is intended to be used on a single computer system. Microware expressly prohibits any reproduction of the software on tape, disk or any other medium except for backup purposes. Distribution of this software, in part or whole, to any other party or on any other system may constitute copyright infringements and misappropriation of trade secrets and confidential processes which are the property of Microware and/or other parties. Unauthorized distribution of software may cause damages far in excess of the value of the copies involved. For additional copies of this software and/or documentation, or if you have questions concerning the above notice, the documentation and/or software, please contact your OS-9 supplier. Trademarks Microware, OS-9, and RAVE are registered trademarks of Microware Systems Corporation. Microware Systems Corporation • 1900 N.W. 114th Street Des Moines, Iowa 50325-7077 • Phone: 515/224-1929 Preface Introduction Manual Organization The OS-9 Technical User Manual is organized into two main sections: The OS-9 Technical Overview is covered in chapters 1 through 7 and Appendix A, B and C; OS-9 System Calls is covered in Appendix D. The OS-9 Technical Overview contains the following chapters and appendices: Chapter 1 – System Overview Provides a general overview of OS-9’s four levels of modularity, I/O processing, memory modules, and program modules. Chapter 2 – The Kernel Outlines the responsibilities of the kernel. Explains user and system state processing, memory management, system initialization, process creation and scheduling, and exception and interrupt processing. Chapter 3 – OS-9 Input/Output System Explains the software components of the OS-9 I/O system and the relationships between those components. Chapter 4 – Interprocess Communications Describes the five forms of interprocess communication supported by OS-9: signals, alarms, events, pipes, and data modules. Chapter 5 – User Trap Handlers Explains how to install and execute trap handlers, and provides an example of trap handler coding. Chapter 6 – The Math Module Discusses math module functions, and lists descriptions of the assembler calls you can use with the math module. Chapter 7 – RBF File System Explains OS-9’s disk file organization, raw physical I/O on RBF devices, record locking, and file security. i Preface Appendix A – Example Code Contains example code that you can use as a guide when creating your own modules. Provides examples of RBF, SCF, and SBF device descriptors. Appendix B – Path Descriptors and Device Descriptors Includes the device descriptor initialization table definitions and path descriptor option tables for RBF, SCF, SBF, and PIPEMAN type devices. Appendix C – OS-9 System Calls contains descriptions for the following types of system calls: User-State System Calls I/O System Calls System-State System Calls The OS-9 Technical User Manual is designed for you to use in conjunction with the OS-9 Technical I/O User Manual. ii Table of Contents OS-9 Technical User Manual System Overview Chapter 1 System Modularity. 1-1 I/O Overview. 1-3 The Kernel Chapter 2 Responsibilities of the Kernel. 2-1 System Call Overview. 2-1 Memory Management. 2-5 System Initialization. 2-12 Process Creation. 2-18 Process Scheduling. 2-22 Exception and Interrupt Processing. 2-24 OS-9 Input/Output System Chapter 3 The OS-9 Unified Input/Output System. 3-1 The Kernel and I/O. 3-2 File Managers. 3-6 Device Driver Modules. 3-10 Interprocess Chapter 4 Communications Signals. 4-1 Alarms. 4-3 Events. 4-6 Pipes. 4-8 Data Modules. 4-13 User Trap Handlers Chapter 5 Trap Handlers. 5-1 Installing and Executing Trap Handlers. 5-2 OS-9 and tcall: Equivalent Assembly Language Syntax. 5-2 Calling a Trap Handler. 5-3 An Example Trap Handler. 5-5 Trace of Example Two Using the Example Trap Handler. 5-8 I Table of Contents OS-9 Technical User Manual The Math Module Chapter 6 The Standard Function Library Module. 6-1 Calling Standard Function Module Routines. 6-2 Data Formats. 6-2 The Math Module. 6-3 T$Acs. 6-5 T$Asn. 6-6 T$Atn. 6-7 T$AtoD. 6-8 T$AtoF. 6-9 T$AtoL. 6-10 T$AtoN. 6-11 T$AtoU. 6-12 T$Cos. 6-13 T$DAdd. 6-14 T$DCmp. 6-15 T$DDec. 6-16 T$DDiv. 6-17 T$DInc. 6-18 T$DInt. 6-19 T$DMul. 6-20 T$DNeg. 6-21 T$DNrm. 6-22 T$DSub. 6-23 T$DtoA. 6-24 T$DtoF. 6-25 T$DtoL. 6-26 T$DtoU. 6-27 T$DTrn. 6-28 T$Exp. 6-29 T$FAdd. 6-30 T$FCmp. 6-31 T$FDec. 6-32 T$FDiv. 6-33 T$FInc. 6-34 T$FInt. 6-35 T$FMul. 6-36 T$FNeg. 6-37 T$FSub. 6-38 T$FtoA. 6-39 T$FtoD. ..