Statistics
| Revision:

root / branches / wireless / docs / libwireless / html / xbee_8c.html @ 1823

History | View | Annotate | Download (21.5 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.c File Reference</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&nbsp;Page</span></a></li>
15
      <li><a href="modules.html"><span>Modules</span></a></li>
16
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
17
      <li class="current"><a href="files.html"><span>Files</span></a></li>
18
    </ul>
19
  </div>
20
  <div class="tabs">
21
    <ul>
22
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
23
      <li><a href="globals.html"><span>Globals</span></a></li>
24
    </ul>
25
  </div>
26
</div>
27
<div class="contents">
28
<h1>xbee.c File Reference</h1>
29
<p>XBee Interface.  
30
<a href="#_details">More...</a></p>
31
<code>#include &lt;lights.h&gt;</code><br/>
32
<code>#include &lt;string.h&gt;</code><br/>
33
<code>#include &lt;avr/io.h&gt;</code><br/>
34
<code>#include &lt;avr/interrupt.h&gt;</code><br/>
35
<code>#include &lt;time.h&gt;</code><br/>
36
<code>#include &lt;<a class="el" href="wl__defs_8h_source.html">wl_defs.h</a>&gt;</code><br/>
37
<code>#include &lt;<a class="el" href="wireless_8h_source.html">wireless.h</a>&gt;</code><br/>
38
<code>#include &lt;eeprom.h&gt;</code><br/>
39
<code>#include &quot;<a class="el" href="xbee_8h_source.html">xbee.h</a>&quot;</code><br/>
40
<table border="0" cellpadding="0" cellspacing="0">
41
<tr><td colspan="2"><h2>Defines</h2></td></tr>
42
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a18c660886e331ecfbfba5c5ce86e356a"></a><!-- doxytag: member="xbee.c::NUM_LAST_PACKETS" ref="a18c660886e331ecfbfba5c5ce86e356a" args="" -->
43
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>NUM_LAST_PACKETS</b>&nbsp;&nbsp;&nbsp;10</td></tr>
44
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0cd9b23acdf4ae51a7f0aa91bf0673b6"></a><!-- doxytag: member="xbee.c::XBEE_API_OFF" ref="a0cd9b23acdf4ae51a7f0aa91bf0673b6" args="" -->
45
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_API_OFF</b>&nbsp;&nbsp;&nbsp;0x00</td></tr>
46
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a1b840e5f5eeb4c61bc364d567dc583fe"></a><!-- doxytag: member="xbee.c::XBEE_API_ON" ref="a1b840e5f5eeb4c61bc364d567dc583fe" args="" -->
47
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_API_ON</b>&nbsp;&nbsp;&nbsp;0x10</td></tr>
48
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aabe1d60ad71cd3a9135ab8ee66aafe2f"></a><!-- doxytag: member="xbee.c::XBEE_API_ESCAPE" ref="aabe1d60ad71cd3a9135ab8ee66aafe2f" args="" -->
49
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_API_ESCAPE</b>&nbsp;&nbsp;&nbsp;0x20</td></tr>
50
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a80baa30bed665f697031f0d664b47b8f"></a><!-- doxytag: member="xbee.c::XBEE_API_MASK" ref="a80baa30bed665f697031f0d664b47b8f" args="" -->
51
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_API_MASK</b>&nbsp;&nbsp;&nbsp;0x30</td></tr>
52
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a571366b409acc3cf88b11f4517b5035d"></a><!-- doxytag: member="xbee.c::XBEE_COMMAND_WAIT" ref="a571366b409acc3cf88b11f4517b5035d" args="" -->
53
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_COMMAND_WAIT</b>&nbsp;&nbsp;&nbsp;0x80</td></tr>
54
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac18872e6011029aaee5086907d68d5f6"></a><!-- doxytag: member="xbee.c::XBEE_COMMAND_RESPONSE" ref="ac18872e6011029aaee5086907d68d5f6" args="" -->
55
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_COMMAND_RESPONSE</b>&nbsp;&nbsp;&nbsp;0xC0</td></tr>
56
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a63b294491a5ccb1dc043846c94598bf8"></a><!-- doxytag: member="xbee.c::XBEE_COMMAND_NONE" ref="a63b294491a5ccb1dc043846c94598bf8" args="" -->
57
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_COMMAND_NONE</b>&nbsp;&nbsp;&nbsp;0x00</td></tr>
58
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a05c1d6c59ecaa5429bf5274f02537598"></a><!-- doxytag: member="xbee.c::XBEE_COMMAND_MASK" ref="a05c1d6c59ecaa5429bf5274f02537598" args="" -->
59
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_COMMAND_MASK</b>&nbsp;&nbsp;&nbsp;0xC0</td></tr>
60
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a771f7792d83c2b783abadf05c92850a7"></a><!-- doxytag: member="xbee.c::XBEE_NOT_INITD" ref="a771f7792d83c2b783abadf05c92850a7" args="" -->
61
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>XBEE_NOT_INITD</b>&nbsp;&nbsp;&nbsp;0xF0</td></tr>
62
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4e3174b3441c7b675c371c708443a42a"></a><!-- doxytag: member="xbee.c::LAST_PACKET_MASK" ref="a4e3174b3441c7b675c371c708443a42a" args="" -->
63
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>LAST_PACKET_MASK</b>&nbsp;&nbsp;&nbsp;0x0F</td></tr>
64
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a584031babb534b94a63848b43bf88ee5"></a><!-- doxytag: member="xbee.c::ESCAPE_MARKER" ref="a584031babb534b94a63848b43bf88ee5" args="" -->
65
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>ESCAPE_MARKER</b>&nbsp;&nbsp;&nbsp;0x7D</td></tr>
66
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7f51719fbf2274af9266c15543b26eca"></a><!-- doxytag: member="xbee.c::ESCAPE_XOR" ref="a7f51719fbf2274af9266c15543b26eca" args="" -->
67
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>ESCAPE_XOR</b>&nbsp;&nbsp;&nbsp;0x20</td></tr>
68
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab854bf5a3cd6698b70ba613576046e47"></a><!-- doxytag: member="xbee.c::ESCAPE1" ref="ab854bf5a3cd6698b70ba613576046e47" args="" -->
69
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>ESCAPE1</b>&nbsp;&nbsp;&nbsp;0x7E</td></tr>
70
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a02c370da64328420e0f878ad074959d5"></a><!-- doxytag: member="xbee.c::ESCAPE2" ref="a02c370da64328420e0f878ad074959d5" args="" -->
71
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>ESCAPE2</b>&nbsp;&nbsp;&nbsp;0x7D</td></tr>
72
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6650a1844aa3fc6292f7c06d9b69634f"></a><!-- doxytag: member="xbee.c::ESCAPE3" ref="a6650a1844aa3fc6292f7c06d9b69634f" args="" -->
73
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>ESCAPE3</b>&nbsp;&nbsp;&nbsp;0x11</td></tr>
74
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ade56248d1f61075bfd7cccb45fe00dec"></a><!-- doxytag: member="xbee.c::ESCAPE4" ref="ade56248d1f61075bfd7cccb45fe00dec" args="" -->
75
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>ESCAPE4</b>&nbsp;&nbsp;&nbsp;0x13</td></tr>
76
<tr><td class="memItemLeft" align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga614217d263be1fb1a5f76e2ff7be19a2">PORT</a>&nbsp;&nbsp;&nbsp;UDR1</td></tr>
77
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gaf8bfae90c5d6853fcfb487e05b9f50c8"></a><!-- doxytag: member="xbee.c::FLAG" ref="gaf8bfae90c5d6853fcfb487e05b9f50c8" args="" -->
78
#define&nbsp;</td><td class="memItemRight" valign="bottom"><b>FLAG</b>&nbsp;&nbsp;&nbsp;(UCSR1A &amp; (1&lt;&lt;RXC1))</td></tr>
79
<tr><td colspan="2"><h2>Functions</h2></td></tr>
80
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gaf29617dd4988f4b056f9476004ae5cbf">xbee_putc</a> (uint8_t c)</td></tr>
81
<tr><td class="memItemLeft" align="right" valign="top">int16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga409ff62ddd9e22eaf745a50f688263fd">xbee_getc</a> (void)</td></tr>
82
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gae564a6f5453934b0234a054fbc238fd3">xbee_getc_nb</a> (uint8_t *c)</td></tr>
83
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga2694f3530e4cf256ff9e96600aea753c">xbee_send_read_at_command</a> (uint8_t *command)</td></tr>
84
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gafe6b2efc8b84d41b224b65fe9a9b0f70"></a><!-- doxytag: member="xbee.c::xbee_basic_buf_add" ref="gafe6b2efc8b84d41b224b65fe9a9b0f70" args="(uint8_t *ptr, uint8_t byte)" -->
85
int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>xbee_basic_buf_add</b> (uint8_t *ptr, uint8_t byte)</td></tr>
86
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga3aa01c87cec1f5836297de808c82a405"></a><!-- doxytag: member="xbee.c::xbee_basic_buf_get" ref="ga3aa01c87cec1f5836297de808c82a405" args="(uint8_t *ptr)" -->
87
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>xbee_basic_buf_get</b> (uint8_t *ptr)</td></tr>
88
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga344c1c7c8bbd9bdb4903d3e9443edbbd"></a><!-- doxytag: member="xbee.c::xbee_other_buf_add" ref="ga344c1c7c8bbd9bdb4903d3e9443edbbd" args="(uint8_t *ptr, uint8_t byte)" -->
89
int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>xbee_other_buf_add</b> (uint8_t *ptr, uint8_t byte)</td></tr>
90
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga335b40b15f89a8a0d26db9226812914e">check_last_receive</a> (uint16_t source, uint8_t framenum)</td></tr>
91
<tr><td class="memItemLeft" align="right" valign="top">uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga8a4c7ae8201a7ca230fdb47bfa13d044">getStatus</a> (uint8_t mask)</td></tr>
92
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gaff39fc829e5307a35a062bcc6fac616f"></a><!-- doxytag: member="xbee.c::setStatus" ref="gaff39fc829e5307a35a062bcc6fac616f" args="(uint8_t mask, uint8_t value)" -->
93
void&nbsp;</td><td class="memItemRight" valign="bottom"><b>setStatus</b> (uint8_t mask, uint8_t value)</td></tr>
94
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a22c53350028fb65a39b098fa56f3d5e4"></a><!-- doxytag: member="xbee.c::ackhandle" ref="a22c53350028fb65a39b098fa56f3d5e4" args="(uint8_t num, uint8_t val)" -->
95
void&nbsp;</td><td class="memItemRight" valign="bottom"><b>ackhandle</b> (uint8_t num, uint8_t val)</td></tr>
96
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gae6e8a8009a9ae0c59f25a496d1cf5a84"></a><!-- doxytag: member="xbee.c::ISR" ref="gae6e8a8009a9ae0c59f25a496d1cf5a84" args="(USART1_RX_vect)" -->
97
&nbsp;</td><td class="memItemRight" valign="bottom"><b>ISR</b> (USART1_RX_vect)</td></tr>
98
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gac4c5f6ba46371313200945e6456a9942"></a><!-- doxytag: member="xbee.c::xbee_other_buf_get" ref="gac4c5f6ba46371313200945e6456a9942" args="(uint8_t *ptr)" -->
99
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>xbee_other_buf_get</b> (uint8_t *ptr)</td></tr>
100
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga31a4df97d6865a40123337045109b9f1">xbee_init</a> ()</td></tr>
101
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Initialize the XBee library.  <a href="group__xbee.html#ga31a4df97d6865a40123337045109b9f1"></a><br/></td></tr>
102
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga3fe446135ba896e6438a4fcd67154119">xbee_terminate</a> ()</td></tr>
103
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Uninitialize the XBee library.  <a href="group__xbee.html#ga3fe446135ba896e6438a4fcd67154119"></a><br/></td></tr>
104
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gae75ee9a54a5811b8bc302dc2d70f0215">xbee_sendc</a> (uint8_t byte)</td></tr>
105
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Send byte to the xbee in API mode.  <a href="group__xbee.html#gae75ee9a54a5811b8bc302dc2d70f0215"></a><br/></td></tr>
106
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga5805e267e3b6f4b7bdad7aa6dc65ee04">xbee_send</a> (uint8_t *buf, uint16_t size)</td></tr>
107
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Send an array of bytes to the xbee in API mode.  <a href="group__xbee.html#ga5805e267e3b6f4b7bdad7aa6dc65ee04"></a><br/></td></tr>
108
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga2eb96c49811a1d9f2ccd1e1186915077">xbee_checksum_add</a> (uint8_t *buf, uint8_t len, uint8_t *sum)</td></tr>
109
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add a buffer to the checksum value.  <a href="group__xbee.html#ga2eb96c49811a1d9f2ccd1e1186915077"></a><br/></td></tr>
110
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga2a39ffce83d65d22aeefb41dfce2112f">xbee_send_header</a> (uint16_t len)</td></tr>
111
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Send a frame header to the xbee.  <a href="group__xbee.html#ga2a39ffce83d65d22aeefb41dfce2112f"></a><br/></td></tr>
112
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gaae54f7208cfa786cb56d4d78ab3ceffe">xbee_send_packet</a> (uint8_t *packet, uint8_t len, uint16_t dest, uint8_t options, uint8_t frame)</td></tr>
113
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Send a packet to the XBee.  <a href="group__xbee.html#gaae54f7208cfa786cb56d4d78ab3ceffe"></a><br/></td></tr>
114
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gadbcb9cc8cf6afa28e6de8defb33f8196">xbee_set_pan</a> (uint16_t id)</td></tr>
115
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the PAN ID for the XBee.  <a href="group__xbee.html#gadbcb9cc8cf6afa28e6de8defb33f8196"></a><br/></td></tr>
116
<tr><td class="memItemLeft" align="right" valign="top">uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#gaa740c59073c6db9e00a2a2de10a95091">xbee_get_pan</a> ()</td></tr>
117
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the XBee's PAN ID.  <a href="group__xbee.html#gaa740c59073c6db9e00a2a2de10a95091"></a><br/></td></tr>
118
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga4f67630ca81e5eae064bb58c3818d3fd">xbee_set_channel</a> (uint8_t channel)</td></tr>
119
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the channel the XBee is currently using.  <a href="group__xbee.html#ga4f67630ca81e5eae064bb58c3818d3fd"></a><br/></td></tr>
120
<tr><td class="memItemLeft" align="right" valign="top">int8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga319d4bccd5e6b09d2f377d2170104817">xbee_get_channel</a> (void)</td></tr>
121
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the channel the XBee is currently using.  <a href="group__xbee.html#ga319d4bccd5e6b09d2f377d2170104817"></a><br/></td></tr>
122
<tr><td class="memItemLeft" align="right" valign="top">uint16_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__xbee.html#ga24d751120f5cded06a70d156c29261fc">xbee_get_address</a> (void)</td></tr>
123
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the XBee's 16-bit address.  <a href="group__xbee.html#ga24d751120f5cded06a70d156c29261fc"></a><br/></td></tr>
124
<tr><td colspan="2"><h2>Variables</h2></td></tr>
125
<tr><td class="memItemLeft" align="right" valign="top">uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="xbee_8c.html#a94652d65b245bd874ff76bac4e0a2b23">xbee_basic_buf</a> [PACKET_BUFFER_SIZE]</td></tr>
126
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4162f367889b477c35cdefdd72d67c1b"></a><!-- doxytag: member="xbee.c::basic_buf_first" ref="a4162f367889b477c35cdefdd72d67c1b" args="" -->
127
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>basic_buf_first</b> = (PACKET_BUFFER_SIZE-1)</td></tr>
128
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a645b109e07dad69b8314f773e0978399"></a><!-- doxytag: member="xbee.c::basic_buf_last" ref="a645b109e07dad69b8314f773e0978399" args="" -->
129
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>basic_buf_last</b> = 0</td></tr>
130
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a44888b88606af1d1c22c73f65d880313"></a><!-- doxytag: member="xbee.c::xbee_other_buf" ref="a44888b88606af1d1c22c73f65d880313" args="[PACKET_BUFFER_SIZE]" -->
131
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>xbee_other_buf</b> [PACKET_BUFFER_SIZE]</td></tr>
132
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab75ab53d4df1cb0af09e6d2e4e7cd75b"></a><!-- doxytag: member="xbee.c::other_buf_first" ref="ab75ab53d4df1cb0af09e6d2e4e7cd75b" args="" -->
133
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>other_buf_first</b> = (PACKET_BUFFER_SIZE-1)</td></tr>
134
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6bf335c9fa259e2e3531ea37370d3801"></a><!-- doxytag: member="xbee.c::other_buf_last" ref="a6bf335c9fa259e2e3531ea37370d3801" args="" -->
135
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>other_buf_last</b> = 0</td></tr>
136
<tr><td class="memItemLeft" ><a class="anchor" id="a18ed68029e795b2c38b97f6f1be1ab78"></a><!-- doxytag: member="xbee.c::lastPacket" ref="a18ed68029e795b2c38b97f6f1be1ab78" args="[NUM_LAST_PACKETS]" -->
137
struct {</td></tr>
138
<tr><td class="memItemLeft" >&nbsp;&nbsp;&nbsp;uint16_t&nbsp;&nbsp;&nbsp;<b>source</b></td></tr>
139
<tr><td class="memItemLeft" >&nbsp;&nbsp;&nbsp;uint8_t&nbsp;&nbsp;&nbsp;<b>framenum</b></td></tr>
140
<tr><td class="memItemLeft" valign="top">}&nbsp;</td><td class="memItemRight" valign="bottom"><b>lastPacket</b> [NUM_LAST_PACKETS]</td></tr>
141
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a35a1327ee0fb8fabee9d7e4ddac1eccd"></a><!-- doxytag: member="xbee.c::xbee_status" ref="a35a1327ee0fb8fabee9d7e4ddac1eccd" args="" -->
142
uint8_t&nbsp;</td><td class="memItemRight" valign="bottom"><b>xbee_status</b> = XBEE_NOT_INITD</td></tr>
143
</table>
144
<hr/><a name="_details"></a><h2>Detailed Description</h2>
145
<p>XBee Interface. </p>
146
<p>Copyright (c) 2009 Colony Project</p>
147
<p>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</p>
148
<p>The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.</p>
149
<p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p>
150
<p>Implementation of low level communication with the XBee in API mode.</p>
151
<dl class="author"><dt><b>Author:</b></dt><dd>Colony Project, CMU Robotics Club </dd></dl>
152
<hr/><h2>Variable Documentation</h2>
153
<a class="anchor" id="a94652d65b245bd874ff76bac4e0a2b23"></a><!-- doxytag: member="xbee.c::xbee_basic_buf" ref="a94652d65b245bd874ff76bac4e0a2b23" args="[PACKET_BUFFER_SIZE]" -->
154
<div class="memitem">
155
<div class="memproto">
156
      <table class="memname">
157
        <tr>
158
          <td class="memname">uint8_t <a class="el" href="xbee_8c.html#a94652d65b245bd874ff76bac4e0a2b23">xbee_basic_buf</a>[PACKET_BUFFER_SIZE]</td>
159
        </tr>
160
      </table>
161
</div>
162
<div class="memdoc">
163
<p>Definition for wireless library receive packet structure</p>
164
<p>Basic Buffer Packet: byte 1: length of source+data bytes 2-3: source bytes 4-n: data</p>
165
<p>Other Buffer Packet: byte 1: length of group+source+data byte 2: group number bytes 3-4: source bytes 5-n: data </p>
166

    
167
<p>Referenced by <a class="el" href="wireless__receive_8c_source.html#l00100">wl_get_basic()</a>, and <a class="el" href="xbee_8c_source.html#l00729">xbee_init()</a>.</p>
168

    
169
</div>
170
</div>
171
</div>
172
<hr class="footer"/><address style="text-align: right;"><small>Generated on Thu May 6 13:17:00 2010 for libwireless by&nbsp;
173
<a href="http://www.doxygen.org/index.html">
174
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
175
</body>
176
</html>