root / trunk / docs / libdragonfly / group__xbee.html @ 1398
History | View | Annotate | Download (8.27 KB)
1 |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
---|---|
2 |
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> |
3 |
<title>libdragonfly: XBee Input / Output</title> |
4 |
<link href="tabs.css" rel="stylesheet" type="text/css"> |
5 |
<link href="doxygen.css" rel="stylesheet" type="text/css"> |
6 |
</head><body> |
7 |
<!-- Generated by Doxygen 1.5.9 -->
|
8 |
<div class="navigation" id="top"> |
9 |
<div class="tabs"> |
10 |
<ul>
|
11 |
<li><a href="index.html"><span>Main Page</span></a></li> |
12 |
<li><a href="pages.html"><span>Related Pages</span></a></li> |
13 |
<li><a href="modules.html"><span>Modules</span></a></li> |
14 |
<li><a href="annotated.html"><span>Data Structures</span></a></li> |
15 |
<li><a href="files.html"><span>Files</span></a></li> |
16 |
</ul>
|
17 |
</div>
|
18 |
</div>
|
19 |
<div class="contents"> |
20 |
<h1>XBee Input / Output</h1>Functions for XBee input / output. |
21 |
<a href="#_details">More...</a> |
22 |
<p>
|
23 |
<table border="0" cellpadding="0" cellspacing="0"> |
24 |
<tr><td></td></tr> |
25 |
<tr><td colspan="2"><br><h2>Defines</h2></td></tr> |
26 |
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g7125fc8f3df24a2db8e074983206b054"></a><!-- doxytag: member="xbee::XBEE_BAUD" ref="g7125fc8f3df24a2db8e074983206b054" args="" --> |
27 |
#define </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#g7125fc8f3df24a2db8e074983206b054">XBEE_BAUD</a> 9600</td></tr> |
28 |
|
29 |
<tr><td class="mdescLeft"> </td><td class="mdescRight">the XBee baud rate <br></td></tr> |
30 |
<tr><td colspan="2"><br><h2>Functions</h2></td></tr> |
31 |
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#g964a1e8461e9c1187e5d69f521e5e107">xbee_init</a> (void)</td></tr> |
32 |
|
33 |
<tr><td class="mdescLeft"> </td><td class="mdescRight">Initialize the XBee. <a href="#g964a1e8461e9c1187e5d69f521e5e107"></a><br></td></tr> |
34 |
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#g70c6b231330312d4f69b9a8afb5af989">xbee_putc</a> (char c)</td></tr> |
35 |
|
36 |
<tr><td class="mdescLeft"> </td><td class="mdescRight">Print a character to the XBee. <a href="#g70c6b231330312d4f69b9a8afb5af989"></a><br></td></tr> |
37 |
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#g1f468ae159ba5d97bdfb3f4855d15d88">xbee_getc</a> (void)</td></tr> |
38 |
|
39 |
<tr><td class="mdescLeft"> </td><td class="mdescRight">Read a character from the XBee. <a href="#g1f468ae159ba5d97bdfb3f4855d15d88"></a><br></td></tr> |
40 |
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gfb7bd5dd535e8251bfff78854c6c15f2">xbee_getc_nb</a> (char *c)</td></tr> |
41 |
|
42 |
<tr><td class="mdescLeft"> </td><td class="mdescRight">Read a character from the XBee without blocking. <a href="#gfb7bd5dd535e8251bfff78854c6c15f2"></a><br></td></tr> |
43 |
</table>
|
44 |
<hr><a name="_details"></a><h2>Detailed Description</h2> |
45 |
Functions for XBee input / output. |
46 |
<p>
|
47 |
Low level functions for XBee input and output. <hr><h2>Function Documentation</h2> |
48 |
<a class="anchor" name="g1f468ae159ba5d97bdfb3f4855d15d88"></a><!-- doxytag: member="serial.h::xbee_getc" ref="g1f468ae159ba5d97bdfb3f4855d15d88" args="(void)" --> |
49 |
<div class="memitem"> |
50 |
<div class="memproto"> |
51 |
<table class="memname"> |
52 |
<tr>
|
53 |
<td class="memname">int xbee_getc </td> |
54 |
<td>(</td> |
55 |
<td class="paramtype">void </td> |
56 |
<td class="paramname"> </td> |
57 |
<td> ) </td> |
58 |
<td></td> |
59 |
</tr>
|
60 |
</table>
|
61 |
</div>
|
62 |
<div class="memdoc"> |
63 |
|
64 |
<p>
|
65 |
Read a character from the XBee. |
66 |
<p>
|
67 |
Returns the first character in the buffer received from USB. This function blocks execution until a character has been received. xbee_init must be called before this function may be used.<p>
|
68 |
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the first character in the xbee buffer</dd></dl> |
69 |
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__xbee.html#g964a1e8461e9c1187e5d69f521e5e107" title="Initialize the XBee.">xbee_init</a>, <a class="el" href="group__xbee.html#gfb7bd5dd535e8251bfff78854c6c15f2" title="Read a character from the XBee without blocking.">xbee_getc_nb</a> </dd></dl> |
70 |
|
71 |
<p>Referenced by <a class="el" href="serial_8c_source.html#l00089">xbee_init()</a>.</p> |
72 |
|
73 |
</div>
|
74 |
</div><p> |
75 |
<a class="anchor" name="gfb7bd5dd535e8251bfff78854c6c15f2"></a><!-- doxytag: member="serial.h::xbee_getc_nb" ref="gfb7bd5dd535e8251bfff78854c6c15f2" args="(char *c)" --> |
76 |
<div class="memitem"> |
77 |
<div class="memproto"> |
78 |
<table class="memname"> |
79 |
<tr>
|
80 |
<td class="memname">int xbee_getc_nb </td> |
81 |
<td>(</td> |
82 |
<td class="paramtype">char * </td> |
83 |
<td class="paramname"> <em>c</em> </td> |
84 |
<td> ) </td> |
85 |
<td></td> |
86 |
</tr>
|
87 |
</table>
|
88 |
</div>
|
89 |
<div class="memdoc"> |
90 |
|
91 |
<p>
|
92 |
Read a character from the XBee without blocking. |
93 |
<p>
|
94 |
Non blocking version of xbee_getc. If a character is present in the buffer, it is returned, otherwise -1 is returned immediately. xbee_init must be called before this function can be used.<p>
|
95 |
<dl compact><dt><b>Parameters:</b></dt><dd> |
96 |
<table border="0" cellspacing="2" cellpadding="0"> |
97 |
<tr><td valign="top"></td><td valign="top"><em>c</em> </td><td>the received character. This will be set if a character has been received.</td></tr> |
98 |
</table>
|
99 |
</dl>
|
100 |
<dl class="return" compact><dt><b>Returns:</b></dt><dd>-1 if no character is available, 0 otherwise</dd></dl> |
101 |
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__xbee.html#g964a1e8461e9c1187e5d69f521e5e107" title="Initialize the XBee.">xbee_init</a>, <a class="el" href="group__xbee.html#g1f468ae159ba5d97bdfb3f4855d15d88" title="Read a character from the XBee.">xbee_getc</a> </dd></dl> |
102 |
|
103 |
</div>
|
104 |
</div><p> |
105 |
<a class="anchor" name="g964a1e8461e9c1187e5d69f521e5e107"></a><!-- doxytag: member="serial.h::xbee_init" ref="g964a1e8461e9c1187e5d69f521e5e107" args="(void)" --> |
106 |
<div class="memitem"> |
107 |
<div class="memproto"> |
108 |
<table class="memname"> |
109 |
<tr>
|
110 |
<td class="memname">void xbee_init </td> |
111 |
<td>(</td> |
112 |
<td class="paramtype">void </td> |
113 |
<td class="paramname"> </td> |
114 |
<td> ) </td> |
115 |
<td></td> |
116 |
</tr>
|
117 |
</table>
|
118 |
</div>
|
119 |
<div class="memdoc"> |
120 |
|
121 |
<p>
|
122 |
Initialize the XBee. |
123 |
<p>
|
124 |
Initializes communication over the XBee. This must be called before any other xbee function may be used. |
125 |
<p>References <a class="el" href="serial_8c_source.html#l00048">xbee_fd</a>, <a class="el" href="serial_8c_source.html#l00206">xbee_getc()</a>, and <a class="el" href="serial_8c_source.html#l00139">xbee_putc()</a>.</p> |
126 |
|
127 |
<p>Referenced by <a class="el" href="dragonfly__lib_8c_source.html#l00068">dragonfly_init()</a>.</p> |
128 |
|
129 |
</div>
|
130 |
</div><p> |
131 |
<a class="anchor" name="g70c6b231330312d4f69b9a8afb5af989"></a><!-- doxytag: member="serial.h::xbee_putc" ref="g70c6b231330312d4f69b9a8afb5af989" args="(char c)" --> |
132 |
<div class="memitem"> |
133 |
<div class="memproto"> |
134 |
<table class="memname"> |
135 |
<tr>
|
136 |
<td class="memname">int xbee_putc </td> |
137 |
<td>(</td> |
138 |
<td class="paramtype">char </td> |
139 |
<td class="paramname"> <em>c</em> </td> |
140 |
<td> ) </td> |
141 |
<td></td> |
142 |
</tr>
|
143 |
</table>
|
144 |
</div>
|
145 |
<div class="memdoc"> |
146 |
|
147 |
<p>
|
148 |
Print a character to the XBee. |
149 |
<p>
|
150 |
Sends a character to the XBee.<p>
|
151 |
<dl compact><dt><b>Parameters:</b></dt><dd> |
152 |
<table border="0" cellspacing="2" cellpadding="0"> |
153 |
<tr><td valign="top"></td><td valign="top"><em>c</em> </td><td>the character to send </td></tr> |
154 |
</table>
|
155 |
</dl>
|
156 |
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 for success, nonzero for failure </dd></dl> |
157 |
|
158 |
<p>Referenced by <a class="el" href="serial_8c_source.html#l00089">xbee_init()</a>.</p> |
159 |
|
160 |
</div>
|
161 |
</div><p> |
162 |
</div>
|
163 |
<hr size="1"><address style="text-align: right;"><small>Generated on Mon Sep 7 19:07:28 2009 for libdragonfly by |
164 |
<a href="http://www.doxygen.org/index.html"> |
165 |
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.9 </small></address> |
166 |
</body>
|
167 |
</html>
|