http:^^osl.csc.ncsu.edu^departmental^labs^osl-lab.html

来自「This data set contains WWW-pages collect」· HTML 代码 · 共 620 行 · 第 1/2 页

HTML
620
字号
Date: Tue, 26 Nov 1996 00:08:22 GMT
Server: NCSA/1.5.2
Last-modified: Mon, 29 Jan 1996 15:38:25 GMT
Content-type: text/html
Content-length: 21535

<HTML><p align=center><!WA0><a href="http://www.csc.ncsu.edu/cgi-bin/imagemap/header-all" ><!WA1><img src="http://www.csc.ncsu.edu/graphics/headers/pic/all.gif" ISMAP ALT="Menubar"></a><HEAD> <TITLE>Operating Systems LaboratoryOrganization and Tools</TITLE></HEAD><H2 ALIGN=center>Operating Systems<BR>Laboratory Organization and Tools</H2><H3 ALIGN=center><I>Carol Miller</I></H3><H4 ALIGN=center><I>HTML by William Hicks and Earl Shannon</I></H4><H3 align=center><a name="table">Table of Contents<br><!WA2><a href="#intro">Introduction</a><br><!WA3><a href="#tools">Operating System Development Tools</a><br></h3><h4 align=center><!WA4><a href="#xcc">xcc</a><!WA5><a href="#as">as</a><!WA6><a href="#down">download</a><!WA7><a href="#odt">odt</a><!WA8><a href="#busers">busers</a><!WA9><a href="#xinu8">Xinu8</a></h4><br><h3 align=center><!WA10><a href="#develop">Program Development Example</a><br><!WA11><a href="#trouble">Troubleshooting</a><br></h3><HR><a name="intro"><H3>Introduction:</H3> The Operating Systems Laboratory of the Computer ScienceDepartment is provided for students enrolled in upper level undergraduateand graduate operating system courses.  This document contains a descriptionof the computers in the lab and the software development tools availableto students in these advanced classes.<BR><HR><BR><H3>Laboratory Configuration</H3>The Operating Systems Laboratory, often referred to as OSL, for the ComputerScience Department is located in Daniels 205.  This lab is a vital resourcefor two undergraduate courses (CSC 451 and CSC 452) and the graduate levelreal-time operating systems course (CSC 574). The computers in the laboratoryfor CSC 451 consist of a single Sun Sparc and five Sun 3/60 Xinu clients,named friedpie, fishstick, onionring, tatortot, and frenchfry. <BR><H4>Hushpuppy</H4>The Sparc workstation, known as hushpuppy, is where student accounts are located and Xinu software development is done.  Hushpuppy uses the SunOSoperating system which is a 4.3 version of UNIX with System V release 3.2extensions.  It is connected to the campus network via ethernet and usesTCP/IP to communicate with other machines.  Hushpuppy can also be reachedby using a Hayes compatible modem through the NCSU Campus dataswitch, university terminal servers, or from other computer systems via Internetusing the address hushpuppy.csc.ncsu.edu or just plain hushpuppy if you arecurrently in the NCSU Internet Domain.<p>To telnet to hushpuppy you can also just click<!WA12><a href = "telnet://hushpuppy.csc"> here.</a><BR><p>SunOS has many of the commands found on other campus machines such as aza,the Eos workstations, and garfield, some of which are running Digital Equipment's ULTRIX.  Familiarity with any of these systems will allow youto quickly become comfortable using SunOS.  Help is available via theon-line manuals commonly called man pages.  The following is an exampleto show how to display man pages for the SunOS command ls, which willlist the contents of a directory.<BR><BR><CODE><PRE>	sun4-%man ls</PRE></CODE><BR>Hushpuppy responds with:<BR><CODE><PRE>		reformatting page. Wait... done	LS(1V)			USER COMMANDS			LS(1V)	NAME ls - list the contents of a directory	SYNOPSIS ls [-aAcCdfFgilLqrRstu1 ] filename ...	SYSTEM V SYNOPSIS /usr/5bin/ls [-abcCdfFgilLmnopqrRstux] filename ...</PRE></CODE>and continues with the remaining information on the ls command.<BR><H4>Xinu Clients</H4>There are five Xinu clients.  They are named fishstick, frenchfry, onionring,tatortot, and friedpie.  They are Sun 3/60 with 8 or 4 megabytes of RAM, twoserial ports, an ethernet connection, and a SCSI port.  The console port(one of the two serial ports) on each of the five clients is connected tohushpuppy via a multiplexer.  This connection allows the server machine toact as a front end to the Xinu client and eliminates the need for an additional terminal.  The operating system also suppports a terminal connected to the second serial port, but which is not currently configured.<BR> The five target machines (clients) are connected to each other and tohushpuppy through an ethernet network.  It is through this connection theclients download Xinu executables created on the Sparc (hushpuppy). Devices such as hard disks, CD-ROMs, and scanners can be connected to theSun via the SCSI port.<BR><p><!WA13><a href="#table">Contents</a><hr><a name="tools"><H3>Operating System Development Tools</H2>Xinu is a small operating system originally designed for the Digital EquipmentLSI 11 computer but has been transported to other platforms; it is for thisreason that a Xinu target machine is sometimes called an LSI.  Written by Douglas Comer and associates at Purdue University, Xinu and its developmenttools are used to explore the different aspects of operating system design.Xinu Version 6 is discussed in Comer's book Operating System Design, TheXinu Approach volume one.  Volume two of this text covers Xinu Version 7.Xinu 6 is currently installed on hushpuppy and can be found in the directory /usr/Xinu/.  The C and MC68030 assembly source files for Xinu 6 are locatedin the directory /usr/Xinu/src, Xinu header files are in /usr/Xinu/include/,and the library files are located in /usr/Xinu/lib/.<BR><a name="xcc"><H4>xcc: C Compiler for Xinu</H4>The command xcc invokes the C compiler, assember, and loader to produceobject files, Motorola MC68030 assembly language files, or Xinu executablesfrom input files located on hushpuppy.  The input files can be C source files,Motorola 680xx assembly source files, object files, or libraries of objectfiles.  The distinction between the different types of files is made by the suffix of the file name:<BR><PRE>	Suffix		File Type	.c		C source code	.s		MC680xx assembly source	.o 		object file	.a		object file library</PRE>For example, xcc would assume the files main.c, io.c, and control.c to be C source code and the file lowlevel.s to be an assembly module.  It is recommended that you use xcc to assemble routines written in assembly language.<BR>Below are the switches (options sent to programs via the command line) thatxcc understands.<BR><PRE>	Switch		Purpose	-c		To suppress the loading(linking) phase of the			compilation, and force xcc to stop after			producing '.o' files from source programs.	-o output	To name the final output file output.	-v		Verbose output narrating each step of the A			compile.	-Dname		Define name to the preprocessor, as if by the			#define directive.	-E		Run only the macro preprocessor on the named			C programs, and send the result to standard			output.	-Idir		#include files whose names do not begin with 'I'			are always sought first in the directory of			the file argument, the in directories named in			the -I options, then in directories on a 			standard list.	-O		Invoke the object-code improver as part of the			C compilation.	-P 		Run only the macro preprocessor on the named C			programs, and send the result to corresponding			files suffixed with .i.	-S		Compile the named C programs into assembly			language, and leave the asembly-language output			in corresponding files suffixed with .s, without			assembling or loading the result.	-L		Include the standalone startup routine to allow			downloading without Xinu.  The xcc command can be			used to generate modules for downloading that do			not contain the Xinu operating system.  The -L			switch is used to create this standalone object file.			When a standalone module is mode, the linker uses 			the libsa.a library of functions instead of the usual			libx.a and libc.a.			</PRE>For example, to compile a C source file named main.c, an assembly listingnamed lowlevel.s, and the object io.o into an executable named prog1 usexcc in the following way:<BR><PRE>	xcc -o prog1 main.c lowlevel.s io.o</PRE>For more information about the above options, consult the man pages on theSun C compiler (cc command).<BR><a name="as"><H4>as: MC680xx Assembler</H4>The Sun 3/60's are based upon the Motorola 68000 family of microprocessors.The command as can be used to assemble 680xx source files into machinecode, however the resulting binary file in not in the proper format fordownloading.  It is for this reason that you are encouraged to use xcc todo all your assembling.  The assemble the file setup.s, enter:<PRE>	xcc setup.s</PRE><a name="down"><H4>download: Download Executable to Xinu Client</H4>The download command loads the absolute binary program image produced byxcc into the memory of the target machine.  The name of the file to download can be provided as an argument otherwise the name a.out is assumed.  The -m<machine_name> option can be used to select a 3/60 to send your binaries to,otherwise any available client machine is used.  For example:<PRE>	download -mfishstick prog1 </PRE>will download the file prog1 to fishstick.  If no client is available(all are reserved by other users) then download will display an errormessage.<BR><a name="odt"><H4>odt: Connect the User Terminal to the Console Port on the Xinu Client</H4>The command odt takes it name from the on-line debugging technique (odt)feature of the LSI 11 and PDP 11 computers.  This feature is a ROM-basedmonitor which accepts console keyboard commands.  The name odt has been kept for historical reasons and to provide uniformity across different Xinuplatforms.  The development tool odt is used to connect the user'sterminal to the console port on a client machine.  Input from the keyboardis sent to the 3/60 and output for the 3/60 is displayed on your terminal.<BR>To run a downloaded program, enter odt at the prompt on the server machine.You will see a message telling you to which 3/60 you are being connected.This will automatically be the machine you selected previously when youdownloaded your executable.  Press &ltReturn> a few times until a >prompt appears.  If you do not get a prompt or if it seems that a programis already running on the client then enter the key sequence \ (the backslashcharacter) followed by &ltControl-@> repeatedly until the 3/60 respondswith the correct prompt.  Enter b at the prompt to boot the client.  Thiswill load Xinu and your executable into the memory of the machine.  Startyour program by typing g 4000 and pressing <Return>.  Below is an exampleusing the above instructions.<BR><PRE>	sun4-%download prog1	using front end 'hushpuppy':   Using backend 'fishstick'	downloading file: prog1	Sent Xk bytes 	download completed</PRE>Note: The X in the line Sent Xk bytes will be some number. <PRE>	sun4-%odt	using front end 'hushpuppy':   Using backend 'fishstick'	Using /dev/ttyX</PRE>Note: The X in the line Using /dev/ttyX will be a device name such as m00.<PRE>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?