⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 x-ix865.html

📁 this about vxworks operations systems
💻 HTML
📖 第 1 页 / 共 5 页
字号:
</tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><dl class="margin"><dd><div class="Indent"><a name="85476"> </a>Because <b class="command">vxload</b> must read the image file to memory at 0x8000, it checks to see that this memory is not in use by MS-DOS, and generates an error if it is. If you receive such an error, reconfigure your PC target to make the space available by loading MS-DOS into high memory and reducing the number of device drivers. Or start <b class="command">vxload</b> instead of the MS-DOS command interpreter <b class="file">command.com</b>. (If you take this approach, remember to first ensure that you can restore your previous configuration.) </div><br><dd><div class="Indent"><a name="85477"> </a>The following is a sample <b class="file">config.sys</b> file that shows these suggestions:</div><br><dl class="margin"><dd><pre class="Code3"><b><a name="85478">device=c:\dos\himem.sys dos=high,umb shell=c:\vxload.com c:\bootrom.dat</a></b></pre></dl><dd><div class="Indent"><a name="85481"> </a>The file <b class="file">bootrom.dat</b> must have an <b class="file">a.out</b> header, unlike the <b class="file">bootrom.sys</b> file made by <b class="command">mkboot</b>.</div><br></dl></dl></dl><dl class="margin"><dd><font face="Helvetica, sans-serif" size="-1" class="sans"><h5 class="HU"><i><a name="87998">Building a Boot Disk/Diskette from a Solaris Host</a></i></h5></font><dl class="margin"><dd><p class="Body"><a name="87999"> </a>Use <b class="file">/usr/bin/fdformat</b> that comes with Solaris. It requires a bootstrap loader file called <b class="file">vxld.bin</b>, which can be downloaded from WindSurf. </p><dd><p class="Body"><a name="88000"> </a>Copy <b class="file">vxld.bin</b> to your Solaris file system, insert a 1.44 MB diskette into the Sun diskette drive, and issue the <b class="command">fdformat</b> command to format the diskette and install the boot block. </p><dl class="margin"><dd><pre class="Code2"><b><a name="88001">fdformat -U -d -B vxld.bin  </b><tt class="output">Formatting 1.44 MB in /vol/dev/rdiskette0/no_name#7 Press return to start formatting floppy. .................................................................... fdformat: using "vxld.bin" for MS-DOS boot loader</tt><b></a></b></pre></dl><dd><p class="Body"><a name="88006"> </a>Now create the <b class="file">bootrom.sys</b>:</p><dl class="margin"><dd><pre class="Code2"><b><a name="88007"></b><tt class="output">%</tt><b> cd <i class="textVariable">installDir</i>/target/config/<i class="textVariable">bspName </i></b><tt class="output">%</tt><b> make bootrom_uncmp </b><tt class="output">%</tt><b> aoutToBinDec &lt; bootrom_uncop &gt; bootrom.sys</a></b></pre></dl><dd><p class="Body"><a name="88005"> </a>Copy the new <b class="file">bootrom.sys</b> file to your boot diskette.</p></dl><dd><font face="Helvetica, sans-serif" size="-1" class="sans"><h5 class="HU"><i><a name="85484">Building a Boot Disk/Diskette from VxWorks</a></i></h5></font><dl class="margin"><dd><p class="Body"><a name="85487"> </a>The routine <b class="routine"><i class="routine">mkbootFd</i></b><b>(&nbsp;)</b> produces a VxWorks boot diskette, and <b class="routine"><i class="routine">mkbootAta</i></b><b>(&nbsp;)</b> produces a VxWorks boot disk (an IDE or ATA hard disk). Both run on any VxWorks x86 target. They are provided in <i class="textVariable">installDir</i><b class="file">/target/config/</b><i class="textVariable">bspname/</i><b class="file">mkboot.c</b>. Use a DOS-formatted disk or diskette.</p></dl></dl><dl class="margin"><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/caution.gif"></td><td><hr><div class="CalloutCell"><a name="86785"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">CAUTION:  </font></b></a>The <b class="routine"><i class="routine">mkbootFd</i></b><b>(&nbsp;)</b> routine supports only high-density diskettes.</div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><dd><p class="Body"><a name="85497"> </a>The <b class="routine"><i class="routine">mkbootFd</i></b><b>(&nbsp;)</b>, <b class="routine"><i class="routine">mkbootAta</i></b><b>(&nbsp;)</b>, and <b class="routine"><i class="routine">mkbootTffs</i></b><b>(&nbsp;)</b> routines write the boot sector so that it contains the VxWorks bootstrap loader and make a boot image named <b class="file">bootrom.sys</b>. The boot image can be derived from one of the images listed in <a href="x-ix865.html#85675"><i class="title">VxWorks Images</i></a>. Before making any version of the image, make sure that <b class="symbol_UC">DEFAULT_BOOT_LINE</b> in <b class="file">config.h</b> is set correctly (see <i class="title">Tornado User's Guide: Setup and Startup</i>), and that the size of the boot image (text+data+bss) is verified to be less than 512KB. It cannot be larger than this, because it is written into lower memory.</p><dd><p class="Body"><a name="85501"> </a>During the booting process, the VxWorks bootstrap loader reads <b class="file">bootrom.sys</b> and then jumps to the entry point of the boot image. </p><dd><p class="Body"><a name="85502"> </a>The <b class="routine"><i class="routine">mkbootFd</i></b><b>(&nbsp;)</b> routine requires the following parameters: </p><dl class="margin"><dd><pre class="Code2"><b><a name="85503">STATUS mkbootFd (int drive, int fdType, char *filename)</a></b></pre></dl><dd><p class="Body"><a name="85504"> </a>The first two parameters specify the drive number and diskette type, specified as in <a href="x-ix865.html#85530"><i class="title">Booting VxWorks from a Diskette, an ATA/IDE Disk, a PC Card, or a Flash File System</i></a>. The third parameter specifies the file name of the boot image. </p><dd><p class="Body"><a name="85508"> </a>The <b class="routine"><i class="routine">mkbootAta</i></b><b>(&nbsp;)</b> routine requires the following parameters: </p><dl class="margin"><dd><pre class="Code2"><b><a name="85509">STATUS mkbootAta (int ctrl, int drive, char *filename)</a></b></pre></dl><dd><p class="Body"><a name="85510"> </a>The first two parameters specify the controller number and drive number, specified as in <a href="x-ix865.html#85530"><i class="title">Booting VxWorks from a Diskette, an ATA/IDE Disk, a PC Card, or a Flash File System</i></a>. The third parameter specifies the file name of the boot image. </p><dd><p class="Body"><a name="89013"> </a>The <b class="routine"><i class="routine">mkbootTffs</i></b><b>(&nbsp;)</b> routine requires the following parameters: </p><dl class="margin"><dd><pre class="Code2"><b><a name="89014">STATUS mkbootTffs (int drive, int removeBit, char *filename)</a></b></pre></dl><dd><p class="Body"><a name="89015"> </a>The first two parameters specify the drive number and removable bit, specified as in <a href="x-ix865.html#85530"><i class="title">Booting VxWorks from a Diskette, an ATA/IDE Disk, a PC Card, or a Flash File System</i></a>. The third parameter specifies the file name of the boot image. </p><dd><p class="Body"><a name="85514"> </a>For example, to create a boot disk for the pc386 BSP if you are using a UNIX host, first use the following commands on the host to create the <b class="file">mkboot.o</b> object from <b class="file">mkboot.c</b>: </p><dl class="margin"><dd><pre class="Code2"><b><a name="85515"></b><tt class="output">% </tt><b>cd <i class="textVariable">installDir</i>/target/config/pc386 </b><tt class="output">% </tt><b>make mkboot.o</a></b></pre></dl><dd><p class="Body"><a name="85516"> </a>Then, from the Tornado shell, move to the appropriate directory, load <b class="file">mkboot.o</b>, and then invoke <b class="routine"><i class="routine">mkbootFd</i></b><b>(&nbsp;)</b>, <b class="routine"><i class="routine">mkbootAta</i></b><b>(&nbsp;)</b>, or <b class="routine"><i class="routine">mkbootTffs</i></b><b>(&nbsp;)</b>. Remember to place a formatted, empty diskette in the appropriate drive if you use <b class="routine"><i class="routine">mkbootFd</i></b><b>(&nbsp;)</b>.</p><dd><p class="Body"><a name="85517"> </a>In this example, <b class="routine"><i class="routine">mkbootAta</i></b><b>(&nbsp;)</b> builds a local IDE disk on drive <b class="file">C:</b> from <b class="file">bootrom_uncmp</b> with the default <b class="symbol_lc">ataResources[]</b> table (see <a href="x-ix865.html#86295"><i class="title">ATA/IDE Disk Driver</i></a>):</p><dl class="margin"><dd><pre class="Code2"><b><a name="85522"></b><tt class="output">-&gt;</tt><b> cd "<i class="textVariable">installDir</i>/target/config/pc386" </b><tt class="output">-&gt;</tt><b> ld &lt; mkboot.o </b><tt class="output">-&gt;</tt><b> mkbootAta 0,0,"bootrom_uncmp"<b class="routine"><i class="routine"></i></b></a></b></pre></dl></dl></dl><dl class="margin"><dd><font face="Helvetica, sans-serif" size="-1" class="sans"><h5 class="HU"><i><a name="85530">Booting VxWorks from a Diskette, an ATA/IDE Disk, a PC Card, or a Flash File System</a></i></h5></font><dl class="margin"><dd><p class="Body"><a name="85531"> </a>Four boot devices are available in VxWorks for the x86, one for diskettes, one for ATA/IDE hard disks, one for PCMCIA PC cards, and one for flash files. You can also build your own VxWorks boot ROMs using optional hardware; see <a href="x-ix865.html#85809"><i class="title">ROM Card and EPROM Support</i></a>. Alternatively, as with other VxWorks platforms, you can also boot over an Ethernet (using one of the supported Ethernet cards), or over a SLIP connection.</p></dl></dl><dl class="margin"><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/caution.gif"></td><td><hr><div class="CalloutCell"><a name="86804"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">CAUTION:  </font></b></a>Because standard PC BIOS components do not support initial booting from PCMCIA devices, systems which load VxWorks from these devices must use a VxWorks boot disk/diskette. See <a href="x-ix865.html#85397"><i class="title">Building a Boot Disk/Diskette from MS-DOS</i></a>, <a href="x-ix865.html#87998"><i class="title">Building a Boot Disk/Diskette from a Solaris Host</i></a>, and <a href="x-ix865.html#85484"><i class="title">Building a Boot Disk/Diskette from VxWorks</i></a>.</div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><dd><p class="Body"><a name="85552"> </a>When booting from a diskette, an ATA/IDE disk, a PC card, or a flash file system, first make sure that the boot device is formatted for an MS-DOS file system. The VxWorks boot program mounts the boot device by automatically calling either <b class="routine"><i class="routine">usrFdConfig</i></b><b>(&nbsp;)</b> in <b class="file">usrFd.c</b> for diskettes, <b class="routine"><i class="routine">usrAtaConfig</i></b><b>(&nbsp;)</b> in <b class="file">usrAta.c</b> for ATA/IDE hard disks, <b class="routine"><i class="routine">usrPcmciaConfig</i></b><b>(&nbsp;)</b> in <b class="file">usrPcmcia.c</b> for PC cards, or <b class="routine"><i class="routine">usrTffsConfig</i></b><b>(&nbsp;)</b> for flash file systems. (All files are located in <i class="textVariable">installDir</i><b class="file">/target/src/config</b>.) </p></dl><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/caution.gif"></td><td><hr><div class="CalloutCell"><a name="87650"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">CAUTION:  </font></b></a>Because the boot program uses <b class="routine"><i class="routine">usrFdConfig</i></b><b>(&nbsp;)</b> for floppy diskettes, and because <b class="routine"><i class="routine">usrFdConfig</i></b><b>(&nbsp;)</b> does not provide the <b class="symbol_UC">DOS_VOL_CONFIG</b> structure required to use <b class="routine"><i class="routine">dosFsVolUnmount</i></b><b>(&nbsp;)</b>, you must instead use <b class="routine"><i class="routine">ioctl</i></b><b>(&nbsp;)</b> with <b class="symbol_UC">FIOUNMOUNT</b> before removing the floppy diskette.</div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><dd><p class="Body"><a name="85557"> </a>In each case, a <i class="textVariable">mount point</i> name is taken from the file name specified as one of the boot parameters. You might choose diskette zero (drive <b class="file">A:</b>) to be mounted as <b class="file">/fd0</b> (by supplying a boot file name that begins with that string). Similarly, you might choose ATA/IDE hard disk zero (drive <b class="file">C:</b>) to be mounted as <b class="file">/ata0</b>, you might choose the PC card in socket 0 to be mounted as <b class="file">/pc0</b>, or you might choose the flash file system called drive 1 as <b class="file">/tffs0</b>. In each case, the name of the directory mount point (<b class="file">fd0</b>, <b class="file">ata0</b>, <b class="file">pc0</b>, or<b class="file"> tffs0</b> in these examples) can be any legal file name. (For more information on <b class="routine"><i class="routine">usrFdConfig</i></b><b>(&nbsp;)</b>, <b class="routine"><i class="routine">usrAtaConfig</i></b><b>(&nbsp;)</b>, <b class="routine"><i class="routine">usrPcmciaConfig</i></b><b>(&nbsp;)</b>, or <b class="routine"><i class="routine">usrTffsConfig</i></b><b>(&nbsp;)</b>, see <a href="x-ix865.html#85632"><i class="title">Mounting a DOS File System</i></a>.)</p><dd><p class="Body"><a name="85561"> </a>Because the PC hardware does not have a standard NVRAM interface, the only way to change default boot parameters is to rebuild the bootstrap code with a new definition for <b class="symbol_UC">DEFAULT_BOOT_LINE</b> in <b class="file">config.h</b>. See <a href="x-ix865.html#86707"><i class="title">Boot Process</i></a> for instructions on how to rebuild the bootstrap code.</p></dl><dd><p class="table" callout><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td valign="top" width="40"><br><img border="0" alt="*" src="icons/caution.gif"></td><td><hr><div class="CalloutCell"><a name="86828"><b class="symbol_UC"><font face="Helvetica, sans-serif" size="-1" class="sans">CAUTION:  </font></b></a>To enable rebooting with <kbd>CTRL+X</kbd>, you must set some of the BSP-specific global variables <b class="symbol_lc">sysWarmType</b>, <b class="symbol_lc">sysWarmFdType</b>, <b class="symbol_lc">sysWarmFdDrive</b>, <b class="symbol_lc">sysWarmAtaCtrl</b>, <b class="symbol_lc">sysWarmAtaDrive</b>, and <b class="symbol_lc">sysWarmTffsDrive</b>, depending on which boot device you use. For more information, see <a href="x-ix865.html#85745">Table&nbsp;D-3</a>. </div></td></tr><tr valign="top"><td></td><td><hr></td></tr><tr valign="middle"><td colspan="20"></td></tr></table></p callout><dl class="margin"><b class="HU-bullet"><li><a name="85581"> </a><font face="Helvetica, sans-serif" size="-1" class="sans">Booting from Diskette</font></li></b></dl><dl class="margin"><dd><p class="Body"><a name="85582"> </a>To boot from a diskette, specify the boot device as <b class="file">fd</b> (for <i class="term">floppy device</i>). First, specify the <i class="textVariable">drive number</i> on the <b class="symbol_lc">boot device:</b> line of the boot parameters display. Then, specify the <i class="textVariable">diskette type</i> (3.5" or 5.25"). The format is as follows: </p><dl class="margin"><dd><pre class="Code2"><b><a name="85583"></b><tt class="output">boot device:</tt><b> fd=<i class="textVariable">drive number</i>, <i class="textVariable">diskette type</i></a></b></pre></dl></dl><dl class="margin"><dd><div class="Item"><a name="85584"> </a><i class="textVariable">drive number</i> </div><dl class="margin"><dd><div class="Indent"><a name="87281"> </a>a digit specifying the diskette drive:<p class="table"><table border="0" cellpadding="0" cellspacing="0"><tr valign="top"><td colspan=1 rowspan=1><p class="BodyLeft"><a name="87290"> </a>0 =</p></td><td colspan=1 rowspan=1><p class="BodyLeft"><a name="87292"> </a>default; the first diskette drive (drive <b class="file">A:</b>)</p></td></tr><tr valign="top"><td colspan=1 rowspan=1><p class="BodyLeft"><a name="87294"> </a>1 =</p></td><td colspan=1 rowspan=1><p class="BodyLeft"><a name="87296"> </a>the second diskette drive (drive <b class="file">B:</b>)</p></td>

⌨️ 快捷键说明

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