2022-07-20 05:06 AM
Good morning all right guys. I'm currently implementing USB communication on the STM32F072R8T6 microcontroller with "Custom HID" class. I'm having problems receiving data from the Host (PC) in the function below. The following happens: I can receive up to 2 data packets from the Host and then I can no longer receive and process them. In the communication on the other side, sending from "Device" to "Host" I'm not having problems, but only to receive them (Host to Device). I followed the recommendation of this link for such an implementation https://www.youtube.com/watch?v=3JGRt3BFYrM&t=257s I didn't use HID Terminal, in fact I didn't find anything on the Internet but a professional Host application. Thanks
static int8_t CUSTOM_HID_OutEvent_FS(uint8_t* state)
{
/* USER CODE BEGIN 6 */
__disable_irq();
memcpy(BufferUSB_RX,state,64);
memset(state, '\0',64);
strlen(Buffer_TX));
__enable_irq();
return (USBD_OK);
/* USER CODE END 6 */
}
2022-08-03 07:15 AM
Thanks for help.
2022-09-12 02:29 PM
I have exactly the same problem.
But ST leaves us alone!