ReactOS  0.4.15-dev-1367-g07cc0b5
hidpi.h File Reference
#include "hidusage.h"
Include dependency graph for hidpi.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _HIDP_UNKNOWN_TOKEN
 
struct  _HIDP_KEYBOARD_MODIFIER_STATE
 
struct  _USAGE_AND_PAGE
 
struct  _HIDD_ATTRIBUTES
 
struct  _HIDD_CONFIGURATION
 
struct  _HIDP_BUTTON_CAPS
 
struct  _HIDP_CAPS
 
struct  _HIDP_DATA
 
struct  _HIDP_EXTENDED_ATTRIBUTES
 
struct  _HIDP_LINK_COLLECTION_NODE
 
struct  _HIDP_VALUE_CAPS
 

Macros

#define HIDAPI   DECLSPEC_IMPORT
 
#define HIDP_LINK_COLLECTION_ROOT   ((USHORT) -1)
 
#define HIDP_LINK_COLLECTION_UNSPECIFIED   ((USHORT) 0)
 
#define FACILITY_HID_ERROR_CODE   0x11
 
#define HIDP_ERROR_CODES(SEV, CODE)   ((NTSTATUS) (((SEV) << 28) | (FACILITY_HID_ERROR_CODE << 16) | (CODE)))
 
#define HIDP_STATUS_SUCCESS   (HIDP_ERROR_CODES(0x0, 0))
 
#define HIDP_STATUS_NULL   (HIDP_ERROR_CODES(0x8, 1))
 
#define HIDP_STATUS_INVALID_PREPARSED_DATA   (HIDP_ERROR_CODES(0xC, 1))
 
#define HIDP_STATUS_INVALID_REPORT_TYPE   (HIDP_ERROR_CODES(0xC, 2))
 
#define HIDP_STATUS_INVALID_REPORT_LENGTH   (HIDP_ERROR_CODES(0xC, 3))
 
#define HIDP_STATUS_USAGE_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 4))
 
#define HIDP_STATUS_VALUE_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 5))
 
#define HIDP_STATUS_BAD_LOG_PHY_VALUES   (HIDP_ERROR_CODES(0xC, 6))
 
#define HIDP_STATUS_BUFFER_TOO_SMALL   (HIDP_ERROR_CODES(0xC, 7))
 
#define HIDP_STATUS_INTERNAL_ERROR   (HIDP_ERROR_CODES(0xC, 8))
 
#define HIDP_STATUS_I8042_TRANS_UNKNOWN   (HIDP_ERROR_CODES(0xC, 9))
 
#define HIDP_STATUS_INCOMPATIBLE_REPORT_ID   (HIDP_ERROR_CODES(0xC, 0xA))
 
#define HIDP_STATUS_NOT_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xB))
 
#define HIDP_STATUS_IS_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xC))
 
#define HIDP_STATUS_DATA_INDEX_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 0xD))
 
#define HIDP_STATUS_DATA_INDEX_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 0xE))
 
#define HIDP_STATUS_BUTTON_NOT_PRESSED   (HIDP_ERROR_CODES(0xC, 0xF))
 
#define HIDP_STATUS_REPORT_DOES_NOT_EXIST   (HIDP_ERROR_CODES(0xC, 0x10))
 
#define HIDP_STATUS_NOT_IMPLEMENTED   (HIDP_ERROR_CODES(0xC, 0x20))
 
#define HIDP_STATUS_I8242_TRANS_UNKNOWN   HIDP_STATUS_I8042_TRANS_UNKNOWN
 
#define HidP_GetButtonCaps(_Type_, _Caps_, _Len_, _Data_)   HidP_GetSpecificButtonCaps(_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)
 
#define HidP_GetButtons(Rty, UPa, LCo, ULi, ULe, Ppd, Rep, RLe)   HidP_GetUsages(Rty, UPa, LCo, ULi, ULe, Ppd, Rep, RLe)
 
#define HidP_GetButtonListLength(RTy, UPa, Ppd)   HidP_GetUsageListLength(Rty, UPa, Ppd)
 
#define HidP_GetButtonsEx(RT, LC, BL, UL, PD, R, RL)   HidP_GetUsagesEx(RT, LC, BL, UL, PD, R, RL)
 
#define HidP_GetValueCaps(_Type_, _Caps_, _Len_, _Data_)   HidP_GetSpecificValueCaps (_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)
 
#define HidP_IsSameUsageAndPage(u1, u2)   ((* (PULONG) &u1) == (* (PULONG) &u2))
 
#define HidP_SetButtons(RT, UP, LC, UL1, UL2, PD, R, RL)   HidP_SetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)
 
#define HidP_UnsetButtons(RT, UP, LC, UL1, UL2, PD, R, RL)   HidP_UnsetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)
 

Typedefs

typedef PUCHAR PHIDP_REPORT_DESCRIPTOR
 
typedef struct _HIDP_PREPARSED_DATA * PHIDP_PREPARSED_DATA
 
typedef struct _HIDP_UNKNOWN_TOKEN HIDP_UNKNOWN_TOKEN
 
typedef struct _HIDP_UNKNOWN_TOKENPHIDP_UNKNOWN_TOKEN
 
typedef enum _HIDP_KEYBOARD_DIRECTION HIDP_KEYBOARD_DIRECTION
 
typedef struct _HIDP_KEYBOARD_MODIFIER_STATE HIDP_KEYBOARD_MODIFIER_STATE
 
typedef struct _HIDP_KEYBOARD_MODIFIER_STATEPHIDP_KEYBOARD_MODIFIER_STATE
 
typedef BOOLEAN(NTAPIPHIDP_INSERT_SCANCODES) (_In_opt_ PVOID Context, _In_reads_bytes_(Length) PCHAR NewScanCodes, _In_ ULONG Length)
 
typedef struct _USAGE_AND_PAGE USAGE_AND_PAGE
 
typedef struct _USAGE_AND_PAGEPUSAGE_AND_PAGE
 
typedef struct _HIDD_ATTRIBUTES HIDD_ATTRIBUTES
 
typedef struct _HIDD_ATTRIBUTESPHIDD_ATTRIBUTES
 
typedef struct _HIDD_CONFIGURATION HIDD_CONFIGURATION
 
typedef struct _HIDD_CONFIGURATIONPHIDD_CONFIGURATION
 
typedef struct _HIDP_BUTTON_CAPS HIDP_BUTTON_CAPS
 
typedef struct _HIDP_BUTTON_CAPSPHIDP_BUTTON_CAPS
 
typedef struct _HIDP_CAPS HIDP_CAPS
 
typedef struct _HIDP_CAPSPHIDP_CAPS
 
typedef struct _HIDP_DATA HIDP_DATA
 
typedef struct _HIDP_DATAPHIDP_DATA
 
typedef struct _HIDP_EXTENDED_ATTRIBUTES HIDP_EXTENDED_ATTRIBUTES
 
typedef struct _HIDP_EXTENDED_ATTRIBUTESPHIDP_EXTENDED_ATTRIBUTES
 
typedef struct _HIDP_LINK_COLLECTION_NODE HIDP_LINK_COLLECTION_NODE
 
typedef struct _HIDP_LINK_COLLECTION_NODEPHIDP_LINK_COLLECTION_NODE
 
typedef struct _HIDP_VALUE_CAPS HIDP_VALUE_CAPS
 
typedef struct _HIDP_VALUE_CAPSPHIDP_VALUE_CAPS
 
typedef enum _HIDP_REPORT_TYPE HIDP_REPORT_TYPE
 

Enumerations

enum  _HIDP_KEYBOARD_DIRECTION { HidP_Keyboard_Break, HidP_Keyboard_Make }
 
enum  _HIDP_REPORT_TYPE { HidP_Input, HidP_Output, HidP_Feature }
 

Functions

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsageAndPagesToI8042ScanCodes (_In_reads_(UsageListLength) PUSAGE_AND_PAGE ChangedUsageList, _In_ ULONG UsageListLength, _In_ HIDP_KEYBOARD_DIRECTION KeyAction, _Inout_ PHIDP_KEYBOARD_MODIFIER_STATE ModifierState, _In_ PHIDP_INSERT_SCANCODES InsertCodesProcedure, _In_opt_ PVOID InsertCodesContext)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsagesToI8042ScanCodes (_In_reads_(UsageListLength) PUSAGE ChangedUsageList, _In_ ULONG UsageListLength, _In_ HIDP_KEYBOARD_DIRECTION KeyAction, _Inout_ PHIDP_KEYBOARD_MODIFIER_STATE ModifierState, _In_ PHIDP_INSERT_SCANCODES InsertCodesProcedure, _In_opt_ PVOID InsertCodesContext)
 
_Must_inspect_result_ _IRQL_requires_max_ (PASSIVE_LEVEL) HIDAPI NTSTATUS NTAPI HidP_GetCaps(_In_ PHIDP_PREPARSED_DATA PreparsedData
 
_Must_inspect_result_ _IRQL_requires_max_ (DISPATCH_LEVEL) HIDAPI NTSTATUS NTAPI HidP_GetData(_In_ HIDP_REPORT_TYPE ReportType
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG _In_ PHIDP_PREPARSED_DATA _Out_writes_bytes_ (ReportLength) PCHAR Report
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetScaledUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _Out_ PLONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsages (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _Out_writes_to_(*UsageLength, *UsageLength) USAGE *UsageList, _Inout_ ULONG *UsageLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Out_writes_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ _In_ USHORT _Inout_updates_to_ UsageLength PUSAGE_AND_PAGE _Inout_ ULONG _In_ PHIDP_PREPARSED_DATA _In_reads_bytes_ (ReportLength) PCHAR Report
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _Out_ PULONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValueArray (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _Inout_updates_bytes_(UsageValueByteLength) PCHAR UsageValue, _In_ USHORT UsageValueByteLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetData (_In_ HIDP_REPORT_TYPE ReportType, _Inout_updates_to_(*DataLength, *DataLength) PHIDP_DATA DataList, _Inout_ PULONG DataLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetScaledUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _In_ LONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Inout_updates_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsages (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _Inout_updates_to_(*UsageLength, *UsageLength) PUSAGE UsageList, _Inout_ PULONG UsageLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _In_ ULONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Inout_updates_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValueArray (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _In_reads_bytes_(UsageValueByteLength) PCHAR UsageValue, _In_ USHORT UsageValueByteLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Inout_updates_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_UnsetUsages (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_opt_ USHORT LinkCollection, _Inout_updates_to_(*UsageLength, *UsageLength) PUSAGE UsageList, _Inout_ PULONG UsageLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ _In_reads_ (UsageListLength) PUSAGE_AND_PAGE CurrentUsageList
 
_Must_inspect_result_ _Out_writes_ (UsageListLength) PUSAGE_AND_PAGE BreakUsageList
 

Variables

_Must_inspect_result_ _Out_ PHIDP_CAPS Capabilities
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA DataList
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG DataLength
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG _In_ PHIDP_PREPARSED_DATA PreparsedData
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG _In_ PHIDP_PREPARSED_DATA _In_ ULONG ReportLength
 
_Must_inspect_result_ _In_ USHORT DataIndex
 
_Must_inspect_result_ _In_ USHORT _In_ PHIDP_PREPARSED_DATA _Out_writes_to_ LengthAttributes PHIDP_EXTENDED_ATTRIBUTES Attributes
 
_Must_inspect_result_ _In_ USHORT _In_ PHIDP_PREPARSED_DATA _Out_writes_to_ LengthAttributes PHIDP_EXTENDED_ATTRIBUTES _Inout_ OUT PULONG LengthAttributes
 
_Must_inspect_result_ _Inout_ PULONG LinkCollectionNodesLength
 
_Must_inspect_result_ _In_ USAGE UsagePage
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT LinkCollection
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE Usage
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_BUTTON_CAPS ButtonCaps
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_BUTTON_CAPS _Inout_ PUSHORT ButtonCapsLength
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_VALUE_CAPS ValueCaps
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_VALUE_CAPS _Inout_ PUSHORT ValueCapsLength
 
_Must_inspect_result_ _In_ USHORT _Inout_updates_to_ UsageLength PUSAGE_AND_PAGE ButtonList
 
_Must_inspect_result_ _In_ USHORT _Inout_updates_to_ UsageLength PUSAGE_AND_PAGE _Inout_ ULONGUsageLength
 
_Must_inspect_result_ _In_ UCHAR ReportID
 
_Must_inspect_result_ _In_ ULONG UsageListLength
 

Macro Definition Documentation

◆ FACILITY_HID_ERROR_CODE

#define FACILITY_HID_ERROR_CODE   0x11

Definition at line 243 of file hidpi.h.

◆ HIDAPI

#define HIDAPI   DECLSPEC_IMPORT

Definition at line 35 of file hidpi.h.

◆ HIDP_ERROR_CODES

#define HIDP_ERROR_CODES (   SEV,
  CODE 
)    ((NTSTATUS) (((SEV) << 28) | (FACILITY_HID_ERROR_CODE << 16) | (CODE)))

Definition at line 245 of file hidpi.h.

◆ HidP_GetButtonCaps

#define HidP_GetButtonCaps (   _Type_,
  _Caps_,
  _Len_,
  _Data_ 
)    HidP_GetSpecificButtonCaps(_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)

Definition at line 279 of file hidpi.h.

◆ HidP_GetButtonListLength

#define HidP_GetButtonListLength (   RTy,
  UPa,
  Ppd 
)    HidP_GetUsageListLength(Rty, UPa, Ppd)

Definition at line 297 of file hidpi.h.

◆ HidP_GetButtons

#define HidP_GetButtons (   Rty,
  UPa,
  LCo,
  ULi,
  ULe,
  Ppd,
  Rep,
  RLe 
)    HidP_GetUsages(Rty, UPa, LCo, ULi, ULe, Ppd, Rep, RLe)

Definition at line 294 of file hidpi.h.

◆ HidP_GetButtonsEx

#define HidP_GetButtonsEx (   RT,
  LC,
  BL,
  UL,
  PD,
  R,
  RL 
)    HidP_GetUsagesEx(RT, LC, BL, UL, PD, R, RL)

Definition at line 312 of file hidpi.h.

◆ HidP_GetValueCaps

#define HidP_GetValueCaps (   _Type_,
  _Caps_,
  _Len_,
  _Data_ 
)    HidP_GetSpecificValueCaps (_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)

Definition at line 470 of file hidpi.h.

◆ HidP_IsSameUsageAndPage

#define HidP_IsSameUsageAndPage (   u1,
  u2 
)    ((* (PULONG) &u1) == (* (PULONG) &u2))

Definition at line 495 of file hidpi.h.

◆ HIDP_LINK_COLLECTION_ROOT

#define HIDP_LINK_COLLECTION_ROOT   ((USHORT) -1)

Definition at line 184 of file hidpi.h.

◆ HIDP_LINK_COLLECTION_UNSPECIFIED

#define HIDP_LINK_COLLECTION_UNSPECIFIED   ((USHORT) 0)

Definition at line 185 of file hidpi.h.

◆ HidP_SetButtons

#define HidP_SetButtons (   RT,
  UP,
  LC,
  UL1,
  UL2,
  PD,
  R,
  RL 
)    HidP_SetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)

Definition at line 530 of file hidpi.h.

◆ HIDP_STATUS_BAD_LOG_PHY_VALUES

#define HIDP_STATUS_BAD_LOG_PHY_VALUES   (HIDP_ERROR_CODES(0xC, 6))

Definition at line 255 of file hidpi.h.

◆ HIDP_STATUS_BUFFER_TOO_SMALL

#define HIDP_STATUS_BUFFER_TOO_SMALL   (HIDP_ERROR_CODES(0xC, 7))

Definition at line 256 of file hidpi.h.

◆ HIDP_STATUS_BUTTON_NOT_PRESSED

#define HIDP_STATUS_BUTTON_NOT_PRESSED   (HIDP_ERROR_CODES(0xC, 0xF))

Definition at line 264 of file hidpi.h.

◆ HIDP_STATUS_DATA_INDEX_NOT_FOUND

#define HIDP_STATUS_DATA_INDEX_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 0xD))

Definition at line 262 of file hidpi.h.

◆ HIDP_STATUS_DATA_INDEX_OUT_OF_RANGE

#define HIDP_STATUS_DATA_INDEX_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 0xE))

Definition at line 263 of file hidpi.h.

◆ HIDP_STATUS_I8042_TRANS_UNKNOWN

#define HIDP_STATUS_I8042_TRANS_UNKNOWN   (HIDP_ERROR_CODES(0xC, 9))

Definition at line 258 of file hidpi.h.

◆ HIDP_STATUS_I8242_TRANS_UNKNOWN

#define HIDP_STATUS_I8242_TRANS_UNKNOWN   HIDP_STATUS_I8042_TRANS_UNKNOWN

Definition at line 267 of file hidpi.h.

◆ HIDP_STATUS_INCOMPATIBLE_REPORT_ID

#define HIDP_STATUS_INCOMPATIBLE_REPORT_ID   (HIDP_ERROR_CODES(0xC, 0xA))

Definition at line 259 of file hidpi.h.

◆ HIDP_STATUS_INTERNAL_ERROR

#define HIDP_STATUS_INTERNAL_ERROR   (HIDP_ERROR_CODES(0xC, 8))

Definition at line 257 of file hidpi.h.

◆ HIDP_STATUS_INVALID_PREPARSED_DATA

#define HIDP_STATUS_INVALID_PREPARSED_DATA   (HIDP_ERROR_CODES(0xC, 1))

Definition at line 250 of file hidpi.h.

◆ HIDP_STATUS_INVALID_REPORT_LENGTH

#define HIDP_STATUS_INVALID_REPORT_LENGTH   (HIDP_ERROR_CODES(0xC, 3))

Definition at line 252 of file hidpi.h.

◆ HIDP_STATUS_INVALID_REPORT_TYPE

#define HIDP_STATUS_INVALID_REPORT_TYPE   (HIDP_ERROR_CODES(0xC, 2))

Definition at line 251 of file hidpi.h.

◆ HIDP_STATUS_IS_VALUE_ARRAY

#define HIDP_STATUS_IS_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xC))

Definition at line 261 of file hidpi.h.

◆ HIDP_STATUS_NOT_IMPLEMENTED

#define HIDP_STATUS_NOT_IMPLEMENTED   (HIDP_ERROR_CODES(0xC, 0x20))

Definition at line 266 of file hidpi.h.

◆ HIDP_STATUS_NOT_VALUE_ARRAY

#define HIDP_STATUS_NOT_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xB))

Definition at line 260 of file hidpi.h.

◆ HIDP_STATUS_NULL

#define HIDP_STATUS_NULL   (HIDP_ERROR_CODES(0x8, 1))

Definition at line 249 of file hidpi.h.

◆ HIDP_STATUS_REPORT_DOES_NOT_EXIST

#define HIDP_STATUS_REPORT_DOES_NOT_EXIST   (HIDP_ERROR_CODES(0xC, 0x10))

Definition at line 265 of file hidpi.h.

◆ HIDP_STATUS_SUCCESS

#define HIDP_STATUS_SUCCESS   (HIDP_ERROR_CODES(0x0, 0))

Definition at line 248 of file hidpi.h.

◆ HIDP_STATUS_USAGE_NOT_FOUND

#define HIDP_STATUS_USAGE_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 4))

Definition at line 253 of file hidpi.h.

◆ HIDP_STATUS_VALUE_OUT_OF_RANGE

#define HIDP_STATUS_VALUE_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 5))

Definition at line 254 of file hidpi.h.

◆ HidP_UnsetButtons

#define HidP_UnsetButtons (   RT,
  UP,
  LC,
  UL1,
  UL2,
  PD,
  R,
  RL 
)    HidP_UnsetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)

Definition at line 618 of file hidpi.h.

Typedef Documentation

◆ HIDD_ATTRIBUTES

◆ HIDD_CONFIGURATION

◆ HIDP_BUTTON_CAPS

◆ HIDP_CAPS

◆ HIDP_DATA

◆ HIDP_EXTENDED_ATTRIBUTES

◆ HIDP_KEYBOARD_DIRECTION

◆ HIDP_KEYBOARD_MODIFIER_STATE

◆ HIDP_LINK_COLLECTION_NODE

◆ HIDP_REPORT_TYPE

◆ HIDP_UNKNOWN_TOKEN

◆ HIDP_VALUE_CAPS

◆ PHIDD_ATTRIBUTES

◆ PHIDD_CONFIGURATION

◆ PHIDP_BUTTON_CAPS

◆ PHIDP_CAPS

◆ PHIDP_DATA

◆ PHIDP_EXTENDED_ATTRIBUTES

◆ PHIDP_INSERT_SCANCODES

typedef BOOLEAN(NTAPI * PHIDP_INSERT_SCANCODES) (_In_opt_ PVOID Context, _In_reads_bytes_(Length) PCHAR NewScanCodes, _In_ ULONG Length)

Definition at line 73 of file hidpi.h.

◆ PHIDP_KEYBOARD_MODIFIER_STATE

◆ PHIDP_LINK_COLLECTION_NODE

◆ PHIDP_PREPARSED_DATA

typedef struct _HIDP_PREPARSED_DATA* PHIDP_PREPARSED_DATA

Definition at line 39 of file hidpi.h.

◆ PHIDP_REPORT_DESCRIPTOR

Definition at line 38 of file hidpi.h.

◆ PHIDP_UNKNOWN_TOKEN

◆ PHIDP_VALUE_CAPS

◆ PUSAGE_AND_PAGE

◆ USAGE_AND_PAGE

Enumeration Type Documentation

◆ _HIDP_KEYBOARD_DIRECTION

Enumerator
HidP_Keyboard_Break 
HidP_Keyboard_Make 

Definition at line 47 of file hidpi.h.

47  {
enum _HIDP_KEYBOARD_DIRECTION HIDP_KEYBOARD_DIRECTION

◆ _HIDP_REPORT_TYPE

Enumerator
HidP_Input 
HidP_Output 
HidP_Feature 

Definition at line 237 of file hidpi.h.

237  {
238  HidP_Input,
239  HidP_Output,
enum _HIDP_REPORT_TYPE HIDP_REPORT_TYPE

Function Documentation

◆ _In_reads_()

◆ _In_reads_bytes_()

◆ _IRQL_requires_max_() [1/2]

_Must_inspect_result_ _IRQL_requires_max_ ( PASSIVE_LEVEL  )

Definition at line 64 of file Messaging.c.

75 {
76  PFLT_SERVER_PORT_OBJECT PortObject;
78 
79  /* The caller must allow at least one connection */
80  if (MaxConnections == 0)
81  {
83  }
84 
85  /* The request must be for a kernel handle */
86  if (!(ObjectAttributes->Attributes & OBJ_KERNEL_HANDLE))
87  {
89  }
90 
91  /*
92  * Get rundown protection on the target to stop the owner
93  * from unloading whilst this port object is open. It gets
94  * removed in the FltpServerPortClose callback
95  */
97  if (!NT_SUCCESS(Status))
98  {
99  return Status;
100  }
101 
102  /* Create the server port object for this filter */
106  KernelMode,
107  NULL,
108  sizeof(FLT_SERVER_PORT_OBJECT),
109  0,
110  0,
111  (PVOID *)&PortObject);
112  if (NT_SUCCESS(Status))
113  {
114  /* Zero out the struct */
115  RtlZeroMemory(PortObject, sizeof(FLT_SERVER_PORT_OBJECT));
116 
117  /* Increment the ref count on the target filter */
119 
120  /* Setup the filter port object */
121  PortObject->Filter = Filter;
122  PortObject->ConnectNotify = ConnectNotifyCallback;
124  PortObject->MessageNotify = MessageNotifyCallback;
125  PortObject->Cookie = ServerPortCookie;
126  PortObject->MaxConnections = MaxConnections;
127 
128  /* Insert the object */
129  Status = ObInsertObject(PortObject,
130  NULL,
132  0,
133  NULL,
135  if (NT_SUCCESS(Status))
136  {
137  /* Lock the connection list */
139 
140  /* Add the new port object to the connection list and increment the count */
143 
144  /* Unlock the connection list*/
146  }
147  }
148 
149  if (!NT_SUCCESS(Status))
150  {
151  /* Allow the filter to be cleaned up */
153  }
154 
155  return Status;
156 }
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
Definition: conport.c:35
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
_Must_inspect_result_ _Outptr_ PFLT_PORT * ServerPort
Definition: fltkernel.h:1873
PFLT_CONNECT_NOTIFY ConnectNotify
Definition: fltmgrint.h:191
VOID FLTAPI FltObjectDereference(_Inout_ PVOID Object)
Definition: Object.c:53
LONG NTSTATUS
Definition: precomp.h:26
#define InsertTailList(ListHead, Entry)
#define OBJ_KERNEL_HANDLE
Definition: winternl.h:231
VOID FASTCALL ExReleaseFastMutex(IN PFAST_MUTEX FastMutex)
Definition: fmutex.c:31
ULONG FltpObjectPointerReference(_In_ PFLT_OBJECT Object)
Definition: Object.c:322
LIST_ENTRY mList
Definition: fltmgrint.h:56
_Must_inspect_result_ _In_opt_ PFLT_FILTER Filter
Definition: fltkernel.h:1802
#define FILE_READ_DATA
Definition: nt_native.h:628
NTSTATUS NTAPI ObCreateObject(IN KPROCESSOR_MODE ProbeMode OPTIONAL, IN POBJECT_TYPE Type, IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL, IN KPROCESSOR_MODE AccessMode, IN OUT PVOID ParseContext OPTIONAL, IN ULONG ObjectSize, IN ULONG PagedPoolCharge OPTIONAL, IN ULONG NonPagedPoolCharge OPTIONAL, OUT PVOID *Object)
Definition: oblife.c:952
Status
Definition: gdiplustypes.h:24
POBJECT_TYPE ServerPortObjectType
Definition: Messaging.c:24
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY _In_ PFLT_DISCONNECT_NOTIFY DisconnectNotifyCallback
Definition: fltkernel.h:1873
PVOID *typedef PHANDLE
Definition: ntsecpkg.h:454
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY ConnectNotifyCallback
Definition: fltkernel.h:1873
NTSTATUS NTAPI ObInsertObject(IN PVOID Object, IN PACCESS_STATE AccessState OPTIONAL, IN ACCESS_MASK DesiredAccess, IN ULONG ObjectPointerBias, OUT PVOID *NewObject OPTIONAL, OUT PHANDLE Handle)
Definition: obhandle.c:2932
#define STANDARD_RIGHTS_ALL
Definition: nt_native.h:69
VOID FASTCALL ExAcquireFastMutex(IN PFAST_MUTEX FastMutex)
Definition: fmutex.c:23
NTSTATUS FLTAPI FltObjectReference(_Inout_ PVOID Object)
Definition: Object.c:41
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID ServerPortCookie
Definition: fltkernel.h:1873
#define NULL
Definition: types.h:112
FAST_MUTEX mLock
Definition: fltmgrint.h:55
PFLT_MESSAGE_NOTIFY MessageNotify
Definition: fltmgrint.h:193
#define RtlZeroMemory(Destination, Length)
Definition: typedefs.h:262
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY _In_ PFLT_DISCONNECT_NOTIFY _In_opt_ PFLT_MESSAGE_NOTIFY _In_ LONG MaxConnections
Definition: fltkernel.h:1873
PFLT_DISCONNECT_NOTIFY DisconnectNotify
Definition: fltmgrint.h:192
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY _In_ PFLT_DISCONNECT_NOTIFY _In_opt_ PFLT_MESSAGE_NOTIFY MessageNotifyCallback
Definition: fltkernel.h:1873
FLT_MUTEX_LIST_HEAD ConnectionList
Definition: fltmgrint.h:121

◆ _IRQL_requires_max_() [2/2]

_Must_inspect_result_ _IRQL_requires_max_ ( DISPATCH_LEVEL  )

Definition at line 3557 of file common.c.

3587 {
3588  NTSTATUS status;
3589  BOOLEAN requestSent = FALSE;
3590 
3591  BOOLEAN shouldRetry = TRUE;
3592  PCDB cdb = (PCDB)DeviceExtension->PowerContext.Srb.Cdb;
3593  ULONG timeoutValue = DeviceExtension->TimeOutValue;
3594  ULONG retryCount = 1;
3595 
3596  // reset some fields.
3597  DeviceExtension->PowerContext.RetryIntervalIn100ns = 0;
3598  status = PowerContextReuseRequest(DeviceExtension);
3599  RequestClearSendTime(DeviceExtension->PowerContext.PowerRequest);
3600 
3601  if (!NT_SUCCESS(status))
3602  {
3603  return status;
3604  }
3605 
3606  // set proper timeout value and max retry count.
3607  switch(DeviceExtension->PowerContext.PowerChangeState.PowerDown)
3608  {
3612  break;
3613 
3614  case PowerDownDeviceLocked:
3615  // Case of issuing SYNC CACHE command. Do not use power irp timeout remaining time in this case
3616  // as we want to give best try on SYNC CACHE command.
3617  retryCount = MAXIMUM_RETRIES;
3618  timeoutValue = DeviceExtension->TimeOutValue;
3619  break;
3620 
3622  {
3623  // Case of issuing STOP UNIT command
3624  // As "Imme" bit is set to '1', this command should be completed in short time.
3625  // This command is at low importance, failure of this command has very small impact.
3626  ULONG secondsRemaining = 0;
3627 
3628 #if (WINVER >= 0x0601)
3629  // this API is introduced in Windows7
3630  PoQueryWatchdogTime(DeviceExtension->LowerPdo, &secondsRemaining);
3631 #endif
3632 
3633  if (secondsRemaining == 0)
3634  {
3635  // not able to retrieve remaining time from PoQueryWatchdogTime API, use default values.
3636  retryCount = MAXIMUM_RETRIES;
3637  timeoutValue = SCSI_CDROM_TIMEOUT;
3638  }
3639  else
3640  {
3641  // plan to leave about 30 seconds to lower level drivers if possible.
3642  if (secondsRemaining >= 32)
3643  {
3644  retryCount = (secondsRemaining - 30)/SCSI_CDROM_TIMEOUT + 1;
3645  timeoutValue = SCSI_CDROM_TIMEOUT;
3646 
3647  if (retryCount > MAXIMUM_RETRIES)
3648  {
3649  retryCount = MAXIMUM_RETRIES;
3650  }
3651 
3652  if (retryCount == 1)
3653  {
3654  timeoutValue = secondsRemaining - 30;
3655  }
3656  }
3657  else
3658  {
3659  // issue the command with minimal timeout value and do not retry on it.
3660  retryCount = 1;
3661  timeoutValue = 2;
3662  }
3663  }
3664  }
3665  break;
3666  default:
3667  NT_ASSERT( FALSE );
3669  return status;
3670  }
3671 
3672  DeviceExtension->PowerContext.RetryCount = retryCount;
3673 
3674  // issue command.
3675  while (shouldRetry)
3676  {
3677 
3678  // set SRB fields.
3679  DeviceExtension->PowerContext.Srb.SrbFlags = SRB_FLAGS_NO_DATA_TRANSFER |
3684 
3685  DeviceExtension->PowerContext.Srb.Function = SRB_FUNCTION_EXECUTE_SCSI;
3686  DeviceExtension->PowerContext.Srb.TimeOutValue = timeoutValue;
3687 
3688  if (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceInitial)
3689  {
3690  DeviceExtension->PowerContext.Srb.Function = SRB_FUNCTION_LOCK_QUEUE;
3691  }
3692  else if (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceLocked)
3693  {
3694  DeviceExtension->PowerContext.Srb.Function = SRB_FUNCTION_QUIESCE_DEVICE;
3695  }
3696  else if (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceQuiesced)
3697  {
3698  // Case of issuing SYNC CACHE command.
3699  DeviceExtension->PowerContext.Srb.CdbLength = 10;
3700  cdb->SYNCHRONIZE_CACHE10.OperationCode = SCSIOP_SYNCHRONIZE_CACHE;
3701  }
3702  else if (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceFlushed)
3703  {
3704  // Case of issuing STOP UNIT command.
3705  DeviceExtension->PowerContext.Srb.CdbLength = 6;
3706  cdb->START_STOP.OperationCode = SCSIOP_START_STOP_UNIT;
3707  cdb->START_STOP.Start = 0;
3708  cdb->START_STOP.Immediate = 1;
3709  }
3710  else if (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceStopped)
3711  {
3712  DeviceExtension->PowerContext.Srb.Function = SRB_FUNCTION_UNLOCK_QUEUE;
3713  }
3714 
3715  // Set up completion routine and context if requested
3716  if (CompletionRoutine)
3717  {
3718  WdfRequestSetCompletionRoutine(DeviceExtension->PowerContext.PowerRequest,
3720  Context);
3721  }
3722 
3723  status = RequestSend(DeviceExtension,
3724  DeviceExtension->PowerContext.PowerRequest,
3725  DeviceExtension->IoTarget,
3727  &requestSent);
3728 
3729  if (requestSent)
3730  {
3731  if ((CompletionRoutine == NULL) &&
3732  (SRB_STATUS(DeviceExtension->PowerContext.Srb.SrbStatus) != SRB_STATUS_SUCCESS))
3733  {
3734  TracePrint((TRACE_LEVEL_ERROR,
3735  TRACE_FLAG_POWER,
3736  "%p\tError occured when issuing %s command to device. Srb %p, Status %x\n",
3737  DeviceExtension->PowerContext.PowerRequest,
3738  (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceQuiesced) ? "SYNC CACHE" : "STOP UNIT",
3739  &DeviceExtension->PowerContext.Srb,
3740  DeviceExtension->PowerContext.Srb.SrbStatus));
3741 
3742  NT_ASSERT(!(TEST_FLAG(DeviceExtension->PowerContext.Srb.SrbStatus, SRB_STATUS_QUEUE_FROZEN)));
3743 
3744  shouldRetry = RequestSenseInfoInterpret(DeviceExtension,
3745  DeviceExtension->PowerContext.PowerRequest,
3746  &(DeviceExtension->PowerContext.Srb),
3747  retryCount - DeviceExtension->PowerContext.RetryCount,
3748  &status,
3749  &(DeviceExtension->PowerContext.RetryIntervalIn100ns));
3750 
3751  if (shouldRetry && (DeviceExtension->PowerContext.RetryCount-- == 0))
3752  {
3753  shouldRetry = FALSE;
3754  }
3755  }
3756  else
3757  {
3758  // succeeded, do not need to retry.
3759  shouldRetry = FALSE;
3760  }
3761 
3762  }
3763  else
3764  {
3765  // request failed to be sent
3766  shouldRetry = FALSE;
3767  }
3768 
3769  if (shouldRetry)
3770  {
3771  LARGE_INTEGER t;
3772  t.QuadPart = -DeviceExtension->PowerContext.RetryIntervalIn100ns;
3774 
3775  status = PowerContextReuseRequest(DeviceExtension);
3776  if (!NT_SUCCESS(status))
3777  {
3778  shouldRetry = FALSE;
3779  }
3780  }
3781  }
3782 
3783  if (DeviceExtension->PowerContext.PowerChangeState.PowerDown == PowerDownDeviceQuiesced)
3784  {
3785  // record SYNC CACHE command completion time stamp.
3786  KeQueryTickCount(&DeviceExtension->PowerContext.Step1CompleteTime);
3787  }
3788 
3789  return status;
3790 }
#define SRB_FUNCTION_UNLOCK_QUEUE
Definition: srb.h:325
#define SCSIOP_SYNCHRONIZE_CACHE
Definition: cdrw_hw.h:918
#define SRB_FUNCTION_QUIESCE_DEVICE
Definition: srb.h:90
#define SRB_FLAGS_NO_QUEUE_FREEZE
Definition: srb.h:396
#define TRUE
Definition: types.h:120
Definition: cdrw_hw.h:28
LONG NTSTATUS
Definition: precomp.h:26
struct _CDB::_SYNCHRONIZE_CACHE10 SYNCHRONIZE_CACHE10
GLdouble GLdouble t
Definition: gl.h:2047
#define SRB_STATUS(Status)
Definition: srb.h:381
VOID RequestClearSendTime(_In_ WDFREQUEST Request)
Definition: common.c:111
#define MAXIMUM_RETRIES
Definition: cdrom.h:124
return STATUS_NOT_IMPLEMENTED
#define SCSI_CDROM_TIMEOUT
Definition: cdrom.c:170
#define FALSE
Definition: types.h:117
NTSTATUS NTAPI KeDelayExecutionThread(IN KPROCESSOR_MODE WaitMode, IN BOOLEAN Alertable, IN PLARGE_INTEGER Interval OPTIONAL)
Definition: wait.c:283
#define SRB_FLAGS_BYPASS_LOCKED_QUEUE
Definition: srb.h:402
unsigned char BOOLEAN
union _CDB * PCDB
struct _CDB::_START_STOP START_STOP
VOID NTAPI KeQueryTickCount(IN PLARGE_INTEGER TickCount)
Definition: clock.c:165
#define TEST_FLAG(Flags, Bit)
Definition: cdrom.h:1495
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
#define SRB_FLAGS_DISABLE_SYNCH_TRANSFER
Definition: srb.h:389
#define SRB_FLAGS_NO_DATA_TRANSFER
Definition: srb.h:394
BOOLEAN RequestSenseInfoInterpret(_In_ PCDROM_DEVICE_EXTENSION DeviceExtension, _In_ WDFREQUEST Request, _In_ PSCSI_REQUEST_BLOCK Srb, _In_ ULONG RetriedCount, _Out_ NTSTATUS *Status, _Out_opt_ _Deref_out_range_(0, MAXIMUM_RETRY_FOR_SINGLE_IO_IN_100NS_UNITS) LONGLONG *RetryIntervalIn100ns)
Definition: sense.c:2467
#define SRB_STATUS_QUEUE_FROZEN
Definition: srb.h:378
NTSTATUS RequestSend(_In_ PCDROM_DEVICE_EXTENSION DeviceExtension, _In_ WDFREQUEST Request, _In_ WDFIOTARGET IoTarget, _In_ ULONG Flags, _Out_opt_ PBOOLEAN RequestSent)
Definition: common.c:3793
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
_In_ WDFREQUEST _In_opt_ PFN_WDF_REQUEST_COMPLETION_ROUTINE CompletionRoutine
Definition: wdfrequest.h:893
#define NULL
Definition: types.h:112
#define SRB_FUNCTION_EXECUTE_SCSI
Definition: srb.h:307
unsigned int ULONG
Definition: retypes.h:1
#define SRB_STATUS_SUCCESS
Definition: srb.h:333
#define SRB_FLAGS_D3_PROCESSING
Definition: srb.h:156
static SERVICE_STATUS status
Definition: service.c:31
#define SCSIOP_START_STOP_UNIT
Definition: cdrw_hw.h:897
#define SRB_FUNCTION_LOCK_QUEUE
Definition: srb.h:324
#define NT_ASSERT
Definition: rtlfuncs.h:3312
Definition: ps.c:97

◆ _Out_writes_()

◆ _Out_writes_bytes_()

◆ HidP_GetScaledUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetScaledUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_Out_ PLONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_GetUsages()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsages ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_Out_writes_to_ *, *UsageLength USAGE UsageList,
_Inout_ ULONG UsageLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Out_writes_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_GetUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_Out_ PULONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_GetUsageValueArray()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValueArray ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_Inout_updates_bytes_(UsageValueByteLength) PCHAR  UsageValue,
_In_ USHORT  UsageValueByteLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetData()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetData ( _In_ HIDP_REPORT_TYPE  ReportType,
_Inout_updates_to_ *, *DataLength PHIDP_DATA  DataList,
_Inout_ PULONG  DataLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetScaledUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetScaledUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_In_ LONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Inout_updates_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetUsages()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsages ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_Inout_updates_to_ *, *UsageLength PUSAGE  UsageList,
_Inout_ PULONG  UsageLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_In_ ULONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Inout_updates_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetUsageValueArray()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValueArray ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_In_reads_bytes_(UsageValueByteLength) PCHAR  UsageValue,
_In_ USHORT  UsageValueByteLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Inout_updates_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_TranslateUsageAndPagesToI8042ScanCodes()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsageAndPagesToI8042ScanCodes ( _In_reads_(UsageListLength) PUSAGE_AND_PAGE  ChangedUsageList,
_In_ ULONG  UsageListLength,
_In_ HIDP_KEYBOARD_DIRECTION  KeyAction,
_Inout_ PHIDP_KEYBOARD_MODIFIER_STATE  ModifierState,
_In_ PHIDP_INSERT_SCANCODES  InsertCodesProcedure,
_In_opt_ PVOID  InsertCodesContext 
)

Referenced by KbdHid_ReadCompletion().

◆ HidP_TranslateUsagesToI8042ScanCodes()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsagesToI8042ScanCodes ( _In_reads_(UsageListLength) PUSAGE  ChangedUsageList,
_In_ ULONG  UsageListLength,
_In_ HIDP_KEYBOARD_DIRECTION  KeyAction,
_Inout_ PHIDP_KEYBOARD_MODIFIER_STATE  ModifierState,
_In_ PHIDP_INSERT_SCANCODES  InsertCodesProcedure,
_In_opt_ PVOID  InsertCodesContext 
)

◆ HidP_UnsetUsages()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_UnsetUsages ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_opt_ USHORT  LinkCollection,
_Inout_updates_to_ *, *UsageLength PUSAGE  UsageList,
_Inout_ PULONG  UsageLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

Variable Documentation

◆ Attributes

◆ ButtonCaps

◆ ButtonCapsLength

◆ ButtonList

◆ Capabilities

Definition at line 324 of file hidpi.h.

◆ DataIndex

Definition at line 346 of file hidpi.h.

Referenced by WriteMidiUartMulti().

◆ DataLength

Definition at line 333 of file hidpi.h.

◆ DataList

◆ LengthAttributes

◆ LinkCollection

◆ LinkCollectionNodesLength

_Must_inspect_result_ _Inout_ PULONG LinkCollectionNodesLength

Definition at line 358 of file hidpi.h.

◆ PreparsedData

◆ ReportID

◆ ReportLength

◆ Usage

◆ UsageLength

◆ UsageListLength

◆ UsagePage

◆ ValueCaps

◆ ValueCapsLength