2019-06-19 09:02 AM
Hi,
Im developing a logger device with STM32F411CC processor. I use the latest Cube, DFP, Keil etc. I would like to use the USB to log datas to a flash drive. I developed a prototype software with an older usb msc host example and it worked on a F4 discovery board.
Now i have the new hardware and i have several questions.
The newest generated code's strusture was a bit different from the old one but it won't the problem.
Thanks a lot!
Bests
Attila
2019-06-19 09:09 AM
SW is stucking in HOST_USER_UNRECOVERED_ERROR:
case CTRL_ERROR:
/*
After a halt condition is encountered or an error is detected by the
host, a control endpoint is allowed to recover by accepting the next Setup
PID; i.e., recovery actions via some other pipe are not required for control
endpoints. For the Default Control Pipe, a device reset will ultimately be
required to clear the halt or error condition if the next Setup PID is not
accepted.
*/
if (++ phost->Control.errorcount <= USBH_MAX_ERROR_COUNT)
{
/* try to recover control */
USBH_LL_Stop(phost);
/* Do the transmission again, starting from SETUP Packet */
phost->Control.state = CTRL_SETUP;
phost->RequestState = CMD_SEND;
}
else
{
phost->pUser(phost, HOST_USER_UNRECOVERED_ERROR);
phost->Control.errorcount = 0U;
USBH_ErrLog("Control error");
status = USBH_FAIL;
}
break;
2019-06-19 09:39 AM
Sorry my fault, the texas battery charger and OTG power management IC has a WDT inside it (with default 40sec reset time) disable it solved the half of the problems. Still stucked in HOST_USER_UNRECOVERED_ERROR sometimes. Replug the flash drive fixes the problem, but can i solve it by SW?
2020-03-02 05:45 AM
have the same problem with a F746 did you fixed it?