USB_Host_Shield_2.0/hid_8h_source.html

329 lines
59 KiB
HTML
Raw Normal View History

2013-01-30 22:00:18 +01:00
<!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"/>
2014-01-10 18:20:37 +01:00
<meta name="generator" content="Doxygen 1.8.6"/>
<title>USB Host Shield 2.0: hid.h Source File</title>
2013-01-30 22:00:18 +01:00
<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="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
$(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="imageStyle.css" rel="stylesheet" type="text/css"/>
2013-01-30 22:00:18 +01:00
</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">USB Host Shield 2.0
2013-01-30 22:00:18 +01:00
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
2014-01-10 18:20:37 +01:00
<!-- Generated by Doxygen 1.8.6 -->
2013-01-30 22:00:18 +01:00
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<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="annotated.html"><span>Classes</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
<li>
<div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<img id="MSearchSelect" src="search/mag_sel.png"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
alt=""/>
<input type="text" id="MSearchField" value="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
</span>
</div>
</li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="files.html"><span>File&#160;List</span></a></li>
<li><a href="globals.html"><span>File&#160;Members</span></a></li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Macros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Pages</a></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 id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_e5fbe6d2783ccd4c93c7856d92d7be6e.html">GitHub</a></li><li class="navelem"><a class="el" href="dir_397a095372f04465e811d0ee219bbf8f.html">USB_Host_Shield_2.0</a></li> </ul>
2013-01-30 22:00:18 +01:00
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle">
<div class="title">hid.h</div> </div>
</div><!--header-->
<div class="contents">
<a href="hid_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span>&#160;<span class="comment">/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved.</span></div>
<div class="line"><a name="l00002"></a><span class="lineno"> 2</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00003"></a><span class="lineno"> 3</span>&#160;<span class="comment">This software may be distributed and modified under the terms of the GNU</span></div>
<div class="line"><a name="l00004"></a><span class="lineno"> 4</span>&#160;<span class="comment">General Public License version 2 (GPL2) as published by the Free Software</span></div>
<div class="line"><a name="l00005"></a><span class="lineno"> 5</span>&#160;<span class="comment">Foundation and appearing in the file GPL2.TXT included in the packaging of</span></div>
<div class="line"><a name="l00006"></a><span class="lineno"> 6</span>&#160;<span class="comment">this file. Please note that GPL2 Section 2[b] requires that all works based</span></div>
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span>&#160;<span class="comment">on this software must also be made publicly available under the terms of</span></div>
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span>&#160;<span class="comment">the GPL2 (&quot;Copyleft&quot;).</span></div>
<div class="line"><a name="l00009"></a><span class="lineno"> 9</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span>&#160;<span class="comment">Contact information</span></div>
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span>&#160;<span class="comment">-------------------</span></div>
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span>&#160;<span class="comment"></span></div>
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span>&#160;<span class="comment">Circuits At Home, LTD</span></div>
<div class="line"><a name="l00014"></a><span class="lineno"> 14</span>&#160;<span class="comment">Web : http://www.circuitsathome.com</span></div>
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span>&#160;<span class="comment">e-mail : support@circuitsathome.com</span></div>
2013-04-01 22:52:24 +02:00
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span>&#160;<span class="comment"> */</span></div>
2013-01-30 22:00:18 +01:00
<div class="line"><a name="l00017"></a><span class="lineno"> 17</span>&#160;<span class="preprocessor">#if !defined(__HID_H__)</span></div>
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define __HID_H__</span></div>
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span>&#160;<span class="preprocessor"></span></div>
2013-10-21 21:15:43 +02:00
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_usb_8h.html">Usb.h</a>&quot;</span></div>
<div class="line"><a name="l00021"></a><span class="lineno"> 21</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="hidusagestr_8h.html">hidusagestr.h</a>&quot;</span></div>
<div class="line"><a name="l00022"></a><span class="lineno"> 22</span>&#160;</div>
2014-01-10 18:20:37 +01:00
<div class="line"><a name="l00023"></a><span class="lineno"><a class="line" href="hid_8h.html#aeeb08a8b14bc04296f1c839872abc8af"> 23</a></span>&#160;<span class="preprocessor">#define MAX_REPORT_PARSERS 2</span></div>
<div class="line"><a name="l00024"></a><span class="lineno"><a class="line" href="hid_8h.html#a9901c86718db1fefe5d116aa254361cf"> 24</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAX_HID_CLASS_DESCRIPTORS 5</span></div>
<div class="line"><a name="l00025"></a><span class="lineno"> 25</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00026"></a><span class="lineno"><a class="line" href="hid_8h.html#a80a14b35dd7216f368201bbdc1cb101c"> 26</a></span>&#160;<span class="preprocessor">#define DATA_SIZE_MASK 0x03</span></div>
<div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="hid_8h.html#aff17a6771d3319ab64930cd2b937d6cf"> 27</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TYPE_MASK 0x0C</span></div>
<div class="line"><a name="l00028"></a><span class="lineno"><a class="line" href="hid_8h.html#a5bf2f9f7270f2a399d2a2621fc111fef"> 28</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_MASK 0xF0</span></div>
<div class="line"><a name="l00029"></a><span class="lineno"> 29</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00030"></a><span class="lineno"><a class="line" href="hid_8h.html#ac4c40e44b6ef0e020230df304a75f8c7"> 30</a></span>&#160;<span class="preprocessor">#define DATA_SIZE_0 0x00</span></div>
<div class="line"><a name="l00031"></a><span class="lineno"><a class="line" href="hid_8h.html#a81e8f549407197122ec10d84b8c42794"> 31</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define DATA_SIZE_1 0x01</span></div>
<div class="line"><a name="l00032"></a><span class="lineno"><a class="line" href="hid_8h.html#afe89ca0c78d174017905ca74606e7917"> 32</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define DATA_SIZE_2 0x02</span></div>
<div class="line"><a name="l00033"></a><span class="lineno"><a class="line" href="hid_8h.html#a6fa5c717ec22c6281adf163d0dc4a1fb"> 33</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define DATA_SIZE_4 0x03</span></div>
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00035"></a><span class="lineno"><a class="line" href="hid_8h.html#ae10440ac2324170ae0b1d3b0e3aa767f"> 35</a></span>&#160;<span class="preprocessor">#define TYPE_MAIN 0x00</span></div>
<div class="line"><a name="l00036"></a><span class="lineno"><a class="line" href="hid_8h.html#a765b65914273505c0f53f4aff43a8124"> 36</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TYPE_GLOBAL 0x04</span></div>
<div class="line"><a name="l00037"></a><span class="lineno"><a class="line" href="hid_8h.html#a2520712de518edfc55a2897ecf7faaec"> 37</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TYPE_LOCAL 0x08</span></div>
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00039"></a><span class="lineno"><a class="line" href="hid_8h.html#a967854f388f55aaadfa5a07967e338a8"> 39</a></span>&#160;<span class="preprocessor">#define TAG_MAIN_INPUT 0x80</span></div>
<div class="line"><a name="l00040"></a><span class="lineno"><a class="line" href="hid_8h.html#a8d2abc629c107c06d019529822536057"> 40</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_MAIN_OUTPUT 0x90</span></div>
<div class="line"><a name="l00041"></a><span class="lineno"><a class="line" href="hid_8h.html#aa03120f934f69e4e543e42ecc2c48542"> 41</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_MAIN_COLLECTION 0xA0</span></div>
<div class="line"><a name="l00042"></a><span class="lineno"><a class="line" href="hid_8h.html#add8764d1be0e197bf0014add5cd0e5c3"> 42</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_MAIN_FEATURE 0xB0</span></div>
<div class="line"><a name="l00043"></a><span class="lineno"><a class="line" href="hid_8h.html#ae3646aed7eada251138358475fc07568"> 43</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_MAIN_ENDCOLLECTION 0xC0</span></div>
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00045"></a><span class="lineno"><a class="line" href="hid_8h.html#a97f5f77e22b386e3c1bd6db9152d8f10"> 45</a></span>&#160;<span class="preprocessor">#define TAG_GLOBAL_USAGEPAGE 0x00</span></div>
<div class="line"><a name="l00046"></a><span class="lineno"><a class="line" href="hid_8h.html#afc4b9bd4728c551a2632bdb8adc6726b"> 46</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_LOGICALMIN 0x10</span></div>
<div class="line"><a name="l00047"></a><span class="lineno"><a class="line" href="hid_8h.html#ab626df6886a8a1fb2e9fcaf7cbce5f46"> 47</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_LOGICALMAX 0x20</span></div>
<div class="line"><a name="l00048"></a><span class="lineno"><a class="line" href="hid_8h.html#a4cd6b210dc464605163af1a3e1965ab6"> 48</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_PHYSMIN 0x30</span></div>
<div class="line"><a name="l00049"></a><span class="lineno"><a class="line" href="hid_8h.html#a166b5d338fee5bc456fad49a4f0130f4"> 49</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_PHYSMAX 0x40</span></div>
<div class="line"><a name="l00050"></a><span class="lineno"><a class="line" href="hid_8h.html#aac7c7c715577b60dfc5cdf8c44f561ee"> 50</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_UNITEXP 0x50</span></div>
<div class="line"><a name="l00051"></a><span class="lineno"><a class="line" href="hid_8h.html#aa7b5cfc69c6bf86a11181ce7d57ad307"> 51</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_UNIT 0x60</span></div>
<div class="line"><a name="l00052"></a><span class="lineno"><a class="line" href="hid_8h.html#a337c4f4bdeeb44713eb218380b53c829"> 52</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_REPORTSIZE 0x70</span></div>
<div class="line"><a name="l00053"></a><span class="lineno"><a class="line" href="hid_8h.html#a1c175bc4e216046159a2848456496e4f"> 53</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_REPORTID 0x80</span></div>
<div class="line"><a name="l00054"></a><span class="lineno"><a class="line" href="hid_8h.html#a06b93bdd561b801f45b29014a5fda1b6"> 54</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_REPORTCOUNT 0x90</span></div>
<div class="line"><a name="l00055"></a><span class="lineno"><a class="line" href="hid_8h.html#a55fe29097369768aaf9d5b27d39e11e3"> 55</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_PUSH 0xA0</span></div>
<div class="line"><a name="l00056"></a><span class="lineno"><a class="line" href="hid_8h.html#aeae2d9a0a91e33d97a49285f8cc6294c"> 56</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_GLOBAL_POP 0xB0</span></div>
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00058"></a><span class="lineno"><a class="line" href="hid_8h.html#a69cf38b0d771c29c23b533de1235ef80"> 58</a></span>&#160;<span class="preprocessor">#define TAG_LOCAL_USAGE 0x00</span></div>
<div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="hid_8h.html#ae6b21bd3b0804cf4afcbc982658238e4"> 59</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_LOCAL_USAGEMIN 0x10</span></div>
<div class="line"><a name="l00060"></a><span class="lineno"><a class="line" href="hid_8h.html#ab80d05a68a36596bfd81e87cb7aa14d2"> 60</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define TAG_LOCAL_USAGEMAX 0x20</span></div>
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>&#160;<span class="comment">/* HID requests */</span></div>
<div class="line"><a name="l00063"></a><span class="lineno"><a class="line" href="hid_8h.html#a264e2a54e5ef95976daa14a8ba9f2f93"> 63</a></span>&#160;<span class="preprocessor">#define bmREQ_HIDOUT USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_INTERFACE</span></div>
<div class="line"><a name="l00064"></a><span class="lineno"><a class="line" href="hid_8h.html#ab73db1dfbfe4bf3e203c1980da72eda3"> 64</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define bmREQ_HIDIN USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_INTERFACE</span></div>
<div class="line"><a name="l00065"></a><span class="lineno"><a class="line" href="hid_8h.html#a06186a720fca492fb03e8c5fd58934c8"> 65</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define bmREQ_HIDREPORT USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_STANDARD|USB_SETUP_RECIPIENT_INTERFACE</span></div>
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span>&#160;<span class="comment">/* HID constants. Not part of chapter 9 */</span></div>
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>&#160;<span class="comment">/* Class-Specific Requests */</span></div>
<div class="line"><a name="l00069"></a><span class="lineno"><a class="line" href="hid_8h.html#a73dbc093cd8c096054332fde410cd9ed"> 69</a></span>&#160;<span class="preprocessor">#define HID_REQUEST_GET_REPORT 0x01</span></div>
<div class="line"><a name="l00070"></a><span class="lineno"><a class="line" href="hid_8h.html#a83087478087d308095e2d40225e3bc8d"> 70</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_REQUEST_GET_IDLE 0x02</span></div>
<div class="line"><a name="l00071"></a><span class="lineno"><a class="line" href="hid_8h.html#a5a5af41fcad0684bb2a1f69ffa053521"> 71</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_REQUEST_GET_PROTOCOL 0x03</span></div>
<div class="line"><a name="l00072"></a><span class="lineno"><a class="line" href="hid_8h.html#aee05d40a014750b24a7e9967f6f389f4"> 72</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_REQUEST_SET_REPORT 0x09</span></div>
<div class="line"><a name="l00073"></a><span class="lineno"><a class="line" href="hid_8h.html#ad5c09f0330516b99cfd6e125ca5a877b"> 73</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_REQUEST_SET_IDLE 0x0A</span></div>
<div class="line"><a name="l00074"></a><span class="lineno"><a class="line" href="hid_8h.html#a98e797920e119fe3e77d9d4181750b42"> 74</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_REQUEST_SET_PROTOCOL 0x0B</span></div>
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>&#160;<span class="comment">/* Class Descriptor Types */</span></div>
<div class="line"><a name="l00077"></a><span class="lineno"><a class="line" href="hid_8h.html#a90140ca7ead37fd62faeb395f0942a67"> 77</a></span>&#160;<span class="preprocessor">#define HID_DESCRIPTOR_HID 0x21</span></div>
<div class="line"><a name="l00078"></a><span class="lineno"><a class="line" href="hid_8h.html#a0e317fe63190a7be08676fcc92258902"> 78</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_DESCRIPTOR_REPORT 0x22</span></div>
<div class="line"><a name="l00079"></a><span class="lineno"><a class="line" href="hid_8h.html#a4c0f76c9856d874ad38fe898aa753d28"> 79</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_DESRIPTOR_PHY 0x23</span></div>
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>&#160;<span class="comment">/* Protocol Selection */</span></div>
<div class="line"><a name="l00082"></a><span class="lineno"><a class="line" href="hid_8h.html#a41258c5dd55e5ae0378ec8ded892ce37"> 82</a></span>&#160;<span class="preprocessor">#define HID_BOOT_PROTOCOL 0x00</span></div>
<div class="line"><a name="l00083"></a><span class="lineno"><a class="line" href="hid_8h.html#a5153bc7974af5cfead6daea72b8b2f6a"> 83</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_RPT_PROTOCOL 0x01</span></div>
2013-10-21 21:15:43 +02:00
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span>&#160;<span class="preprocessor"></span></div>
2014-01-10 18:20:37 +01:00
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span>&#160;<span class="comment">/* HID Interface Class Code */</span></div>
<div class="line"><a name="l00086"></a><span class="lineno"><a class="line" href="hid_8h.html#af5c77c554d065e04ff5b343c05a53fe6"> 86</a></span>&#160;<span class="preprocessor">#define HID_INTF 0x03</span></div>
2013-10-21 21:15:43 +02:00
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>&#160;<span class="preprocessor"></span></div>
2014-01-10 18:20:37 +01:00
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>&#160;<span class="comment">/* HID Interface Class SubClass Codes */</span></div>
<div class="line"><a name="l00089"></a><span class="lineno"><a class="line" href="hid_8h.html#af36d3643d6fb5f552eac19c356d9baf0"> 89</a></span>&#160;<span class="preprocessor">#define HID_BOOT_INTF_SUBCLASS 0x01</span></div>
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span>&#160;<span class="comment">/* HID Interface Class Protocol Codes */</span></div>
<div class="line"><a name="l00092"></a><span class="lineno"><a class="line" href="hid_8h.html#a050926404254a7fa1d6b5253a79abc59"> 92</a></span>&#160;<span class="preprocessor">#define HID_PROTOCOL_NONE 0x00</span></div>
<div class="line"><a name="l00093"></a><span class="lineno"><a class="line" href="hid_8h.html#a059227938fbd1b45ce693d91d2856ca9"> 93</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_PROTOCOL_KEYBOARD 0x01</span></div>
<div class="line"><a name="l00094"></a><span class="lineno"><a class="line" href="hid_8h.html#aeabcfc288ffa25ac6896d19e0642b104"> 94</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_PROTOCOL_MOUSE 0x02</span></div>
<div class="line"><a name="l00095"></a><span class="lineno"> 95</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00096"></a><span class="lineno"><a class="line" href="hid_8h.html#a9a71248c522943951b5af70ec9c14c02"> 96</a></span>&#160;<span class="preprocessor">#define HID_ITEM_TYPE_MAIN 0</span></div>
<div class="line"><a name="l00097"></a><span class="lineno"><a class="line" href="hid_8h.html#a8e56e8090f1af7aae473e8a8b6832fb8"> 97</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_ITEM_TYPE_GLOBAL 1</span></div>
<div class="line"><a name="l00098"></a><span class="lineno"><a class="line" href="hid_8h.html#a0bfb0e326d9a01072c029cba788d6456"> 98</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_ITEM_TYPE_LOCAL 2</span></div>
<div class="line"><a name="l00099"></a><span class="lineno"><a class="line" href="hid_8h.html#ae492b86b9ff1e40dfcccc904e9a30a13"> 99</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_ITEM_TYPE_RESERVED 3</span></div>
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00101"></a><span class="lineno"><a class="line" href="hid_8h.html#a574c9762fdcc2eea83be135ae54a52a1"> 101</a></span>&#160;<span class="preprocessor">#define HID_LONG_ITEM_PREFIX 0xfe // Long item prefix value</span></div>
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00103"></a><span class="lineno"><a class="line" href="hid_8h.html#a0c5cd5d30f7be0479ac6dbcb5e41f99a"> 103</a></span>&#160;<span class="preprocessor">#define bmHID_MAIN_ITEM_TAG 0xfc // Main item tag mask</span></div>
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00105"></a><span class="lineno"><a class="line" href="hid_8h.html#ab0c161ec8da9a2d5b4234efc6e66e1ab"> 105</a></span>&#160;<span class="preprocessor">#define bmHID_MAIN_ITEM_INPUT 0x80 // Main item Input tag value</span></div>
<div class="line"><a name="l00106"></a><span class="lineno"><a class="line" href="hid_8h.html#a16de52cc993408e12b019895d9676812"> 106</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define bmHID_MAIN_ITEM_OUTPUT 0x90 // Main item Output tag value</span></div>
<div class="line"><a name="l00107"></a><span class="lineno"><a class="line" href="hid_8h.html#a814680d5ac9f4928107ef8e551ea2a0f"> 107</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define bmHID_MAIN_ITEM_FEATURE 0xb0 // Main item Feature tag value</span></div>
<div class="line"><a name="l00108"></a><span class="lineno"><a class="line" href="hid_8h.html#a457b69fda34dfaa82e266bd93f094e13"> 108</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define bmHID_MAIN_ITEM_COLLECTION 0xa0 // Main item Collection tag value</span></div>
<div class="line"><a name="l00109"></a><span class="lineno"><a class="line" href="hid_8h.html#a31f12a2a73c8fb9303e8d05fe35dbdae"> 109</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define bmHID_MAIN_ITEM_END_COLLECTION 0xce // Main item End Collection tag value</span></div>
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00111"></a><span class="lineno"><a class="line" href="hid_8h.html#a11681fe3d0edf3f376786e301bc77ac1"> 111</a></span>&#160;<span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_PHYSICAL 0</span></div>
<div class="line"><a name="l00112"></a><span class="lineno"><a class="line" href="hid_8h.html#af406e4017fe65e288e3be1f4d9a77348"> 112</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_APPLICATION 1</span></div>
<div class="line"><a name="l00113"></a><span class="lineno"><a class="line" href="hid_8h.html#a6fc76c6d37f89a2ac571e1c76bf19ae0"> 113</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_LOGICAL 2</span></div>
<div class="line"><a name="l00114"></a><span class="lineno"><a class="line" href="hid_8h.html#aa9a82c8196c0fe8ba4a891c9d9126e3e"> 114</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_REPORT 3</span></div>
<div class="line"><a name="l00115"></a><span class="lineno"><a class="line" href="hid_8h.html#a9a69ff65a363bb0ef246c9f840312edf"> 115</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_NAMED_ARRAY 4</span></div>
<div class="line"><a name="l00116"></a><span class="lineno"><a class="line" href="hid_8h.html#af6e75ab2e524eafad8f6481ba5b3f1b2"> 116</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_USAGE_SWITCH 5</span></div>
<div class="line"><a name="l00117"></a><span class="lineno"><a class="line" href="hid_8h.html#ac9a63c95debeb34fc5ea25921d93c099"> 117</a></span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define HID_MAIN_ITEM_COLLECTION_USAGE_MODIFIER 6</span></div>
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00119"></a><span class="lineno"><a class="line" href="struct_hid_item_prefix.html"> 119</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct_hid_item_prefix.html">HidItemPrefix</a> {</div>
<div class="line"><a name="l00120"></a><span class="lineno"><a class="line" href="struct_hid_item_prefix.html#a4b0af0a3d7ac50bdbedcd5fae929200d"> 120</a></span>&#160; uint8_t <a class="code" href="struct_hid_item_prefix.html#a4b0af0a3d7ac50bdbedcd5fae929200d">bSize</a> : 2;</div>
<div class="line"><a name="l00121"></a><span class="lineno"><a class="line" href="struct_hid_item_prefix.html#a16874c73fdb809e4c46407ca83684927"> 121</a></span>&#160; uint8_t <a class="code" href="struct_hid_item_prefix.html#a16874c73fdb809e4c46407ca83684927">bType</a> : 2;</div>
<div class="line"><a name="l00122"></a><span class="lineno"><a class="line" href="struct_hid_item_prefix.html#a9c8a256ca8e493adfce8772445fef01e"> 122</a></span>&#160; uint8_t <a class="code" href="struct_hid_item_prefix.html#a9c8a256ca8e493adfce8772445fef01e">bTag</a> : 4;</div>
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span>&#160;};</div>
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>&#160;</div>
<div class="line"><a name="l00125"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html"> 125</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct_main_item_i_o_feature.html">MainItemIOFeature</a> {</div>
<div class="line"><a name="l00126"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#a5d578c79399be5da63790c7396fc5336"> 126</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#a5d578c79399be5da63790c7396fc5336">bmIsConstantOrData</a> : 1;</div>
<div class="line"><a name="l00127"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#adaf8eafeb85f6aff94e211601e76ee8f"> 127</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#adaf8eafeb85f6aff94e211601e76ee8f">bmIsArrayOrVariable</a> : 1;</div>
<div class="line"><a name="l00128"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#aeb93d03989043229774d2a6832e48628"> 128</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#aeb93d03989043229774d2a6832e48628">bmIsRelativeOrAbsolute</a> : 1;</div>
<div class="line"><a name="l00129"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#a7acdfbb4a6b53046205cccae67fa26d4"> 129</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#a7acdfbb4a6b53046205cccae67fa26d4">bmIsWrapOrNoWrap</a> : 1;</div>
<div class="line"><a name="l00130"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#abbe00a271ed4f5200399dd2ec5d18795"> 130</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#abbe00a271ed4f5200399dd2ec5d18795">bmIsNonLonearOrLinear</a> : 1;</div>
<div class="line"><a name="l00131"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#afd8eca62fe742513103795799d960d01"> 131</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#afd8eca62fe742513103795799d960d01">bmIsNoPreferedOrPrefered</a> : 1;</div>
<div class="line"><a name="l00132"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#a9673a5c3415a2f43b488aa32181b1f4c"> 132</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#a9673a5c3415a2f43b488aa32181b1f4c">bmIsNullOrNoNull</a> : 1;</div>
<div class="line"><a name="l00133"></a><span class="lineno"><a class="line" href="struct_main_item_i_o_feature.html#aaa20e71b24fe2de818a85b0cbdcba33e"> 133</a></span>&#160; uint8_t <a class="code" href="struct_main_item_i_o_feature.html#aaa20e71b24fe2de818a85b0cbdcba33e">bmIsVolatileOrNonVolatile</a> : 1;</div>
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span>&#160;};</div>
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>&#160;</div>
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>&#160;<span class="keyword">class </span><a class="code" href="class_h_i_d.html">HID</a>;</div>
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span>&#160;</div>
<div class="line"><a name="l00138"></a><span class="lineno"><a class="line" href="class_h_i_d_report_parser.html"> 138</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_h_i_d_report_parser.html">HIDReportParser</a> {</div>
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>&#160; <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_h_i_d_report_parser.html#ad2837f3d78c7ac3f1c2b3a4815420d97">Parse</a>(<a class="code" href="class_h_i_d.html">HID</a> *hid, <span class="keywordtype">bool</span> is_rpt_id, uint8_t len, uint8_t *buf) = 0;</div>
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>&#160;};</div>
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>&#160;</div>
2013-10-21 21:15:43 +02:00
<div class="line"><a name="l00143"></a><span class="lineno"><a class="line" href="class_h_i_d.html"> 143</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_h_i_d.html">HID</a> : <span class="keyword">public</span> <a class="code" href="class_u_s_b_device_config.html">USBDeviceConfig</a>, <span class="keyword">public</span> <a class="code" href="class_usb_config_xtracter.html">UsbConfigXtracter</a> {</div>
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>&#160;<span class="keyword">protected</span>:</div>
<div class="line"><a name="l00145"></a><span class="lineno"><a class="line" href="class_h_i_d.html#a1583e665c2b930e8683c10dc271f013f"> 145</a></span>&#160; <a class="code" href="class_u_s_b.html">USB</a> *<a class="code" href="class_h_i_d.html#a1583e665c2b930e8683c10dc271f013f">pUsb</a>; <span class="comment">// USB class instance pointer</span></div>
<div class="line"><a name="l00146"></a><span class="lineno"><a class="line" href="class_h_i_d.html#a525edb36c2cd8470eae703d3b236e4a7"> 146</a></span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a525edb36c2cd8470eae703d3b236e4a7">bAddress</a>; <span class="comment">// address</span></div>
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>&#160;</div>
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>&#160;<span class="keyword">protected</span>:</div>
<div class="line"><a name="l00149"></a><span class="lineno"><a class="line" href="class_h_i_d.html#a845b9961830a6778c296e8571759dd38"> 149</a></span>&#160; <span class="keyword">static</span> <span class="keyword">const</span> uint8_t <a class="code" href="class_h_i_d.html#a845b9961830a6778c296e8571759dd38">epInterruptInIndex</a> = 1; <span class="comment">// InterruptIN endpoint index</span></div>
<div class="line"><a name="l00150"></a><span class="lineno"><a class="line" href="class_h_i_d.html#aeb7fc07fe6dbc98d518967fdbc441ab3"> 150</a></span>&#160; <span class="keyword">static</span> <span class="keyword">const</span> uint8_t <a class="code" href="class_h_i_d.html#aeb7fc07fe6dbc98d518967fdbc441ab3">epInterruptOutIndex</a> = 2; <span class="comment">// InterruptOUT endpoint index</span></div>
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>&#160;</div>
<div class="line"><a name="l00152"></a><span class="lineno"><a class="line" href="class_h_i_d.html#afe5186f46ac7b580bb3dc289e3f237b2"> 152</a></span>&#160; <span class="keyword">static</span> <span class="keyword">const</span> uint8_t <a class="code" href="class_h_i_d.html#afe5186f46ac7b580bb3dc289e3f237b2">maxHidInterfaces</a> = 3;</div>
<div class="line"><a name="l00153"></a><span class="lineno"><a class="line" href="class_h_i_d.html#acd92969682030cd5cac310dd7746c7c7"> 153</a></span>&#160; <span class="keyword">static</span> <span class="keyword">const</span> uint8_t <a class="code" href="class_h_i_d.html#acd92969682030cd5cac310dd7746c7c7">maxEpPerInterface</a> = 2;</div>
<div class="line"><a name="l00154"></a><span class="lineno"><a class="line" href="class_h_i_d.html#a884aa67312324e7d23a052a6dc80337e"> 154</a></span>&#160; <span class="keyword">static</span> <span class="keyword">const</span> uint8_t <a class="code" href="class_h_i_d.html#a884aa67312324e7d23a052a6dc80337e">totalEndpoints</a> = (<a class="code" href="class_h_i_d.html#afe5186f46ac7b580bb3dc289e3f237b2">maxHidInterfaces</a> * <a class="code" href="class_h_i_d.html#acd92969682030cd5cac310dd7746c7c7">maxEpPerInterface</a> + 1);</div>
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>&#160;</div>
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>&#160; <span class="keywordtype">void</span> <a class="code" href="class_h_i_d.html#a9e2e57ffd2701ebd171842fa9a3f54bd">PrintEndpointDescriptor</a>(<span class="keyword">const</span> <a class="code" href="struct_u_s_b___e_n_d_p_o_i_n_t___d_e_s_c_r_i_p_t_o_r.html">USB_ENDPOINT_DESCRIPTOR</a>* ep_ptr);</div>
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>&#160; <span class="keywordtype">void</span> <a class="code" href="class_h_i_d.html#a733e3944b51dced26ef257f047c227dc">PrintHidDescriptor</a>(<span class="keyword">const</span> <a class="code" href="struct_u_s_b___h_i_d___d_e_s_c_r_i_p_t_o_r.html">USB_HID_DESCRIPTOR</a> *pDesc);</div>
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span>&#160;</div>
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span>&#160; <span class="keyword">virtual</span> <a class="code" href="class_h_i_d_report_parser.html">HIDReportParser</a>* <a class="code" href="class_h_i_d.html#ac51c88a0be514a748598008d312adc1d">GetReportParser</a>(uint8_t <span class="keywordtype">id</span>);</div>
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span>&#160;</div>
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>&#160;</div>
<div class="line"><a name="l00163"></a><span class="lineno"><a class="line" href="class_h_i_d.html#acea6b13146dc6fb351a912382ce806fd"> 163</a></span>&#160; <a class="code" href="class_h_i_d.html#acea6b13146dc6fb351a912382ce806fd">HID</a>(<a class="code" href="class_u_s_b.html">USB</a> *pusb) : <a class="code" href="class_h_i_d.html#a1583e665c2b930e8683c10dc271f013f">pUsb</a>(pusb) {</div>
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>&#160; };</div>
2013-04-01 22:52:24 +02:00
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>&#160;</div>
2013-10-21 21:15:43 +02:00
<div class="line"><a name="l00166"></a><span class="lineno"><a class="line" href="class_h_i_d.html#afd4bcb073a263f662dd5433139d6ebf3"> 166</a></span>&#160; <span class="keyword">const</span> <a class="code" href="class_u_s_b.html">USB</a>* <a class="code" href="class_h_i_d.html#afd4bcb073a263f662dd5433139d6ebf3">GetUsb</a>() {</div>
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span>&#160; <span class="keywordflow">return</span> <a class="code" href="class_h_i_d.html#a1583e665c2b930e8683c10dc271f013f">pUsb</a>;</div>
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>&#160; };</div>
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>&#160; <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="class_h_i_d.html#ae3b964d20c828fb27076f50d220fe275">SetReportParser</a>(uint8_t <span class="keywordtype">id</span>, <a class="code" href="class_h_i_d_report_parser.html">HIDReportParser</a> *prs);</div>
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>&#160;</div>
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a276ec67d360b59c3144d7ea2e2f5149e">SetProtocol</a>(uint8_t iface, uint8_t protocol);</div>
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a70be6b7ad992954b8648d7d06e2d4e2b">GetProtocol</a>(uint8_t iface, uint8_t* dataptr);</div>
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a52f9c963ffe4715829ff1b84a9eac24c">GetIdle</a>(uint8_t iface, uint8_t reportID, uint8_t* dataptr);</div>
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a6b27ed48d16c6ab09a5ea9a97a628149">SetIdle</a>(uint8_t iface, uint8_t reportID, uint8_t duration);</div>
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>&#160;</div>
2014-01-10 18:20:37 +01:00
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#abecb44a94d722becd9b95788e46d90c3">GetReportDescr</a>(uint16_t wIndex, <a class="code" href="class_u_s_b_read_parser.html">USBReadParser</a> *parser = NULL);</div>
2013-10-21 21:15:43 +02:00
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>&#160;</div>
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a13dccfb3aa8144626ba587969e3ef3b0">GetHidDescr</a>(uint8_t ep, uint16_t nbytes, uint8_t* dataptr);</div>
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a4b59be9ba5dbdc09d2e47cf734c02fdc">GetReport</a>(uint8_t ep, uint8_t iface, uint8_t report_type, uint8_t report_id, uint16_t nbytes, uint8_t* dataptr);</div>
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>&#160; uint8_t <a class="code" href="class_h_i_d.html#a58ca963ba0f12d2a457cb247595f38e9">SetReport</a>(uint8_t ep, uint8_t iface, uint8_t report_type, uint8_t report_id, uint16_t nbytes, uint8_t* dataptr);</div>
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span>&#160;};</div>
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>&#160;</div>
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>&#160;<span class="preprocessor">#endif // __HID_H__</span></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_h_i_d_html_a52f9c963ffe4715829ff1b84a9eac24c"><div class="ttname"><a href="class_h_i_d.html#a52f9c963ffe4715829ff1b84a9eac24c">HID::GetIdle</a></div><div class="ttdeci">uint8_t GetIdle(uint8_t iface, uint8_t reportID, uint8_t *dataptr)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00041">hid.cpp:41</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_ac51c88a0be514a748598008d312adc1d"><div class="ttname"><a href="class_h_i_d.html#ac51c88a0be514a748598008d312adc1d">HID::GetReportParser</a></div><div class="ttdeci">virtual HIDReportParser * GetReportParser(uint8_t id)</div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_h_i_d_html_a58ca963ba0f12d2a457cb247595f38e9"><div class="ttname"><a href="class_h_i_d.html#a58ca963ba0f12d2a457cb247595f38e9">HID::SetReport</a></div><div class="ttdeci">uint8_t SetReport(uint8_t ep, uint8_t iface, uint8_t report_type, uint8_t report_id, uint16_t nbytes, uint8_t *dataptr)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00033">hid.cpp:33</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="struct_u_s_b___e_n_d_p_o_i_n_t___d_e_s_c_r_i_p_t_o_r_html"><div class="ttname"><a href="struct_u_s_b___e_n_d_p_o_i_n_t___d_e_s_c_r_i_p_t_o_r.html">USB_ENDPOINT_DESCRIPTOR</a></div><div class="ttdef"><b>Definition:</b> <a href="usb__ch9_8h_source.html#l00141">usb_ch9.h:141</a></div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_h_i_d_html_a4b59be9ba5dbdc09d2e47cf734c02fdc"><div class="ttname"><a href="class_h_i_d.html#a4b59be9ba5dbdc09d2e47cf734c02fdc">HID::GetReport</a></div><div class="ttdeci">uint8_t GetReport(uint8_t ep, uint8_t iface, uint8_t report_type, uint8_t report_id, uint16_t nbytes, uint8_t *dataptr)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00037">hid.cpp:37</a></div></div>
<div class="ttc" id="struct_main_item_i_o_feature_html_a5d578c79399be5da63790c7396fc5336"><div class="ttname"><a href="struct_main_item_i_o_feature.html#a5d578c79399be5da63790c7396fc5336">MainItemIOFeature::bmIsConstantOrData</a></div><div class="ttdeci">uint8_t bmIsConstantOrData</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00126">hid.h:126</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_aeb7fc07fe6dbc98d518967fdbc441ab3"><div class="ttname"><a href="class_h_i_d.html#aeb7fc07fe6dbc98d518967fdbc441ab3">HID::epInterruptOutIndex</a></div><div class="ttdeci">static const uint8_t epInterruptOutIndex</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00150">hid.h:150</a></div></div>
<div class="ttc" id="class_u_s_b_device_config_html"><div class="ttname"><a href="class_u_s_b_device_config.html">USBDeviceConfig</a></div><div class="ttdef"><b>Definition:</b> <a href="_usb_core_8h_source.html#l00105">UsbCore.h:105</a></div></div>
<div class="ttc" id="_usb_8h_html"><div class="ttname"><a href="_usb_8h.html">Usb.h</a></div></div>
<div class="ttc" id="class_h_i_d_html_a525edb36c2cd8470eae703d3b236e4a7"><div class="ttname"><a href="class_h_i_d.html#a525edb36c2cd8470eae703d3b236e4a7">HID::bAddress</a></div><div class="ttdeci">uint8_t bAddress</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00146">hid.h:146</a></div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="struct_main_item_i_o_feature_html_adaf8eafeb85f6aff94e211601e76ee8f"><div class="ttname"><a href="struct_main_item_i_o_feature.html#adaf8eafeb85f6aff94e211601e76ee8f">MainItemIOFeature::bmIsArrayOrVariable</a></div><div class="ttdeci">uint8_t bmIsArrayOrVariable</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00127">hid.h:127</a></div></div>
<div class="ttc" id="struct_hid_item_prefix_html_a9c8a256ca8e493adfce8772445fef01e"><div class="ttname"><a href="struct_hid_item_prefix.html#a9c8a256ca8e493adfce8772445fef01e">HidItemPrefix::bTag</a></div><div class="ttdeci">uint8_t bTag</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00122">hid.h:122</a></div></div>
<div class="ttc" id="struct_hid_item_prefix_html_a16874c73fdb809e4c46407ca83684927"><div class="ttname"><a href="struct_hid_item_prefix.html#a16874c73fdb809e4c46407ca83684927">HidItemPrefix::bType</a></div><div class="ttdeci">uint8_t bType</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00121">hid.h:121</a></div></div>
<div class="ttc" id="class_h_i_d_html_a70be6b7ad992954b8648d7d06e2d4e2b"><div class="ttname"><a href="class_h_i_d.html#a70be6b7ad992954b8648d7d06e2d4e2b">HID::GetProtocol</a></div><div class="ttdeci">uint8_t GetProtocol(uint8_t iface, uint8_t *dataptr)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00053">hid.cpp:53</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="struct_u_s_b___h_i_d___d_e_s_c_r_i_p_t_o_r_html"><div class="ttname"><a href="struct_u_s_b___h_i_d___d_e_s_c_r_i_p_t_o_r.html">USB_HID_DESCRIPTOR</a></div><div class="ttdef"><b>Definition:</b> <a href="usb__ch9_8h_source.html#l00151">usb_ch9.h:151</a></div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_h_i_d_html_a276ec67d360b59c3144d7ea2e2f5149e"><div class="ttname"><a href="class_h_i_d.html#a276ec67d360b59c3144d7ea2e2f5149e">HID::SetProtocol</a></div><div class="ttdeci">uint8_t SetProtocol(uint8_t iface, uint8_t protocol)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00049">hid.cpp:49</a></div></div>
<div class="ttc" id="class_h_i_d_html_abecb44a94d722becd9b95788e46d90c3"><div class="ttname"><a href="class_h_i_d.html#abecb44a94d722becd9b95788e46d90c3">HID::GetReportDescr</a></div><div class="ttdeci">uint8_t GetReportDescr(uint16_t wIndex, USBReadParser *parser=NULL)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00017">hid.cpp:17</a></div></div>
<div class="ttc" id="struct_hid_item_prefix_html_a4b0af0a3d7ac50bdbedcd5fae929200d"><div class="ttname"><a href="struct_hid_item_prefix.html#a4b0af0a3d7ac50bdbedcd5fae929200d">HidItemPrefix::bSize</a></div><div class="ttdeci">uint8_t bSize</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00120">hid.h:120</a></div></div>
<div class="ttc" id="struct_main_item_i_o_feature_html_a7acdfbb4a6b53046205cccae67fa26d4"><div class="ttname"><a href="struct_main_item_i_o_feature.html#a7acdfbb4a6b53046205cccae67fa26d4">MainItemIOFeature::bmIsWrapOrNoWrap</a></div><div class="ttdeci">uint8_t bmIsWrapOrNoWrap</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00129">hid.h:129</a></div></div>
<div class="ttc" id="struct_main_item_i_o_feature_html_aaa20e71b24fe2de818a85b0cbdcba33e"><div class="ttname"><a href="struct_main_item_i_o_feature.html#aaa20e71b24fe2de818a85b0cbdcba33e">MainItemIOFeature::bmIsVolatileOrNonVolatile</a></div><div class="ttdeci">uint8_t bmIsVolatileOrNonVolatile</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00133">hid.h:133</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_afd4bcb073a263f662dd5433139d6ebf3"><div class="ttname"><a href="class_h_i_d.html#afd4bcb073a263f662dd5433139d6ebf3">HID::GetUsb</a></div><div class="ttdeci">const USB * GetUsb()</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00166">hid.h:166</a></div></div>
<div class="ttc" id="hidusagestr_8h_html"><div class="ttname"><a href="hidusagestr_8h.html">hidusagestr.h</a></div></div>
<div class="ttc" id="class_h_i_d_html"><div class="ttname"><a href="class_h_i_d.html">HID</a></div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00143">hid.h:143</a></div></div>
<div class="ttc" id="class_h_i_d_html_acea6b13146dc6fb351a912382ce806fd"><div class="ttname"><a href="class_h_i_d.html#acea6b13146dc6fb351a912382ce806fd">HID::HID</a></div><div class="ttdeci">HID(USB *pusb)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00163">hid.h:163</a></div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="struct_main_item_i_o_feature_html_a9673a5c3415a2f43b488aa32181b1f4c"><div class="ttname"><a href="struct_main_item_i_o_feature.html#a9673a5c3415a2f43b488aa32181b1f4c">MainItemIOFeature::bmIsNullOrNoNull</a></div><div class="ttdeci">uint8_t bmIsNullOrNoNull</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00132">hid.h:132</a></div></div>
<div class="ttc" id="class_u_s_b_read_parser_html"><div class="ttname"><a href="class_u_s_b_read_parser.html">USBReadParser</a></div><div class="ttdef"><b>Definition:</b> <a href="_usb_core_8h_source.html#l00171">UsbCore.h:171</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_ae3b964d20c828fb27076f50d220fe275"><div class="ttname"><a href="class_h_i_d.html#ae3b964d20c828fb27076f50d220fe275">HID::SetReportParser</a></div><div class="ttdeci">virtual bool SetReportParser(uint8_t id, HIDReportParser *prs)</div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_usb_config_xtracter_html"><div class="ttname"><a href="class_usb_config_xtracter.html">UsbConfigXtracter</a></div><div class="ttdef"><b>Definition:</b> <a href="confdescparser_8h_source.html#l00023">confdescparser.h:23</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_report_parser_html_ad2837f3d78c7ac3f1c2b3a4815420d97"><div class="ttname"><a href="class_h_i_d_report_parser.html#ad2837f3d78c7ac3f1c2b3a4815420d97">HIDReportParser::Parse</a></div><div class="ttdeci">virtual void Parse(HID *hid, bool is_rpt_id, uint8_t len, uint8_t *buf)=0</div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_h_i_d_html_a733e3944b51dced26ef257f047c227dc"><div class="ttname"><a href="class_h_i_d.html#a733e3944b51dced26ef257f047c227dc">HID::PrintHidDescriptor</a></div><div class="ttdeci">void PrintHidDescriptor(const USB_HID_DESCRIPTOR *pDesc)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00073">hid.cpp:73</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_a1583e665c2b930e8683c10dc271f013f"><div class="ttname"><a href="class_h_i_d.html#a1583e665c2b930e8683c10dc271f013f">HID::pUsb</a></div><div class="ttdeci">USB * pUsb</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00145">hid.h:145</a></div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="class_h_i_d_html_a6b27ed48d16c6ab09a5ea9a97a628149"><div class="ttname"><a href="class_h_i_d.html#a6b27ed48d16c6ab09a5ea9a97a628149">HID::SetIdle</a></div><div class="ttdeci">uint8_t SetIdle(uint8_t iface, uint8_t reportID, uint8_t duration)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00045">hid.cpp:45</a></div></div>
<div class="ttc" id="struct_main_item_i_o_feature_html_abbe00a271ed4f5200399dd2ec5d18795"><div class="ttname"><a href="struct_main_item_i_o_feature.html#abbe00a271ed4f5200399dd2ec5d18795">MainItemIOFeature::bmIsNonLonearOrLinear</a></div><div class="ttdeci">uint8_t bmIsNonLonearOrLinear</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00130">hid.h:130</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_a845b9961830a6778c296e8571759dd38"><div class="ttname"><a href="class_h_i_d.html#a845b9961830a6778c296e8571759dd38">HID::epInterruptInIndex</a></div><div class="ttdeci">static const uint8_t epInterruptInIndex</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00149">hid.h:149</a></div></div>
<div class="ttc" id="class_h_i_d_html_a13dccfb3aa8144626ba587969e3ef3b0"><div class="ttname"><a href="class_h_i_d.html#a13dccfb3aa8144626ba587969e3ef3b0">HID::GetHidDescr</a></div><div class="ttdeci">uint8_t GetHidDescr(uint8_t ep, uint16_t nbytes, uint8_t *dataptr)</div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="struct_hid_item_prefix_html"><div class="ttname"><a href="struct_hid_item_prefix.html">HidItemPrefix</a></div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00119">hid.h:119</a></div></div>
<div class="ttc" id="struct_main_item_i_o_feature_html"><div class="ttname"><a href="struct_main_item_i_o_feature.html">MainItemIOFeature</a></div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00125">hid.h:125</a></div></div>
<div class="ttc" id="class_h_i_d_report_parser_html"><div class="ttname"><a href="class_h_i_d_report_parser.html">HIDReportParser</a></div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00138">hid.h:138</a></div></div>
<div class="ttc" id="class_u_s_b_html"><div class="ttname"><a href="class_u_s_b.html">USB</a></div><div class="ttdef"><b>Definition:</b> <a href="_usb_core_8h_source.html#l00176">UsbCore.h:176</a></div></div>
<div class="ttc" id="struct_main_item_i_o_feature_html_afd8eca62fe742513103795799d960d01"><div class="ttname"><a href="struct_main_item_i_o_feature.html#afd8eca62fe742513103795799d960d01">MainItemIOFeature::bmIsNoPreferedOrPrefered</a></div><div class="ttdeci">uint8_t bmIsNoPreferedOrPrefered</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00131">hid.h:131</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_a884aa67312324e7d23a052a6dc80337e"><div class="ttname"><a href="class_h_i_d.html#a884aa67312324e7d23a052a6dc80337e">HID::totalEndpoints</a></div><div class="ttdeci">static const uint8_t totalEndpoints</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00154">hid.h:154</a></div></div>
2014-01-10 18:20:37 +01:00
<div class="ttc" id="struct_main_item_i_o_feature_html_aeb93d03989043229774d2a6832e48628"><div class="ttname"><a href="struct_main_item_i_o_feature.html#aeb93d03989043229774d2a6832e48628">MainItemIOFeature::bmIsRelativeOrAbsolute</a></div><div class="ttdeci">uint8_t bmIsRelativeOrAbsolute</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00128">hid.h:128</a></div></div>
<div class="ttc" id="class_h_i_d_html_a9e2e57ffd2701ebd171842fa9a3f54bd"><div class="ttname"><a href="class_h_i_d.html#a9e2e57ffd2701ebd171842fa9a3f54bd">HID::PrintEndpointDescriptor</a></div><div class="ttdeci">void PrintEndpointDescriptor(const USB_ENDPOINT_DESCRIPTOR *ep_ptr)</div><div class="ttdef"><b>Definition:</b> <a href="hid_8cpp_source.html#l00057">hid.cpp:57</a></div></div>
2013-10-21 21:15:43 +02:00
<div class="ttc" id="class_h_i_d_html_acd92969682030cd5cac310dd7746c7c7"><div class="ttname"><a href="class_h_i_d.html#acd92969682030cd5cac310dd7746c7c7">HID::maxEpPerInterface</a></div><div class="ttdeci">static const uint8_t maxEpPerInterface</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00153">hid.h:153</a></div></div>
<div class="ttc" id="class_h_i_d_html_afe5186f46ac7b580bb3dc289e3f237b2"><div class="ttname"><a href="class_h_i_d.html#afe5186f46ac7b580bb3dc289e3f237b2">HID::maxHidInterfaces</a></div><div class="ttdeci">static const uint8_t maxHidInterfaces</div><div class="ttdef"><b>Definition:</b> <a href="hid_8h_source.html#l00152">hid.h:152</a></div></div>
2013-01-30 22:00:18 +01:00
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
2013-01-30 22:00:18 +01:00
<img class="footer" src="doxygen.png" alt="doxygen"/>
2014-01-10 18:20:37 +01:00
</a> 1.8.6
2013-01-30 22:00:18 +01:00
</small></address>
</body>
</html>