SDL 3.0
SDL_hidapi.h
Go to the documentation of this file.
1/*
2 Simple DirectMedia Layer
3 Copyright (C) 1997-2024 Sam Lantinga <slouken@libsdl.org>
4
5 This software is provided 'as-is', without any express or implied
6 warranty. In no event will the authors be held liable for any damages
7 arising from the use of this software.
8
9 Permission is granted to anyone to use this software for any purpose,
10 including commercial applications, and to alter it and redistribute it
11 freely, subject to the following restrictions:
12
13 1. The origin of this software must not be misrepresented; you must not
14 claim that you wrote the original software. If you use this software
15 in a product, an acknowledgment in the product documentation would be
16 appreciated but is not required.
17 2. Altered source versions must be plainly marked as such, and must not be
18 misrepresented as being the original software.
19 3. This notice may not be removed or altered from any source distribution.
20*/
21
22/**
23 * \file SDL_hidapi.h
24 *
25 * Header file for SDL HIDAPI functions.
26 *
27 * This is an adaptation of the original HIDAPI interface by Alan Ott,
28 * and includes source code licensed under the following BSD license:
29 *
30 Copyright (c) 2010, Alan Ott, Signal 11 Software
31 All rights reserved.
32
33 Redistribution and use in source and binary forms, with or without
34 modification, are permitted provided that the following conditions are met:
35
36 * Redistributions of source code must retain the above copyright notice,
37 this list of conditions and the following disclaimer.
38 * Redistributions in binary form must reproduce the above copyright
39 notice, this list of conditions and the following disclaimer in the
40 documentation and/or other materials provided with the distribution.
41 * Neither the name of Signal 11 Software nor the names of its
42 contributors may be used to endorse or promote products derived from
43 this software without specific prior written permission.
44
45 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
46 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
47 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
48 ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
49 LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
50 CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
51 SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
52 INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
53 CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
54 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
55 POSSIBILITY OF SUCH DAMAGE.
56 *
57 * If you would like a version of SDL without this code, you can build SDL
58 * with SDL_HIDAPI_DISABLED defined to 1. You might want to do this for example
59 * on iOS or tvOS to avoid a dependency on the CoreBluetooth framework.
60 */
61
62#ifndef SDL_hidapi_h_
63#define SDL_hidapi_h_
64
65#include <SDL3/SDL_stdinc.h>
66#include <SDL3/SDL_error.h>
67
68#include <SDL3/SDL_begin_code.h>
69/* Set up for C function definitions, even when using C++ */
70#ifdef __cplusplus
71extern "C" {
72#endif
73
74/**
75 * A handle representing an open HID device
76 *
77 * \since This struct is available since SDL 3.0.0.
78 */
79struct SDL_hid_device;
80typedef struct SDL_hid_device SDL_hid_device; /**< opaque hidapi structure */
81
82/**
83 * HID underlying bus types.
84 *
85 * \since This enum is available since SDL 3.0.0.
86 */
87typedef enum SDL_hid_bus_type {
88 /** Unknown bus type */
90
91 /** USB bus
92 Specifications:
93 https://usb.org/hid */
95
96 /** Bluetooth or Bluetooth LE bus
97 Specifications:
98 https://www.bluetooth.com/specifications/specs/human-interface-device-profile-1-1-1/
99 https://www.bluetooth.com/specifications/specs/hid-service-1-0/
100 https://www.bluetooth.com/specifications/specs/hid-over-gatt-profile-1-0/ */
102
103 /** I2C bus
104 Specifications:
105 https://docs.microsoft.com/previous-versions/windows/hardware/design/dn642101(v=vs.85) */
107
108 /** SPI bus
109 Specifications:
110 https://www.microsoft.com/download/details.aspx?id=103325 */
112
114
115/** hidapi info structure */
116
117/**
118 * Information about a connected HID device
119 *
120 * \since This struct is available since SDL 3.0.0.
121 */
123{
124 /** Platform-specific device path */
125 char *path;
126 /** Device Vendor ID */
127 unsigned short vendor_id;
128 /** Device Product ID */
129 unsigned short product_id;
130 /** Serial Number */
132 /** Device Release Number in binary-coded decimal,
133 also known as Device Version Number */
134 unsigned short release_number;
135 /** Manufacturer String */
137 /** Product string */
139 /** Usage Page for this Device/Interface
140 (Windows/Mac/hidraw only) */
141 unsigned short usage_page;
142 /** Usage for this Device/Interface
143 (Windows/Mac/hidraw only) */
144 unsigned short usage;
145 /** The USB interface which this logical device
146 represents.
147
148 Valid only if the device is a USB HID device.
149 Set to -1 in all other cases.
150 */
152
153 /** Additional information about the USB interface.
154 Valid on libusb and Android implementations. */
158
159 /** Underlying bus type */
161
162 /** Pointer to the next device */
164
166
167
168/**
169 * Initialize the HIDAPI library.
170 *
171 * This function initializes the HIDAPI library. Calling it is not strictly
172 * necessary, as it will be called automatically by SDL_hid_enumerate() and
173 * any of the SDL_hid_open_*() functions if it is needed. This function should
174 * be called at the beginning of execution however, if there is a chance of
175 * HIDAPI handles being opened by different threads simultaneously.
176 *
177 * Each call to this function should have a matching call to SDL_hid_exit()
178 *
179 * \returns 0 on success or a negative error code on failure; call
180 * SDL_GetError() for more information.
181 *
182 * \since This function is available since SDL 3.0.0.
183 *
184 * \sa SDL_hid_exit
185 */
186extern DECLSPEC int SDLCALL SDL_hid_init(void);
187
188/**
189 * Finalize the HIDAPI library.
190 *
191 * This function frees all of the static data associated with HIDAPI. It
192 * should be called at the end of execution to avoid memory leaks.
193 *
194 * \returns 0 on success or a negative error code on failure; call
195 * SDL_GetError() for more information.
196 *
197 * \since This function is available since SDL 3.0.0.
198 *
199 * \sa SDL_hid_init
200 */
201extern DECLSPEC int SDLCALL SDL_hid_exit(void);
202
203/**
204 * Check to see if devices may have been added or removed.
205 *
206 * Enumerating the HID devices is an expensive operation, so you can call this
207 * to see if there have been any system device changes since the last call to
208 * this function. A change in the counter returned doesn't necessarily mean
209 * that anything has changed, but you can call SDL_hid_enumerate() to get an
210 * updated device list.
211 *
212 * Calling this function for the first time may cause a thread or other system
213 * resource to be allocated to track device change notifications.
214 *
215 * \returns a change counter that is incremented with each potential device
216 * change, or 0 if device change detection isn't available.
217 *
218 * \since This function is available since SDL 3.0.0.
219 *
220 * \sa SDL_hid_enumerate
221 */
222extern DECLSPEC Uint32 SDLCALL SDL_hid_device_change_count(void);
223
224/**
225 * Enumerate the HID Devices.
226 *
227 * This function returns a linked list of all the HID devices attached to the
228 * system which match vendor_id and product_id. If `vendor_id` is set to 0
229 * then any vendor matches. If `product_id` is set to 0 then any product
230 * matches. If `vendor_id` and `product_id` are both set to 0, then all HID
231 * devices will be returned.
232 *
233 * By default SDL will only enumerate controllers, to reduce risk of hanging
234 * or crashing on bad drivers, but SDL_HINT_HIDAPI_ENUMERATE_ONLY_CONTROLLERS
235 * can be set to "0" to enumerate all HID devices.
236 *
237 * \param vendor_id The Vendor ID (VID) of the types of device to open, or 0
238 * to match any vendor.
239 * \param product_id The Product ID (PID) of the types of device to open, or 0
240 * to match any product.
241 * \returns a pointer to a linked list of type SDL_hid_device_info, containing
242 * information about the HID devices attached to the system, or NULL
243 * in the case of failure. Free this linked list by calling
244 * SDL_hid_free_enumeration().
245 *
246 * \since This function is available since SDL 3.0.0.
247 *
248 * \sa SDL_hid_device_change_count
249 */
250extern DECLSPEC SDL_hid_device_info * SDLCALL SDL_hid_enumerate(unsigned short vendor_id, unsigned short product_id);
251
252/**
253 * Free an enumeration linked list.
254 *
255 * This function frees a linked list created by SDL_hid_enumerate().
256 *
257 * \param devs Pointer to a list of struct_device returned from
258 * SDL_hid_enumerate().
259 *
260 * \since This function is available since SDL 3.0.0.
261 */
262extern DECLSPEC void SDLCALL SDL_hid_free_enumeration(SDL_hid_device_info *devs);
263
264/**
265 * Open a HID device using a Vendor ID (VID), Product ID (PID) and optionally
266 * a serial number.
267 *
268 * If `serial_number` is NULL, the first device with the specified VID and PID
269 * is opened.
270 *
271 * \param vendor_id The Vendor ID (VID) of the device to open.
272 * \param product_id The Product ID (PID) of the device to open.
273 * \param serial_number The Serial Number of the device to open (Optionally
274 * NULL).
275 * \returns a pointer to a SDL_hid_device object on success or NULL on
276 * failure.
277 *
278 * \since This function is available since SDL 3.0.0.
279 */
280extern DECLSPEC SDL_hid_device * SDLCALL SDL_hid_open(unsigned short vendor_id, unsigned short product_id, const wchar_t *serial_number);
281
282/**
283 * Open a HID device by its path name.
284 *
285 * The path name be determined by calling SDL_hid_enumerate(), or a
286 * platform-specific path name can be used (eg: /dev/hidraw0 on Linux).
287 *
288 * \param path The path name of the device to open
289 * \returns a pointer to a SDL_hid_device object on success or NULL on
290 * failure.
291 *
292 * \since This function is available since SDL 3.0.0.
293 */
294extern DECLSPEC SDL_hid_device * SDLCALL SDL_hid_open_path(const char *path);
295
296/**
297 * Write an Output report to a HID device.
298 *
299 * The first byte of `data` must contain the Report ID. For devices which only
300 * support a single report, this must be set to 0x0. The remaining bytes
301 * contain the report data. Since the Report ID is mandatory, calls to
302 * SDL_hid_write() will always contain one more byte than the report contains.
303 * For example, if a hid report is 16 bytes long, 17 bytes must be passed to
304 * SDL_hid_write(), the Report ID (or 0x0, for devices with a single report),
305 * followed by the report data (16 bytes). In this example, the length passed
306 * in would be 17.
307 *
308 * SDL_hid_write() will send the data on the first OUT endpoint, if one
309 * exists. If it does not, it will send the data through the Control Endpoint
310 * (Endpoint 0).
311 *
312 * \param dev A device handle returned from SDL_hid_open().
313 * \param data The data to send, including the report number as the first
314 * byte.
315 * \param length The length in bytes of the data to send.
316 * \returns the actual number of bytes written and -1 on error.
317 *
318 * \since This function is available since SDL 3.0.0.
319 */
320extern DECLSPEC int SDLCALL SDL_hid_write(SDL_hid_device *dev, const unsigned char *data, size_t length);
321
322/**
323 * Read an Input report from a HID device with timeout.
324 *
325 * Input reports are returned to the host through the INTERRUPT IN endpoint.
326 * The first byte will contain the Report number if the device uses numbered
327 * reports.
328 *
329 * \param dev A device handle returned from SDL_hid_open().
330 * \param data A buffer to put the read data into.
331 * \param length The number of bytes to read. For devices with multiple
332 * reports, make sure to read an extra byte for the report
333 * number.
334 * \param milliseconds timeout in milliseconds or -1 for blocking wait.
335 * \returns the actual number of bytes read and -1 on error. If no packet was
336 * available to be read within the timeout period, this function
337 * returns 0.
338 *
339 * \since This function is available since SDL 3.0.0.
340 */
341extern DECLSPEC int SDLCALL SDL_hid_read_timeout(SDL_hid_device *dev, unsigned char *data, size_t length, int milliseconds);
342
343/**
344 * Read an Input report from a HID device.
345 *
346 * Input reports are returned to the host through the INTERRUPT IN endpoint.
347 * The first byte will contain the Report number if the device uses numbered
348 * reports.
349 *
350 * \param dev A device handle returned from SDL_hid_open().
351 * \param data A buffer to put the read data into.
352 * \param length The number of bytes to read. For devices with multiple
353 * reports, make sure to read an extra byte for the report
354 * number.
355 * \returns the actual number of bytes read and -1 on error. If no packet was
356 * available to be read and the handle is in non-blocking mode, this
357 * function returns 0.
358 *
359 * \since This function is available since SDL 3.0.0.
360 */
361extern DECLSPEC int SDLCALL SDL_hid_read(SDL_hid_device *dev, unsigned char *data, size_t length);
362
363/**
364 * Set the device handle to be non-blocking.
365 *
366 * In non-blocking mode calls to SDL_hid_read() will return immediately with a
367 * value of 0 if there is no data to be read. In blocking mode, SDL_hid_read()
368 * will wait (block) until there is data to read before returning.
369 *
370 * Nonblocking can be turned on and off at any time.
371 *
372 * \param dev A device handle returned from SDL_hid_open().
373 * \param nonblock enable or not the nonblocking reads - 1 to enable
374 * nonblocking - 0 to disable nonblocking.
375 * \returns 0 on success or a negative error code on failure; call
376 * SDL_GetError() for more information.
377 *
378 * \since This function is available since SDL 3.0.0.
379 */
380extern DECLSPEC int SDLCALL SDL_hid_set_nonblocking(SDL_hid_device *dev, int nonblock);
381
382/**
383 * Send a Feature report to the device.
384 *
385 * Feature reports are sent over the Control endpoint as a Set_Report
386 * transfer. The first byte of `data` must contain the Report ID. For devices
387 * which only support a single report, this must be set to 0x0. The remaining
388 * bytes contain the report data. Since the Report ID is mandatory, calls to
389 * SDL_hid_send_feature_report() will always contain one more byte than the
390 * report contains. For example, if a hid report is 16 bytes long, 17 bytes
391 * must be passed to SDL_hid_send_feature_report(): the Report ID (or 0x0, for
392 * devices which do not use numbered reports), followed by the report data (16
393 * bytes). In this example, the length passed in would be 17.
394 *
395 * \param dev A device handle returned from SDL_hid_open().
396 * \param data The data to send, including the report number as the first
397 * byte.
398 * \param length The length in bytes of the data to send, including the report
399 * number.
400 * \returns the actual number of bytes written and -1 on error.
401 *
402 * \since This function is available since SDL 3.0.0.
403 */
404extern DECLSPEC int SDLCALL SDL_hid_send_feature_report(SDL_hid_device *dev, const unsigned char *data, size_t length);
405
406/**
407 * Get a feature report from a HID device.
408 *
409 * Set the first byte of `data` to the Report ID of the report to be read.
410 * Make sure to allow space for this extra byte in `data`. Upon return, the
411 * first byte will still contain the Report ID, and the report data will start
412 * in data[1].
413 *
414 * \param dev A device handle returned from SDL_hid_open().
415 * \param data A buffer to put the read data into, including the Report ID.
416 * Set the first byte of `data` to the Report ID of the report to
417 * be read, or set it to zero if your device does not use numbered
418 * reports.
419 * \param length The number of bytes to read, including an extra byte for the
420 * report ID. The buffer can be longer than the actual report.
421 * \returns the number of bytes read plus one for the report ID (which is
422 * still in the first byte), or -1 on error.
423 *
424 * \since This function is available since SDL 3.0.0.
425 */
426extern DECLSPEC int SDLCALL SDL_hid_get_feature_report(SDL_hid_device *dev, unsigned char *data, size_t length);
427
428/**
429 * Get an input report from a HID device.
430 *
431 * Set the first byte of `data` to the Report ID of the report to be read.
432 * Make sure to allow space for this extra byte in `data`. Upon return, the
433 * first byte will still contain the Report ID, and the report data will start
434 * in data[1].
435 *
436 * \param dev A device handle returned from SDL_hid_open().
437 * \param data A buffer to put the read data into, including the Report ID.
438 * Set the first byte of `data` to the Report ID of the report to
439 * be read, or set it to zero if your device does not use numbered
440 * reports.
441 * \param length The number of bytes to read, including an extra byte for the
442 * report ID. The buffer can be longer than the actual report.
443 * \returns the number of bytes read plus one for the report ID (which is
444 * still in the first byte), or -1 on error.
445 *
446 * \since This function is available since SDL 3.0.0.
447 */
448extern DECLSPEC int SDLCALL SDL_hid_get_input_report(SDL_hid_device *dev, unsigned char *data, size_t length);
449
450/**
451 * Close a HID device.
452 *
453 * \param dev A device handle returned from SDL_hid_open().
454 * \returns 0 on success or a negative error code on failure; call
455 * SDL_GetError() for more information.
456 *
457 * \since This function is available since SDL 3.0.0.
458 */
459extern DECLSPEC int SDLCALL SDL_hid_close(SDL_hid_device *dev);
460
461/**
462 * Get The Manufacturer String from a HID device.
463 *
464 * \param dev A device handle returned from SDL_hid_open().
465 * \param string A wide string buffer to put the data into.
466 * \param maxlen The length of the buffer in multiples of wchar_t.
467 * \returns 0 on success or a negative error code on failure; call
468 * SDL_GetError() for more information.
469 *
470 * \since This function is available since SDL 3.0.0.
471 */
472extern DECLSPEC int SDLCALL SDL_hid_get_manufacturer_string(SDL_hid_device *dev, wchar_t *string, size_t maxlen);
473
474/**
475 * Get The Product String from a HID device.
476 *
477 * \param dev A device handle returned from SDL_hid_open().
478 * \param string A wide string buffer to put the data into.
479 * \param maxlen The length of the buffer in multiples of wchar_t.
480 * \returns 0 on success or a negative error code on failure; call
481 * SDL_GetError() for more information.
482 *
483 * \since This function is available since SDL 3.0.0.
484 */
485extern DECLSPEC int SDLCALL SDL_hid_get_product_string(SDL_hid_device *dev, wchar_t *string, size_t maxlen);
486
487/**
488 * Get The Serial Number String from a HID device.
489 *
490 * \param dev A device handle returned from SDL_hid_open().
491 * \param string A wide string buffer to put the data into.
492 * \param maxlen The length of the buffer in multiples of wchar_t.
493 * \returns 0 on success or a negative error code on failure; call
494 * SDL_GetError() for more information.
495 *
496 * \since This function is available since SDL 3.0.0.
497 */
498extern DECLSPEC int SDLCALL SDL_hid_get_serial_number_string(SDL_hid_device *dev, wchar_t *string, size_t maxlen);
499
500/**
501 * Get a string from a HID device, based on its string index.
502 *
503 * \param dev A device handle returned from SDL_hid_open().
504 * \param string_index The index of the string to get.
505 * \param string A wide string buffer to put the data into.
506 * \param maxlen The length of the buffer in multiples of wchar_t.
507 * \returns 0 on success or a negative error code on failure; call
508 * SDL_GetError() for more information.
509 *
510 * \since This function is available since SDL 3.0.0.
511 */
512extern DECLSPEC int SDLCALL SDL_hid_get_indexed_string(SDL_hid_device *dev, int string_index, wchar_t *string, size_t maxlen);
513
514/**
515 * Get the device info from a HID device.
516 *
517 * \param dev A device handle returned from SDL_hid_open().
518 * \returns a pointer to the SDL_hid_device_info for this hid_device, or NULL
519 * in the case of failure; call SDL_GetError() for more information.
520 * This struct is valid until the device is closed with
521 * SDL_hid_close().
522 *
523 * \since This function is available since SDL 3.0.0.
524 */
526
527/**
528 * Get a report descriptor from a HID device.
529 *
530 * User has to provide a preallocated buffer where descriptor will be copied
531 * to. The recommended size for a preallocated buffer is 4096 bytes.
532 *
533 * \param dev A device handle returned from SDL_hid_open().
534 * \param buf The buffer to copy descriptor into.
535 * \param buf_size The size of the buffer in bytes.
536 * \returns the number of bytes actually copied, or -1 on error; call
537 * SDL_GetError() for more information.
538 *
539 * \since This function is available since SDL 3.0.0.
540 */
541extern DECLSPEC int SDLCALL SDL_hid_get_report_descriptor(SDL_hid_device *dev, unsigned char *buf, size_t buf_size);
542
543/**
544 * Start or stop a BLE scan on iOS and tvOS to pair Steam Controllers.
545 *
546 * \param active SDL_TRUE to start the scan, SDL_FALSE to stop the scan
547 *
548 * \since This function is available since SDL 3.0.0.
549 */
550extern DECLSPEC void SDLCALL SDL_hid_ble_scan(SDL_bool active);
551
552/* Ends C function definitions when using C++ */
553#ifdef __cplusplus
554}
555#endif
556#include <SDL3/SDL_close_code.h>
557
558#endif /* SDL_hidapi_h_ */
SDL_hid_device * SDL_hid_open(unsigned short vendor_id, unsigned short product_id, const wchar_t *serial_number)
struct SDL_hid_device SDL_hid_device
Definition SDL_hidapi.h:80
int SDL_hid_init(void)
void SDL_hid_ble_scan(SDL_bool active)
int SDL_hid_get_product_string(SDL_hid_device *dev, wchar_t *string, size_t maxlen)
int SDL_hid_get_report_descriptor(SDL_hid_device *dev, unsigned char *buf, size_t buf_size)
int SDL_hid_read(SDL_hid_device *dev, unsigned char *data, size_t length)
int SDL_hid_close(SDL_hid_device *dev)
Uint32 SDL_hid_device_change_count(void)
SDL_hid_bus_type
Definition SDL_hidapi.h:87
@ SDL_HID_API_BUS_SPI
Definition SDL_hidapi.h:111
@ SDL_HID_API_BUS_I2C
Definition SDL_hidapi.h:106
@ SDL_HID_API_BUS_UNKNOWN
Definition SDL_hidapi.h:89
@ SDL_HID_API_BUS_BLUETOOTH
Definition SDL_hidapi.h:101
@ SDL_HID_API_BUS_USB
Definition SDL_hidapi.h:94
int SDL_hid_exit(void)
int SDL_hid_get_feature_report(SDL_hid_device *dev, unsigned char *data, size_t length)
SDL_hid_device * SDL_hid_open_path(const char *path)
int SDL_hid_get_serial_number_string(SDL_hid_device *dev, wchar_t *string, size_t maxlen)
int SDL_hid_get_manufacturer_string(SDL_hid_device *dev, wchar_t *string, size_t maxlen)
void SDL_hid_free_enumeration(SDL_hid_device_info *devs)
int SDL_hid_get_input_report(SDL_hid_device *dev, unsigned char *data, size_t length)
int SDL_hid_get_indexed_string(SDL_hid_device *dev, int string_index, wchar_t *string, size_t maxlen)
SDL_hid_device_info * SDL_hid_enumerate(unsigned short vendor_id, unsigned short product_id)
int SDL_hid_write(SDL_hid_device *dev, const unsigned char *data, size_t length)
int SDL_hid_send_feature_report(SDL_hid_device *dev, const unsigned char *data, size_t length)
SDL_hid_device_info * SDL_hid_get_device_info(SDL_hid_device *dev)
int SDL_hid_set_nonblocking(SDL_hid_device *dev, int nonblock)
int SDL_hid_read_timeout(SDL_hid_device *dev, unsigned char *data, size_t length, int milliseconds)
int SDL_bool
Definition SDL_stdinc.h:170
uint32_t Uint32
Definition SDL_stdinc.h:224
unsigned short product_id
Definition SDL_hidapi.h:129
unsigned short vendor_id
Definition SDL_hidapi.h:127
wchar_t * product_string
Definition SDL_hidapi.h:138
SDL_hid_bus_type bus_type
Definition SDL_hidapi.h:160
struct SDL_hid_device_info * next
Definition SDL_hidapi.h:163
unsigned short usage
Definition SDL_hidapi.h:144
wchar_t * manufacturer_string
Definition SDL_hidapi.h:136
unsigned short usage_page
Definition SDL_hidapi.h:141
unsigned short release_number
Definition SDL_hidapi.h:134
wchar_t * serial_number
Definition SDL_hidapi.h:131