Project

General

Profile

Revision 241

Updated libdragonfly documentation.

View differences:

group__analog.html
1 1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
2
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
3 3
<title>libdragonfly: Analog</title>
4 4
<link href="doxygen.css" rel="stylesheet" type="text/css">
5 5
<link href="tabs.css" rel="stylesheet" type="text/css">
6 6
</head><body>
7
<!-- Generated by Doxygen 1.4.6 -->
7
<!-- Generated by Doxygen 1.5.3 -->
8 8
<div class="tabs">
9 9
  <ul>
10 10
    <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
11 11
    <li><a href="modules.html"><span>Modules</span></a></li>
12 12
    <li><a href="files.html"><span>Files</span></a></li>
13
  </ul></div>
13
    <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
14
  </ul>
15
</div>
14 16
<h1>Analog</h1><table border="0" cellpadding="0" cellspacing="0">
15 17
<tr><td></td></tr>
16 18
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
......
105 107
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read the position of the wheel.  <a href="#g973e63eb508819a37efe3231b6a39550"></a><br></td></tr>
106 108
</table>
107 109
<hr><a name="_details"></a><h2>Detailed Description</h2>
108
Functions for manipulation the ADC on the dragonfly board. All definitions may be found in <a class="el" href="analog_8h.html">analog.h</a>. <hr><h2>Function Documentation</h2>
109
<a class="anchor" name="g875bf8cb165a3a288eb1aa2ac06be4f3"></a><!-- doxytag: member="analog.c::analog10" ref="g875bf8cb165a3a288eb1aa2ac06be4f3" args="(int which)" --><p>
110
<table class="mdTable" cellpadding="2" cellspacing="0">
111
  <tr>
112
    <td class="mdRow">
113
      <table cellpadding="0" cellspacing="0" border="0">
110
Functions for manipulation the ADC on the dragonfly board. All definitions may be found in <a class="el" href="analog_8h.html" title="Contains functions and definitions for using the ADC.">analog.h</a>. <hr><h2>Function Documentation</h2>
111
<a class="anchor" name="g875bf8cb165a3a288eb1aa2ac06be4f3"></a><!-- doxytag: member="analog.c::analog10" ref="g875bf8cb165a3a288eb1aa2ac06be4f3" args="(int which)" -->
112
<div class="memitem">
113
<div class="memproto">
114
      <table class="memname">
114 115
        <tr>
115
          <td class="md" nowrap valign="top">unsigned int analog10           </td>
116
          <td class="md" valign="top">(&nbsp;</td>
117
          <td class="md" nowrap valign="top">int&nbsp;</td>
118
          <td class="mdname1" valign="top" nowrap> <em>which</em>          </td>
119
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
120
          <td class="md" nowrap></td>
116
          <td class="memname">unsigned int analog10           </td>
117
          <td>(</td>
118
          <td class="paramtype">int&nbsp;</td>
119
          <td class="paramname"> <em>which</em>          </td>
120
          <td>&nbsp;)&nbsp;</td>
121
          <td width="100%"></td>
121 122
        </tr>
122 123
      </table>
123
    </td>
124
  </tr>
125
</table>
126
<table cellspacing="5" cellpadding="0" border="0">
127
  <tr>
128
    <td>
129
      &nbsp;
130
    </td>
131
    <td>
124
</div>
125
<div class="memdoc">
132 126

  
133 127
<p>
134 128
Read a 10-bit number from an analog port. 
......
139 133
    <tr><td valign="top"></td><td valign="top"><em>which</em>&nbsp;</td><td>the analog port to read from. Typically a constant, one of AN0 - AN7.</td></tr>
140 134
  </table>
141 135
</dl>
142
<dl compact><dt><b>Returns:</b></dt><dd>the ten bit number input to the specified port</dd></dl>
143
<dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#g55f66ff6f3449ef81d97b7e47f041918">analog_init</a>, <a class="el" href="group__analog.html#gf1211040ce2c54f12f98df7d47a4eb27">analog8</a> </dd></dl>
144
    </td>
145
  </tr>
146
</table>
147
<a class="anchor" name="gf1211040ce2c54f12f98df7d47a4eb27"></a><!-- doxytag: member="analog.c::analog8" ref="gf1211040ce2c54f12f98df7d47a4eb27" args="(int which)" --><p>
148
<table class="mdTable" cellpadding="2" cellspacing="0">
149
  <tr>
150
    <td class="mdRow">
151
      <table cellpadding="0" cellspacing="0" border="0">
136
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the ten bit number input to the specified port</dd></dl>
137
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#g55f66ff6f3449ef81d97b7e47f041918" title="Initialize analog ports.">analog_init</a>, <a class="el" href="group__analog.html#gf1211040ce2c54f12f98df7d47a4eb27" title="Read an 8-bit number from an analog port.">analog8</a> </dd></dl>
138

  
139
</div>
140
</div><p>
141
<a class="anchor" name="gf1211040ce2c54f12f98df7d47a4eb27"></a><!-- doxytag: member="analog.c::analog8" ref="gf1211040ce2c54f12f98df7d47a4eb27" args="(int which)" -->
142
<div class="memitem">
143
<div class="memproto">
144
      <table class="memname">
152 145
        <tr>
153
          <td class="md" nowrap valign="top">unsigned int analog8           </td>
154
          <td class="md" valign="top">(&nbsp;</td>
155
          <td class="md" nowrap valign="top">int&nbsp;</td>
156
          <td class="mdname1" valign="top" nowrap> <em>which</em>          </td>
157
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
158
          <td class="md" nowrap></td>
146
          <td class="memname">unsigned int analog8           </td>
147
          <td>(</td>
148
          <td class="paramtype">int&nbsp;</td>
149
          <td class="paramname"> <em>which</em>          </td>
150
          <td>&nbsp;)&nbsp;</td>
151
          <td width="100%"></td>
159 152
        </tr>
160 153
      </table>
161
    </td>
162
  </tr>
163
</table>
164
<table cellspacing="5" cellpadding="0" border="0">
165
  <tr>
166
    <td>
167
      &nbsp;
168
    </td>
169
    <td>
154
</div>
155
<div class="memdoc">
170 156

  
171 157
<p>
172 158
Read an 8-bit number from an analog port. 
......
177 163
    <tr><td valign="top"></td><td valign="top"><em>which</em>&nbsp;</td><td>the analog port to read from. One of the constants AN0 - AN7.</td></tr>
178 164
  </table>
179 165
</dl>
180
<dl compact><dt><b>Returns:</b></dt><dd>the eight bit input to the specified port</dd></dl>
181
<dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#g55f66ff6f3449ef81d97b7e47f041918">analog_init</a>, <a class="el" href="group__analog.html#g875bf8cb165a3a288eb1aa2ac06be4f3">analog10</a> </dd></dl>
182
    </td>
183
  </tr>
184
</table>
185
<a class="anchor" name="g55f66ff6f3449ef81d97b7e47f041918"></a><!-- doxytag: member="analog.c::analog_init" ref="g55f66ff6f3449ef81d97b7e47f041918" args="(void)" --><p>
186
<table class="mdTable" cellpadding="2" cellspacing="0">
187
  <tr>
188
    <td class="mdRow">
189
      <table cellpadding="0" cellspacing="0" border="0">
166
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the eight bit input to the specified port</dd></dl>
167
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#g55f66ff6f3449ef81d97b7e47f041918" title="Initialize analog ports.">analog_init</a>, <a class="el" href="group__analog.html#g875bf8cb165a3a288eb1aa2ac06be4f3" title="Read a 10-bit number from an analog port.">analog10</a> </dd></dl>
168

  
169
</div>
170
</div><p>
171
<a class="anchor" name="g55f66ff6f3449ef81d97b7e47f041918"></a><!-- doxytag: member="analog.c::analog_init" ref="g55f66ff6f3449ef81d97b7e47f041918" args="(void)" -->
172
<div class="memitem">
173
<div class="memproto">
174
      <table class="memname">
190 175
        <tr>
191
          <td class="md" nowrap valign="top">void analog_init           </td>
192
          <td class="md" valign="top">(&nbsp;</td>
193
          <td class="md" nowrap valign="top">void&nbsp;</td>
194
          <td class="mdname1" valign="top" nowrap>          </td>
195
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
196
          <td class="md" nowrap></td>
176
          <td class="memname">void analog_init           </td>
177
          <td>(</td>
178
          <td class="paramtype">void&nbsp;</td>
179
          <td class="paramname">          </td>
180
          <td>&nbsp;)&nbsp;</td>
181
          <td width="100%"></td>
197 182
        </tr>
198 183
      </table>
199
    </td>
200
  </tr>
201
</table>
202
<table cellspacing="5" cellpadding="0" border="0">
203
  <tr>
204
    <td>
205
      &nbsp;
206
    </td>
207
    <td>
184
</div>
185
<div class="memdoc">
208 186

  
209 187
<p>
210 188
Initialize analog ports. 
211 189
<p>
212 190
Initializes the ADC. Call analog_init before reading from the analog ports.<p>
213
<dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#gf1211040ce2c54f12f98df7d47a4eb27">analog8</a>, <a class="el" href="group__analog.html#g875bf8cb165a3a288eb1aa2ac06be4f3">analog10</a> </dd></dl>
214
    </td>
215
  </tr>
216
</table>
217
<a class="anchor" name="g973e63eb508819a37efe3231b6a39550"></a><!-- doxytag: member="analog.c::wheel" ref="g973e63eb508819a37efe3231b6a39550" args="(void)" --><p>
218
<table class="mdTable" cellpadding="2" cellspacing="0">
219
  <tr>
220
    <td class="mdRow">
221
      <table cellpadding="0" cellspacing="0" border="0">
191
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#gf1211040ce2c54f12f98df7d47a4eb27" title="Read an 8-bit number from an analog port.">analog8</a>, <a class="el" href="group__analog.html#g875bf8cb165a3a288eb1aa2ac06be4f3" title="Read a 10-bit number from an analog port.">analog10</a> </dd></dl>
192

  
193
</div>
194
</div><p>
195
<a class="anchor" name="g973e63eb508819a37efe3231b6a39550"></a><!-- doxytag: member="analog.c::wheel" ref="g973e63eb508819a37efe3231b6a39550" args="(void)" -->
196
<div class="memitem">
197
<div class="memproto">
198
      <table class="memname">
222 199
        <tr>
223
          <td class="md" nowrap valign="top">int wheel           </td>
224
          <td class="md" valign="top">(&nbsp;</td>
225
          <td class="md" nowrap valign="top">void&nbsp;</td>
226
          <td class="mdname1" valign="top" nowrap>          </td>
227
          <td class="md" valign="top">&nbsp;)&nbsp;</td>
228
          <td class="md" nowrap></td>
200
          <td class="memname">int wheel           </td>
201
          <td>(</td>
202
          <td class="paramtype">void&nbsp;</td>
203
          <td class="paramname">          </td>
204
          <td>&nbsp;)&nbsp;</td>
205
          <td width="100%"></td>
229 206
        </tr>
230 207
      </table>
231
    </td>
232
  </tr>
233
</table>
234
<table cellspacing="5" cellpadding="0" border="0">
235
  <tr>
236
    <td>
237
      &nbsp;
238
    </td>
239
    <td>
208
</div>
209
<div class="memdoc">
240 210

  
241 211
<p>
242 212
Read the position of the wheel. 
243 213
<p>
244 214
Returns the current position of the wheel, as an integer in the range 0 - 255. analog_init must be called before using this function.<p>
245
<dl compact><dt><b>Returns:</b></dt><dd>the orientation of the wheel, as an integer in the range 0 - 255.</dd></dl>
246
<dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#g55f66ff6f3449ef81d97b7e47f041918">analog_init</a> </dd></dl>
247
    </td>
248
  </tr>
249
</table>
250
<hr size="1"><address style="align: right;"><small>Generated on Wed Sep 26 17:39:30 2007 for libdragonfly by&nbsp;
215
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the orientation of the wheel, as an integer in the range 0 - 255.</dd></dl>
216
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__analog.html#g55f66ff6f3449ef81d97b7e47f041918" title="Initialize analog ports.">analog_init</a> </dd></dl>
217

  
218
</div>
219
</div><p>
220
<hr size="1"><address style="text-align: right;"><small>Generated on Thu Nov 8 23:15:40 2007 for libdragonfly by&nbsp;
251 221
<a href="http://www.doxygen.org/index.html">
252
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.6 </small></address>
222
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.3 </small></address>
253 223
</body>
254 224
</html>

Also available in: Unified diff