STM32F769IDiscovery  1.00
uDANTE Audio Networking with STM32F7 DISCO board
usbd_conf_template.h
Go to the documentation of this file.
1 
28 /* Define to prevent recursive inclusion -------------------------------------*/
29 #ifndef __USBD_CONF_TEMPLATE_H
30 #define __USBD_CONF_TEMPLATE_H
31 
32 #ifdef __cplusplus
33  extern "C" {
34 #endif
35 
36 /* Includes ------------------------------------------------------------------*/
37 #include "stm32fxxx.h" /* replace 'stm32xxx' with your HAL driver header filename, ex: stm32f4xx.h */
38 #include <stdio.h>
39 #include <stdlib.h>
40 #include <string.h>
41 
55 #define USBD_MAX_NUM_INTERFACES 1
56 #define USBD_MAX_NUM_CONFIGURATION 1
57 #define USBD_MAX_STR_DESC_SIZ 0x100
58 #define USBD_SUPPORT_USER_STRING 0
59 #define USBD_SELF_POWERED 1
60 #define USBD_DEBUG_LEVEL 2
61 
62 /* MSC Class Config */
63 #define MSC_MEDIA_PACKET 8192
64 
65 /* CDC Class Config */
66 #define USBD_CDC_INTERVAL 2000
67 
68  /* DFU Class Config */
69 #define USBD_DFU_MAX_ITF_NUM 1
70 #define USBD_DFU_XFERS_IZE 1024
71 
72  /* AUDIO Class Config */
73 #define USBD_AUDIO_FREQ 22100
74 
79  /* Memory management macros */
80 #define USBD_malloc malloc
81 #define USBD_free free
82 #define USBD_memset memset
83 #define USBD_memcpy memcpy
84 
85  /* DEBUG macros */
86 
87 
88 #if (USBD_DEBUG_LEVEL > 0)
89 #define USBD_UsrLog(...) printf(__VA_ARGS__);\
90  printf("\n");
91 #else
92 #define USBD_UsrLog(...)
93 #endif
94 
95 
96 #if (USBD_DEBUG_LEVEL > 1)
97 
98 #define USBD_ErrLog(...) printf("ERROR: ") ;\
99  printf(__VA_ARGS__);\
100  printf("\n");
101 #else
102 #define USBD_ErrLog(...)
103 #endif
104 
105 
106 #if (USBD_DEBUG_LEVEL > 2)
107 #define USBD_DbgLog(...) printf("DEBUG : ") ;\
108  printf(__VA_ARGS__);\
109  printf("\n");
110 #else
111 #define USBD_DbgLog(...)
112 #endif
113 
154 #ifdef __cplusplus
155 }
156 #endif
157 
158 #endif /* __USBD_CONF_TEMPLATE_H */
159 
160 
168 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
169