Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > 670855e33fa56439033e33bd4989726e > files > 41

libusbx-devel-doc-1.0.17-2.mga4.noarch.rpm

<!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.5"/>
<title>Device hotplug event notification</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="projectbrief">eXpand your USB potential</div>
    </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.5 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a> &#124;
<a href="#typedef-members">Typedefs</a> &#124;
<a href="#enum-members">Enumerations</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Device hotplug event notification</div>  </div>
</div><!--header-->
<div class="contents">

<p>This page details how to use the libusb hotplug interface, where available.  
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:ga6d4f5e524a3b7ab4a25b751073335d4c"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga6d4f5e524a3b7ab4a25b751073335d4c"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#ga6d4f5e524a3b7ab4a25b751073335d4c">LIBUSB_HOTPLUG_MATCH_ANY</a>&#160;&#160;&#160;-1</td></tr>
<tr class="memdesc:ga6d4f5e524a3b7ab4a25b751073335d4c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Wildcard matching for hotplug events. <br/></td></tr>
<tr class="separator:ga6d4f5e524a3b7ab4a25b751073335d4c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr class="memitem:ga4868157346bbf2c70b6af0cb0a6c0094"><td class="memItemLeft" align="right" valign="top">typedef int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#ga4868157346bbf2c70b6af0cb0a6c0094">libusb_hotplug_callback_handle</a></td></tr>
<tr class="memdesc:ga4868157346bbf2c70b6af0cb0a6c0094"><td class="mdescLeft">&#160;</td><td class="mdescRight">Callback handle.  <a href="#ga4868157346bbf2c70b6af0cb0a6c0094">More...</a><br/></td></tr>
<tr class="separator:ga4868157346bbf2c70b6af0cb0a6c0094"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga75a45f8de2d2ac55c6d52294af12e774"><td class="memItemLeft" align="right" valign="top">typedef int(*&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#ga75a45f8de2d2ac55c6d52294af12e774">libusb_hotplug_callback_fn</a> )(<a class="el" href="group__lib.html#ga4ec088aa7b79c4a9599e39bf36a72833">libusb_context</a> *ctx, <a class="el" href="group__dev.html#ga77eedd00d01eb7569b880e861a971c2b">libusb_device</a> *device, <a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a> event, void *user_data)</td></tr>
<tr class="memdesc:ga75a45f8de2d2ac55c6d52294af12e774"><td class="mdescLeft">&#160;</td><td class="mdescRight">Hotplug callback function type.  <a href="#ga75a45f8de2d2ac55c6d52294af12e774">More...</a><br/></td></tr>
<tr class="separator:ga75a45f8de2d2ac55c6d52294af12e774"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:ga95ce2ec85dec177854c423cea2853c52"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#ga95ce2ec85dec177854c423cea2853c52">libusb_hotplug_flag</a> { <a class="el" href="group__hotplug.html#gga95ce2ec85dec177854c423cea2853c52a01a1c0c9f4e6852cb6df713f2e8a7f6b">LIBUSB_HOTPLUG_ENUMERATE</a> = 1
 }</td></tr>
<tr class="memdesc:ga95ce2ec85dec177854c423cea2853c52"><td class="mdescLeft">&#160;</td><td class="mdescRight">Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102.  <a href="group__hotplug.html#ga95ce2ec85dec177854c423cea2853c52">More...</a><br/></td></tr>
<tr class="separator:ga95ce2ec85dec177854c423cea2853c52"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga556d598ca379618a41bbec3597f55dcf"><td class="memItemLeft" align="right" valign="top">enum &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a> { <a class="el" href="group__hotplug.html#gga556d598ca379618a41bbec3597f55dcfac012270cba6e08dafe7e3bec204dffd6">LIBUSB_HOTPLUG_EVENT_DEVICE_ARRIVED</a> = 0x01, 
<a class="el" href="group__hotplug.html#gga556d598ca379618a41bbec3597f55dcfac8234e02b673893ed549329ef3180a27">LIBUSB_HOTPLUG_EVENT_DEVICE_LEFT</a> = 0x02
 }</td></tr>
<tr class="memdesc:ga556d598ca379618a41bbec3597f55dcf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102.  <a href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">More...</a><br/></td></tr>
<tr class="separator:ga556d598ca379618a41bbec3597f55dcf"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gae6c5f1add6cc754005549c7259dc35ea"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#gae6c5f1add6cc754005549c7259dc35ea">libusb_hotplug_register_callback</a> (<a class="el" href="group__lib.html#ga4ec088aa7b79c4a9599e39bf36a72833">libusb_context</a> *ctx, <a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a> events, <a class="el" href="group__hotplug.html#ga95ce2ec85dec177854c423cea2853c52">libusb_hotplug_flag</a> flags, int vendor_id, int product_id, int dev_class, <a class="el" href="group__hotplug.html#ga75a45f8de2d2ac55c6d52294af12e774">libusb_hotplug_callback_fn</a> cb_fn, void *user_data, <a class="el" href="group__hotplug.html#ga4868157346bbf2c70b6af0cb0a6c0094">libusb_hotplug_callback_handle</a> *handle)</td></tr>
<tr class="memdesc:gae6c5f1add6cc754005549c7259dc35ea"><td class="mdescLeft">&#160;</td><td class="mdescRight">Register a hotplug callback function.  <a href="#gae6c5f1add6cc754005549c7259dc35ea">More...</a><br/></td></tr>
<tr class="separator:gae6c5f1add6cc754005549c7259dc35ea"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga3d038cee3d9d96c4c4daf811f05f6ad3"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__hotplug.html#ga3d038cee3d9d96c4c4daf811f05f6ad3">libusb_hotplug_deregister_callback</a> (<a class="el" href="group__lib.html#ga4ec088aa7b79c4a9599e39bf36a72833">libusb_context</a> *ctx, <a class="el" href="group__hotplug.html#ga4868157346bbf2c70b6af0cb0a6c0094">libusb_hotplug_callback_handle</a> handle)</td></tr>
<tr class="memdesc:ga3d038cee3d9d96c4c4daf811f05f6ad3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deregisters a hotplug callback.  <a href="#ga3d038cee3d9d96c4c4daf811f05f6ad3">More...</a><br/></td></tr>
<tr class="separator:ga3d038cee3d9d96c4c4daf811f05f6ad3"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>This page details how to use the libusb hotplug interface, where available. </p>
<p>Be mindful that not all platforms currently implement hotplug notification and that you should first call on <a class="el" href="group__misc.html#ga9b8e324d28c624cd0b8e7ba21607b8db">libusb_has_capability()</a> with parameter <a class="el" href="group__misc.html#ggaab1b3fa0728c06fafbee897795889bd5a8b1bbccc648a6677cb9030a6ba827438">LIBUSB_CAP_HAS_HOTPLUG</a> to confirm that hotplug support is available. </p>
<h2 class="groupheader">Typedef Documentation</h2>
<a class="anchor" id="ga4868157346bbf2c70b6af0cb0a6c0094"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef int <a class="el" href="group__hotplug.html#ga4868157346bbf2c70b6af0cb0a6c0094">libusb_hotplug_callback_handle</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Callback handle. </p>
<p>Callbacks handles are generated by <a class="el" href="group__hotplug.html#gae6c5f1add6cc754005549c7259dc35ea" title="Register a hotplug callback function. ">libusb_hotplug_register_callback()</a> and can be used to deregister callbacks. Callback handles are unique per libusb_context and it is safe to call <a class="el" href="group__hotplug.html#ga3d038cee3d9d96c4c4daf811f05f6ad3" title="Deregisters a hotplug callback. ">libusb_hotplug_deregister_callback()</a> on an already deregisted callback.</p>
<p>Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102</p>
<p>For more information, see <a class="el" href="hotplug.html">Device hotplug event notification</a>. </p>

</div>
</div>
<a class="anchor" id="ga75a45f8de2d2ac55c6d52294af12e774"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef int( * libusb_hotplug_callback_fn)(<a class="el" href="group__lib.html#ga4ec088aa7b79c4a9599e39bf36a72833">libusb_context</a> *ctx, <a class="el" href="group__dev.html#ga77eedd00d01eb7569b880e861a971c2b">libusb_device</a> *device, <a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a> event, void *user_data)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Hotplug callback function type. </p>
<p>When requesting hotplug event notifications, you pass a pointer to a callback function of this type.</p>
<p>This callback may be called by an internal event thread and as such it is recommended the callback do minimal processing before returning.</p>
<p>libusbx will call this function later, when a matching event had happened on a matching device. See <a class="el" href="hotplug.html">Device hotplug event notification</a> for more information.</p>
<p>It is safe to call either <a class="el" href="group__hotplug.html#gae6c5f1add6cc754005549c7259dc35ea" title="Register a hotplug callback function. ">libusb_hotplug_register_callback()</a> or <a class="el" href="group__hotplug.html#ga3d038cee3d9d96c4c4daf811f05f6ad3" title="Deregisters a hotplug callback. ">libusb_hotplug_deregister_callback()</a> from within a callback function.</p>
<p>Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">ctx</td><td>context of this notification </td></tr>
    <tr><td class="paramname">device</td><td>libusb_device this event occurred on </td></tr>
    <tr><td class="paramname">event</td><td>event that occurred </td></tr>
    <tr><td class="paramname">user_data</td><td>user data provided when this callback was registered </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>bool whether this callback is finished processing events. returning 1 will cause this callback to be deregistered </dd></dl>

</div>
</div>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a class="anchor" id="ga95ce2ec85dec177854c423cea2853c52"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__hotplug.html#ga95ce2ec85dec177854c423cea2853c52">libusb_hotplug_flag</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102. </p>
<p>Flags for hotplug events </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga95ce2ec85dec177854c423cea2853c52a01a1c0c9f4e6852cb6df713f2e8a7f6b"></a>LIBUSB_HOTPLUG_ENUMERATE</em>&nbsp;</td><td class="fielddoc">
<p>Arm the callback and fire it for all matching currently attached devices. </p>
</td></tr>
</table>

</div>
</div>
<a class="anchor" id="ga556d598ca379618a41bbec3597f55dcf"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">enum <a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102. </p>
<p>Hotplug events </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><em><a class="anchor" id="gga556d598ca379618a41bbec3597f55dcfac012270cba6e08dafe7e3bec204dffd6"></a>LIBUSB_HOTPLUG_EVENT_DEVICE_ARRIVED</em>&nbsp;</td><td class="fielddoc">
<p>A device has been plugged in and is ready to use. </p>
</td></tr>
<tr><td class="fieldname"><em><a class="anchor" id="gga556d598ca379618a41bbec3597f55dcfac8234e02b673893ed549329ef3180a27"></a>LIBUSB_HOTPLUG_EVENT_DEVICE_LEFT</em>&nbsp;</td><td class="fielddoc">
<p>A device has left and is no longer available. </p>
<p>It is the user's responsibility to call libusb_close on any handle associated with a disconnected device. It is safe to call libusb_get_device_descriptor on a device that has left </p>
</td></tr>
</table>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="gae6c5f1add6cc754005549c7259dc35ea"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int libusb_hotplug_register_callback </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__lib.html#ga4ec088aa7b79c4a9599e39bf36a72833">libusb_context</a> *&#160;</td>
          <td class="paramname"><em>ctx</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a>&#160;</td>
          <td class="paramname"><em>events</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__hotplug.html#ga95ce2ec85dec177854c423cea2853c52">libusb_hotplug_flag</a>&#160;</td>
          <td class="paramname"><em>flags</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>vendor_id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>product_id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>dev_class</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__hotplug.html#ga75a45f8de2d2ac55c6d52294af12e774">libusb_hotplug_callback_fn</a>&#160;</td>
          <td class="paramname"><em>cb_fn</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>user_data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__hotplug.html#ga4868157346bbf2c70b6af0cb0a6c0094">libusb_hotplug_callback_handle</a> *&#160;</td>
          <td class="paramname"><em>handle</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Register a hotplug callback function. </p>
<p>Register a callback with the libusb_context. The callback will fire when a matching event occurs on a matching device. The callback is armed until either it is deregistered with <a class="el" href="group__hotplug.html#ga3d038cee3d9d96c4c4daf811f05f6ad3" title="Deregisters a hotplug callback. ">libusb_hotplug_deregister_callback()</a> or the supplied callback returns 1 to indicate it is finished processing events.</p>
<p>If the <a class="el" href="group__hotplug.html#gga95ce2ec85dec177854c423cea2853c52a01a1c0c9f4e6852cb6df713f2e8a7f6b">LIBUSB_HOTPLUG_ENUMERATE</a> is passed the callback will be called with a <a class="el" href="group__hotplug.html#gga556d598ca379618a41bbec3597f55dcfac012270cba6e08dafe7e3bec204dffd6">LIBUSB_HOTPLUG_EVENT_DEVICE_ARRIVED</a> for all devices already plugged into the machine. Note that libusbx modifies its internal device list from a separate thread, while calling hotplug callbacks from <a class="el" href="group__poll.html#ga4989086e3f0327f3886a4c474ec7c327" title="Handle any pending events in blocking mode. ">libusb_handle_events()</a>, so it is possible for a device to already be present on, or removed from, its internal device list, while the hotplug callbacks still need to be dispatched. This means that when using <a class="el" href="group__hotplug.html#gga95ce2ec85dec177854c423cea2853c52a01a1c0c9f4e6852cb6df713f2e8a7f6b">LIBUSB_HOTPLUG_ENUMERATE</a>, your callback may be called twice for the arrival of the same device, once from <a class="el" href="group__hotplug.html#gae6c5f1add6cc754005549c7259dc35ea" title="Register a hotplug callback function. ">libusb_hotplug_register_callback()</a> and once from <a class="el" href="group__poll.html#ga4989086e3f0327f3886a4c474ec7c327" title="Handle any pending events in blocking mode. ">libusb_handle_events()</a>; and/or your callback may be called for the removal of a device for which an arrived call was never made.</p>
<p>Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">ctx</td><td>context to register this callback with </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">events</td><td>bitwise or of events that will trigger this callback. See <a class="el" href="group__hotplug.html#ga556d598ca379618a41bbec3597f55dcf">libusb_hotplug_event</a> </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">flags</td><td>hotplug callback flags. See <a class="el" href="group__hotplug.html#ga95ce2ec85dec177854c423cea2853c52">libusb_hotplug_flag</a> </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">vendor_id</td><td>the vendor id to match or <a class="el" href="group__hotplug.html#ga6d4f5e524a3b7ab4a25b751073335d4c">LIBUSB_HOTPLUG_MATCH_ANY</a> </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">product_id</td><td>the product id to match or <a class="el" href="group__hotplug.html#ga6d4f5e524a3b7ab4a25b751073335d4c">LIBUSB_HOTPLUG_MATCH_ANY</a> </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">dev_class</td><td>the device class to match or <a class="el" href="group__hotplug.html#ga6d4f5e524a3b7ab4a25b751073335d4c">LIBUSB_HOTPLUG_MATCH_ANY</a> </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">cb_fn</td><td>the function to be invoked on a matching event/device </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">user_data</td><td>user data to pass to the callback function </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">handle</td><td>pointer to store the handle of the allocated callback (can be NULL) </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>LIBUSB_SUCCESS on success LIBUSB_ERROR code on failure </dd></dl>

</div>
</div>
<a class="anchor" id="ga3d038cee3d9d96c4c4daf811f05f6ad3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void libusb_hotplug_deregister_callback </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__lib.html#ga4ec088aa7b79c4a9599e39bf36a72833">libusb_context</a> *&#160;</td>
          <td class="paramname"><em>ctx</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__hotplug.html#ga4868157346bbf2c70b6af0cb0a6c0094">libusb_hotplug_callback_handle</a>&#160;</td>
          <td class="paramname"><em>handle</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Deregisters a hotplug callback. </p>
<p>Deregister a callback from a libusb_context. This function is safe to call from within a hotplug callback.</p>
<p>Since version 1.0.16, <a class="el" href="group__misc.html#gaa83ecded256e0767220bcc21cc92365d">LIBUSBX_API_VERSION</a> &gt;= 0x01000102</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">ctx</td><td>context this callback is registered with </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">handle</td><td>the handle of the callback to deregister </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Sat Oct 19 2013 16:44:34 by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.5
</small></address>
</body>
</html>