usbd_cdc_core.h
Go to the documentation of this file.
1 
28 /* Includes ------------------------------------------------------------------*/
29 
30 #ifndef __USB_CDC_CORE_H_
31 #define __USB_CDC_CORE_H_
32 
33 #include "usbd_ioreq.h"
34 
48 #define USB_CDC_CONFIG_DESC_SIZ (67)
49 #define USB_CDC_DESC_SIZ (67-9)
50 
51 #define DEVICE_CLASS_CDC 0x02
52 #define DEVICE_SUBCLASS_CDC 0x00
53 
54 
55 #define USB_DEVICE_DESCRIPTOR_TYPE 0x01
56 #define USB_CONFIGURATION_DESCRIPTOR_TYPE 0x02
57 #define USB_STRING_DESCRIPTOR_TYPE 0x03
58 #define USB_INTERFACE_DESCRIPTOR_TYPE 0x04
59 #define USB_ENDPOINT_DESCRIPTOR_TYPE 0x05
60 
61 #define STANDARD_ENDPOINT_DESC_SIZE 0x09
62 
63 #define CDC_DATA_IN_PACKET_SIZE CDC_DATA_MAX_PACKET_SIZE
64 
65 #define CDC_DATA_OUT_PACKET_SIZE CDC_DATA_MAX_PACKET_SIZE
66 
67 /*---------------------------------------------------------------------*/
68 /* CDC definitions */
69 /*---------------------------------------------------------------------*/
70 
71 /**************************************************/
72 /* CDC Requests */
73 /**************************************************/
74 #define SEND_ENCAPSULATED_COMMAND 0x00
75 #define GET_ENCAPSULATED_RESPONSE 0x01
76 #define SET_COMM_FEATURE 0x02
77 #define GET_COMM_FEATURE 0x03
78 #define CLEAR_COMM_FEATURE 0x04
79 #define SET_LINE_CODING 0x20
80 #define GET_LINE_CODING 0x21
81 #define SET_CONTROL_LINE_STATE 0x22
82 #define SEND_BREAK 0x23
83 #define NO_CMD 0xFF
84 
93 typedef struct _CDC_IF_PROP
94 {
95  uint16_t (*pIf_Init) (void);
96  uint16_t (*pIf_DeInit) (void);
97  uint16_t (*pIf_Ctrl) (uint32_t Cmd, uint8_t* Buf, uint32_t Len);
98  uint16_t (*pIf_DataTx) (const uint8_t* Buf, uint32_t Len);
99  uint16_t (*pIf_DataRx) (uint8_t* Buf, uint32_t Len);
100 }
132 #endif /* __USB_CDC_CORE_H_ */
133 
141 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
struct _CDC_IF_PROP CDC_IF_Prop_TypeDef
USBD_Class_cb_TypeDef USBD_CDC_cb
uint16_t(* pIf_DeInit)(void)
Definition: usbd_cdc_core.h:96
uint16_t(* pIf_DataRx)(uint8_t *Buf, uint32_t Len)
Definition: usbd_cdc_core.h:99
uint16_t(* pIf_DataTx)(const uint8_t *Buf, uint32_t Len)
Definition: usbd_cdc_core.h:98
uint16_t(* pIf_Ctrl)(uint32_t Cmd, uint8_t *Buf, uint32_t Len)
Definition: usbd_cdc_core.h:97
header file for the usbd_ioreq.c file
uint16_t(* pIf_Init)(void)
Definition: usbd_cdc_core.h:95


rosflight_firmware
Author(s): Daniel Koch , James Jackson
autogenerated on Wed Jul 3 2019 19:59:26