/*
LUFA Library
- Copyright (C) Dean Camera, 2012.
+ Copyright (C) Dean Camera, 2015.
dean [at] fourwalledcubicle [dot] com
www.lufa-lib.org
*/
/*
- Copyright 2012 Dean Camera (dean [at] fourwalledcubicle [dot] com)
+ Copyright 2015 Dean Camera (dean [at] fourwalledcubicle [dot] com)
Permission to use, copy, modify, distribute, and sell this
software and its documentation for any purpose is hereby granted
advertising or publicity pertaining to distribution of the
software without specific, written prior permission.
- The author disclaim all warranties with regard to this
+ The author disclaims all warranties with regard to this
software, including all implied warranties of merchantability
and fitness. In no event shall the author be liable for any
special, indirect or consequential damages or any damages
/** \ingroup Group_USBClassHID
* \defgroup Group_USBClassHIDDevice HID Class Device Mode Driver
*
- * \section Sec_Dependencies Module Source Dependencies
+ * \section Sec_USBClassHIDDevice_Dependencies Module Source Dependencies
* The following files must be built with any user project that uses this module:
* - LUFA/Drivers/USB/Class/Device/HIDClassDevice.c <i>(Makefile source module name: LUFA_SRC_USBCLASS)</i>
*
- * \section Sec_ModDescription Module Description
+ * \section Sec_USBClassHIDDevice_ModDescription Module Description
* Device Mode USB Class driver framework interface, for the HID USB Class driver.
*
* @{
*/
typedef struct
{
- const struct
+ struct
{
uint8_t InterfaceNumber; /**< Interface number of the HID interface within the device. */
- uint8_t ReportINEndpointNumber; /**< Endpoint number of the HID interface's IN report endpoint. */
- uint16_t ReportINEndpointSize; /**< Size in bytes of the HID interface's IN report endpoint. */
- bool ReportINEndpointDoubleBank; /**< Indicates if the HID interface's IN report endpoint should use double banking. */
+ USB_Endpoint_Table_t ReportINEndpoint; /**< Data IN HID report endpoint configuration table. */
void* PrevReportINBuffer; /**< Pointer to a buffer where the previously created HID input report can be
* stored by the driver, for comparison purposes to detect report changes that
* must be sent immediately to the host. This should point to a buffer big enough
* to hold the largest HID input report sent from the HID interface. If this is set
- * to \c NULL, it is up to the user to force transfers when needed in the
- * \ref CALLBACK_HID_Device_CreateHIDReport() callback function.
- *
- * \note Due to the single buffer, the internal driver can only correctly compare
- * subsequent reports with identical report IDs. In multiple report devices,
- * this buffer should be set to \c NULL and the decision to send reports made
- * by the user application instead.
+ * to \c NULL, it is up to the user to force transfers when needed in the
+ * \ref CALLBACK_HID_Device_CreateHIDReport() callback function.
+ *
+ * \note Due to the single buffer, the internal driver can only correctly compare
+ * subsequent reports with identical report IDs. In multiple report devices,
+ * this buffer should be set to \c NULL and the decision to send reports made
+ * by the user application instead.
*/
uint8_t PrevReportINBufferSize; /**< Size in bytes of the given input report buffer. This is used to create a
* second buffer of the same size within the driver so that subsequent reports
* can be compared. If the user app is to determine when reports are to be sent
- * exclusively (i.e. \ref PrevReportINBuffer is \c NULL) this value must still be
- * set to the size of the largest report the device can issue to the host.
+ * exclusively (i.e. \c PrevReportINBuffer is \c NULL) this value must still be
+ * set to the size of the largest report the device can issue to the host.
*/
} Config; /**< Config data for the USB class interface within the device. All elements in this section
* <b>must</b> be set or the interface will fail to enumerate and operate correctly.
uint16_t PrevFrameNum; /**< Frame number of the previous HID report packet opportunity. */
uint16_t IdleCount; /**< Report idle period, in milliseconds, set by the host. */
uint16_t IdleMSRemaining; /**< Total number of milliseconds remaining before the idle period elapsed - this
- * should be decremented by the user application if non-zero each millisecond. */
+ * should be decremented by the user application if non-zero each millisecond. */
} State; /**< State data for the USB class interface within the device. All elements in this section
* are reset to their defaults when the interface is enumerated.
*/