This file is indexed.

/usr/share/doc/libusb-1.0-doc/html/index.html is in libusb-1.0-doc 2:1.0.21-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<!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.12"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libusb-1.0 API 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 id="projectlogo"><img alt="Logo" src="libusb.png"/></td>
    <td style="padding-left: 0.5em;">
    <div id="projectbrief">A cross-platform user library to access USB devices</div>
    </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.12 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',false,false,'search.php','Search');
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">libusb-1.0 API Reference </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><h1><a class="anchor" id="intro"></a>
Introduction</h1>
<p>libusb is an open source library that allows you to communicate with USB devices from userspace. For more info, see the <a href="http://libusb.info">libusb homepage</a>.</p>
<p>This documentation is aimed at application developers wishing to communicate with USB peripherals from their own software. After reviewing this documentation, feedback and questions can be sent to the <a href="http://mailing-list.libusb.info">libusb-devel mailing list</a>.</p>
<p>This documentation assumes knowledge of how to operate USB devices from a software standpoint (descriptors, configurations, interfaces, endpoints, control/bulk/interrupt/isochronous transfers, etc). Full information can be found in the <a href="http://www.usb.org/developers/docs/">USB 3.0 Specification</a> which is available for free download. You can probably find less verbose introductions by searching the web.</p>
<h1><a class="anchor" id="API"></a>
Application Programming Interface (API)</h1>
<p>See the <a class="el" href="libusb_api.html">Application Programming Interface</a> page for a complete list of the libusb functions.</p>
<h1><a class="anchor" id="features"></a>
Library features</h1>
<ul>
<li>All transfer types supported (control/bulk/interrupt/isochronous)</li>
<li>2 transfer interfaces:<ol type="1">
<li>Synchronous (simple)</li>
<li>Asynchronous (more complicated, but more powerful)</li>
</ol>
</li>
<li>Thread safe (although the asynchronous interface means that you usually won't need to thread)</li>
<li>Lightweight with lean API</li>
<li>Compatible with libusb-0.1 through the libusb-compat-0.1 translation layer</li>
<li>Hotplug support (on some platforms). See <a class="el" href="libusb_hotplug.html">Device hotplug event notification</a>.</li>
</ul>
<h1><a class="anchor" id="gettingstarted"></a>
Getting Started</h1>
<p>To begin reading the API documentation, start with the Modules page which links to the different categories of libusb's functionality.</p>
<p>One decision you will have to make is whether to use the synchronous or the asynchronous data transfer interface. The <a class="el" href="libusb_io.html">Synchronous and asynchronous device I/O</a> documentation provides some insight into this topic.</p>
<p>Some example programs can be found in the libusb source distribution under the "examples" subdirectory. The libusb homepage includes a list of real-life project examples which use libusb.</p>
<h1><a class="anchor" id="errorhandling"></a>
Error handling</h1>
<p>libusb functions typically return 0 on success or a negative error code on failure. These negative error codes relate to LIBUSB_ERROR constants which are listed on the <a class="el" href="group__libusb__misc.html">miscellaneous</a> documentation page.</p>
<h1><a class="anchor" id="msglog"></a>
Debug message logging</h1>
<p>libusb uses stderr for all logging. By default, logging is set to NONE, which means that no output will be produced. However, unless the library has been compiled with logging disabled, then any application calls to <a class="el" href="group__libusb__lib.html#ga5f8376b7a863a5a8d5b8824feb8a427a" title="Set log message verbosity. ">libusb_set_debug()</a>, or the setting of the environmental variable LIBUSB_DEBUG outside of the application, can result in logging being produced. Your application should therefore not close stderr, but instead direct it to the null device if its output is undesirable.</p>
<p>The <a class="el" href="group__libusb__lib.html#ga5f8376b7a863a5a8d5b8824feb8a427a" title="Set log message verbosity. ">libusb_set_debug()</a> function can be used to enable logging of certain messages. Under standard configuration, libusb doesn't really log much so you are advised to use this function to enable all error/warning/ informational messages. It will help debug problems with your software.</p>
<p>The logged messages are unstructured. There is no one-to-one correspondence between messages being logged and success or failure return codes from libusb functions. There is no format to the messages, so you should not try to capture or parse them. They are not and will not be localized. These messages are not intended to being passed to your application user; instead, you should interpret the error codes returned from libusb functions and provide appropriate notification to the user. The messages are simply there to aid you as a programmer, and if you're confused because you're getting a strange error code from a libusb function, enabling message logging may give you a suitable explanation.</p>
<p>The LIBUSB_DEBUG environment variable can be used to enable message logging at run-time. This environment variable should be set to a log level number, which is interpreted the same as the <a class="el" href="group__libusb__lib.html#ga5f8376b7a863a5a8d5b8824feb8a427a" title="Set log message verbosity. ">libusb_set_debug()</a> parameter. When this environment variable is set, the message logging verbosity level is fixed and <a class="el" href="group__libusb__lib.html#ga5f8376b7a863a5a8d5b8824feb8a427a" title="Set log message verbosity. ">libusb_set_debug()</a> effectively does nothing.</p>
<p>libusb can be compiled without any logging functions, useful for embedded systems. In this case, <a class="el" href="group__libusb__lib.html#ga5f8376b7a863a5a8d5b8824feb8a427a" title="Set log message verbosity. ">libusb_set_debug()</a> and the LIBUSB_DEBUG environment variable have no effects.</p>
<p>libusb can also be compiled with verbose debugging messages always. When the library is compiled in this way, all messages of all verbosities are always logged. <a class="el" href="group__libusb__lib.html#ga5f8376b7a863a5a8d5b8824feb8a427a" title="Set log message verbosity. ">libusb_set_debug()</a> and the LIBUSB_DEBUG environment variable have no effects.</p>
<h1><a class="anchor" id="remarks"></a>
Other remarks</h1>
<p>libusb does have imperfections. The <a class="el" href="libusb_caveats.html">caveats</a> page attempts to document these. </p>
</div></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Wed Oct 26 2016 18:57:04 by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.12
</small></address>
</body>
</html>