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

📄 redboot_installing.sgml

📁 eCos/RedBoot for勤研ARM AnywhereII(4510) 含全部源代码
💻 SGML
📖 第 1 页 / 共 5 页
字号:
<!-- {{{ Banner                         -->

<!-- =============================================================== -->
<!--                                                                 -->
<!--     redboot_installing.sgml                                     -->
<!--                                                                 -->
<!--     RedBoot Documentation                                       -->
<!--                                                                 -->
<!-- =============================================================== -->
<!-- ####COPYRIGHTBEGIN####                                          -->
<!--                                                                 -->
<!-- =============================================================== -->
<!-- Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003 Red Hat, Inc.  -->
<!-- This material may be distributed only subject to the terms      -->
<!-- and conditions set forth in the Open Publication License, v1.0  -->
<!-- or later (the latest version is presently available at          -->
<!-- http://www.opencontent.org/openpub/)                            -->
<!-- Distribution of the work or derivative of the work in any       -->
<!-- standard (paper) book form is prohibited unless prior           -->
<!-- permission obtained from the copyright holder                   -->
<!-- =============================================================== -->
<!--                                                                 -->      
<!-- ####COPYRIGHTEND####                                            -->
<!-- =============================================================== -->
<!-- #####DESCRIPTIONBEGIN####                                       -->
<!--                                                                 -->
<!-- ####DESCRIPTIONEND####                                          -->
<!-- =============================================================== -->

<!-- }}} -->

<!-- FIXME:
   Need to make index terms consistent
-->


<chapter id="Installation-and-Testing">
<title>Installation and Testing</title>
<indexterm><primary>installing and testing RedBoot</primary></indexterm><indexterm>
<primary>RedBoot</primary><secondary>installing and testing</secondary></indexterm>

<!-- *************************** AM3x ********************** -->

<?Pub _newpage>
<sect1 id="asb2305">
<title>AM3x/MN103E010 Matsushita MN103E010 (AM33/2.0) ASB2305 Board</title>
<sect2>
<title>Overview</title>
<para>
<indexterm>
<primary>Matsushita MN103E010 (AM33/2.0) ASB2305 Board</primary>
<secondary>installing and testing</secondary>
</indexterm>
<indexterm>
<primary>installing and testing</primary>
<secondary>Matsushita MN103E010 (AM33/2.0) ASB2305 Board</secondary>
</indexterm>
RedBoot supports the debug serial port and the built in ethernet port for communication and
downloads. The default serial port settings are 115200,8,N,1 with RTS/CTS flow control. RedBoot can
run from either flash, and can support flash management for either the boot PROM or the system
flash regions.</para>

<para>The following RedBoot configurations are supported:

      <informaltable frame="all">
	<tgroup cols="4" colsep="1" rowsep="1" align="left">
	  <thead>
	    <row>
	      <entry>Configuration</entry>
	      <entry>Mode</entry>
	      <entry>Description</entry>
	      <entry>File</entry>
	    </row>
	  </thead>
	  <tbody>
	    <row>
	      <entry>PROM</entry>
	      <entry>[ROM]</entry>
	      <entry>RedBoot running from the boot PROM and able to
	      access the system flash.</entry>
	      <entry>redboot_ROM.ecm</entry>
	    </row>
	    <row>
	      <entry>FLASH</entry>
	      <entry>[ROM]</entry>
	      <entry>RedBoot running from the system flash and able to
	      access the boot PROM.</entry>
	      <entry>redboot_FLASH.ecm</entry>
	    </row>
	    <row>
	      <entry>RAM</entry>
	      <entry>[RAM]</entry>
	      <entry>RedBoot running from RAM and able to access the
	      boot PROM.</entry>
	      <entry>redboot_RAM.ecm</entry>
	    </row>
</tbody>
</tgroup>
</informaltable>
</para>
</sect2>

<sect2>
<title>Initial Installation</title>
<para>Unless a pre-programmed system flash module is available to be plugged into a new board,
RedBoot must be installed with the aid of a JTAG interface unit. To achieve this, the RAM mode
RedBoot must be loaded directly into RAM by JTAG and started, and then <emphasis>that</emphasis>
must be used to store the ROM mode RedBoot into the boot PROM.</para>
<para>These instructions assume that you have binary images of the RAM-based and boot PROM-based
RedBoot images available.</para>
<sect3>
<title>Preparing to program the board</title>
<para>If the board is to be programmed, whether via JTAG or RedBoot, some hardware settings need to
be changed:</para>
<itemizedlist>
<listitem>
<para>Jumper across ST18 on the board to allow write access to the boot PROM.</para>
</listitem>
<listitem>
<para>Set DIP switch S1-3 to OFF to allow RedBoot to write to the system flash.</para>
</listitem>
<listitem>
<para>Set the switch S5 (on the front of the board) to boot from whichever flash is
<emphasis>not</emphasis> being programmed. Note that the RedBoot image cannot access the flash from
which it is currently executing (it can only access the other flash).</para>
</listitem>
</itemizedlist>
<para>
The RedBoot binary image files should also be copied to the TFTP pickup area on the host providing
TFTP services if that is how RedBoot should pick up the images it is going to program into the
flash. Alternatively, the images can be passed by YMODEM over the serial link.
</para>
</sect3>
<sect3>
<title>Preparing to use the JTAG debugger</title>
<para>The JTAG debugger will also need setting up:</para>
<orderedlist>
<listitem><para>Install the JTAG debugger software (WICE103E) on a PC running Windows (WinNT is
probably the best choice for this) in &ldquo;C:/PanaX&rdquo;.</para>
</listitem>
<listitem><para>Install the Matsushita provided &ldquo;project&rdquo; into the
&ldquo;C:/Panax/wice103e/prj&rdquo; directory.</para>
</listitem>
<listitem><para>Install the RedBoot image files into the &ldquo;C:/Panax/wice103e/prj&rdquo;
directory under the names redboot.ram and redboot.prom.</para>
</listitem>
<listitem><para>Make sure the PC's BIOS has the parallel port set to full bidirectional
mode.</para>
</listitem>
<listitem><para>Connect the JTAG debugger to the PC's parallel port.</para>
</listitem>
<listitem><para>Connect the JTAG debugger to the board.</para>
</listitem>
<listitem><para>Set the switch on the front of the board to boot from &ldquo;boot
PROM&rdquo;.</para>
</listitem>
<listitem><para>Power up the JTAG debugger and then power up the board.</para>
</listitem>
<listitem><para>Connect the board's Debug Serial port to a computer by a null modem cable.</para>
</listitem>
<listitem><para>Start minicom or some other serial communication software and set for 115200 baud,
1-N-8 with hardware (RTS/CTS) flow control.</para>
</listitem>
</orderedlist>
</sect3>
<sect3>
<title>Loading the RAM-based RedBoot via JTAG</title>
<para>To perform the first half of the operation, the following steps should be followed:</para>
<orderedlist>
<listitem><para>Start the JTAG debugger software.</para>
</listitem>
<listitem>
<para>Run the following commands at the JTAG debugger's prompt to set up the MMU registers on the
CPU.</para>
<screen>
<userinput>ed 0xc0002000, 0x12000580</userinput>

<userinput>ed 0xd8c00100, 0x8000fe01</userinput>
<userinput>ed 0xd8c00200, 0x21111000</userinput>
<userinput>ed 0xd8c00204, 0x00100200</userinput>
<userinput>ed 0xd8c00208, 0x00000004</userinput>

<userinput>ed 0xd8c00110, 0x8400fe01</userinput>
<userinput>ed 0xd8c00210, 0x21111000</userinput>
<userinput>ed 0xd8c00214, 0x00100200</userinput>
<userinput>ed 0xd8c00218, 0x00000004</userinput>

<userinput>ed 0xd8c00120, 0x8600ff81</userinput>
<userinput>ed 0xd8c00220, 0x21111000</userinput>
<userinput>ed 0xd8c00224, 0x00100200</userinput>
<userinput>ed 0xd8c00228, 0x00000004</userinput>

<userinput>ed 0xd8c00130, 0x8680ff81</userinput>
<userinput>ed 0xd8c00230, 0x21111000</userinput>
<userinput>ed 0xd8c00234, 0x00100200</userinput>
<userinput>ed 0xd8c00238, 0x00000004</userinput>

<userinput>ed 0xd8c00140, 0x9800f801</userinput>
<userinput>ed 0xd8c00240, 0x00140000</userinput>
<userinput>ed 0xd8c00244, 0x11011100</userinput>
<userinput>ed 0xd8c00248, 0x01000001</userinput>

<userinput>ed 0xda000000, 0x55561645</userinput>
<userinput>ed 0xda000004, 0x000003c0</userinput>
<userinput>ed 0xda000008, 0x9000fe01</userinput>
<userinput>ed 0xda00000c, 0x9200fe01</userinput>
<userinput>ed 0xda000000, 0xa89b0654</userinput>
</screen>
</listitem>
<listitem>
<para>Run the following commands at the JTAG debugger's prompt to tell it what regions of the CPU's
address space it can access:</para>
<screen>
<userinput>ex 0x80000000,0x81ffffff,/mexram</userinput>
<userinput>ex 0x84000000,0x85ffffff,/mexram</userinput>
<userinput>ex 0x86000000,0x867fffff,/mexram</userinput>
<userinput>ex 0x86800000,0x87ffffff,/mexram</userinput>
<userinput>ex 0x8c000000,0x8cffffff,/mexram</userinput>
<userinput>ex 0x90000000,0x93ffffff,/mexram</userinput>
</screen>
</listitem>
<listitem><para>Instruct the debugger to load the RAM RedBoot image into RAM:</para>
<screen>
<userinput>_pc=90000000</userinput>
<userinput>u_pc</userinput>
<userinput>rd redboot.ram,90000000</userinput>
</screen>
</listitem>
<listitem><para>Load the boot PROM RedBoot into RAM:</para>
<screen>
<userinput>rd redboot.prom,91020000</userinput>
</screen>
</listitem>
<listitem><para>Start RedBoot in RAM:</para>
<screen>
<userinput>g</userinput>
</screen>
<para>Note that RedBoot may take some time to start up, as it will attempt to query a BOOTP or DHCP
server to try and automatically get an IP address for the board. Note, however, that it should send
a plus over the serial port immediately, and the 7-segment LEDs should display &ldquo;rh
8&rdquo;.</para>
</listitem>
</orderedlist>
</sect3>
<sect3>
<title>Loading the boot PROM-based RedBoot via the RAM mode RedBoot</title>
<para>Once the RAM mode RedBoot is up and running, it can be communicated with by way of the serial
port. Commands can now be entered directly to RedBoot for flashing the boot PROM.</para>
<orderedlist>
<listitem><para>Instruct RedBoot to initialise the boot PROM:</para>
<screen>
RedBoot> <userinput>fi init</userinput>
</screen>
</listitem>
<listitem><para>Write the previously loaded redboot.prom image into the boot PROM:</para>
<screen>
RedBoot> <userinput>fi write -f 0x80000000 -b 0x91020000 -l 0x00020000</userinput>
</screen>
</listitem>
<listitem><para>Check that RedBoot has written the image:</para>
<screen>
RedBoot> <userinput>dump -b 0x91020000</userinput>
RedBoot> <userinput>dump -b 0x80000000</userinput>
</screen>
<para>Barring the difference in address, the two dumps should be the same.</para>
</listitem>
<listitem><para>Close the JTAG software and power-cycle the board. The RedBoot banners should be
displayed again over the serial port, followed by the RedBoot prompt. The boot PROM-based RedBoot
will now be running.</para>
</listitem>
<listitem><para>Power off the board and unjumper ST18 to write-protect the contents of the boot
PROM. Then power the board back up.</para>
</listitem>
<listitem><para>Run the following command to initialise the system flash:</para>
<screen>
RedBoot> <userinput>fi init</userinput>
</screen>
<para>Then program the system flash based RedBoot into the system flash:</para>
<screen>
RedBoot> <userinput>load -r -b %{FREEMEMLO} redboot_FLASH.bin</userinput>
RedBoot> <userinput>fi write -f 0x84000000 -b %{FREEMEMLO} -l 0x00020000</userinput>
</screen>
<note>
<title>NOTE</title>
<para>RedBoot arranges the flashes on booting such that they always appear at the same addresses,
no matter which one was booted from.</para>
</note>
</listitem>
<listitem>
<para>A similar sequence of commands can be used to program the boot PROM when RedBoot has been
booted from an image stored in the system flash.
</para>
<screen>
RedBoot> <userinput>load -r -b %{FREEMEMLO} /tftpboot/redboot_ROM.bin</userinput>
RedBoot> <userinput>fi write -f 0x80000000 -b %{FREEMEMLO} -l 0x00020000</userinput>
</screen>
<para>See <xref linkend="Persistent-State-Flash"> for details on configuring the RedBoot in
general, and also <xref linkend="Flash-Image-System"> for more details on programming the system
flash.</para>
</listitem>
</orderedlist>
</sect3>
</sect2>
<sect2>
<title>Additional Commands</title>
<para>The <command>exec</command> command which allows the loading and execution of
Linux kernels, is supported for this architecture (see <xref linkend="executing-programs">). The
<command>exec</command> parameters used for ASB2305 board are:</para>
<variablelist>
<varlistentry><term>
-w <replaceable>&lt;time></replaceable></term>
<listitem><para>Wait time in seconds before starting kernel</para></listitem></varlistentry>
<varlistentry><term>
-c <replaceable>"params"</replaceable></term>
<listitem><para>Parameters passed to kernel</para></listitem></varlistentry>
<varlistentry><term><replaceable>&lt;addr></replaceable></term>
<listitem><para>Kernel entry point, defaulting to the entry point of the last image
loaded</para></listitem></varlistentry>
</variablelist>
<para>The parameter string is stored in the on-chip memory at location 0x8C001000, and is prefixed
by &ldquo;cmdline:&rdquo; if it was supplied.</para>
</sect2>
<sect2>
<title>Memory Maps </title>
<para>RedBoot sets up the following memory map on the ASB2305 board.</para>
<note>
<title>NOTE</title>
<para>The regions mapped between 0x80000000-0x9FFFFFFF are cached by the CPU. However, all those
regions can be accessed uncached by adding 0x20000000 to the address.</para>
</note>
<programlisting>
Physical Address Range   Description
-----------------------  -----------
0x80000000 - 0x9FFFFFFF  Cached Region
0x80000000 - 0x81FFFFFF  Boot PROM
0x84000000 - 0x85FFFFFF  System Flash
0x86000000 - 0x86007FFF  64Kbit Sys Config EEPROM
0x86F90000 - 0x86F90003  4x 7-segment LEDs
0x86FA0000 - 0x86FA0003  Software DIP Switches
0x86FB0000 - 0x86FB001F  PC16550 Debug Serial Port
0x8C000000 - 0x8FFFFFFF  On-Chip Memory (repeated 16Kb SRAM)
0x90000000 - 0x93FFFFFF  SDRAM
0x98000000 - 0x9BFFFFFF  Paged PCI Memory Space (64Mb)
0x9C000000 - 0x9DFFFFFF  PCI Local SRAM (32Mb)
0x9E000000 - 0x9E03FFFF  PCI I/O Space
0x9E040000 - 0x9E0400FF  AM33-PCI Bridge Registers
0x9FFFFFF4 - 0x9FFFFFF7  PCI Memory Page Register
0x9FFFFFF8 - 0x9FFFFFFF  PCI Config Registers
0xA0000000 - 0xBFFFFFFF  Uncached Mirror Region
0xC0000000 - 0xDFFFFFFF  CPU Control Registers
</programlisting>

⌨️ 快捷键说明

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