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

📄 setup-sh-cq7750.html

📁 有关ecos2。0介绍了实时嵌入式的结构以及线程调度的实现和内存的管理等
💻 HTML
字号:
<!-- Copyright (C) 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 is obtained from the copyright holder.               --><HTML><HEAD><TITLE>SH4/CQ7750 Hardware Setup</TITLE><meta name="MSSmartTagsPreventParsing" content="TRUE"><METANAME="GENERATOR"CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+"><LINKREL="HOME"TITLE="eCos User Guide"HREF="ecos-user-guide.html"><LINKREL="UP"TITLE="Target Setup"HREF="appendix-target-setup.html"><LINKREL="PREVIOUS"TITLE="SH3/SE77x9 Hardware Setup"HREF="setup-sh-se77x9.html"><LINKREL="NEXT"TITLE="SH4/SE7751 Hardware Setup"HREF="setup-sh-se7751.html"></HEAD><BODYCLASS="SECT1"BGCOLOR="#FFFFFF"TEXT="#000000"LINK="#0000FF"VLINK="#840084"ALINK="#0000FF"><DIVCLASS="NAVHEADER"><TABLESUMMARY="Header navigation table"WIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><THCOLSPAN="3"ALIGN="center">eCos User Guide</TH></TR><TR><TDWIDTH="10%"ALIGN="left"VALIGN="bottom"><AHREF="setup-sh-se77x9.html"ACCESSKEY="P">Prev</A></TD><TDWIDTH="80%"ALIGN="center"VALIGN="bottom">Appendix A. Target Setup</TD><TDWIDTH="10%"ALIGN="right"VALIGN="bottom"><AHREF="setup-sh-se7751.html"ACCESSKEY="N">Next</A></TD></TR></TABLE><HRALIGN="LEFT"WIDTH="100%"></DIV><DIVCLASS="SECT1"><H1CLASS="SECT1"><ANAME="SETUP-SH-CQ7750">SH4/CQ7750 Hardware Setup</H1><DIVCLASS="SECT2"><H2CLASS="SECT2"><ANAME="AEN4195">Preparing the board</H2><P>Make sure the DIP switches on the board are set as follows:  </P><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">SW1-1 ONSW1-2 OFF   SW1-3 ON   SW1-4 OFF</PRE></TD></TR></TABLE><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">SW2-1 ON   SW2-2 ON   SW2-3 OFF   SW2-4 OFF</PRE></TD></TR></TABLE><P>If you are using a straight through serial cable which hasflow control lines, you will also need to cut JP12 (5-6) as theflow control lines can cause NMIs.</P></DIV><DIVCLASS="SECT2"><H2CLASS="SECT2"><ANAME="AEN4201">eCos GDB Stubs</H2><P>The eCos installation CD contains a copy of the eCos GDB stubsin  binary format which must be programmed into an EPROM or FLASHand  installed on the board.</P><DIVCLASS="SECT3"><H3CLASS="SECT3"><ANAME="AEN4204">Preparing the GDB stubs</H3><P>These stub preparation steps are not strictly necessary asthe eCos distribution ships with pre-compiled stubs in the directoryloaders/sh3-cq7708 relative to the installation root.</P></DIV><DIVCLASS="SECT3"><H3CLASS="SECT3"><ANAME="AEN4207">Building the GDB stub image with the eCos Configuration Tool</H3><P></P><OLTYPE="1"><LI><P>Start with a new document - selecting the <SPANCLASS="emphasis"><ICLASS="EMPHASIS">File-&#62;New</I></SPAN> menu item if necessary to do this.</P></LI><LI><P>Choose the <SPANCLASS="emphasis"><ICLASS="EMPHASIS">Build-&#62;Templates</I></SPAN> menu item, and then select the SH3 cq7708 hardware.</P></LI><LI><P>While still displaying the <SPANCLASS="emphasis"><ICLASS="EMPHASIS">Build-&#62;Templates</I></SPAN> dialog box, select the stubs package template to build a GDB stub.Click <SPANCLASS="emphasis"><ICLASS="EMPHASIS">OK</I></SPAN>.</P></LI><LI><P> Build eCos stubs using <SPANCLASS="emphasis"><ICLASS="EMPHASIS">Build-&#62;Library</I></SPAN>.</P></LI><LI><P> When the build completes, the image files can be foundin the <TTCLASS="FILENAME">bin/</TT> subdirectory of the install tree. GDB stub images have the prefix <TTCLASS="FILENAME">gdb_module</TT>.</P></LI></OL></DIV><DIVCLASS="SECT3"><H3CLASS="SECT3"><ANAME="AEN4227">Building the GDB stub image with ecosconfig</H3><P></P><OLTYPE="1"><LI><P>Make an empty directory to contain the build tree,and cd into it.</P></LI><LI><P> To build a GDB stub ROM image, enter the command:      <TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">$ ecosconfig new cq7708 stubs </PRE></TD></TR></TABLE></P></LI><LI><P> Enter the commands:    <TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">$ ecosconfig tree      $ make</PRE></TD></TR></TABLE></P></LI><LI><P>When the build completes, the image files can be foundin the <TTCLASS="FILENAME">bin/</TT> subdirectory of the install tree. GDB stub images have the prefix <TTCLASS="FILENAME">gdb_module</TT>.  </P></LI></OL></DIV></DIV><DIVCLASS="SECT2"><H2CLASS="SECT2"><ANAME="AEN4242">Programming the stubs in EPROM/FLASH</H2><P>The board can use different sizes of ROMs. Use this tableto adjust the board&#8217;s jumpers to the ROM sizes you areusing.</P><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING">size(kbit)    JP7   JP9   JP10   JP11     256           2-3   2-3   open   open     512           1-2   2-3   open   open     1000          1-2   open  open   2-3     2000          1-2   1-2   open   2-3     4000          1-2   1-2   short  2-3     8000          1-2   1-2   short  1-2</PRE></TD></TR></TABLE><P>There are two ways to program the stubs. We advise you touse method 1, since it is simpler. Method 2 is unsupported and requiresa bit of fiddling.</P><P><SPANCLASS="emphasis"><ICLASS="EMPHASIS">Method 1: </I></SPAN> </P><P>Program the binary stub image into two EPROMs, E and O. EPROME should  contain the even bytes, and O the odd bytes (your EPROMprogrammer should  have the ability to split the image).</P><P>EPROM E should be installed in socket IC8, and EPROM O shouldbe  installed in socket IC4.</P><P>Set JP6 to 16 bit mode (1-2 soldered, 2-3 cut)  Set SW1-4to ON and SW2-1 to OFF.</P><P></P><P><SPANCLASS="emphasis"><ICLASS="EMPHASIS">Method2: </I></SPAN> </P><P>Assuming that the stub binary is smaller than 32 KB, you caninstall it in a single EPROM.</P><P>Compile the <TTCLASS="FILENAME">mkcqrom.c</TT> programfound in the <TTCLASS="FILENAME">misc</TT> directory.</P><P>Use it to convert the binary image to the required format.See the  <TTCLASS="FILENAME">mkcqrom.c</TT> source for adescription of what is done, and why it is  necessary. </P><TABLEBORDER="5"BGCOLOR="#E0E0F0"WIDTH="70%"><TR><TD><PRECLASS="PROGRAMLISTING"> % mkcqrom gdb_module.bin gdb_mangled.bin</PRE></TD></TR></TABLE><P>Program the <TTCLASS="FILENAME">gdb_mangled.bin</TT> fileinto an EPROM and install it in  socket IC4</P><P>Set JP6 to 8 bit mode (cut 1-2, solder 2-3)</P><P>The GDB stubs allow communication with GDB using the serialport at connector CN7. The communication parameters are fixed at38400 baud, 8 data bits, no parity bit and 1 stop bit (8-N-1). Noflow control is employed. Connection to the host computer shouldbe made using a  straight through serial cable.</P></DIV></DIV><DIVCLASS="NAVFOOTER"><HRALIGN="LEFT"WIDTH="100%"><TABLESUMMARY="Footer navigation table"WIDTH="100%"BORDER="0"CELLPADDING="0"CELLSPACING="0"><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top"><AHREF="setup-sh-se77x9.html"ACCESSKEY="P">Prev</A></TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="ecos-user-guide.html"ACCESSKEY="H">Home</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top"><AHREF="setup-sh-se7751.html"ACCESSKEY="N">Next</A></TD></TR><TR><TDWIDTH="33%"ALIGN="left"VALIGN="top">SH3/SE77x9 Hardware Setup</TD><TDWIDTH="34%"ALIGN="center"VALIGN="top"><AHREF="appendix-target-setup.html"ACCESSKEY="U">Up</A></TD><TDWIDTH="33%"ALIGN="right"VALIGN="top">SH4/SE7751 Hardware Setup</TD></TR></TABLE></DIV></BODY></HTML>

⌨️ 快捷键说明

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