root / branches / wireless / docs / libwireless / html / group__xbee__funcs.html @ 1823
History | View | Annotate | Download (23.9 KB)
| 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|---|---|
| 2 | <html xmlns="http://www.w3.org/1999/xhtml"> |
| 3 | <head>
|
| 4 | <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
| 5 | <title>libwireless: Xbee Functions</title> |
| 6 | <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| 7 | <link href="doxygen.css" rel="stylesheet" type="text/css"/> |
| 8 | </head>
|
| 9 | <body>
|
| 10 | <!-- Generated by Doxygen 1.6.3 -->
|
| 11 | <div class="navigation" id="top"> |
| 12 | <div class="tabs"> |
| 13 | <ul>
|
| 14 | <li><a href="index.html"><span>Main Page</span></a></li> |
| 15 | <li><a href="modules.html"><span>Modules</span></a></li> |
| 16 | <li><a href="annotated.html"><span>Data Structures</span></a></li> |
| 17 | <li><a href="files.html"><span>Files</span></a></li> |
| 18 | </ul>
|
| 19 | </div>
|
| 20 | </div>
|
| 21 | <div class="contents"> |
| 22 | <h1>Xbee Functions<br/> |
| 23 | <small>
|
| 24 | [<a class="el" href="group__xbee.html">XBee</a>]</small> |
| 25 | </h1>
|
| 26 | <p>These are the public xbee functions.
|
| 27 | <a href="#_details">More...</a></p> |
| 28 | <table border="0" cellpadding="0" cellspacing="0"> |
| 29 | <tr><td colspan="2"><h2>Functions</h2></td></tr> |
| 30 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga35f6f209aee59fad0490a961587e014a">xbee_init</a> (void)</td></tr> |
| 31 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Initialize the XBee library. <a href="#ga35f6f209aee59fad0490a961587e014a"></a><br/></td></tr> |
| 32 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga0b4c25c76efbe397decacefced00e06c">xbee_terminate</a> (void)</td></tr> |
| 33 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Uninitialize the XBee library. <a href="#ga0b4c25c76efbe397decacefced00e06c"></a><br/></td></tr> |
| 34 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga5805e267e3b6f4b7bdad7aa6dc65ee04">xbee_send</a> (uint8_t *buf, uint16_t size)</td></tr> |
| 35 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Send an array of bytes to the xbee in API mode. <a href="#ga5805e267e3b6f4b7bdad7aa6dc65ee04"></a><br/></td></tr> |
| 36 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#gae75ee9a54a5811b8bc302dc2d70f0215">xbee_sendc</a> (uint8_t byte)</td></tr> |
| 37 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Send byte to the xbee in API mode. <a href="#gae75ee9a54a5811b8bc302dc2d70f0215"></a><br/></td></tr> |
| 38 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga2eb96c49811a1d9f2ccd1e1186915077">xbee_checksum_add</a> (uint8_t *buf, uint8_t len, uint8_t *sum)</td></tr> |
| 39 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Add a buffer to the checksum value. <a href="#ga2eb96c49811a1d9f2ccd1e1186915077"></a><br/></td></tr> |
| 40 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga2a39ffce83d65d22aeefb41dfce2112f">xbee_send_header</a> (uint16_t len)</td></tr> |
| 41 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Send a frame header to the xbee. <a href="#ga2a39ffce83d65d22aeefb41dfce2112f"></a><br/></td></tr> |
| 42 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#gaae54f7208cfa786cb56d4d78ab3ceffe">xbee_send_packet</a> (uint8_t *packet, uint8_t len, uint16_t dest, uint8_t options, uint8_t frame)</td></tr> |
| 43 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Send a packet to the XBee. <a href="#gaae54f7208cfa786cb56d4d78ab3ceffe"></a><br/></td></tr> |
| 44 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#gadbcb9cc8cf6afa28e6de8defb33f8196">xbee_set_pan</a> (uint16_t id)</td></tr> |
| 45 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Set the PAN ID for the XBee. <a href="#gadbcb9cc8cf6afa28e6de8defb33f8196"></a><br/></td></tr> |
| 46 | <tr><td class="memItemLeft" align="right" valign="top">uint16_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga76e60575b236342945b6a69bbe42df9f">xbee_get_pan</a> (void)</td></tr> |
| 47 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the XBee's PAN ID. <a href="#ga76e60575b236342945b6a69bbe42df9f"></a><br/></td></tr> |
| 48 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga4f67630ca81e5eae064bb58c3818d3fd">xbee_set_channel</a> (uint8_t channel)</td></tr> |
| 49 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Set the channel the XBee is currently using. <a href="#ga4f67630ca81e5eae064bb58c3818d3fd"></a><br/></td></tr> |
| 50 | <tr><td class="memItemLeft" align="right" valign="top">int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga319d4bccd5e6b09d2f377d2170104817">xbee_get_channel</a> (void)</td></tr> |
| 51 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the channel the XBee is currently using. <a href="#ga319d4bccd5e6b09d2f377d2170104817"></a><br/></td></tr> |
| 52 | <tr><td class="memItemLeft" align="right" valign="top">uint16_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#ga24d751120f5cded06a70d156c29261fc">xbee_get_address</a> (void)</td></tr> |
| 53 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Get the XBee's 16-bit address. <a href="#ga24d751120f5cded06a70d156c29261fc"></a><br/></td></tr> |
| 54 | <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gacf9354ba8b49419b6286e1318e87aa41"></a><!-- doxytag: member="xbee_funcs::xbee_reset" ref="gacf9354ba8b49419b6286e1318e87aa41" args="(void)" --> |
| 55 | int8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee__funcs.html#gacf9354ba8b49419b6286e1318e87aa41">xbee_reset</a> (void)</td></tr> |
| 56 | <tr><td class="mdescLeft"> </td><td class="mdescRight">Reset XBee. <br/></td></tr> |
| 57 | </table>
|
| 58 | <hr/><a name="_details"></a><h2>Detailed Description</h2> |
| 59 | <p>These are the public xbee functions. </p> |
| 60 | <hr/><h2>Function Documentation</h2> |
| 61 | <a class="anchor" id="ga2eb96c49811a1d9f2ccd1e1186915077"></a><!-- doxytag: member="xbee.h::xbee_checksum_add" ref="ga2eb96c49811a1d9f2ccd1e1186915077" args="(uint8_t *buf, uint8_t len, uint8_t *sum)" --> |
| 62 | <div class="memitem"> |
| 63 | <div class="memproto"> |
| 64 | <table class="memname"> |
| 65 | <tr>
|
| 66 | <td class="memname">int8_t xbee_checksum_add </td> |
| 67 | <td>(</td> |
| 68 | <td class="paramtype">uint8_t * </td> |
| 69 | <td class="paramname"> <em>buf</em>, </td> |
| 70 | </tr>
|
| 71 | <tr>
|
| 72 | <td class="paramkey"></td> |
| 73 | <td></td> |
| 74 | <td class="paramtype">uint8_t </td> |
| 75 | <td class="paramname"> <em>len</em>, </td> |
| 76 | </tr>
|
| 77 | <tr>
|
| 78 | <td class="paramkey"></td> |
| 79 | <td></td> |
| 80 | <td class="paramtype">uint8_t * </td> |
| 81 | <td class="paramname"> <em>sum</em></td><td> </td> |
| 82 | </tr>
|
| 83 | <tr>
|
| 84 | <td></td> |
| 85 | <td>)</td> |
| 86 | <td></td><td></td><td></td> |
| 87 | </tr>
|
| 88 | </table>
|
| 89 | </div>
|
| 90 | <div class="memdoc"> |
| 91 | |
| 92 | <p>Add a buffer to the checksum value. </p> |
| 93 | <p>Adds buf to the previous checksum total</p> |
| 94 | <dl><dt><b>Parameters:</b></dt><dd> |
| 95 | <table border="0" cellspacing="2" cellpadding="0"> |
| 96 | <tr><td valign="top"></td><td valign="top"><em>buf</em> </td><td>a byte buffer to add to the checksum </td></tr> |
| 97 | <tr><td valign="top"></td><td valign="top"><em>len</em> </td><td>the length of the buffer </td></tr> |
| 98 | <tr><td valign="top"></td><td valign="top"><em>sum</em> </td><td>the previous sum</td></tr> |
| 99 | </table>
|
| 100 | </dd>
|
| 101 | </dl>
|
| 102 | <dl class="return"><dt><b>Returns:</b></dt><dd>error code </dd></dl> |
| 103 | |
| 104 | <p>References <a class="el" href="wl__defs_8h_source.html#l00090">WL_ERROR_ARGUMENT</a>, and <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>.</p> |
| 105 | |
| 106 | <p>Referenced by <a class="el" href="wireless__send_8c_source.html#l00091">wl_send()</a>.</p> |
| 107 | |
| 108 | </div>
|
| 109 | </div>
|
| 110 | <a class="anchor" id="ga24d751120f5cded06a70d156c29261fc"></a><!-- doxytag: member="xbee.h::xbee_get_address" ref="ga24d751120f5cded06a70d156c29261fc" args="(void)" --> |
| 111 | <div class="memitem"> |
| 112 | <div class="memproto"> |
| 113 | <table class="memname"> |
| 114 | <tr>
|
| 115 | <td class="memname">uint16_t xbee_get_address </td> |
| 116 | <td>(</td> |
| 117 | <td class="paramtype">void </td> |
| 118 | <td class="paramname"></td> |
| 119 | <td> ) </td> |
| 120 | <td></td> |
| 121 | </tr>
|
| 122 | </table>
|
| 123 | </div>
|
| 124 | <div class="memdoc"> |
| 125 | |
| 126 | <p>Get the XBee's 16-bit address. </p> |
| 127 | <p>Get the 16-bit address of the XBee. This is used to specify who to send messages to and who messages are from.</p> |
| 128 | <dl class="return"><dt><b>Returns:</b></dt><dd>the 16-bit address of the XBee. </dd></dl> |
| 129 | |
| 130 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, <a class="el" href="wl__defs_8h_source.html#l00117">WL_ERROR_XBEE_COMMAND_16BIT</a>, and <a class="el" href="xbee_8c_source.html#l01380">xbee_send_read_at_command()</a>.</p> |
| 131 | |
| 132 | <p>Referenced by <a class="el" href="xbee_8c_source.html#l00729">xbee_init()</a>.</p> |
| 133 | |
| 134 | </div>
|
| 135 | </div>
|
| 136 | <a class="anchor" id="ga319d4bccd5e6b09d2f377d2170104817"></a><!-- doxytag: member="xbee.h::xbee_get_channel" ref="ga319d4bccd5e6b09d2f377d2170104817" args="(void)" --> |
| 137 | <div class="memitem"> |
| 138 | <div class="memproto"> |
| 139 | <table class="memname"> |
| 140 | <tr>
|
| 141 | <td class="memname">int8_t xbee_get_channel </td> |
| 142 | <td>(</td> |
| 143 | <td class="paramtype">void </td> |
| 144 | <td class="paramname"></td> |
| 145 | <td> ) </td> |
| 146 | <td></td> |
| 147 | </tr>
|
| 148 | </table>
|
| 149 | </div>
|
| 150 | <div class="memdoc"> |
| 151 | |
| 152 | <p>Get the channel the XBee is currently using. </p> |
| 153 | <p>Returns the channel which the XBee is currently using.</p> |
| 154 | <dl class="return"><dt><b>Returns:</b></dt><dd>the channel the XBee is using</dd></dl> |
| 155 | <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="group__xbee__funcs.html#ga4f67630ca81e5eae064bb58c3818d3fd" title="Set the channel the XBee is currently using.">xbee_set_channel</a> </dd></dl> |
| 156 | |
| 157 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, <a class="el" href="wl__defs_8h_source.html#l00114">WL_ERROR_XBEE_COMMAND</a>, and <a class="el" href="xbee_8c_source.html#l01380">xbee_send_read_at_command()</a>.</p> |
| 158 | |
| 159 | </div>
|
| 160 | </div>
|
| 161 | <a class="anchor" id="ga76e60575b236342945b6a69bbe42df9f"></a><!-- doxytag: member="xbee.h::xbee_get_pan" ref="ga76e60575b236342945b6a69bbe42df9f" args="(void)" --> |
| 162 | <div class="memitem"> |
| 163 | <div class="memproto"> |
| 164 | <table class="memname"> |
| 165 | <tr>
|
| 166 | <td class="memname">uint16_t xbee_get_pan </td> |
| 167 | <td>(</td> |
| 168 | <td class="paramtype">void </td> |
| 169 | <td class="paramname"></td> |
| 170 | <td> ) </td> |
| 171 | <td></td> |
| 172 | </tr>
|
| 173 | </table>
|
| 174 | </div>
|
| 175 | <div class="memdoc"> |
| 176 | |
| 177 | <p>Get the XBee's PAN ID. </p> |
| 178 | <p>Get the PAN ID for the XBee.</p> |
| 179 | <dl class="return"><dt><b>Returns:</b></dt><dd>the personal area network id, or XBEE_PAN_DEFAULT if it has not yet been set. </dd></dl> |
| 180 | |
| 181 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, <a class="el" href="wl__defs_8h_source.html#l00117">WL_ERROR_XBEE_COMMAND_16BIT</a>, and <a class="el" href="xbee_8c_source.html#l01380">xbee_send_read_at_command()</a>.</p> |
| 182 | |
| 183 | </div>
|
| 184 | </div>
|
| 185 | <a class="anchor" id="ga35f6f209aee59fad0490a961587e014a"></a><!-- doxytag: member="xbee.h::xbee_init" ref="ga35f6f209aee59fad0490a961587e014a" args="(void)" --> |
| 186 | <div class="memitem"> |
| 187 | <div class="memproto"> |
| 188 | <table class="memname"> |
| 189 | <tr>
|
| 190 | <td class="memname">int8_t xbee_init </td> |
| 191 | <td>(</td> |
| 192 | <td class="paramtype">void </td> |
| 193 | <td class="paramname"></td> |
| 194 | <td> ) </td> |
| 195 | <td></td> |
| 196 | </tr>
|
| 197 | </table>
|
| 198 | </div>
|
| 199 | <div class="memdoc"> |
| 200 | |
| 201 | <p>Initialize the XBee library. </p> |
| 202 | <p>Initializes the XBee library so that other functions may be used. </p> |
| 203 | |
| 204 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, <a class="el" href="wl__defs_8h_source.html#l00120">WL_ERROR_BAUD</a>, <a class="el" href="wl__defs_8h_source.html#l00075">WL_ERROR_INIT_ALREADY_INITD</a>, <a class="el" href="wl__defs_8h_source.html#l00117">WL_ERROR_XBEE_COMMAND_16BIT</a>, <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>, <a class="el" href="xbee_8c_source.html#l00087">xbee_basic_buf</a>, <a class="el" href="xbee_8c_source.html#l01725">xbee_get_address()</a>, and <a class="el" href="xbee_8c_source.html#l01586">xbee_set_pan()</a>.</p> |
| 205 | |
| 206 | <p>Referenced by <a class="el" href="wireless_8c_source.html#l00057">wl_init()</a>.</p> |
| 207 | |
| 208 | </div>
|
| 209 | </div>
|
| 210 | <a class="anchor" id="ga5805e267e3b6f4b7bdad7aa6dc65ee04"></a><!-- doxytag: member="xbee.h::xbee_send" ref="ga5805e267e3b6f4b7bdad7aa6dc65ee04" args="(uint8_t *buf, uint16_t size)" --> |
| 211 | <div class="memitem"> |
| 212 | <div class="memproto"> |
| 213 | <table class="memname"> |
| 214 | <tr>
|
| 215 | <td class="memname">int8_t xbee_send </td> |
| 216 | <td>(</td> |
| 217 | <td class="paramtype">uint8_t * </td> |
| 218 | <td class="paramname"> <em>buf</em>, </td> |
| 219 | </tr>
|
| 220 | <tr>
|
| 221 | <td class="paramkey"></td> |
| 222 | <td></td> |
| 223 | <td class="paramtype">uint16_t </td> |
| 224 | <td class="paramname"> <em>size</em></td><td> </td> |
| 225 | </tr>
|
| 226 | <tr>
|
| 227 | <td></td> |
| 228 | <td>)</td> |
| 229 | <td></td><td></td><td></td> |
| 230 | </tr>
|
| 231 | </table>
|
| 232 | </div>
|
| 233 | <div class="memdoc"> |
| 234 | |
| 235 | <p>Send an array of bytes to the xbee in API mode. </p> |
| 236 | <p>Send a buffer buf of size bytes to the XBee in API mode</p> |
| 237 | <dl><dt><b>Parameters:</b></dt><dd> |
| 238 | <table border="0" cellspacing="2" cellpadding="0"> |
| 239 | <tr><td valign="top"></td><td valign="top"><em>buf</em> </td><td>the buffer of data to send </td></tr> |
| 240 | <tr><td valign="top"></td><td valign="top"><em>size</em> </td><td>the number of bytes to send </td></tr> |
| 241 | </table>
|
| 242 | </dd>
|
| 243 | </dl>
|
| 244 | |
| 245 | <p>References <a class="el" href="wl__defs_8h_source.html#l00093">WL_ERROR_SEND</a>, <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>, and <a class="el" href="xbee_8c_source.html#l01015">xbee_sendc()</a>.</p> |
| 246 | |
| 247 | <p>Referenced by <a class="el" href="wireless__send_8c_source.html#l00091">wl_send()</a>, and <a class="el" href="xbee_8c_source.html#l01432">xbee_send_packet()</a>.</p> |
| 248 | |
| 249 | </div>
|
| 250 | </div>
|
| 251 | <a class="anchor" id="ga2a39ffce83d65d22aeefb41dfce2112f"></a><!-- doxytag: member="xbee.h::xbee_send_header" ref="ga2a39ffce83d65d22aeefb41dfce2112f" args="(uint16_t len)" --> |
| 252 | <div class="memitem"> |
| 253 | <div class="memproto"> |
| 254 | <table class="memname"> |
| 255 | <tr>
|
| 256 | <td class="memname">int8_t xbee_send_header </td> |
| 257 | <td>(</td> |
| 258 | <td class="paramtype">uint16_t </td> |
| 259 | <td class="paramname"> <em>len</em></td> |
| 260 | <td> ) </td> |
| 261 | <td></td> |
| 262 | </tr>
|
| 263 | </table>
|
| 264 | </div>
|
| 265 | <div class="memdoc"> |
| 266 | |
| 267 | <p>Send a frame header to the xbee. </p> |
| 268 | <p>Sends header information. Header information includes XBEE_FRAME_START and the packet length, as two bytes.</p> |
| 269 | <dl><dt><b>Parameters:</b></dt><dd> |
| 270 | <table border="0" cellspacing="2" cellpadding="0"> |
| 271 | <tr><td valign="top"></td><td valign="top"><em>type</em> </td><td>the packet type </td></tr> |
| 272 | <tr><td valign="top"></td><td valign="top"><em>len</em> </td><td>the size in bytes of the packet data </td></tr> |
| 273 | </table>
|
| 274 | </dd>
|
| 275 | </dl>
|
| 276 | |
| 277 | <p>References <a class="el" href="wl__defs_8h_source.html#l00093">WL_ERROR_SEND</a>, <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>, <a class="el" href="xbee_8c_source.html#l00945">xbee_putc()</a>, and <a class="el" href="xbee_8c_source.html#l01015">xbee_sendc()</a>.</p> |
| 278 | |
| 279 | <p>Referenced by <a class="el" href="wireless__send_8c_source.html#l00091">wl_send()</a>.</p> |
| 280 | |
| 281 | </div>
|
| 282 | </div>
|
| 283 | <a class="anchor" id="gaae54f7208cfa786cb56d4d78ab3ceffe"></a><!-- doxytag: member="xbee.h::xbee_send_packet" ref="gaae54f7208cfa786cb56d4d78ab3ceffe" args="(uint8_t *packet, uint8_t len, uint16_t dest, uint8_t options, uint8_t frame)" --> |
| 284 | <div class="memitem"> |
| 285 | <div class="memproto"> |
| 286 | <table class="memname"> |
| 287 | <tr>
|
| 288 | <td class="memname">int8_t xbee_send_packet </td> |
| 289 | <td>(</td> |
| 290 | <td class="paramtype">uint8_t * </td> |
| 291 | <td class="paramname"> <em>packet</em>, </td> |
| 292 | </tr>
|
| 293 | <tr>
|
| 294 | <td class="paramkey"></td> |
| 295 | <td></td> |
| 296 | <td class="paramtype">uint8_t </td> |
| 297 | <td class="paramname"> <em>len</em>, </td> |
| 298 | </tr>
|
| 299 | <tr>
|
| 300 | <td class="paramkey"></td> |
| 301 | <td></td> |
| 302 | <td class="paramtype">uint16_t </td> |
| 303 | <td class="paramname"> <em>dest</em>, </td> |
| 304 | </tr>
|
| 305 | <tr>
|
| 306 | <td class="paramkey"></td> |
| 307 | <td></td> |
| 308 | <td class="paramtype">uint8_t </td> |
| 309 | <td class="paramname"> <em>options</em>, </td> |
| 310 | </tr>
|
| 311 | <tr>
|
| 312 | <td class="paramkey"></td> |
| 313 | <td></td> |
| 314 | <td class="paramtype">uint8_t </td> |
| 315 | <td class="paramname"> <em>frame</em></td><td> </td> |
| 316 | </tr>
|
| 317 | <tr>
|
| 318 | <td></td> |
| 319 | <td>)</td> |
| 320 | <td></td><td></td><td></td> |
| 321 | </tr>
|
| 322 | </table>
|
| 323 | </div>
|
| 324 | <div class="memdoc"> |
| 325 | |
| 326 | <p>Send a packet to the XBee. </p> |
| 327 | <p>Send the specified packet.</p> |
| 328 | <dl><dt><b>Parameters:</b></dt><dd> |
| 329 | <table border="0" cellspacing="2" cellpadding="0"> |
| 330 | <tr><td valign="top"></td><td valign="top"><em>packet</em> </td><td>the packet data to send </td></tr> |
| 331 | <tr><td valign="top"></td><td valign="top"><em>len</em> </td><td>the number of bytes in the packet</td></tr> |
| 332 | <tr><td valign="top"></td><td valign="top"><em>dest</em> </td><td>the ID of the XBee to send the packet to, or XBEE_BROADCAST to send the message to all robots in the PAN.</td></tr> |
| 333 | <tr><td valign="top"></td><td valign="top"><em>options</em> </td><td>a combination of the flags XBEE_OPTIONS_NONE, XBEE_OPTIONS_DISABLE_RESPONSE and XBEE_OPTIONS_BROADCAST_ALL_PANS</td></tr> |
| 334 | <tr><td valign="top"></td><td valign="top"><em>frame</em> </td><td>the frame number to associate this packet with. This will be used to identify the response when the XBee alerts us as to whether or not our message was received. </td></tr> |
| 335 | </table>
|
| 336 | </dd>
|
| 337 | </dl>
|
| 338 | |
| 339 | <p>References <a class="el" href="wl__defs_8h_source.html#l00090">WL_ERROR_ARGUMENT</a>, <a class="el" href="wl__defs_8h_source.html#l00093">WL_ERROR_SEND</a>, <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>, <a class="el" href="xbee_8c_source.html#l00945">xbee_putc()</a>, <a class="el" href="xbee_8c_source.html#l01038">xbee_send()</a>, and <a class="el" href="xbee_8c_source.html#l01015">xbee_sendc()</a>.</p> |
| 340 | |
| 341 | </div>
|
| 342 | </div>
|
| 343 | <a class="anchor" id="gae75ee9a54a5811b8bc302dc2d70f0215"></a><!-- doxytag: member="xbee.h::xbee_sendc" ref="gae75ee9a54a5811b8bc302dc2d70f0215" args="(uint8_t byte)" --> |
| 344 | <div class="memitem"> |
| 345 | <div class="memproto"> |
| 346 | <table class="memname"> |
| 347 | <tr>
|
| 348 | <td class="memname">int8_t xbee_sendc </td> |
| 349 | <td>(</td> |
| 350 | <td class="paramtype">uint8_t </td> |
| 351 | <td class="paramname"> <em>byte</em></td> |
| 352 | <td> ) </td> |
| 353 | <td></td> |
| 354 | </tr>
|
| 355 | </table>
|
| 356 | </div>
|
| 357 | <div class="memdoc"> |
| 358 | |
| 359 | <p>Send byte to the xbee in API mode. </p> |
| 360 | <p>Send byte to the xbee in API mode.</p> |
| 361 | <dl><dt><b>Parameters:</b></dt><dd> |
| 362 | <table border="0" cellspacing="2" cellpadding="0"> |
| 363 | <tr><td valign="top"></td><td valign="top"><em>byte</em> </td><td>the byte to be sent </td></tr> |
| 364 | </table>
|
| 365 | </dd>
|
| 366 | </dl>
|
| 367 | |
| 368 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, and <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>.</p> |
| 369 | |
| 370 | <p>Referenced by <a class="el" href="wireless__send_8c_source.html#l00091">wl_send()</a>, <a class="el" href="xbee_8c_source.html#l01038">xbee_send()</a>, <a class="el" href="xbee_8c_source.html#l01332">xbee_send_header()</a>, and <a class="el" href="xbee_8c_source.html#l01432">xbee_send_packet()</a>.</p> |
| 371 | |
| 372 | </div>
|
| 373 | </div>
|
| 374 | <a class="anchor" id="ga4f67630ca81e5eae064bb58c3818d3fd"></a><!-- doxytag: member="xbee.h::xbee_set_channel" ref="ga4f67630ca81e5eae064bb58c3818d3fd" args="(uint8_t channel)" --> |
| 375 | <div class="memitem"> |
| 376 | <div class="memproto"> |
| 377 | <table class="memname"> |
| 378 | <tr>
|
| 379 | <td class="memname">int8_t xbee_set_channel </td> |
| 380 | <td>(</td> |
| 381 | <td class="paramtype">uint8_t </td> |
| 382 | <td class="paramname"> <em>channel</em></td> |
| 383 | <td> ) </td> |
| 384 | <td></td> |
| 385 | </tr>
|
| 386 | </table>
|
| 387 | </div>
|
| 388 | <div class="memdoc"> |
| 389 | |
| 390 | <p>Set the channel the XBee is currently using. </p> |
| 391 | <p>Set the channel the XBee is using.</p> |
| 392 | <dl><dt><b>Parameters:</b></dt><dd> |
| 393 | <table border="0" cellspacing="2" cellpadding="0"> |
| 394 | <tr><td valign="top"></td><td valign="top"><em>channel</em> </td><td>the channel the XBee will not use, between 0x0B and 0x1A</td></tr> |
| 395 | </table>
|
| 396 | </dd>
|
| 397 | </dl>
|
| 398 | <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="group__xbee__funcs.html#ga319d4bccd5e6b09d2f377d2170104817" title="Get the channel the XBee is currently using.">xbee_get_channel</a> </dd></dl> |
| 399 | |
| 400 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, <a class="el" href="wl__defs_8h_source.html#l00090">WL_ERROR_ARGUMENT</a>, <a class="el" href="wl__defs_8h_source.html#l00114">WL_ERROR_XBEE_COMMAND</a>, and <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>.</p> |
| 401 | |
| 402 | </div>
|
| 403 | </div>
|
| 404 | <a class="anchor" id="gadbcb9cc8cf6afa28e6de8defb33f8196"></a><!-- doxytag: member="xbee.h::xbee_set_pan" ref="gadbcb9cc8cf6afa28e6de8defb33f8196" args="(uint16_t id)" --> |
| 405 | <div class="memitem"> |
| 406 | <div class="memproto"> |
| 407 | <table class="memname"> |
| 408 | <tr>
|
| 409 | <td class="memname">int8_t xbee_set_pan </td> |
| 410 | <td>(</td> |
| 411 | <td class="paramtype">uint16_t </td> |
| 412 | <td class="paramname"> <em>id</em></td> |
| 413 | <td> ) </td> |
| 414 | <td></td> |
| 415 | </tr>
|
| 416 | </table>
|
| 417 | </div>
|
| 418 | <div class="memdoc"> |
| 419 | |
| 420 | <p>Set the PAN ID for the XBee. </p> |
| 421 | <p>Sets the personal area network id.</p> |
| 422 | <dl><dt><b>Parameters:</b></dt><dd> |
| 423 | <table border="0" cellspacing="2" cellpadding="0"> |
| 424 | <tr><td valign="top"></td><td valign="top"><em>id</em> </td><td>the new personal area network (PAN) id </td></tr> |
| 425 | </table>
|
| 426 | </dd>
|
| 427 | </dl>
|
| 428 | |
| 429 | <p>References <a class="el" href="xbee_8c_source.html#l00722">getStatus()</a>, <a class="el" href="wl__defs_8h_source.html#l00114">WL_ERROR_XBEE_COMMAND</a>, and <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>.</p> |
| 430 | |
| 431 | <p>Referenced by <a class="el" href="xbee_8c_source.html#l00729">xbee_init()</a>.</p> |
| 432 | |
| 433 | </div>
|
| 434 | </div>
|
| 435 | <a class="anchor" id="ga0b4c25c76efbe397decacefced00e06c"></a><!-- doxytag: member="xbee.h::xbee_terminate" ref="ga0b4c25c76efbe397decacefced00e06c" args="(void)" --> |
| 436 | <div class="memitem"> |
| 437 | <div class="memproto"> |
| 438 | <table class="memname"> |
| 439 | <tr>
|
| 440 | <td class="memname">int8_t xbee_terminate </td> |
| 441 | <td>(</td> |
| 442 | <td class="paramtype">void </td> |
| 443 | <td class="paramname"></td> |
| 444 | <td> ) </td> |
| 445 | <td></td> |
| 446 | </tr>
|
| 447 | </table>
|
| 448 | </div>
|
| 449 | <div class="memdoc"> |
| 450 | |
| 451 | <p>Uninitialize the XBee library. </p> |
| 452 | <p>Call when finished using the XBee library. </p> |
| 453 | |
| 454 | <p>References <a class="el" href="wl__defs_8h_source.html#l00081">WL_ERROR_TERMINATION_FAILED</a>, and <a class="el" href="wl__defs_8h_source.html#l00069">WL_SUCCESS</a>.</p> |
| 455 | |
| 456 | <p>Referenced by <a class="el" href="wireless_8c_source.html#l00087">wl_terminate()</a>.</p> |
| 457 | |
| 458 | </div>
|
| 459 | </div>
|
| 460 | </div>
|
| 461 | <hr class="footer"/><address style="text-align: right;"><small>Generated on Thu May 6 13:17:00 2010 for libwireless by |
| 462 | <a href="http://www.doxygen.org/index.html"> |
| 463 | <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address> |
| 464 | </body>
|
| 465 | </html>
|