usbd_cdc_if.h 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. /* USER CODE BEGIN Header */
  2. /**
  3. ******************************************************************************
  4. * @file : usbd_cdc_if.h
  5. * @version : v2.0_Cube
  6. * @brief : Header for usbd_cdc_if.c file.
  7. ******************************************************************************
  8. * @attention
  9. *
  10. * Copyright (c) 2024 STMicroelectronics.
  11. * All rights reserved.
  12. *
  13. * This software is licensed under terms that can be found in the LICENSE file
  14. * in the root directory of this software component.
  15. * If no LICENSE file comes with this software, it is provided AS-IS.
  16. *
  17. ******************************************************************************
  18. */
  19. /* USER CODE END Header */
  20. /* Define to prevent recursive inclusion -------------------------------------*/
  21. #ifndef __USBD_CDC_IF_H__
  22. #define __USBD_CDC_IF_H__
  23. #ifdef __cplusplus
  24. extern "C" {
  25. #endif
  26. /* Includes ------------------------------------------------------------------*/
  27. #include "usbd_cdc.h"
  28. /* USER CODE BEGIN INCLUDE */
  29. /* USER CODE END INCLUDE */
  30. /** @addtogroup STM32_USB_OTG_DEVICE_LIBRARY
  31. * @brief For Usb device.
  32. * @{
  33. */
  34. /** @defgroup USBD_CDC_IF USBD_CDC_IF
  35. * @brief Usb VCP device module
  36. * @{
  37. */
  38. /** @defgroup USBD_CDC_IF_Exported_Defines USBD_CDC_IF_Exported_Defines
  39. * @brief Defines.
  40. * @{
  41. */
  42. /* Define size for the receive and transmit buffer over CDC */
  43. #define APP_RX_DATA_SIZE 1024
  44. #define APP_TX_DATA_SIZE 1024
  45. /* USER CODE BEGIN EXPORTED_DEFINES */
  46. /* USER CODE END EXPORTED_DEFINES */
  47. /**
  48. * @}
  49. */
  50. /** @defgroup USBD_CDC_IF_Exported_Types USBD_CDC_IF_Exported_Types
  51. * @brief Types.
  52. * @{
  53. */
  54. /* USER CODE BEGIN EXPORTED_TYPES */
  55. /* USER CODE END EXPORTED_TYPES */
  56. /**
  57. * @}
  58. */
  59. /** @defgroup USBD_CDC_IF_Exported_Macros USBD_CDC_IF_Exported_Macros
  60. * @brief Aliases.
  61. * @{
  62. */
  63. /* USER CODE BEGIN EXPORTED_MACRO */
  64. /* USER CODE END EXPORTED_MACRO */
  65. /**
  66. * @}
  67. */
  68. /** @defgroup USBD_CDC_IF_Exported_Variables USBD_CDC_IF_Exported_Variables
  69. * @brief Public variables.
  70. * @{
  71. */
  72. /** CDC Interface callback. */
  73. extern USBD_CDC_ItfTypeDef USBD_Interface_fops_FS;
  74. /* USER CODE BEGIN EXPORTED_VARIABLES */
  75. /* USER CODE END EXPORTED_VARIABLES */
  76. /**
  77. * @}
  78. */
  79. /** @defgroup USBD_CDC_IF_Exported_FunctionsPrototype USBD_CDC_IF_Exported_FunctionsPrototype
  80. * @brief Public functions declaration.
  81. * @{
  82. */
  83. uint8_t CDC_Transmit_FS(uint8_t* Buf, uint16_t Len);
  84. /* USER CODE BEGIN EXPORTED_FUNCTIONS */
  85. /* USER CODE END EXPORTED_FUNCTIONS */
  86. /**
  87. * @}
  88. */
  89. /**
  90. * @}
  91. */
  92. /**
  93. * @}
  94. */
  95. #ifdef __cplusplus
  96. }
  97. #endif
  98. #endif /* __USBD_CDC_IF_H__ */