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

📄 conc_pr6.htm

📁 ST20 Embedded Toolset R2.0.5用于开发基于ST20芯片机顶盒软件的开发平台,2.0.5版本,国内找不到的.在国外论坛上花了N天才找到!
💻 HTM
字号:
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<meta name="GENERATOR" content="Quadralay WebWorks Publisher Professional Edition 6.0.5">
<meta name="TEMPLATEBASE" content="book_html">
<meta name="LASTUPDATED" content="08/22/03 10:12:45">
<title>7.5 Channel communication, synchronization and data-transfer</title>

<STYLE TYPE="text/css">
<!--
	span.Signal { text-transform: uppercase; font-family: Verdana }
-->
</STYLE>

</head>

<body link="#3366CC" vlink="#9999CC" text="#000000" alink="#0000CC" bgcolor="#FFFFFF"
background="images/backgrnd.gif">

<p><img src="images/stlogo.gif" width="106" height="83" align="left"
alt="logo here!"> </p>

<table width="331" border="0" align="right" cellpadding="0" cellspacing="0">
  <tr>
    <td><a href="c2isetto.htm"><img src="images/navtoc.gif" width="84" height="23"
    border="0" alt="TOC"> </a></td>
    <td><a href="conc_pr5.htm"><img src="images/navprev.gif" width="80" height="23"
    border="0" alt="PREV"> </a></td>
    <td><a href="conc_pr7.htm"><img src="images/navnext.gif" width="83" height="23"
    border="0" alt="NEXT"> </a></td>
    <td><a href="c2isetix.htm"><img src="images/navidx.gif" width="84" height="23"
    border="0" alt="INDEX"> </a></td>
  </tr>
</table>

<p><br clear="all">
</p>

<hr align="left">

<blockquote>
<h2>
  <a name="1205163"> </a><font color="#003366"  face="Verdana, Arial, Helvetica, sans-serif">7.5 	 Channel communication, synchronization and data-transfer</font>
</h2><hr>


<p>
  <a name="1208783"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">Channel communication is a means whereby two processes can synchronize and transfer data down a unidirectional point-to-point channel. When a process attempts to communicate it does not continue with execution until the process at the other end of the channel also wishes to communicate. When both process are ready (that is, the two processes are synchronized), the associated data transfer occurs before the processes are permitted to continue with execution.</font>
</p>


<p>
  <a name="1205166"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">This section introduces the various channel implementations, discusses synchronization, details the different types of channel communication, and finally explains how internal channels are implemented and initialized.</font>
</p>


<p>
  <a name="1205167"> </a><font size=2 face="Verdana, Arial, Helvetica, sans-serif"><em>Note:	 On systems that use the ST20-C2, the channel communication protocol is also used to control various internal peripherals. In these cases the `communication' is the (possibly DMA based) activity performed by the subsystem and terms such as `ready to communicate' and `completion of communication' in the subsequent text must be interpreted in this light.</em></font>
</p>

<h3>
  <a name="1205174"> </a><font color="#003366"  face="Verdana, Arial, Helvetica, sans-serif">7.5.1 	 Channels</font>
</h3>


<p>
  <a name="1208692"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">A channel is used for synchronization and data-transfer between two processes. It may be implemented by:</font>
</p>

<ul>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1208750"> </a>a word in memory - for communication between processes on a single ST20-C2 (internal channel), </font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1208754"> </a>an external link - for communication between:</font></p>
  <ul>
<p>    <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1208712"> </a>two ST20-C2's or </font></p>
<p>    <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1208717"> </a>an ST20-C2 and an external device (via an external channel) or an internal subsystem. </font></p>
  </ul>
</ul>

<p>
  <a name="1208722"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">A channel is uniquely identified by a `channel address'. For an internal channel, the channel address corresponds to a memory location which may be allocated by the compiler. For an external channel, the channel address belongs to a range of addresses reserved for external channels (details of this are found in the datasheet for a particular part using the ST20-C2 core).</font>
</p>


<p>
  <a name="1205176"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">A process can be written and compiled without knowledge of whether its channels are connected to other processes on the same processor, or other processors. The same instruction sequence is used in both cases. That is, a process that uses instructions to communicate on a channel, does not need to know how the channel is implemented. However some instructions can only be used on specified implementations. There are two implementations for channels; internal channels and link channels. Link channels are referred to generically as external channels. The instructions determine the channel implementation at run-time.</font>
</p>

<ul>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205177"> </a>An internal channel (sometimes referred to as a soft channel) connects processes that are on the same processor.</font></p>
<p>  <font size=2  face="Verdana, Arial, Helvetica, sans-serif"><li ><a name="1205178"> </a>A link channel allows communication between a process on two neighboring ST20-C2 processors using communication links. This form of communication is also used to access internal subsystems on the ST20-C2 which are suited to the channel interface protocol.</font></p>
</ul>

<h3>
  <a name="1205181"> </a><font color="#003366"  face="Verdana, Arial, Helvetica, sans-serif">7.5.2 	 Synchronization</font>
</h3>


<p>
  <a name="1205182"> </a><font size=2  face="Verdana, Arial, Helvetica, sans-serif">Before data-transfer can occur, there must be synchronization between the inputting and outputting process. The general philosophy is that there are always two sides to any communication, that is, an input and an output. There are two ways of achieving synchronization, which are specific to channels. More generally the semaphore mechanism provided on the ST20-C2 (see <a href="conc_pr8.htm#1205811"><font  color="#0000ff" face="Verdana, Arial, Helvetica, sans-serif"><i>Section

⌨️ 快捷键说明

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