Enhanced OS-9 for the PID7T Board Guide version 1.2

Enhanced OS-9 for the PID7T Board Guide version 1.2 Enhanced OS-9 for the PID7T Board Guide version 1.2

rab.ict.pwr.wroc.pl
from rab.ict.pwr.wroc.pl More from this publisher
12.07.2015 Views

Enhanced OS-9for the PID7TBoard GuideVersion 1.2Intelligent Products For A Smarter World

<strong>Enhanced</strong> <strong>OS</strong>-9<strong>for</strong> <strong>the</strong> <strong>PID7T</strong><strong>Board</strong> <strong>Guide</strong>Version <strong>1.2</strong>Intelligent Products For A Smarter World


Copyright and Publication In<strong>for</strong>mationCopyright ©2000 Microware Systems Corporation. All Rights Reserved. Reproduction ofthis document, in part or whole, by any means, electrical, mechanical, magnetic, optical,chemical, manual, or o<strong>the</strong>rwise is prohibited, without written permission from MicrowareSystems Corporation.This manual reflects Version <strong>1.2</strong> of <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> StrongARM.Revision:CPublication date: April 2000DisclaimerThe in<strong>for</strong>mation contained herein is believed to be accurate as of <strong>the</strong> date of publication.However, Microware will not be liable <strong>for</strong> any damages including indirect or consequential,from use of <strong>the</strong> <strong>OS</strong>-9 operating system, Microware-provided software, or reliance on <strong>the</strong>accuracy of this documentation. The in<strong>for</strong>mation contained herein is subject to changewithout notice.Reproduction NoticeThe software described in this document is intended to be used on a single computersystem. Microware expressly prohibits any reproduction of <strong>the</strong> software on tape, disk, orany o<strong>the</strong>r medium except <strong>for</strong> backup purposes. Distribution of this software, in part orwhole, to any o<strong>the</strong>r party or on any o<strong>the</strong>r system may constitute copyright infringementsand misappropriation of trade secrets and confidential processes which are <strong>the</strong> property ofMicroware and/or o<strong>the</strong>r parties. Unauthorized distribution of software may cause damagesfar in excess of <strong>the</strong> value of <strong>the</strong> copies involved.For additional copies of this software/documentation, or if you have questions concerning<strong>the</strong> above notice, please contact your <strong>OS</strong>-9 supplier.Trademarks<strong>OS</strong>-9, <strong>OS</strong>-9000, DAVID, and MAUI are registered trademarks of Microware SystemsCorporation. SoftStax, FasTrak, UpLink, and Hawk are trademarks of Microware SystemsCorporation. All o<strong>the</strong>r product names referenced herein are ei<strong>the</strong>r trademarks orregistered trademarks of <strong>the</strong>ir respective owners.AddressMicroware Systems Corporation1500 N.W. 118th StreetDes Moines, Iowa 50325515-223-80002 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Table of ContentsChapter 1: Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM 79 Requirements and Compatibility9 Host Hardware Requirements (PC Compatible)9 Host Software Requirements (PC Compatible)9 Target Hardware Requirements10 <strong>OS</strong>-9 <strong>for</strong> ARM Architecture12 Configure <strong>Board</strong> Switch Settings14 Installing <strong>the</strong> Flash Devices15 Connecting <strong>the</strong> Target <strong>Board</strong> to <strong>the</strong> Host PC17 Configuring Your ATA Card (Optional)18 Creating and Configuring a ROM Image18 Terminology18 Valid Configurations22 Building a ROM Image <strong>for</strong> Networking26 Connecting <strong>the</strong> Target to an E<strong>the</strong>rnet Network (Optional)27 Pinging <strong>the</strong> Target28 Creating a new <strong>OS</strong>-9 Coreboot Image in Flash Memory (Optional)28 Making a Coreboot Image with an EPROM programmerChapter 2: <strong>Board</strong> Specific Considerations 3132 Low-Level System Modules36 Boot Options36 Booting from FLASH36 Booting from PCMCIA ATA Card37 Booting from PCMCIA E<strong>the</strong>rnet Card37 Restart Booter37 Break Booter<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 3


38 Example Boot Session and Message39 High-Level System Modules39 CPU Support Modules39 System Configuration Modules40 Interrupt Controller Support40 Vector Module40 Ticker40 Abort Handler41 Generic IO Support Modules (File Managers)41 Pipe Descriptor41 RAM Disk Support42 RAM Disk Descriptors42 Serial and Console Devices42 sc16550 Descriptors43 scllio Descriptors43 PCMCIA Support <strong>for</strong> IDE type Devices43 rb1003 Descriptors44 PCMCIA Support <strong>for</strong> 3COM E<strong>the</strong>rnet card44 spe509_pcm Descriptors44 Network Configuration Modules45 <strong>OS</strong>9 Vector Mappings49 Port Specific UtilitiesChapter 3: <strong>OS</strong>-9 ROM Image Overview 5354 Types of ROM Images54 Coreboot Image57 ROMCore58 Bootfile Image61 Coreboot and Bootfile Image62 Boot Menu Options64 Debuggers64 Microware Hawk64 RomBug4 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


6 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Chapter 1: Installing and Configuring<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMThis chapter describes installing and configuring <strong>Enhanced</strong> <strong>OS</strong>-9 on<strong>the</strong> ARM LTD ARM7TDMI Microprocessor Reference Plat<strong>for</strong>m (<strong>PID7T</strong>)as <strong>the</strong> target plat<strong>for</strong>m. Be<strong>for</strong>e you begin, complete <strong>the</strong> following tasks:• You successfully installed <strong>the</strong> <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM CD-ROMonto your host PC.• You are familiar with your board’s features and capabilities.This chapter includes <strong>the</strong> following sections:• Requirements and Compatibility• <strong>OS</strong>-9 <strong>for</strong> ARM Architecture• Configure <strong>Board</strong> Switch Settings• Installing <strong>the</strong> Flash Devices• Connecting <strong>the</strong> Target <strong>Board</strong> to <strong>the</strong> Host PC• Configuring Your ATA Card (Optional)• Creating and Configuring a ROM Image• Connecting <strong>the</strong> Target to an E<strong>the</strong>rnet Network (Optional)• Creating a new <strong>OS</strong>-9 Coreboot Image in Flash Memory(Optional)7


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMNotePlease refer to your reference board’s hardware documentation <strong>for</strong>in<strong>for</strong>mation on hardware preparation and installation, operatinginstructions, and functional descriptions prior to installing andconfiguring <strong>OS</strong>-9.NoteThese procedures can be per<strong>for</strong>med with o<strong>the</strong>r ARM referenceplat<strong>for</strong>ms. You will need to modify <strong>the</strong> procedures as necessary <strong>for</strong> yourparticular target plat<strong>for</strong>m.8 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMRequirements and Compatibility1Host Hardware Requirements (PC Compatible)Your host PC should have <strong>the</strong> following:• Windows 95, Windows 98, or Windows NT• A minimum of 32MB of free disk space• An E<strong>the</strong>rnet network card• A PCMCIA card reader/writer• At least 16MB of RAMHost Software Requirements (PC Compatible)Your host PC should have a terminal emulation program (such asHyperterminal that comes with Microsoft Windows 95, Windows 98,and Windows NT).Target Hardware RequirementsYour reference board requires <strong>the</strong> following hardware:• Enclosure or chassis with power supply• A RS-232 null modem serial cable<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 9


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM<strong>OS</strong>-9 <strong>for</strong> ARM ArchitectureThe source and example code and makefiles <strong>for</strong> <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong>ARM are located in <strong>the</strong> following directory. The directory structure isshown in Figure 1-1.\mwos\<strong>OS</strong>9000\ARMV4\PORTS\<strong>PID7T</strong>\Figure 1-1 <strong>OS</strong>-9 <strong>for</strong> ARM DirectoriesBOOTSCMDSHWLIBLIBPCFPCMCIABOOTOBJSH<strong>OS</strong>T2RB1003INSTALLBMPINIPORTBOOTDESCRAMRB1003INITDDNODISKH<strong>OS</strong>T3DESCPICLIBPIPESPFSC16550WINDOWSSCLLI<strong>OS</strong>YSTEMSINITSPORTBOOTROMPORTBOOTSPFNoteSome directories are shipped only with OEM licenses.10 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMFigure 1-1 <strong>OS</strong>-9 <strong>for</strong> ARM Directories (continued)1RBFROMSCFSPFSYSMODSUTILSRAMIRQSABORTDESCARMTIMRSC16550ETCTICKERPCMCIACNFGDATADESCRB1003CNFGFUNCDRVRSPE509DESCCOMMCNFGDEFSDRVRCONSCNFGSCLLIOIDEDESCIO16550LLCISLLE509PORTMENUROMCOREUSEDEBUG<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 11


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMConfigure <strong>Board</strong> Switch SettingsFor proper operation <strong>the</strong> <strong>PID7T</strong> must have <strong>the</strong> following switch settings.For more in<strong>for</strong>mation see <strong>the</strong> <strong>PID7T</strong> Development Card Manual.Table 1-1 <strong>PID7T</strong> Switch SettingsJumper Position CommentLK4 open Little EndianLK7openLK8 closed Set Edge interrupt <strong>for</strong> switchLK9openLK10 closed Enable abort switch interruptLK18 closed Boot from ROM (ROM at 0).LK17openTable 1-2 <strong>PID7T</strong> Switch SettingsJumperBlock Position 1-x CommentLK6LK16closed, open, open,openopen, closed,closed, closedBoot from U12 EEPROM, 512k,speed=120ns, width=8bitLK11 (all open 1-8) Parallel port defines12 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMTable 1-3 <strong>PID7T</strong> Switch Settings1SwitchBlock Position 1-x CommentS1 off, off, on, on 20Mhz operationS2S3on,on,on,off,on,on,on,offoff,off,off,offSRAM settings (change able asdesired)SLOT A Must be populated with a 4meg or larger DRAM part.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 13


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMInstalling <strong>the</strong> Flash DevicesNoteIf you have not been shipped an EPROM, see <strong>the</strong> Connecting <strong>the</strong>Target <strong>Board</strong> to <strong>the</strong> Host PC section first.The first stage in configuring your reference board is to install <strong>the</strong>pre-loaded FLASH device included in your <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMpackage. This device includes a coreboot system that has beenpre-configured to get your board up and running quickly. Install <strong>the</strong>FLASH device in socket U12.Figure 1-2 Installing <strong>the</strong> Flash DevicesPCMCIA SocketsU12NoteIf you need to reprogram <strong>the</strong> flash device or create a new flash device,see <strong>the</strong> Connecting <strong>the</strong> Target <strong>Board</strong> to <strong>the</strong> Host PC section.14 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMConnecting <strong>the</strong> Target <strong>Board</strong> to <strong>the</strong> Host PC1Connect an RS-232 null modem cable from <strong>the</strong> reference board to <strong>the</strong>serial port of a Windows 95, Windows 98, or Windows NT system.Step 1.Step 2.Step 3.Step 4.Step 5.Step 6.Step 7.Step 8.Connect <strong>the</strong> serial cable to <strong>the</strong> PL4 connector on <strong>the</strong> reference board.The PL4 connector is serial port 1.Connect <strong>the</strong> o<strong>the</strong>r end of <strong>the</strong> serial cable to <strong>the</strong> Host PC.On <strong>the</strong> Windows desktop, click on <strong>the</strong> Start button and selectPrograms -> Accessories -> Hyperterminal.Click <strong>the</strong> Hypertrm icon and enter a name <strong>for</strong> your Hyperterminalsession.Select an icon <strong>for</strong> <strong>the</strong> new Hyperterminal session. A new icon is createdwith <strong>the</strong> name of your session associated with it. The next time youwant to establish <strong>the</strong> same session, follow <strong>the</strong> directions in Step 3 andlook <strong>for</strong> <strong>the</strong> icon you created in Step 4.Click OKIn <strong>the</strong> Phone Number dialog, go to <strong>the</strong> Connect Using box, and select <strong>the</strong>communications port to be used to connect to <strong>the</strong> reference board.The port selected is <strong>the</strong> same port that you connected to <strong>the</strong> serialcable from <strong>the</strong> reference board.Click OK<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 15


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMStep 9. In <strong>the</strong> Port Settings tab, enter <strong>the</strong> following settings:Bits per second = 19200Data Bits = 8Parity = NoneStop bits = 1Flow control = XOn/XOffFigure 1-3 Port SettingsStep 10.Step 11.Step 12.Click OK.Go to <strong>the</strong> Hyperterminal menu and select Call -> Connect from <strong>the</strong>pull-down menu to establish your terminal session with <strong>the</strong> referenceboard. If you are connected, <strong>the</strong> bottom left of your Hyperterminalscreen will display <strong>the</strong> word connected.Turn on <strong>the</strong> reference board. The <strong>OS</strong>-9 bootstrap message is displayed.16 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMConfiguring Your ATA Card (Optional)1You can use your ATA card to validate that your reference board isoperational without requiring <strong>the</strong> connection to <strong>the</strong> host machine:To configure <strong>the</strong> ATA card:Step 1.Step 2.Step 3.Step 4.From a D<strong>OS</strong> prompt on <strong>the</strong> host machine, navigate to <strong>the</strong> followingdirectory:MW<strong>OS</strong>\<strong>OS</strong>9000\ARMV4\PORTS\<strong>PID7T</strong>\BOOTS\SYSTEMS\PORTBOOTand run os9make.On <strong>the</strong> host machine, copy <strong>the</strong> files located in <strong>the</strong> following directory:MW<strong>OS</strong>\<strong>OS</strong>9000\ARMV4\PORTS\<strong>PID7T</strong>\BOOTS\SYSTEMS\PORTBOOT\os9kbootinto <strong>the</strong> root directory to <strong>the</strong> ATA cardInstall <strong>the</strong> card in socket 1 (top) on <strong>the</strong> reference boardTurn on <strong>the</strong> reference board.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 17


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMCreating and Configuring a ROM ImageThe <strong>OS</strong>-9 ROM image enables booting from PCMCIA IDE type cards.Use <strong>the</strong> Configuration Wizard to create an <strong>OS</strong>-9 ROM image to save in<strong>the</strong> root directory of <strong>the</strong> PCMCIA card. The Configuration Wizard wasinstalled on your host PC during <strong>the</strong> <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMinstallation process.There are several valid configurations <strong>for</strong> generating a ROM Image <strong>for</strong><strong>the</strong> <strong>PID7T</strong> target board. Each of <strong>the</strong>se configurations will use somecombination of <strong>the</strong> <strong>OS</strong>-9 low-level and high-level systems. The low levelsystem initializes <strong>the</strong> target and <strong>the</strong>n finds and starts <strong>the</strong> high levelsystem. The low level system is typically stored on a small boot part(~128Kb FLASH). The high level system is usually stored on a largerflash part or on o<strong>the</strong>r sources such as an ATA-PCMCIA card, or onano<strong>the</strong>r machine (which requires booting via bootp). For <strong>the</strong> <strong>PID7T</strong>, youcan create boots of <strong>the</strong> following configurations:TerminologyROM Image = High-Level boot + Low-Level bootHigh Level boot = bootfile (or os9kboot)Low Level boot = corebootValid Configurations• Entire ROM Image on <strong>the</strong> 512k FLASH part.• Low-level system on <strong>the</strong> 512k/128k FLASH part. High-level systemon <strong>the</strong> PCMCIA ATA card or downloaded from ei<strong>the</strong>r an E<strong>the</strong>rnetBootP server or from a serial port.18 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMTo use <strong>the</strong> Configuration Wizard, per<strong>for</strong>m <strong>the</strong> following steps:1Step 1.Step 2.Select <strong>the</strong> Start button on <strong>the</strong> Windows desktop.Select Programs -> <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM -> MicrowareConfiguration Wizard. The following opening screen is displayed:Figure 1-4 ARM Configuration WizardSelect <strong>the</strong> directorywhere your MW<strong>OS</strong> filestructure is installed onyour Host PCSelect Advanced Modewhen you want to modify anexisting ROM imageSelect Use Wizardwhen building a ROMimage <strong>for</strong> <strong>the</strong> first timeSelect <strong>the</strong>board modelClick on <strong>the</strong>Help button<strong>for</strong> additionalin<strong>for</strong>mation on<strong>the</strong> wizard.Enter <strong>the</strong> filename <strong>for</strong> <strong>the</strong>build you arecreatingStep 3.Step 4.Step 5.Step 6.Step 7.Select <strong>the</strong> path where <strong>the</strong> MW<strong>OS</strong> directory structure is located from <strong>the</strong>MW<strong>OS</strong> location button.Select <strong>the</strong> target board from <strong>the</strong> Port Selection pull-down menu.Name <strong>the</strong> ROM Image in <strong>the</strong> Configuration Name field.Select Advanced Mode and click OK. The Main Configuration windowis displayed.Select Configure -> Bootfile -> NetWork Configuration.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 19


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMNoteIf you intend to use <strong>the</strong> Target board across a network, you need toconfigure <strong>the</strong> E<strong>the</strong>rnet settings. Be sure <strong>the</strong> Enable SoftStax radiobutton is selected in <strong>the</strong> SoftStax Setup tab.Use <strong>the</strong> Configuration Wizard help <strong>for</strong> in<strong>for</strong>mation on <strong>the</strong> settings.Step 8.Step 9.Step 10.Step 11.Step 12.Step 13.!Leave <strong>the</strong> o<strong>the</strong>r options at <strong>the</strong> default settings.Select Configure -> Build Image to display <strong>the</strong> Master Builderwindow.Click Build. This will build a boot image that can be placed on <strong>the</strong>PCMCIA card.Insert <strong>the</strong> PCMCIA IDE card into <strong>the</strong> PCMCIA slot of your computer.Click Save As to save <strong>the</strong> file os9kboot to <strong>the</strong> root directory of <strong>the</strong>PCMCIA IDE card.Turn off <strong>the</strong> power to <strong>the</strong> reference board.WARNINGInserting and removing a PCMCIA card with <strong>the</strong> power on is notsupported in this release. Damage may occur to <strong>the</strong> PCMCIA card if it isinserted or removed while power is applied to <strong>the</strong> board.Step 14.Step 15.Remove <strong>the</strong> PCMCIA IDE card from <strong>the</strong> computer.Position <strong>the</strong> PCMCIA card so that <strong>the</strong> end with <strong>the</strong> connector holes isfacing <strong>the</strong> PCMCIA socket and <strong>the</strong> label is facing up.20 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMStep 16.Step 17.Slide <strong>the</strong> card into <strong>the</strong> upper socket (socket 0) of <strong>the</strong> reference boarduntil <strong>the</strong> card snaps onto <strong>the</strong> connector pins and <strong>the</strong> eject button popsout.Apply power to <strong>the</strong> board. The reference board will boot from <strong>the</strong> IDEPCMCIA card and you should see <strong>the</strong> “$” prompt.1<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 21


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMBuilding a ROM Image <strong>for</strong> NetworkingAlthough <strong>the</strong> <strong>PID7T</strong> boards come with two PCMCIA slots, only one slotwas functional when <strong>OS</strong>-9 was tested. If networking functionality isdesired (<strong>for</strong> example when debugging) it will be necessary to create andconfigure a ROM Image that ei<strong>the</strong>r uses one of <strong>the</strong> following technics:• Use Bootp to <strong>for</strong> a full function ROM Image, including networking.• Place a network boot on an ATA PCMCIA card. This type of boot isnecessary because <strong>the</strong> 512k ROM portion on <strong>the</strong> board does nothave enough space to include a full function ROM Image, includingnetworking.One of <strong>the</strong> following three board configurations will enable you to build afull featured ROM Image that includes networking:• Your <strong>PID7T</strong> board has a working Slot 1. This enables you to use aPCMCIA ATA card in Slot 0 and a PCMCIA e<strong>the</strong>rnet card in slot 1.To determine if your board has this configuration, per<strong>for</strong>m <strong>the</strong>following steps:Step 1.Step 2.Prior to power up, place an ATA card in slot 0 and an E<strong>the</strong>rnet card inslot 1.Power <strong>the</strong> board on. Watch your terminal as <strong>the</strong> board boots up. If itfinds both cards you can use <strong>the</strong> Configuration Wizard to build a fullROM Image on <strong>the</strong> ATA card, which includes networking <strong>for</strong> <strong>the</strong> slot 1.• Slot 1 of your <strong>PID7T</strong> board is non-functional. In this configurationyou can use <strong>the</strong> Configuration Wizard to build a ROM Image thatincludes both ATA PCMCIA support and E<strong>the</strong>rnet support <strong>for</strong> slot 0.To accomplish this task, complete <strong>the</strong> following steps:22 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM1Step 1. Alter <strong>the</strong> Init modules parameter list so that ipstart is not executed atstart up. After configuring your networking options in <strong>the</strong> ConfigurationWizard, select <strong>the</strong> Init Option tab and select <strong>the</strong> user radio button.Step 2. Remove <strong>the</strong> command ipstart; from its parameter list.Step 3. Select Master Builder window and rebuild <strong>the</strong> ROM Image.Step 4. After making your os9kboot file, copy it to a PC-CARD.Step 5. Place <strong>the</strong> ATA card into slot 0 (top) and power your board on. Be sure toboot from mhc1.Step 6. At <strong>the</strong> shell prompt type <strong>the</strong> following command:pcmcia -d -s=0 -vThis powers down <strong>the</strong> ATA card.Step 7. Remove <strong>the</strong> ATA card from slot 0.Step 8. Insert your networking card into slot 0 and type <strong>the</strong> following command:pcmcia -i -s=0 -vThe system should report finding your card.Step 9. Type <strong>the</strong> following command:ipstartThe command line and networking will start up.Following is an example boot of this configuration:<strong>OS</strong>-9000 Bootstrap <strong>for</strong> <strong>the</strong> ARM (Edition 62)MICROWARE PCMCIA SOCKET SERVICESi82365sl step B PCMCIA type controllersocket #00 occupied [0x04]ATA IDE disk found in socket 00IDE Base 0x0c0002e0 : Vector 0x00000047Now trying to Override autobooters.Press <strong>the</strong> spacebar <strong>for</strong> a booter menuBOOTING PROCEDURES AVAILABLE ---------- <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 23


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMBoot embedded <strong>OS</strong>-9000 in-place -------- Copy embedded <strong>OS</strong>-9000 to RAM and boot - Boot from PCMCIA-1 IDE ---------------- Boot from PCMCIA-0 IDE ---------------- Enter system debugger ----------------- Restart <strong>the</strong> System -------------------- Select a boot method from <strong>the</strong> above menu: ide0Wait <strong>for</strong> IDE drive ready......ready.IDE Model: ATA_FLASHNumber Heads: 0x0002Total Cylinders: 0x03d8Sectors Per Track: 0x0020Checking Partitions : 0Fat Type: 0x16File Name: <strong>OS</strong>9KBOOTFile Size: 0x00167648Start Cluster: 0x000057f4Reading Bootfile....Boot AddressBoot Size: 0x0302c760: 0x00167648<strong>OS</strong>-9000 kernel was found.A valid <strong>OS</strong>-9000 bootfile was found.[1]$ pcmcia -d -v -s=0socket0: occupiedIt is now safe to remove <strong>the</strong> card is socket #00[2]$ pcmcia -i -v -s=0MICROWARE PCMCIA SOCKET SERVICESi82365sl step B PCMCIA type controllersocket #0 occupied [0x06]E<strong>the</strong>rnet card found in socket0Base = 0x0c000600 Vector = 71[3]$ mbinstall[4]$ ipstart[5]$ ping hobbesPING hobbes.microware.com (172.16.1.6): 56 data bytes64 bytes from 172.16.1.6: ttl=255 time=20 ms[6]$24 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM• Slot 1 of your <strong>PID7T</strong> board is non-functional. In this configurationyou can use <strong>the</strong> Configuration Wizard to build a ROM Image thatincludes <strong>the</strong> e<strong>the</strong>rnet boot option along with configuring both highand low level networking. You can build a full featured ROM Imageand place it on <strong>the</strong> host system (or any o<strong>the</strong>r machine), which canbe configured to send your os9kboot file to <strong>the</strong> target during startup.Following is an example boot of this configuration:MICROWARE PCMCIA SOCKET SERVICESi82365sl step B PCMCIA type controllerNow trying to Override autobooters.1Press <strong>the</strong> spacebar <strong>for</strong> a booter menuBOOTING PROCEDURES AVAILABLE ---------- Boot embedded <strong>OS</strong>-9000 in-place -------- Copy embedded <strong>OS</strong>-9000 to RAM and boot - Boot from PCMCIA-1 IDE ---------------- Boot from PCMCIA-0 IDE ---------------- Enter system debugger ----------------- Restart <strong>the</strong> System -------------------- Select a boot method from <strong>the</strong> above menu: lrNow searching memory ($00000400 - $0007ffff) <strong>for</strong> an <strong>OS</strong>-9000Kernel...An <strong>OS</strong>-9000 kernel was found at $00026920A valid <strong>OS</strong>-9000 bootfile was found.[1]$<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 25


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMConnecting <strong>the</strong> Target to an E<strong>the</strong>rnet Network(Optional)<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM supports using a 3COM E<strong>the</strong>rlink III - LAN PCCard <strong>for</strong> mwSoftStax TCP/IP connections. Also, <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong>ARM provides system level support <strong>for</strong> telnet, FTP, and NFS.To use E<strong>the</strong>rnet networking, you must create a bootfile that has <strong>the</strong>E<strong>the</strong>rnet options enabled and insert an E<strong>the</strong>rnet PCMCIA card into <strong>the</strong>reference board.Step 1.Step 2.Step 3.Step 4.Step 5.Step 6.Step 7.!Step 8.Click <strong>the</strong> Start button on <strong>the</strong> Windows desktop.Select Programs -> <strong>Enhanced</strong> <strong>OS</strong>-9 ARM -> MicrowareConfiguration Wizard. You should see <strong>the</strong> opening screen.Click OK. The configuration screen is displayed.Select Configure -> Bootfile -> NetWork Configuration.The network options dialog box appears.Change <strong>the</strong> network settings as needed. See <strong>the</strong> mwWizard help <strong>for</strong>more in<strong>for</strong>mation on <strong>the</strong> network settings.Create a new Bootfile by following <strong>the</strong> directions in <strong>the</strong>Creating and Configuring a ROM Image section.Turn off <strong>the</strong> power to <strong>the</strong> reference board.WARNINGInserting and removing a PCMCIA card with <strong>the</strong> power on is notsupported in this release. Damage may occur to <strong>the</strong> PCMCIA card if it isinserted or removed while power is applied to <strong>the</strong> board.Position <strong>the</strong> PCMCIA IDE card so that <strong>the</strong> end with <strong>the</strong> PCMCIA femaleconnector is facing PCMCIA socket 1 (<strong>the</strong> upper socket) and <strong>the</strong> label isfacing up.26 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMStep 9.Step 10.Step 11.Step 12.Step 13.Slide <strong>the</strong> PCMCIA IDE E<strong>the</strong>rnet card into socket 1 (<strong>the</strong> upper socket)until <strong>the</strong> card snaps onto <strong>the</strong> pins and <strong>the</strong> eject button pops out.Position <strong>the</strong> E<strong>the</strong>rnet PCMCIA card so that <strong>the</strong> end with <strong>the</strong> PCMCIAfemale connector is facing PCMCIA socket 0 (<strong>the</strong> lower socket) and <strong>the</strong>label is facing up.Slide <strong>the</strong> PCMCIA E<strong>the</strong>rnet card into socket 0 (<strong>the</strong> lower socket) until<strong>the</strong> card snaps onto <strong>the</strong> pins and <strong>the</strong> eject button pops out.Restart your reference board.Test <strong>the</strong> E<strong>the</strong>rnet connection by pinging <strong>the</strong> reference board.If <strong>the</strong> ping operation fails, you will have to check <strong>the</strong> following items:• is <strong>the</strong> board connected to a live E<strong>the</strong>rnet port?• is <strong>the</strong> E<strong>the</strong>rnet cable defective?• are <strong>the</strong> network settings <strong>for</strong> <strong>the</strong> reference board correct?1Pinging <strong>the</strong> TargetWindows 95, Windows 98, and Windows NT include a Ping commandthat can be used to test <strong>the</strong> E<strong>the</strong>rnet connection <strong>for</strong> <strong>the</strong> referenceboard.Step 1.Step 2.Go to <strong>the</strong> D<strong>OS</strong> prompt.Type ping .The IP Address is <strong>the</strong> address you assigned to <strong>the</strong> evaluation boardin ei<strong>the</strong>r <strong>the</strong> Coreboot module or <strong>the</strong> Bootfile module. The address istyped without <strong>the</strong> brackets.If <strong>the</strong> ping was successful, you will see <strong>the</strong> following response:Reply from : bytes=xx time =xms TTL= xxIf <strong>the</strong> ping was unsuccessful, you will see <strong>the</strong> following response:Request timed out.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 27


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMCreating a new <strong>OS</strong>-9 Coreboot Image in FlashMemory (Optional)If you want to use ROM E<strong>the</strong>rnet services such as System StateDebugging, you must create a new coreboot image. The corebootimage that was shipped with <strong>the</strong> reference board does not allow you toper<strong>for</strong>m System State Debugging because <strong>the</strong> IP address in FlashROM is set to “0.0.0.0”. You can create <strong>the</strong> coreboot image with anEPROM programmer.NoteRe-creating <strong>the</strong> Coreboot image is required only when system statedebugging is desired.Making a Coreboot Image with an EPROM programmerThis section describes creating <strong>the</strong> Coreboot Image. When you aredone creating <strong>the</strong> coreboot image, please refer to your EPROMprogrammer’s instructions to learn how to load <strong>the</strong> Coreboot image into<strong>the</strong> EPROMS.Step 1.Step 2.Click <strong>the</strong> Start button on <strong>the</strong> Windows desktop.Select Programs -> <strong>Enhanced</strong> <strong>OS</strong>-9 ARM -> MicrowareConfiguration Wizard. You should see <strong>the</strong> following openingscreen:28 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Installing and Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARMFigure 1-5 ARM Configuration Wizard1Select <strong>the</strong> directorywhere your MW<strong>OS</strong> filestructure is installed onyour Host PCSelect Advanced Modewhen you want to modify anexisting ROM imageSelect Use Wizardwhen building a ROMimage <strong>for</strong> <strong>the</strong> first timeSelect <strong>the</strong>board modelClick on <strong>the</strong>Help button<strong>for</strong> additionalin<strong>for</strong>mation on<strong>the</strong> wizard.Enter <strong>the</strong> filename <strong>for</strong> <strong>the</strong>build you arecreatingStep 3.Step 4.Step 5.Step 6.Step 7.Step 8.Step 9.Give <strong>the</strong> boot image a name in <strong>the</strong> Configuration Name field.Select Advanced Mode and click OK. The configuration screen isdisplayed.Make any necessary changes to <strong>the</strong> coreboot settings.Select Configure->Build Image to display <strong>the</strong> Master Builderscreen.Select <strong>the</strong> Coreboot Only Image setting and click Build.Click Save As to save <strong>the</strong> coreboot image to a directory of yourchoosing. If you do not have that directory on <strong>the</strong> drive, you can createit.Transfer <strong>the</strong> coreboot image to <strong>the</strong> EPROMS with <strong>the</strong> EPROMprogrammer. You will need to follow <strong>the</strong> documentation <strong>for</strong> <strong>the</strong> EPROMprogrammer to complete this step.NoteMake sure <strong>the</strong> Secure Option is selected when burning Flash parts.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 29


1Installingand Configuring <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> ARM30 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Chapter 2: <strong>Board</strong> SpecificConsiderationsThis chapter contains in<strong>for</strong>mation that is specific to <strong>the</strong> <strong>PID7T</strong> referenceboard from ARM Ltd. It contains <strong>the</strong> following sections:• Low-Level System Modules• Boot Options• High-Level System Modules• <strong>OS</strong>9 Vector Mappings• Port Specific UtilitiesNoteThis document describes using <strong>the</strong> <strong>PID7T</strong> with <strong>the</strong> ARM Ltd.ARM7TDMI processor.More Info MoreIn<strong>for</strong>mation More In<strong>for</strong>mation More In<strong>for</strong>mation More-6-For More In<strong>for</strong>mationFor general in<strong>for</strong>mation on porting <strong>OS</strong>-9, see <strong>the</strong> <strong>OS</strong>-9 Porting <strong>Guide</strong>.31


2<strong>Board</strong>Specific ConsiderationsLow-Level System ModulesMore Info MoreIn<strong>for</strong>mation More In<strong>for</strong>mation More In<strong>for</strong>mation More-6-For More In<strong>for</strong>mationFor a complete list of <strong>OS</strong>-9 modules common to all boards, see <strong>the</strong><strong>OS</strong>-9 Device Descriptor and Configuration Module Referencemanual.The following low-level system modules are tailored specifically <strong>for</strong> <strong>the</strong>ARM Ltd. ARM7TDMI <strong>PID7T</strong> plat<strong>for</strong>m. The functionality of <strong>the</strong>semodules can be altered through changes to <strong>the</strong> configuration datamodule (cnfgdata). Table 2-1 provides a list and brief description of <strong>the</strong>modules. These modules can be found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/PORTS/<strong>PID7T</strong>/CMDS/BOOTOBJS/ROMTable 2-1 <strong>PID7T</strong>-Specific Low-Level System ModuleModule NamecnfgdatacnfgfuncCommcnfgconscnfgideio16550llcisDescriptionContains <strong>the</strong> low-level configuration data.Provides access services to cnfgdata’s data.Inits communication port defined in cnfgdata.Inits console port defined in cnfgdata.IDE boot support module. PCMCIA compatible.Provides polled serial driver support <strong>for</strong> <strong>the</strong> low-levelsystem.Inits <strong>the</strong> PCMCIA interface including cards.32 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsTable 2-1 <strong>PID7T</strong>-Specific Low-Level System Module (continued)2Module Namelle509portmenuromcoreArmtimrusedebugDescriptionProvides low-level e<strong>the</strong>rnet services via 3COMPCMCIA card.Inits booters defined in <strong>the</strong> cnfgdata.<strong>Board</strong> specific initialization code.Provides low-level timer services via time baseregister.Inits low-level debug interface to RomBug, SNDP, ornone.The following low-level system modules provide generic services <strong>for</strong><strong>OS</strong>9000 Modular ROM. Table 2-2 provides a list and brief description of<strong>the</strong> modules. These modules can be found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV3/CMDS/BOOTOBJS/ROMTable 2-2 Generic Services Low-Level System ModulesModule NamebootsysconsoledbgentrydbgserveexcptionflshcachDescriptionBooter registration service module.Provides console services.Inits debugger entry point <strong>for</strong> system use.Provides debugger services.Provides low-level exception services.Provides low-level cache management services.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 33


2<strong>Board</strong>Specific ConsiderationsTable 2-2 Generic Services Low-Level System Modules (continued)Module NamehlprotollbootpLlipllsliplltcplludpllkermitnotifyoverrideparserpcmanprotomanrestartrombootrombreakrombugDescriptionProvides user level code access to protoman.Booter which provides bootp services.Provides low-level IP services.Provides low-level SLIP services.Provides low-level TCP services.Provides low-level UDP services.Booter which uses kermit protocol.Provides state change in<strong>for</strong>mation <strong>for</strong> use with LLand HL drivers.Booter which allows choice between menu and autobooters.Provides argument parsing services.Booter which reads MS-D<strong>OS</strong> file system.Protocol management module.Booter which cause a soft reboot of system.Booter which allows booting from ROM.Booter which calls <strong>the</strong> installed debugger.Low-level system debugger.34 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsTable 2-2 Generic Services Low-Level System Modules (continued)2Module NamesndpsrecordswtimerDescriptionProvides low-level system debug protocol.Booter which accepts S-Records.Provides timer services via software loops.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 35


2<strong>Board</strong>Specific ConsiderationsBoot OptionsFollowing are <strong>the</strong> default boot options <strong>for</strong> <strong>the</strong> reference board. Select<strong>the</strong>se options by hitting <strong>the</strong> space bar during boot up when <strong>the</strong> followingmessage appears on <strong>the</strong> console port:Now trying to Override autobootersChange <strong>the</strong> configuration of <strong>the</strong>se booters by altering <strong>the</strong>default.des file located in <strong>the</strong> following directory:mwos/os9000/ARMV4/PORTS/<strong>PID7T</strong>/ROM/Booters can be configured to be ei<strong>the</strong>r menu or auto booters. The autobooters automatically try and boot in order from each entry in <strong>the</strong> autobooter array. Menu booters from <strong>the</strong> defined menu booter array arechosen interactively from <strong>the</strong> console command line after getting <strong>the</strong>boot menu.Booting from FLASHWhen romcnfg.h has a ROM search list defined <strong>the</strong> options ro andlr appear in <strong>the</strong> boot menu. If no search list is defined N/A appears in<strong>the</strong> boot menu. If an <strong>OS</strong>-9 ROM Image is programmed into Flash in <strong>the</strong>address range defined in ports default.des file, <strong>the</strong> system can bootand run from Flash.rolrRom boot, <strong>the</strong> system runs from <strong>the</strong> Flashbank.Load to ram, <strong>the</strong> system copies <strong>the</strong> Flashimage into ram and runs from <strong>the</strong>re.Booting from PCMCIA ATA CardThe system can boot from ei<strong>the</strong>r from a PC <strong>for</strong>matted PCMCIA hardcard residing in slot 0 or slot 1.36 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific Considerations2NoteThe system will hang during boot if <strong>the</strong>re is not PCMCIA card, and it isconfigured to boot from one.ide1ide0The file os9kboot is searched <strong>for</strong> in slot 1, iffound, it is copied to system RAM and runs from<strong>the</strong>re.The file os9kboot is searched <strong>for</strong> in slot 0, iffound, it is copied to system RAM and runs from<strong>the</strong>re.Booting from PCMCIA E<strong>the</strong>rnet CardThe system can boot using <strong>the</strong> BootP protocol using an E<strong>the</strong>rnet cardand eb option.ebE<strong>the</strong>rnet boot, a PCMCIA card that supportse<strong>the</strong>rnet will use <strong>the</strong> bootp protocol to transfera bootfile into RAM. The system runs from<strong>the</strong>re.Restart BooterThe restart booter allows a method to restart <strong>the</strong> bootstrap sequence.qQuit, quit and attempt to restart <strong>the</strong> bootingprocess.Break BooterThe break booter allows entry to <strong>the</strong> system level debugger (if oneexists). If <strong>the</strong> debugger is not in <strong>the</strong> system <strong>the</strong> system will reset.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 37


2<strong>Board</strong>Specific ConsiderationsbreakBreak, break and enter <strong>the</strong> system leveldebugger Rombug.Example Boot Session and Message<strong>OS</strong>-9000 Bootstrap <strong>for</strong> <strong>the</strong> ARMATA IDE disk found in socket 00Now trying to Override autobooters.BOOTING PROCEDURES AVAILABLE ------------- Boot embedded <strong>OS</strong>-9000 in-place ----------- Copy embedded <strong>OS</strong>-9000 to RAM and boot ---- Boot from PCMCIA-1 IDE ------------------- Boot from PCMCIA-0 IDE ------------------- Restart <strong>the</strong> System ----------------------- Enter system debugger -------------------- Select a boot method from <strong>the</strong> above menu: ide0Wait <strong>for</strong> IDE drive ready.IDE Model : ATA_FLASHNumber Heads: 0x0002Total Cylinders: 0x03d8Sectors Per Track: 0x0020Checking Partitions : 0Fat Type: 0x16File Name: <strong>OS</strong>9KBOOTFile Size: 0x000fdeb0Start Cluster: 0x00003a57Reading Bootfile....Boot AddressBoot Size: 0xc002c850: 0x000fdeb0<strong>OS</strong>-9000 kernel was found.A valid <strong>OS</strong>-9000 bootfile was found.$38 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsHigh-Level System Modules2The following <strong>OS</strong>-9 system modules are tailored specifically <strong>for</strong> <strong>the</strong>ARM Ltd. ARM7TDMI <strong>PID7T</strong> board peripherals. Unless o<strong>the</strong>rwisespecified, each module can be found in a file of <strong>the</strong> same name in <strong>the</strong>following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/PORTS/<strong>PID7T</strong>/CMDS/BOOTOBJSCPU Support ModulesThese files are all found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/CMDS/BOOTOBJSkernelfpuvectorsThe kernel provides all basic services <strong>for</strong> <strong>the</strong><strong>OS</strong>-9 system.Provides software emulation <strong>for</strong> floating pointinstructions.Provides interrupt service entry and exit code.The vectors module is found in <strong>the</strong> file vectarm.System Configuration ModulesThese files are located in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/PORTS/<strong>PID7T</strong>/CMDS/BOOTOBJS/INITSinitnodiskDescriptor module with high level systeminitialization in<strong>for</strong>mation.Same as init, but used in a disk-less system.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 39


2<strong>Board</strong>Specific ConsiderationsInterrupt Controller SupportThis module provides an extension to <strong>the</strong> vectors module by mapping<strong>the</strong> single interrupt generated by an interrupt controller into a range ofpseudo vectors which are recognized by <strong>OS</strong>-9 as extensions to <strong>the</strong>base CPU exception vectors.More Info MoreIn<strong>for</strong>mation More In<strong>for</strong>mation More In<strong>for</strong>mation More-6-For More In<strong>for</strong>mationThe mappings are described in <strong>the</strong> <strong>OS</strong>9 Vector Mappings section.Vector ModulearmirqP2module which provides interruptacknowledge and dispatching support <strong>for</strong> <strong>the</strong>ARM7TDMI pic.TickertkarmDriver which provides <strong>the</strong> system ticker basedon <strong>the</strong> ARM7TDMI system timer.Abort HandlerabortP2module which provides a way to enter <strong>the</strong>system-state debugger via <strong>the</strong> interrupttriggered by <strong>PID7T</strong> switch SW1.40 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsGeneric IO Support Modules (File Managers)2These modules are found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV3/CMDS/BOOTOBJSiomanscfrbfpcfspfmfmpipemanProvides generic io support <strong>for</strong> all IO devicetypes.Provides generic character device managementfunctions.Provides generic block device managementfunctions <strong>for</strong> <strong>OS</strong>-9 <strong>for</strong>mat.Provides generic block device managementfunctions <strong>for</strong> MS-D<strong>OS</strong> FAT <strong>for</strong>mat.Provides generic protocol device managementfunction support.Provides generic graphics device support <strong>for</strong>MAUI.Provides a memory FIFO buffer <strong>for</strong>communication.Pipe DescriptorThe pipe descriptor is found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/PORTS/<strong>PID7T</strong>/CMDS/BOOTOBJS/DESCpipePipeman descriptor which provides a RAMbased FIFO <strong>for</strong> process communication.RAM Disk SupportramRBF driver which provides a RAM based virtualblock device.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 41


2<strong>Board</strong>Specific ConsiderationsRAM Disk DescriptorsThe RAM disk descriptors are found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/PORTS/<strong>PID7T</strong>/CMDS/BOOTOBJS/DESC/RAMr0r0.ddRBF descriptor which provides access to a ramdisk.Same as r0 except with module name dd (<strong>for</strong>use as <strong>the</strong> default device).Serial and Console Devicessc16550SCF driver which provides serial support <strong>the</strong><strong>PID7T</strong>’s 16552.sc16550 Descriptorsterm_t1/t1term_t3/t3Descriptor modules <strong>for</strong> use with SC16552UART A.<strong>PID7T</strong> <strong>Board</strong> header: PL4Default Baud Rate: 19200Default Parity: NoneDefault Data Bits: 8Default Handshake: SoftwareDescriptor modules <strong>for</strong> use with SC16552UART B.<strong>PID7T</strong> <strong>Board</strong> header: PL3Default Baud Rate: 115200Default Parity: NoneDefault Data Bits: 8Default Handshake: Software42 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsscllioSCF driver which provides serial support via <strong>the</strong>polled low-level serial driver.2scllio Descriptorsvcons/termDescriptor modules <strong>for</strong> use with scllio inconjunction with a low-level serial driver. Portconfiguration and set up follows what isconfigured in cnfgdata <strong>for</strong> <strong>the</strong> console port. Itis possible <strong>for</strong> scllio to communicate with atrue low-level serial device driver like io1100,or with an emulated serial interface provided byiovcons.More Info MoreIn<strong>for</strong>mation More In<strong>for</strong>mation More In<strong>for</strong>mation More-6-For More In<strong>for</strong>mationSee <strong>the</strong> <strong>OS</strong>-9 Porting <strong>Guide</strong> <strong>for</strong> more in<strong>for</strong>mation.PCMCIA Support <strong>for</strong> IDE type Devicesrb1003RBF/PCF driver which provides driver support<strong>for</strong> IDE/EIDE devices. This driver is used toprovide disk support <strong>for</strong> PCMCIA ATA FLASH.rb1003 Descriptorshc1/hc1fmt, hc1.dd RBF Descriptor modules <strong>for</strong> use with PCMCIAslot #0 (bottom).<strong>PID7T</strong> <strong>Board</strong> header: SK4hc1fmt: <strong>for</strong>mat enabledhc1.dd: module name of dd<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 43


2<strong>Board</strong>Specific Considerationsmhc1, mhc1.dd PCF Descriptor modules <strong>for</strong> use with PCMCIAslot #0 (bottom).<strong>PID7T</strong> <strong>Board</strong> header: SK4mhc1.dd: module name of ddhe1, he1fmt, he1.dd RBF Descriptor modules <strong>for</strong> use with PCMCIAslot #1 (top).<strong>PID7T</strong> <strong>Board</strong> header: SK4he1fmt: <strong>for</strong>mat enabledhe1.dd: module name of ddmhe1, mhe1.ddPCF Descriptor modules <strong>for</strong> use with PCMCIAslot #1 (top).<strong>PID7T</strong> <strong>Board</strong> header: SK4mhc1.dd: module name of ddPCMCIA Support <strong>for</strong> 3COM E<strong>the</strong>rnet cardThese files are found in <strong>the</strong> following directory:MW<strong>OS</strong>/<strong>OS</strong>9000/ARMV4/PORTS/<strong>PID7T</strong>/CMDS/BOOTOBJS/SPFspe509_pcmSPF driver to support e<strong>the</strong>rnet <strong>for</strong> a 3COME<strong>the</strong>rLink III PCMCIA card.spe509_pcm Descriptorsspe30spe31SPF descriptor module <strong>for</strong> use with PCMCIAslot #0 (bottom, SK4).SPF descriptor module <strong>for</strong> use with PCMCIAslot #1 (top, SK4).Network Configuration Modulesinetdb/inetdb2/rpcdb44 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific Considerations<strong>OS</strong>9 Vector Mappings2This section contains <strong>the</strong> vector mappings <strong>for</strong> <strong>the</strong> <strong>OS</strong>9 <strong>PID7T</strong>implementation on <strong>the</strong> ARM7TDMI.The ARM standard defines exceptions 0x0-0x8. The <strong>OS</strong>-9000 systemmaps <strong>the</strong>se 1-1. External interrupts from vector 0x6 are expanded to<strong>the</strong> virtual vector rage shown below by <strong>the</strong> armirq module.NoteVectors can be virtually remapped from a ROM at physical address 0,into DRAM at virtual address 0. This speeds up interrupt response timeand is enabled by defining <strong>the</strong> first cache list entry as a sub 1 Meg size.More Info MoreIn<strong>for</strong>mation More In<strong>for</strong>mation More In<strong>for</strong>mation More-6-For More In<strong>for</strong>mationSee <strong>the</strong> Arm Development Card Manual <strong>for</strong> fur<strong>the</strong>r in<strong>for</strong>mation onindividual sources.Table 2-3 IRQ Assignments <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> ARM7TDMI <strong>Board</strong><strong>OS</strong>9 IRQ #0x00x10x2ARM FunctionProcessor ResetUndefined InstructionSoftware Interrupt<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 45


2<strong>Board</strong>Specific ConsiderationsTable 2-3 IRQ Assignments <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> ARM7TDMI <strong>Board</strong> (continued)<strong>OS</strong>9 IRQ #0x30x40x50x60x70x8ARM FunctionAbort on Instruction PrefetchAbort on Data AccessUnassigned/ReservedExternal Interrupt (expanded to virtual vectors0x40-0x4f)Fast InterruptAlignment errorTable 2-4 IRQ Assignments <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> ARM7TDMI <strong>Board</strong><strong>OS</strong>-9 IRQ #0x400x410x420x430x440x450x46<strong>PID7T</strong> APB FPGA (pic)ReservedSoft InterruptCOMMSRX from processorCOMMSTX from processorTIMER1 (internal)TIMER2 (internal)PC card slot A46 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsTable 2-4 IRQ Assignments <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> ARM7TDMI <strong>Board</strong> (continued)2<strong>OS</strong>-9 IRQ #0x47<strong>PID7T</strong> APB FPGA (pic)PC card slot B0x48 SERIAL A (16552)0x49 SERIAL B (16552)0x4aPARALLEL0x4b ASB expansion 00x4c ASB expansion 10x4d APB expansion 00x4e APB expansion 10x4f APB expansion 2<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 47


2<strong>Board</strong>Specific ConsiderationsNoteFast Interrupt Vector (0x7)The ARM4 defined fast interrupt (FIQ) mapped to vector 0x7 is handleddifferently by <strong>the</strong> <strong>OS</strong>9 interrupt code and can not be used as freely as<strong>the</strong> external interrupt mapped to vector 0x6. To make fast interrupts asquick as possible <strong>for</strong> extremely time critical code, no context in<strong>for</strong>mationis saved on exception and FIQs are never masked. This requires anyexception handler to save and restore its necessary context if <strong>the</strong> FIQmechanism is to be used. This requirement means that a FIQ handler’sentry and exit points must be in assembly, as <strong>the</strong> C compiler will makeassumptions about context. In addition, no system calls are possibleunless a full C ABI context save has been done first. The <strong>OS</strong>-9 IRQcode <strong>for</strong> <strong>the</strong> ARM7TDMI has assigned all interrupts as normal externalinterrupts and <strong>the</strong> user must re-define a source as an FIQ to make useof this feature.48 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsPort Specific Utilities2The following port specific utilities are included:• pcmcia<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 49


2<strong>Board</strong>Specific ConsiderationspcmciaSyntaxpcmcia []options-s=socket: socket [default all sockets]-d de-iniz socket(s)-i iniz socket(s)-v verbose mode-x dump CIS/Config in<strong>for</strong>mation-? Print this help messageDescriptionpcmcia provides <strong>the</strong> ability to initilize or deinitilize a PCMCIA card after<strong>the</strong> system has booted. It also displays a PCMCIA cards CIS structure.50 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>Board</strong> Specific ConsiderationsExample$ pcmcia -x -s=0ATA IDE disk found in socket0Dump CIS Window <strong>for</strong> Socket #0Addr 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 2 4 6 8 A C E-------- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -----------------28000000 01 03 d9 01 ff 1c 04 03 d9 01 ff 18 02 df 01 20 ...............28000020 04 01 4e 00 01 15 2b 04 01 56 49 4b 49 4e 47 20 ..N...+..VIKING28000040 43 4f 4d 50 4f 4e 45 4e 54 53 20 20 20 20 20 20 COMPONENTS28000060 20 20 00 43 46 20 41 54 41 20 00 56 2e 31 30 32 .CF ATA .V.10228000080 00 ff 21 02 04 01 22 02 01 01 22 03 02 04 5f 1a ..!..."..."..._.280000a0 05 01 03 00 02 0f 1b 09 c0 40 a1 21 55 55 08 00 .........@.!UU..280000c0 22 1b 06 00 01 21 b5 1e 35 1b 0b c1 41 99 21 55 "....!..5...A.!U280000e0 55 64 f0 ff ff 22 1b 06 01 01 21 b5 1e 35 1b 0d Ud..."....!..5..28000100 82 41 98 ea 61 f0 01 07 f6 03 01 ee 22 1b 06 02 .A..a......."...28000120 01 21 b5 1e 35 1b 0d 83 41 98 ea 61 70 01 07 76 .!..5...A..ap..v28000140 03 01 ee 22 1b 06 03 01 21 b5 1e 35 14 00 ff ff ..."....!..5....28000160 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................28000180 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................280001a0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................280001c0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................280001e0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................Dump Config Window <strong>for</strong> Socket #0Addr 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 2 4 6 8 A C E-------- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -----------------28000200 43 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 C...............28000220 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ...............28000240 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000260 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000280 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................280002a0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................280002c0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................280002e0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000320 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000340 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000360 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................28000380 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................280003a0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................280003c0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................280003e0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................2<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 51


2<strong>Board</strong>Specific Considerations52 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Chapter 3: <strong>OS</strong>-9 ROM Image OverviewThis chapter is an overview of building an <strong>Enhanced</strong> <strong>OS</strong>-9 ROM Imageand its components. Using <strong>the</strong> Configuration Wizard eliminates <strong>the</strong>need to have an in-depth understanding of how to create and update an<strong>OS</strong>-9 ROM Image. This chapter explains <strong>the</strong> types of images created by<strong>the</strong> wizard <strong>for</strong> those interested in more detailed knowledge.NoteThis chapter provides a generic, general overview of <strong>the</strong> contents of atypical <strong>OS</strong>-9 ROM image. It is not board/processor specific.53


3<strong>OS</strong>-9ROM Image OverviewTypes of ROM ImagesThe <strong>OS</strong>-9 ROM Image is divided into two sets of files to simplify <strong>the</strong>process of loading and testing <strong>OS</strong>-9. The low-level images are <strong>the</strong>coreboot files, which boot <strong>the</strong> target board to an <strong>OS</strong>-9 boot menu. Thehigh-level images are <strong>the</strong> bootfile files, which boot <strong>the</strong> board up to an<strong>OS</strong>-9 shell prompt.Figure 3-1 <strong>OS</strong>-9 ROM Image<strong>OS</strong>-9 ROM ImageCorebootROMCORELow-level SystemModulesBootfilekernelHigh-level ModulesCoreboot ImageCoreboot is <strong>the</strong> low-level image that boots <strong>the</strong> system up to <strong>the</strong> <strong>OS</strong>-9boot menu on <strong>the</strong> target board. Coreboot is <strong>the</strong> ROMCore imagemerged with several low-level system modules. From this boot menuyou can select a booter module (Flash, PCMCIA ATA card, RAM, etc.).This tells ROMCore <strong>the</strong> location from which to load <strong>the</strong> high-levelsystem. At this point, <strong>OS</strong>-9 is not yet capable of running.54 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewThe configuration wizard simplifies <strong>the</strong> process of building a corebootimage. Table 3-1 lists <strong>the</strong> typically included modules. In this case, <strong>the</strong>high-level system is to be booted from a PCMCIA card:3Table 3-1 Typical Coreboot Image ContentsNamebootsyscnfgdatacnfgfunccommcnfgconscnfgconsoledbgentrydbgservedbinitexcptionflshcachhlprotoideio1100llbootpDescriptionBooter registration service module.Contains <strong>the</strong> low-level configuration data.Provides access services to cnfgdata data.Inits communication port defined in cnfgdata.Inits console port defined in cnfgdata.Provides console services.Inits debugger entry point <strong>for</strong> system use.Provides debugger services.Initilizes any daughter boards present.Provides low-level exception services.Provides low-level cache management services.Provides user level code access to protoman.IDE boot support module. PCMCIA compatible.Provides polled serial driver support <strong>for</strong> <strong>the</strong> low-levelsystem.Booter that provides bootp services.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 55


3<strong>OS</strong>-9ROM Image OverviewTable 3-1 Typical Coreboot Image Contents (continued)Namellcislle509llipllkermitllne2000llsliplltcplludpnotifyoemgloboverrideparserpcmanportmenuprotomanDescriptionInits <strong>the</strong> PCMCIA interface including cards.Provides low-level e<strong>the</strong>rnet services via 3COMPCMCIA card.Provides low-level IP services.Booter that uses kermit protocol.Provides low-level e<strong>the</strong>rnet services viaSOCKET-LPE PCMCIA card.Provides low-level SLIP services.Provides low-level TCP services.Provides low-level UDP services.Provides state change in<strong>for</strong>mation <strong>for</strong> use with LL andHL drivers.Creates a shared variable area <strong>for</strong> high/low levelsystem interactions.Booter that allows choice between menu and autobooters.Provides argument parsing services.Booter that reads MS-D<strong>OS</strong> file system.Inits booters defined in <strong>the</strong> cnfgdata.Protocol management module.56 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewTable 3-1 Typical Coreboot Image Contents (continued)3Namerestartrombootrombreakrombugromcoresndpsplashsrecordswtimertmr1_1100usedebugDescriptionBooter that cause a soft reboot of system.Booter that allows booting from ROM.Booter that calls <strong>the</strong> installed debugger.Low-level system debugger.<strong>Board</strong> specific initialization code.Provides low-level system debug protocol.Provides way to init LCD screen with a compressedimage.Booter that accepts S-Records.Provides timer services via software loops.Provides low-level timer services via time baseregister.Inits low-level debug interface to RomBug, SNDP, ornone.ROMCoreThis is <strong>the</strong> bootstrap code in raw binary object code. ROMCore exists in<strong>the</strong> Coreboot image and is responsible <strong>for</strong> initializing basic hardware,determining boot options, and determining <strong>the</strong> RAM/ROM configuration.ROMCore calls <strong>the</strong> system level debugger (if available) as well as <strong>the</strong>appropriate booter module to find <strong>the</strong> bootfile. After <strong>the</strong> high levelsystem is loaded, ROMCore transfers control over to <strong>the</strong> kernel.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 57


3<strong>OS</strong>-9ROM Image OverviewBootfile ImageThis image contains <strong>the</strong> kernel and o<strong>the</strong>r high-level modules (initmodule, file managers, drivers, descriptors, applications). The image isloaded based on <strong>the</strong> device you select from <strong>the</strong> boot menu. The bootfilenormally brings up a shell prompt, but can be configured toautomatically start your application.The Configuration Wizard simplifies <strong>the</strong> process of building a Bootfileimage. Table 3-2 lists <strong>the</strong> typically included high-level modules.Table 3-2 Typical Bootfile Image ContentsNameabortcachefpugx_sa1100initiomanirq1100irq11x1DescriptionP2module that provides a way to enter <strong>the</strong>system-state debugger.Provides cache control <strong>for</strong> <strong>the</strong> CPU cachehardware. The cache module is in <strong>the</strong> file cach1100.Provides software emulation <strong>for</strong> floating pointinstructions.MFM MAUI driver module with support <strong>for</strong> an LCDpanel.Descriptor module with high level systeminitialization in<strong>for</strong>mation.Provides generic IO support <strong>for</strong> all IO device types.P2module that provides interrupt acknowledge anddispatching support <strong>for</strong> <strong>the</strong> SA1100 pic.P2module that provides interrupt acknowledge anddispatching support <strong>for</strong> <strong>the</strong> SA1111 pic (vectorrange 0x71-0xB2).58 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewTable 3-2 Typical Bootfile Image Contents (continued)3Namekernelmfmnodiskpcfpipepipemanpwrmanpwrplcyr0r0.ddramrb1003DescriptionThe kernel provides all basic services <strong>for</strong> <strong>the</strong> <strong>OS</strong>-9system.Provides generic graphics device support <strong>for</strong> MAUI.Same as init, but used in a disk-less system.Provides generic block device managementfunctions <strong>for</strong> MS-D<strong>OS</strong> FAT <strong>for</strong>mat.Pipeman descriptor that provides a RAM basedFIFO that can be used <strong>for</strong> process communication.Provides a memory FIFO buffer <strong>for</strong> communication.P2module that provides generic powermanagement functions.P2module that provides power state controlfunctions.RBF descriptor that provides access to a ram disk.Same as r0 except with module name dd (<strong>for</strong> use as<strong>the</strong> default device).RBF driver that provides a RAM based virtual blockdevice.RBF/PCF driver that provides driver support <strong>for</strong>IDE/EIDE devices. This driver is used to providedisk support <strong>for</strong> PCMCIA ATA FLASH.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 59


3<strong>OS</strong>-9ROM Image OverviewTable 3-2 Typical Bootfile Image Contents (continued)Namerbfrtc1100sc1100sc16550scfsclliospe509_pcmspe91c94spfspne2000spucb1200DescriptionProvides generic block device managementfunctions <strong>for</strong> <strong>OS</strong>-9 specific <strong>for</strong>mat.Driver that provides <strong>OS</strong>-9 access to <strong>the</strong> SA1110on-board real time clock.SCF driver that provides serial support <strong>the</strong>SA1110’s SP1 and SP3 ports when configured asUARTS.SCF driver that provides serial support <strong>for</strong> PCMCIAmodem cards.Provides generic character device managementfunctions.SCF driver that provides serial support via <strong>the</strong>polled low-level serial driver.SPF driver to support e<strong>the</strong>rnet <strong>for</strong> a 3COME<strong>the</strong>rLink III PCMCIA card.SPF driver to support e<strong>the</strong>rnet <strong>for</strong> <strong>the</strong> SMC91C94chip.Provides generic protocol device managementfunction support.SPF driver to support e<strong>the</strong>rnet <strong>for</strong> a Socket-LPE CFcard.SPF driver that supports <strong>the</strong> on-board PhillipsUCB1200 chip. This device communicates to <strong>the</strong>SA1100 over SP4 using MCP.60 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewTable 3-2 Typical Bootfile Image Contents (continued)3Namessmsysiftk1100vectorsDescriptionThe System Security Module provides support <strong>for</strong><strong>the</strong> Memory Management Unit (MMU) on <strong>the</strong> CPU.P2module that provides SA1100 CPU power statecontrol.Driver that provides <strong>the</strong> system ticker based on <strong>the</strong>SA1110 Operating System Timer.Provides interrupt service entry and exit code. Thevectors module is found in <strong>the</strong> file vect110.Coreboot and Bootfile ImageThe combined coreboot and bootfile images are referred to as <strong>the</strong> <strong>OS</strong>-9ROM Image. The <strong>OS</strong>-9 ROM Image contains a high-level embedded<strong>OS</strong>-9 bootfile as well as <strong>the</strong> system bootstrap code, low-level systemmodules, and embedded utility set <strong>for</strong> a fully functional <strong>OS</strong>-9 embeddedsystem.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 61


3<strong>OS</strong>-9ROM Image OverviewBoot Menu OptionsYou select your boot device menu options using <strong>the</strong> configurationwizard. For each boot device option, you can select whe<strong>the</strong>r you want itto be displayed on a boot menu, set up to autoboot, or both. Theautoboot option enables <strong>the</strong> device selected to automatically boot up<strong>the</strong> high-level bootfile, bypassing <strong>the</strong> boot device menu.NoteWhen using <strong>the</strong> Configuration Wizard, you should select only onedevice <strong>for</strong> autoboot on your system.Following is an example of <strong>the</strong> Boot Menu displayed in <strong>the</strong> terminalemulation window (using Hyperterminal):<strong>OS</strong>-9000 Bootstrap <strong>for</strong> <strong>the</strong> ARMATA IDE disk found in socket 00Now trying to Override autobooters.BOOTING PROCEDURES AVAILABLE ------------- Boot embedded <strong>OS</strong>-9000 in-place ----------- Copy embedded <strong>OS</strong>-9000 to RAM and boot ---- Boot from PCMCIA-1 IDE ------------------- Boot from PCMCIA-0 IDE ------------------- Load bootfile via kermit Download -------- Download and Program coreboot into FLASH - Download and Program bootfile into FLASH - Restart <strong>the</strong> System ----------------------- Enter system debugger -------------------- Select a boot method from <strong>the</strong> above menu: ide062 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewWhat you select <strong>for</strong> boot options in <strong>the</strong> configuration wizard determineswhat modules are included in <strong>the</strong> coreboot image. Table 3-3 lists someof <strong>the</strong> supported boot devices <strong>for</strong> <strong>Enhanced</strong> <strong>OS</strong>-9:3Table 3-3 Supported Boot MethodsType of BootPCMCIA ATA CardBoot embedded <strong>OS</strong>-9in-placeCopy embedded <strong>OS</strong>-9 toRAM and BootDescriptionCopy <strong>OS</strong>-9 from ATA hard drive toRAM and boot (ide0).Boot <strong>OS</strong>-9 from FLASH (bo)Copy <strong>OS</strong>-9 from FLASH (if stored<strong>the</strong>re) to RAM and boot (lr).<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 63


3<strong>OS</strong>-9ROM Image OverviewDebuggersThe configuration wizard supports two debuggers, Microware Hawkand ROMBug. It installs <strong>the</strong> appropriate low-level modules in yourcoreboot file when you make your build. The selection is <strong>the</strong>n containedin <strong>the</strong> coreboot image that is downloaded to your target system.Microware HawkMicroware Hawk and its debugger enable you to create, run, debug,and update your programs. It is included on your <strong>Enhanced</strong> <strong>OS</strong>-9 CD.RomBugRomBug is used to debug system and user state programs. It runs insupervisor state and takes over control of <strong>the</strong> CPU when invoked.RomBug is configured as a low-level module that gains access to <strong>the</strong>resources it needs by using o<strong>the</strong>r low-level modules.64 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewIncluding Options in Your Build3Using <strong>the</strong> configuration wizard, <strong>the</strong>re are additional options you canselect as part of your build. These options enable increasedfunctionality on <strong>the</strong> target system. Following are descriptions of some of<strong>the</strong>se options.ROM Utility SetTable 3-4 lists <strong>the</strong> utilities in <strong>the</strong> ROM utility set.Table 3-4 ROM Utility Setshell date devs breakdeiniz dump echo eventsexbin help ident inizirqs link maps mdirmfree printenv procs setimesleep tmode unlink xmodeMore Info MoreIn<strong>for</strong>mation More In<strong>for</strong>mation More In<strong>for</strong>mation More-6-For More In<strong>for</strong>mationFor more in<strong>for</strong>mation on ROM utilities, see <strong>the</strong> <strong>OS</strong>-9 UtilitiesReference.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 65


3<strong>OS</strong>-9ROM Image OverviewRomBug in Bootfile (p2init)The p2init utility initializes an <strong>OS</strong>9P2 system extension module after<strong>the</strong> operating system is up and running. This provides additionalfunctionality which would not be available when <strong>the</strong> <strong>OS</strong>9P2 module isinitialized as part of <strong>the</strong> system startup. You can also use <strong>the</strong> p2initutility to add <strong>OS</strong>9P2 modules to a running ROM-based system.User State Debugging ModulesUser state is <strong>the</strong> normal program environment in which processes areexecuted. Generally, user-state processes do not deal directly with <strong>the</strong>specific hardware configuration of <strong>the</strong> system. System-state debuggingis defined as debugging <strong>the</strong> entire system as opposed to just oneprocess running on <strong>the</strong> system (user-state debugging). System-statedebugging is initiated by using <strong>the</strong> attach command ei<strong>the</strong>r to attach to asystem or to an emulator.Enable Disk Support ModulesThese modules support disk and tape devices in addition to utilities tomanipulate <strong>the</strong>se device classes. It adds RBF, PCF, and SCF based I/Odevices.Disk UtilitiesThese utilities provide utilities <strong>for</strong> partitioning, <strong>for</strong>matting, andmaintaining disks on target systems.SoftStax Support ModulesThese modules support <strong>the</strong> SoftStax communications environment ontarget systems.66 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


<strong>OS</strong>-9 ROM Image OverviewNFS Client Support Module3This module provides support <strong>for</strong> <strong>the</strong> Network File System (NFS).Keyboard SupportThis enables <strong>the</strong> use of a keyboard attached to <strong>the</strong> target system.Mouse SupportThis enables <strong>the</strong> use of a mouse as an input device on <strong>the</strong> targetsystem.User ModulesBy default, <strong>the</strong> only module included is kermit. You can include o<strong>the</strong>rmodules by editing <strong>the</strong> user.ml file under <strong>the</strong> Sources-Port pull-downmenu found in <strong>the</strong> configuration wizard Advanced Mode.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 67


3<strong>OS</strong>-9ROM Image Overview68 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Appendix A: The FastbootEnhancementThe Fastboot enhancements to <strong>OS</strong>-9 provide faster system bootstrapper<strong>for</strong>mance to embedded systems. The normal bootstrap per<strong>for</strong>manceof <strong>OS</strong>-9 is attributable to its flexibility. <strong>OS</strong>-9 handles many differentruntime configurations to which it dynamically adjusts during <strong>the</strong>bootstrap process.The Fastboot concept consists of in<strong>for</strong>ming <strong>OS</strong>-9 that <strong>the</strong> definedconfiguration is static and valid. These assumptions eliminate <strong>the</strong>dynamic searching <strong>OS</strong>-9 normally per<strong>for</strong>ms during <strong>the</strong> bootstrapprocess and enables <strong>the</strong> system to per<strong>for</strong>m a minimal amount ofruntime configuration. As a result, a significant increase in bootstrapspeed is achieved.69


ATheFastboot EnhancementOverviewThe Fastboot enhancement consists of a set of flags that control <strong>the</strong>bootstrap process. Each flag in<strong>for</strong>ms some portion of <strong>the</strong> bootstrapcode that a particular assumption can be made and that <strong>the</strong> associatedbootstrap functionality should be omitted.The Fastboot enhancement enables control flags to be statically definedwhen <strong>the</strong> embedded system is initially configured as well asdynamically altered during <strong>the</strong> bootstrap process itself. For example, <strong>the</strong>bootstrap code could be configured to query dip switch settings,respond to device interrupts, or respond to <strong>the</strong> presence of specificresources which would indicate different bootstrap requirements.In addition, <strong>the</strong> Fastboot enhancement’s versatility allows <strong>for</strong> specialconsiderations under certain circumstances. This versatility is useful ina system where all resources are known, static, and functional, butadditional validation is required during bootstrap <strong>for</strong> a particularinstance such as a resource failure. The low-level bootstrap code couldrespond to some <strong>for</strong>m of user input that would in<strong>for</strong>m it that additionalchecking and system verification is desired.70 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


The Fastboot EnhancementImplementation OverviewAThe Fastboot configuration flags have been implemented as a set of bitfields. An entire 32-bit field has been dedicated <strong>for</strong> bootstrapconfiguration. This four-byte field is contained within <strong>the</strong> set of datastructures shared by <strong>the</strong> ModRom sub-components and <strong>the</strong> kernel.Hence, <strong>the</strong> field is available <strong>for</strong> modification and inspection by <strong>the</strong> entireset of system modules (high-level and low-level). Currently, <strong>the</strong>re arejust six bit flags defined with eight bits reserved <strong>for</strong> user-definablebootstrap functionality. The reserved user-definable bits are <strong>the</strong>high-order eight bits (31-24). This leaves bits available <strong>for</strong> futureenhancements. The currently defined bits and <strong>the</strong>ir associatedbootstrap functionality are listed below:B_QUICKVALThe B_QUICKVAL bit indicates that only <strong>the</strong> module headers ofmodules in ROM are to be validated during <strong>the</strong> memory module searchphase. This causes <strong>the</strong> CRC check on modules to be omitted. Thisoption is potentially a large time saver due to <strong>the</strong> complexity andexpense of CRC generation. If a system has many modules in ROM,where access time is typically longer than RAM, omitting <strong>the</strong> CRCcheck on <strong>the</strong> modules will drastically decrease <strong>the</strong> bootstrap time. It isfairly rare that corruption of data occurs in ROM. There<strong>for</strong>e, omittingCRC checking will usually be a safe option.B_OKRAMThe B_OKRAM bit in<strong>for</strong>ms both <strong>the</strong> low-level and high-level systems that<strong>the</strong>y should accept <strong>the</strong>ir respective RAM definitions without verification.Normally, <strong>the</strong> system probes memory during bootstrap based on <strong>the</strong>defined RAM parameters. This allows system designers to specify apossible RAM range which <strong>the</strong> system will validate upon startup. Thus<strong>the</strong> system can accommodate varying amounts of RAM. But in anembedded system where <strong>the</strong> RAM limits are usually statically defined<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 71


ATheFastboot Enhancementand presumed to be functional, <strong>the</strong>re is no need to validate <strong>the</strong> definedRAM list. Bootstrap time is saved by assuming that <strong>the</strong> RAM definition isaccurate.B_OKROMThe B_OKROM bit causes acceptance of <strong>the</strong> ROM definition withoutprobing <strong>for</strong> ROM. This configuration option behaves just like <strong>the</strong>B_OKRAM option except that it applies to <strong>the</strong> acceptance of <strong>the</strong> ROMdefinition.B_1STINITThe B_1STINIT bit causes acceptance of <strong>the</strong> first init module foundduring cold-start. By default, <strong>the</strong> kernel searches <strong>the</strong> entire ROM listpassed up by <strong>the</strong> ModRom <strong>for</strong> init modules be<strong>for</strong>e it accepts and uses<strong>the</strong> init module with <strong>the</strong> highest revision number. In a staticallydefined system, time is saved by using this option to omit <strong>the</strong> extendedinit module search.B_NOIRQMASKThe B_NOIRQMASK bit in<strong>for</strong>ms <strong>the</strong> entire bootstrap system that it shouldnot mask interrupts <strong>for</strong> <strong>the</strong> duration of <strong>the</strong> bootstrap process. Normally,<strong>the</strong> ModRom code and <strong>the</strong> kernel cold-start mask interrupts <strong>for</strong> <strong>the</strong>duration of <strong>the</strong> system startup. But some systems that have a welldefined interrupt system (i.e. completely calmed by <strong>the</strong> sysinithardware initialization code) and also have a requirement to respond toan installed interrupt handler during system startup can enable thisoption to prevent <strong>the</strong> ModRom and <strong>the</strong> kernel cold-start from disablinginterrupts. This is particularly useful in power-sensitive systems thatneed to respond to “power-failure” oriented interrupts.72 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


The Fastboot EnhancementANoteSome portions of <strong>the</strong> system may still mask interrupts <strong>for</strong> short periods during <strong>the</strong>execution of critical sections.B_NOPARITYIf <strong>the</strong> RAM probing operation has not been omitted, <strong>the</strong> B_NOPARITYbit causes <strong>the</strong> system to not per<strong>for</strong>m parity initialization of <strong>the</strong> RAM.Parity initialization occurs during <strong>the</strong> RAM probe phase. TheB_NOPARITY option is useful <strong>for</strong> systems that ei<strong>the</strong>r require no parityinitialization at all or systems that only require it <strong>for</strong> “power-on” resetconditions. Systems that only require parity initialization <strong>for</strong> initial“power-on” reset conditions can dynamically use this option to preventparity initialization <strong>for</strong> subsequent “non-power-on” reset conditions.<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 73


ATheFastboot EnhancementImplementation DetailsThis section describes <strong>the</strong> compile-time and runtime methods by whichusers can control <strong>the</strong> bootstrap speed of <strong>the</strong>ir system.Compile-time ConfigurationThe compile-time configuration of <strong>the</strong> bootstrap is provided by apre-defined macro (BOOT_CONFIG) which is used to set <strong>the</strong> initialbit-field values of <strong>the</strong> bootstrap flags. Users can redefine <strong>the</strong> macro <strong>for</strong>recompilation to create a new bootstrap configuration. The newover-riding value of <strong>the</strong> macro should be established by redefining <strong>the</strong>macro in <strong>the</strong> rom_config.h header file or as a macro definitionparameter in <strong>the</strong> compilation command.The rom_config.h header file is one of <strong>the</strong> main files used toconfigure <strong>the</strong> ModRom system. It contains many of <strong>the</strong> specificconfiguration details of <strong>the</strong> low-level system. Here is an example ofhow a user can redefine <strong>the</strong> bootstrap configuration of <strong>the</strong>ir systemusing <strong>the</strong> BOOT_CONFIG macro in <strong>the</strong> rom_config.h header file:#define BOOT_CONFIG (B_OKRAM + B_OKROM + B_QUICKVAL)And here is an alternate example showing <strong>the</strong> default definition as acompile switch in <strong>the</strong> compilation command in <strong>the</strong> makefile:SPEC_COPTS = -dNEWINFO –dNOPARITYINIT –dBOOT_CONFIG=0x7This redefinition of <strong>the</strong> BOOT_CONFIG macro would result in a bootstrapmethod which would accept <strong>the</strong> RAM and ROM definitions as <strong>the</strong>y arewithout verification, and also validate modules solely on <strong>the</strong> correctnessof <strong>the</strong>ir module headers.Runtime ConfigurationThe default bootstrap configuration can be overridden at runtime bychanging <strong>the</strong> rinf->os->boot_config variable from ei<strong>the</strong>r alow-level P2 module or from <strong>the</strong> sysinit2() function of <strong>the</strong>74 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


The Fastboot Enhancementsysinit.c file. The runtime code can query jumper or o<strong>the</strong>r hardwaresettings to determine what user-defined bootstrap procedure should beused. An example P2 module is shown below.ANoteIf <strong>the</strong> override is per<strong>for</strong>med in <strong>the</strong> sysinit2() function, <strong>the</strong> effect isnot realized until after <strong>the</strong> low-level system memory searches havebeen per<strong>for</strong>med. This means that any runtime override of <strong>the</strong> defaultsettings pertaining to <strong>the</strong> memory search must be done from <strong>the</strong> codein <strong>the</strong> P2 module code.#define NEWINFO#include #include #include #include #include #include error_code p2start(Rominfo rinf, u_char *glbls){/* if switch or jumper setting is set… */if (switch_or_jumper == SET) {/* <strong>for</strong>ce checking of ROM and RAM lists */rinf->os->boot_config &= ~(B_OKROM+B_OKRAM);}return SUCCESS;}<strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong> 75


ATheFastboot Enhancement76 <strong>Enhanced</strong> <strong>OS</strong>-9 <strong>for</strong> <strong>the</strong> <strong>PID7T</strong> <strong>Board</strong> <strong>Guide</strong>


Product Discrepancy ReportTo: Microware Customer SupportFAX: 515-224-1352From:___________________________________________Company:_______________________________________Phone:__________________________________________Fax:_____________________Email:__________________Product Name:Description of Problem:________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________Host Plat<strong>for</strong>m______________________________________Target Plat<strong>for</strong>m____________________________________77

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!