<!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"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>XBee-Arduino: PayloadRequest Class Reference</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="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">XBee-Arduino
   &#160;<span id="projectnumber">0.2</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="class_payload_request-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">PayloadRequest Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>All TX packets that support payloads extend this class.  
 <a href="class_payload_request.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_x_bee_8h_source.html">XBee.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for PayloadRequest:</div>
<div class="dyncontent">
 <div class="center">
  <img src="class_payload_request.png" usemap="#PayloadRequest_map" alt=""/>
  <map id="PayloadRequest_map" name="PayloadRequest_map">
<area href="class_x_bee_request.html" title="Super class of all XBee requests (TX packets) Users should never create an instance of this class; in..." alt="XBeeRequest" shape="rect" coords="112,0,214,24"/>
<area href="class_tx16_request.html" title="Represents a Series 1 TX packet that corresponds to Api Id: TX_16_REQUEST Be careful not to send a da..." alt="Tx16Request" shape="rect" coords="0,112,102,136"/>
<area href="class_tx64_request.html" title="Represents a Series 1 TX packet that corresponds to Api Id: TX_64_REQUEST. " alt="Tx64Request" shape="rect" coords="112,112,214,136"/>
<area href="class_z_b_tx_request.html" title="Represents a Series 2 TX packet that corresponds to Api Id: ZB_TX_REQUEST. " alt="ZBTxRequest" shape="rect" coords="224,112,326,136"/>
</map>
 </div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a22cc9fd971a1334346560689d7d8c8d5"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a22cc9fd971a1334346560689d7d8c8d5"></a>
&#160;</td><td class="memItemRight" valign="bottom"><b>PayloadRequest</b> (uint8_t apiId, uint8_t frameId, uint8_t *payload, uint8_t payloadLength)</td></tr>
<tr class="separator:a22cc9fd971a1334346560689d7d8c8d5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1e2d5757fefda70dfd0c567b3dd0ba39"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a1e2d5757fefda70dfd0c567b3dd0ba39"></a>
uint8_t *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_payload_request.html#a1e2d5757fefda70dfd0c567b3dd0ba39">getPayload</a> ()</td></tr>
<tr class="memdesc:a1e2d5757fefda70dfd0c567b3dd0ba39"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the payload of the packet, if not null. <br/></td></tr>
<tr class="separator:a1e2d5757fefda70dfd0c567b3dd0ba39"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa9abc1f496a1c457f796207aa8a7567d"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aa9abc1f496a1c457f796207aa8a7567d"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_payload_request.html#aa9abc1f496a1c457f796207aa8a7567d">setPayload</a> (uint8_t *payloadPtr)</td></tr>
<tr class="memdesc:aa9abc1f496a1c457f796207aa8a7567d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the payload array. <br/></td></tr>
<tr class="separator:aa9abc1f496a1c457f796207aa8a7567d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afb718d069f05611623833437c99893a4"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="afb718d069f05611623833437c99893a4"></a>
uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_payload_request.html#afb718d069f05611623833437c99893a4">getPayloadLength</a> ()</td></tr>
<tr class="memdesc:afb718d069f05611623833437c99893a4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the length of the payload array, as specified by the user. <br/></td></tr>
<tr class="separator:afb718d069f05611623833437c99893a4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6e86a663ab6299afaa1cf21ad7c2c5c1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_payload_request.html#a6e86a663ab6299afaa1cf21ad7c2c5c1">setPayloadLength</a> (uint8_t payloadLength)</td></tr>
<tr class="memdesc:a6e86a663ab6299afaa1cf21ad7c2c5c1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the length of the payload to include in the request.  <a href="#a6e86a663ab6299afaa1cf21ad7c2c5c1">More...</a><br/></td></tr>
<tr class="separator:a6e86a663ab6299afaa1cf21ad7c2c5c1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="inherit_header pub_methods_class_x_bee_request"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_class_x_bee_request')"><img src="closed.png" alt="-"/>&#160;Public Member Functions inherited from <a class="el" href="class_x_bee_request.html">XBeeRequest</a></td></tr>
<tr class="memitem:af80fd559cab746ab8573087cddda71a2 inherit pub_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="af80fd559cab746ab8573087cddda71a2"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_x_bee_request.html#af80fd559cab746ab8573087cddda71a2">XBeeRequest</a> (uint8_t apiId, uint8_t frameId)</td></tr>
<tr class="memdesc:af80fd559cab746ab8573087cddda71a2 inherit pub_methods_class_x_bee_request"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor TODO make protected. <br/></td></tr>
<tr class="separator:af80fd559cab746ab8573087cddda71a2 inherit pub_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aed1724c11e710217807c971e40105c86 inherit pub_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_x_bee_request.html#aed1724c11e710217807c971e40105c86">setFrameId</a> (uint8_t frameId)</td></tr>
<tr class="memdesc:aed1724c11e710217807c971e40105c86 inherit pub_methods_class_x_bee_request"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the frame id.  <a href="#aed1724c11e710217807c971e40105c86">More...</a><br/></td></tr>
<tr class="separator:aed1724c11e710217807c971e40105c86 inherit pub_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a20394c7ea4666224c50bef25cc0cd836 inherit pub_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a20394c7ea4666224c50bef25cc0cd836"></a>
uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_x_bee_request.html#a20394c7ea4666224c50bef25cc0cd836">getFrameId</a> ()</td></tr>
<tr class="memdesc:a20394c7ea4666224c50bef25cc0cd836 inherit pub_methods_class_x_bee_request"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the frame id. <br/></td></tr>
<tr class="separator:a20394c7ea4666224c50bef25cc0cd836 inherit pub_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a746d0373c9fb6ed0ff8b7e04f5fb12c9 inherit pub_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a746d0373c9fb6ed0ff8b7e04f5fb12c9"></a>
uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_x_bee_request.html#a746d0373c9fb6ed0ff8b7e04f5fb12c9">getApiId</a> ()</td></tr>
<tr class="memdesc:a746d0373c9fb6ed0ff8b7e04f5fb12c9 inherit pub_methods_class_x_bee_request"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the API id. <br/></td></tr>
<tr class="separator:a746d0373c9fb6ed0ff8b7e04f5fb12c9 inherit pub_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad5b998cd95a570bdaa4d74c6c8790d94 inherit pub_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top">virtual uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_x_bee_request.html#ad5b998cd95a570bdaa4d74c6c8790d94">getFrameData</a> (uint8_t pos)=0</td></tr>
<tr class="memdesc:ad5b998cd95a570bdaa4d74c6c8790d94 inherit pub_methods_class_x_bee_request"><td class="mdescLeft">&#160;</td><td class="mdescRight">Starting after the frame id (pos = 0) and up to but not including the checksum Note: Unlike Digi's definition of the frame data, this does not start with the API ID.  <a href="#ad5b998cd95a570bdaa4d74c6c8790d94">More...</a><br/></td></tr>
<tr class="separator:ad5b998cd95a570bdaa4d74c6c8790d94 inherit pub_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a03b6c558db5836fa7167c0fba7405642 inherit pub_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a03b6c558db5836fa7167c0fba7405642"></a>
virtual uint8_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_x_bee_request.html#a03b6c558db5836fa7167c0fba7405642">getFrameDataLength</a> ()=0</td></tr>
<tr class="memdesc:a03b6c558db5836fa7167c0fba7405642 inherit pub_methods_class_x_bee_request"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the size of the api frame (not including frame id or api id or checksum). <br/></td></tr>
<tr class="separator:a03b6c558db5836fa7167c0fba7405642 inherit pub_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="inherited"></a>
Additional Inherited Members</h2></td></tr>
<tr class="inherit_header pro_methods_class_x_bee_request"><td colspan="2" onclick="javascript:toggleInherit('pro_methods_class_x_bee_request')"><img src="closed.png" alt="-"/>&#160;Protected Member Functions inherited from <a class="el" href="class_x_bee_request.html">XBeeRequest</a></td></tr>
<tr class="memitem:aee756672e79dbb05358187cb53f61b1a inherit pro_methods_class_x_bee_request"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aee756672e79dbb05358187cb53f61b1a"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><b>setApiId</b> (uint8_t apiId)</td></tr>
<tr class="separator:aee756672e79dbb05358187cb53f61b1a inherit pro_methods_class_x_bee_request"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>All TX packets that support payloads extend this class. </p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a6e86a663ab6299afaa1cf21ad7c2c5c1"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void PayloadRequest::setPayloadLength </td>
          <td>(</td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>payloadLength</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets the length of the payload to include in the request. </p>
<p>For example if the payload array is 50 bytes and you only want the first 10 to be included in the packet, set the length to 10. Length must be &lt;= to the array length. </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="_x_bee_8h_source.html">XBee.h</a></li>
<li>XBee.cpp</li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Sat Feb 1 2014 18:47:30 for XBee-Arduino by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.6
</small></address>
</body>
</html>
