2 * Copyright 2009, Michael Lotz, mmlr@mlotz.ch.
3 * Distributed under the terms of the MIT License.
8 #include "HIDDataTypes.h"
16 HIDParser(HIDDevice
*device
);
19 HIDDevice
* Device() { return fDevice
; };
21 status_t
ParseReportDescriptor(
22 const uint8
*reportDescriptor
,
23 size_t descriptorLength
);
25 bool UsesReportIDs() { return fUsesReportIDs
; };
27 HIDReport
* FindReport(uint8 type
, uint8 id
);
28 uint8
CountReports(uint8 type
);
29 HIDReport
* ReportAt(uint8 type
, uint8 index
);
30 size_t MaxReportSize();
32 HIDCollection
* RootCollection() { return fRootCollection
; };
34 void SetReport(status_t status
, uint8
*report
,
40 HIDReport
* _FindOrCreateReport(uint8 type
, uint8 id
);
41 float _CalculateResolution(global_item_state
*state
);
47 HIDReport
** fReports
;
48 HIDCollection
* fRootCollection
;
51 #endif // HID_PARSER_H