hidapi_hidpi.h 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. /*******************************************************
  2. HIDAPI - Multi-Platform library for
  3. communication with HID devices.
  4. libusb/hidapi Team
  5. Copyright 2022, All Rights Reserved.
  6. At the discretion of the user of this library,
  7. this software may be licensed under the terms of the
  8. GNU General Public License v3, a BSD-Style license, or the
  9. original HIDAPI license as outlined in the LICENSE.txt,
  10. LICENSE-gpl3.txt, LICENSE-bsd.txt, and LICENSE-orig.txt
  11. files located at the root of the source distribution.
  12. These files may also be found in the public source
  13. code repository located at:
  14. https://github.com/libusb/hidapi .
  15. ********************************************************/
  16. #ifndef HIDAPI_HIDPI_H
  17. #define HIDAPI_HIDPI_H
  18. #ifdef HIDAPI_USE_DDK
  19. #include <hidpi.h>
  20. #else
  21. /* This part of the header mimics hidpi.h,
  22. but only what is used by HIDAPI */
  23. typedef struct _HIDP_PREPARSED_DATA * PHIDP_PREPARSED_DATA;
  24. typedef struct _HIDP_CAPS
  25. {
  26. USAGE Usage;
  27. USAGE UsagePage;
  28. USHORT InputReportByteLength;
  29. USHORT OutputReportByteLength;
  30. USHORT FeatureReportByteLength;
  31. USHORT Reserved[17];
  32. USHORT NumberLinkCollectionNodes;
  33. USHORT NumberInputButtonCaps;
  34. USHORT NumberInputValueCaps;
  35. USHORT NumberInputDataIndices;
  36. USHORT NumberOutputButtonCaps;
  37. USHORT NumberOutputValueCaps;
  38. USHORT NumberOutputDataIndices;
  39. USHORT NumberFeatureButtonCaps;
  40. USHORT NumberFeatureValueCaps;
  41. USHORT NumberFeatureDataIndices;
  42. } HIDP_CAPS, *PHIDP_CAPS;
  43. #define HIDP_STATUS_SUCCESS 0x00110000
  44. #define HIDP_STATUS_INVALID_PREPARSED_DATA 0xc0110001
  45. typedef NTSTATUS (__stdcall *HidP_GetCaps_)(PHIDP_PREPARSED_DATA preparsed_data, PHIDP_CAPS caps);
  46. #endif
  47. #endif /* HIDAPI_HIDPI_H */