esp-nimble-cpp/class_nim_b_l_e_client_callbacks.html

343 lines
16 KiB
HTML
Raw Normal View History

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://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"/>
2022-01-15 23:23:57 +01:00
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
2022-01-15 23:23:57 +01:00
<title>esp-nimble-cpp: NimBLEClientCallbacks 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="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.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 id="projectalign" style="padding-left: 0.5em;">
2022-01-15 23:23:57 +01:00
<div id="projectname">esp-nimble-cpp
2022-07-31 19:38:16 +02:00
&#160;<span id="projectnumber">1.4.0</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
2022-01-15 23:23:57 +01:00
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('class_nim_b_l_e_client_callbacks.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="class_nim_b_l_e_client_callbacks-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">NimBLEClientCallbacks Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Callbacks associated with a BLE client.
<a href="class_nim_b_l_e_client_callbacks.html#details">More...</a></p>
<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:a96de53d9745f243d544cd89498f979ae"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_nim_b_l_e_client_callbacks.html#a96de53d9745f243d544cd89498f979ae">onConnect</a> (<a class="el" href="class_nim_b_l_e_client.html">NimBLEClient</a> *pClient)</td></tr>
<tr class="memdesc:a96de53d9745f243d544cd89498f979ae"><td class="mdescLeft">&#160;</td><td class="mdescRight">Called after client connects. <a href="class_nim_b_l_e_client_callbacks.html#a96de53d9745f243d544cd89498f979ae">More...</a><br /></td></tr>
<tr class="separator:a96de53d9745f243d544cd89498f979ae"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3e5571e4d5ee53c5c4b25ceaac66b808"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_nim_b_l_e_client_callbacks.html#a3e5571e4d5ee53c5c4b25ceaac66b808">onDisconnect</a> (<a class="el" href="class_nim_b_l_e_client.html">NimBLEClient</a> *pClient)</td></tr>
<tr class="memdesc:a3e5571e4d5ee53c5c4b25ceaac66b808"><td class="mdescLeft">&#160;</td><td class="mdescRight">Called when disconnected from the server. <a href="class_nim_b_l_e_client_callbacks.html#a3e5571e4d5ee53c5c4b25ceaac66b808">More...</a><br /></td></tr>
<tr class="separator:a3e5571e4d5ee53c5c4b25ceaac66b808"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8bc6a072e1cc974ef084eb2cad18dac6"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_nim_b_l_e_client_callbacks.html#a8bc6a072e1cc974ef084eb2cad18dac6">onConnParamsUpdateRequest</a> (<a class="el" href="class_nim_b_l_e_client.html">NimBLEClient</a> *pClient, const ble_gap_upd_params *params)</td></tr>
<tr class="memdesc:a8bc6a072e1cc974ef084eb2cad18dac6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Called when server requests to update the connection parameters. <a href="class_nim_b_l_e_client_callbacks.html#a8bc6a072e1cc974ef084eb2cad18dac6">More...</a><br /></td></tr>
<tr class="separator:a8bc6a072e1cc974ef084eb2cad18dac6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9850764aec546747537c6baa2a4622f5"><td class="memItemLeft" align="right" valign="top">virtual uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_nim_b_l_e_client_callbacks.html#a9850764aec546747537c6baa2a4622f5">onPassKeyRequest</a> ()</td></tr>
<tr class="memdesc:a9850764aec546747537c6baa2a4622f5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Called when server requests a passkey for pairing. <a href="class_nim_b_l_e_client_callbacks.html#a9850764aec546747537c6baa2a4622f5">More...</a><br /></td></tr>
<tr class="separator:a9850764aec546747537c6baa2a4622f5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a40fb2013fc4ebe51f770699377922065"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_nim_b_l_e_client_callbacks.html#a40fb2013fc4ebe51f770699377922065">onAuthenticationComplete</a> (ble_gap_conn_desc *desc)</td></tr>
<tr class="memdesc:a40fb2013fc4ebe51f770699377922065"><td class="mdescLeft">&#160;</td><td class="mdescRight">Called when the pairing procedure is complete. <a href="class_nim_b_l_e_client_callbacks.html#a40fb2013fc4ebe51f770699377922065">More...</a><br /></td></tr>
<tr class="separator:a40fb2013fc4ebe51f770699377922065"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ace39ee838319e415bd0fc5c72a653ff0"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_nim_b_l_e_client_callbacks.html#ace39ee838319e415bd0fc5c72a653ff0">onConfirmPIN</a> (uint32_t pin)</td></tr>
<tr class="memdesc:ace39ee838319e415bd0fc5c72a653ff0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Called when using numeric comparision for pairing. <a href="class_nim_b_l_e_client_callbacks.html#ace39ee838319e415bd0fc5c72a653ff0">More...</a><br /></td></tr>
<tr class="separator:ace39ee838319e415bd0fc5c72a653ff0"><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>Callbacks associated with a BLE client. </p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a id="a40fb2013fc4ebe51f770699377922065"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a40fb2013fc4ebe51f770699377922065">&#9670;&nbsp;</a></span>onAuthenticationComplete()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void NimBLEClientCallbacks::onAuthenticationComplete </td>
<td>(</td>
<td class="paramtype">ble_gap_conn_desc *&#160;</td>
<td class="paramname"><em>desc</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Called when the pairing procedure is complete. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">desc</td><td>A pointer to the struct containing the connection information.<br />
This can be used to check the status of the connection encryption/pairing. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="ace39ee838319e415bd0fc5c72a653ff0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ace39ee838319e415bd0fc5c72a653ff0">&#9670;&nbsp;</a></span>onConfirmPIN()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool NimBLEClientCallbacks::onConfirmPIN </td>
<td>(</td>
<td class="paramtype">uint32_t&#160;</td>
<td class="paramname"><em>pin</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Called when using numeric comparision for pairing. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">pin</td><td>The pin to compare with the server. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True to accept the pin. </dd></dl>
</div>
</div>
<a id="a96de53d9745f243d544cd89498f979ae"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a96de53d9745f243d544cd89498f979ae">&#9670;&nbsp;</a></span>onConnect()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void NimBLEClientCallbacks::onConnect </td>
<td>(</td>
<td class="paramtype"><a class="el" href="class_nim_b_l_e_client.html">NimBLEClient</a> *&#160;</td>
<td class="paramname"><em>pClient</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Called after client connects. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">pClient</td><td>A pointer to the calling client object. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a8bc6a072e1cc974ef084eb2cad18dac6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8bc6a072e1cc974ef084eb2cad18dac6">&#9670;&nbsp;</a></span>onConnParamsUpdateRequest()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool NimBLEClientCallbacks::onConnParamsUpdateRequest </td>
<td>(</td>
<td class="paramtype"><a class="el" href="class_nim_b_l_e_client.html">NimBLEClient</a> *&#160;</td>
<td class="paramname"><em>pClient</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const ble_gap_upd_params *&#160;</td>
<td class="paramname"><em>params</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Called when server requests to update the connection parameters. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">pClient</td><td>A pointer to the calling client object. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">params</td><td>A pointer to the struct containing the connection parameters requested. </td></tr>
</table>
</dd>
</dl>
2022-07-31 19:38:16 +02:00
<dl class="section return"><dt>Returns</dt><dd>True to accept the parameters. </dd></dl>
</div>
</div>
<a id="a3e5571e4d5ee53c5c4b25ceaac66b808"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3e5571e4d5ee53c5c4b25ceaac66b808">&#9670;&nbsp;</a></span>onDisconnect()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void NimBLEClientCallbacks::onDisconnect </td>
<td>(</td>
<td class="paramtype"><a class="el" href="class_nim_b_l_e_client.html">NimBLEClient</a> *&#160;</td>
<td class="paramname"><em>pClient</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Called when disconnected from the server. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">pClient</td><td>A pointer to the calling client object. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a9850764aec546747537c6baa2a4622f5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9850764aec546747537c6baa2a4622f5">&#9670;&nbsp;</a></span>onPassKeyRequest()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">uint32_t NimBLEClientCallbacks::onPassKeyRequest </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Called when server requests a passkey for pairing. </p>
<dl class="section return"><dt>Returns</dt><dd>The passkey to be sent to the server. </dd></dl>
</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="navelem"><a class="el" href="class_nim_b_l_e_client_callbacks.html">NimBLEClientCallbacks</a></li>
2022-01-15 23:23:57 +01:00
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1 </li>
</ul>
</div>
</body>
</html>