2 ******************************************************************************
3 * @file usbh_hid_core.h
4 * @author MCD Application Team
7 * @brief This file contains all the prototypes for the usbh_hid_core.c
8 ******************************************************************************
11 * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
12 * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
13 * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
14 * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
15 * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
16 * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
18 * <h2><center>© COPYRIGHT 2011 STMicroelectronics</center></h2>
19 ******************************************************************************
22 /* Define to prevent recursive ----------------------------------------------*/
23 #ifndef __USBH_HID_CORE_H
24 #define __USBH_HID_CORE_H
26 /* Includes ------------------------------------------------------------------*/
27 #include "usbh_core.h"
28 #include "usbh_stdreq.h"
30 #include "usbh_ioreq.h"
33 /** @addtogroup USBH_LIB
37 /** @addtogroup USBH_CLASS
41 /** @addtogroup USBH_HID_CLASS
45 /** @defgroup USBH_HID_CORE
46 * @brief This file is the Header file for USBH_HID_CORE.c
51 /** @defgroup USBH_HID_CORE_Exported_Types
56 /* States for HID State Machine */
71 HID_REQ_GET_REPORT_DESC,
83 void (*Decode) (uint8_t *data);
87 typedef struct _HID_Report
111 /* Structure for HID process */
112 typedef struct _HID_Process
120 HID_CtlState ctl_state;
133 /** @defgroup USBH_HID_CORE_Exported_Defines
137 #define USB_HID_REQ_GET_REPORT 0x01
138 #define USB_HID_GET_IDLE 0x02
139 #define USB_HID_GET_PROTOCOL 0x03
140 #define USB_HID_SET_REPORT 0x09
141 #define USB_HID_SET_IDLE 0x0A
142 #define USB_HID_SET_PROTOCOL 0x0B
147 /** @defgroup USBH_HID_CORE_Exported_Macros
154 /** @defgroup USBH_HID_CORE_Exported_Variables
157 extern USBH_Class_cb_TypeDef HID_cb;
162 /** @defgroup USBH_HID_CORE_Exported_FunctionsPrototype
166 USBH_Status USBH_Set_Report (USB_OTG_CORE_HANDLE *pdev,
171 uint8_t* reportBuff);
177 #endif /* __USBH_HID_CORE_H */
194 /******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE****/