Hello,
I'm doing first steps with USB using the controlCard with the 28069U (iso). The example usb_host_msc provided works perfect to read some files on my USB stick.
The only thing I did see is that the program hangs in the loop shown below if I disconnect the USB stick while I do access a file.
while(g_sUSBHCD.USBOUTPipes[ulPipeIdx].eState == PIPE_WRITING)
tested like this:
- in terminal enter the command: cat file.ext (file.ext is a really big file which is now displayed on the terminal)
- disconnect USB stick while the file access is running
- --> The porogram hangs.
Now my question: How do I best handle this use case? How do you handle this?
Thank you for sharing your ideas!
Best Regards,
Roger