ArduinoCore-mbed icon indicating copy to clipboard operation
ArduinoCore-mbed copied to clipboard

USBHOST coding error resulting in spurious error message

Open hhoppert opened this issue 2 years ago • 1 comments

tusbh_msg_root_enable()

        res = -1;
        while (res!=0){
            res = tusbh_device_attach(dev);
            TUSB_ROOT_INFO("Device attach failed\n");
        }

This will cause a "Device attach failed" to always be printed, regardless of the outcome of the first device_attach() call.

I'll get around to a pull request, but this should be a quick fix. (working on getting USBHost more stable on Portenta Machine Control)

hhoppert avatar Jun 24 '23 21:06 hhoppert

@hhoppert Did you manage to get the PR in and USBHost stable? I have not been able to get HS core working reliably on H7 (https://github.com/arduino/ArduinoCore-mbed/issues/725).

Any pointers would be helpful.

stickybun avatar Sep 10 '23 14:09 stickybun