8255_8h_source.html 13.5 KB
Newer Older
Philippe Gerum's avatar
Philippe Gerum committed
1 2 3 4 5
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
Philippe Gerum's avatar
Philippe Gerum committed
6
<meta name="generator" content="Doxygen 1.8.9.1"/>
Philippe Gerum's avatar
Philippe Gerum committed
7 8 9 10 11 12
<title>Xenomai: kernel/drivers/analogy/intel/8255.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
Philippe Gerum's avatar
Philippe Gerum committed
13
<script type="text/javascript" src="navtreedata.js"></script>
Philippe Gerum's avatar
Philippe Gerum committed
14 15 16 17 18 19 20 21 22 23 24 25
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() {
    if ($('.searchresults').length > 0) { searchBox.DOMSearchField().focus(); }
  });
</script>
Philippe Gerum's avatar
Philippe Gerum committed
26
<link rel="search" href="search_opensearch.php?v=opensearch.xml" type="application/opensearchdescription+xml" title="Xenomai"/>
Philippe Gerum's avatar
Philippe Gerum committed
27 28 29 30 31 32 33 34 35 36
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">Xenomai
Philippe Gerum's avatar
Philippe Gerum committed
37
   &#160;<span id="projectnumber">3.0-rc7</span>
Philippe Gerum's avatar
Philippe Gerum committed
38 39 40 41 42 43 44
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
Philippe Gerum's avatar
Philippe Gerum committed
45
<!-- Generated by Doxygen 1.8.9.1 -->
Philippe Gerum's avatar
Philippe Gerum committed
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
          <div class="left">
            <form id="FSearchBox" action="search.php" method="get">
              <img id="MSearchSelect" src="search/mag.png" alt=""/>
              <input type="text" id="MSearchField" name="query" value="Search" size="20" accesskey="S" 
                     onfocus="searchBox.OnSearchFieldFocus(true)" 
                     onblur="searchBox.OnSearchFieldFocus(false)"/>
            </form>
          </div><div class="right"></div>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('8255_8h_source.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">8255.h</div>  </div>
</div><!--header-->
<div class="contents">
Philippe Gerum's avatar
Philippe Gerum committed
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> * Hardware driver for 8255 chip</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> * @note Copyright (C) 1999 David A. Schleef &lt;ds@schleef.org&gt;</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> * This library is free software; you can redistribute it and/or</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"> * modify it under the terms of the GNU Lesser General Public</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> * License as published by the Free Software Foundation; either</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> * version 2 of the License, or (at your option) any later version.</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> * This library is distributed in the hope that it will be useful,</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment"> * but WITHOUT ANY WARRANTY; without even the implied warranty of</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * Lesser General Public License for more details.</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment"> * You should have received a copy of the GNU Lesser General Public</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment"> * License along with this library; if not, write to the Free Software</span></div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment"> * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA.</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="preprocessor">#ifndef __ANALOGY_8255_H__</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
116 117
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="preprocessor">#define __ANALOGY_8255_H__</span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
118
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;<span class="preprocessor">#include &lt;rtdm/analogy/device.h&gt;</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
119 120
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;<span class="keyword">typedef</span> int (*a4l_8255_cb_t)(int, int, int, <span class="keywordtype">unsigned</span> long);</div>
Philippe Gerum's avatar
Philippe Gerum committed
121
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
122 123 124 125 126 127 128 129 130 131
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>subd_8255_struct {</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;        <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> cb_arg;</div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;        a4l_8255_cb_t cb_func;</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;        <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> status;</div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;        <span class="keywordtype">int</span> have_irq;</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;        <span class="keywordtype">int</span> io_bits;</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;} subd_8255_t;</div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;<span class="preprocessor">#if (defined(CONFIG_XENO_DRIVERS_ANALOGY_8255) || \</span></div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;<span class="preprocessor">     defined(CONFIG_XENO_DRIVERS_ANALOGY_8255_MODULE))</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
132
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
133
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;<span class="preprocessor">#define _8255_SIZE 4</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
134
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
135
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;<span class="preprocessor">#define _8255_DATA 0</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
136 137
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;<span class="preprocessor">#define _8255_CR 3</span></div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
138
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;<span class="preprocessor">#define CR_C_LO_IO      0x01</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
139 140 141 142 143 144 145
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;<span class="preprocessor">#define CR_B_IO         0x02</span></div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;<span class="preprocessor">#define CR_B_MODE       0x04</span></div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;<span class="preprocessor">#define CR_C_HI_IO      0x08</span></div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;<span class="preprocessor">#define CR_A_IO         0x10</span></div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;<span class="preprocessor">#define CR_A_MODE(a)    ((a)&lt;&lt;5)</span></div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;<span class="preprocessor">#define CR_CW           0x80</span></div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
146 147 148 149
<div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;<span class="keywordtype">void</span> a4l_subdev_8255_init(<span class="keyword">struct</span> <a class="code" href="structa4l__subdevice.html">a4l_subdevice</a> *subd);</div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;<span class="keywordtype">void</span> a4l_subdev_8255_interrupt(<span class="keyword">struct</span> <a class="code" href="structa4l__subdevice.html">a4l_subdevice</a> *subd);</div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;</div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;<span class="preprocessor">#else </span><span class="comment">/* !CONFIG_XENO_DRIVERS_ANALOGY_8255 */</span><span class="preprocessor"></span></div>
Philippe Gerum's avatar
Philippe Gerum committed
150
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
151
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;<span class="preprocessor">#define a4l_subdev_8255_init(x)         do { } while(0)</span></div>
Philippe Gerum's avatar
Philippe Gerum committed
152 153
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;<span class="preprocessor">#define a4l_subdev_8255_interrupt(x)    do { } while(0)</span></div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
154
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;<span class="preprocessor">#endif </span><span class="comment">/* CONFIG_XENO_DRIVERS_ANALOGY_8255 */</span><span class="preprocessor"></span></div>
Philippe Gerum's avatar
Philippe Gerum committed
155
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;</div>
Philippe Gerum's avatar
Philippe Gerum committed
156
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;<span class="preprocessor">#endif </span><span class="comment">/* !__ANALOGY_8255_H__ */</span><span class="preprocessor"></span></div>
Philippe Gerum's avatar
Philippe Gerum committed
157 158 159 160 161 162
<div class="ttc" id="structa4l__subdevice_html"><div class="ttname"><a href="structa4l__subdevice.html">a4l_subdevice</a></div><div class="ttdoc">Structure describing the subdevice. </div><div class="ttdef"><b>Definition:</b> subdevice.h:40</div></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
Philippe Gerum's avatar
Philippe Gerum committed
163
    <li class="navelem"><a class="el" href="dir_8b78405b740e5bdbd92488e46bcf1f2c.html">kernel</a></li><li class="navelem"><a class="el" href="dir_4fdcb1398e61e008bc24b5c82dd0e413.html">drivers</a></li><li class="navelem"><a class="el" href="dir_31a96663369dc5c2c94e127607529c96.html">analogy</a></li><li class="navelem"><a class="el" href="dir_dd5c9ac68f2cb31ff69401ab3669f253.html">intel</a></li><li class="navelem"><b>8255.h</b></li>
Philippe Gerum's avatar
Philippe Gerum committed
164 165
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
Philippe Gerum's avatar
Philippe Gerum committed
166
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.9.1 </li>
Philippe Gerum's avatar
Philippe Gerum committed
167 168 169 170
  </ul>
</div>
</body>
</html>