Hoernchen has uploaded this change for review. ( https://gerrit.osmocom.org/c/simtrace2/+/26028 )
Change subject: firmware: increase reset delay before usb reattach ...................................................................... firmware: increase reset delay before usb reattach The previous value was way too low and led to reenumeration issues when switching from app to bl because the hosts are fairly lenient and feature long delays until they accept disappearing devices as gone for good instead of ignoring a presuambly flaky usb cable or connection. Related: SYS5061 Change-Id: I9b8c8bf794ad5b94fc7ea2a01d1ebf4e36862c36 --- M firmware/apps/dfu/main.c M firmware/libcommon/source/usb.c 2 files changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.osmocom.org:29418/simtrace2 refs/changes/28/26028/1 diff --git a/firmware/apps/dfu/main.c b/firmware/apps/dfu/main.c index 4813881..48ba879 100644 --- a/firmware/apps/dfu/main.c +++ b/firmware/apps/dfu/main.c @@ -342,7 +342,7 @@ TRACE_INFO("USB init...\n\r"); /* Signal USB reset by disabling the pull-up on USB D+ for at least 10 ms */ USBD_Disconnect(); - mdelay(50); + mdelay(500); USBDFU_Initialize(&dfu_descriptors); while (USBD_GetState() < USBD_STATE_CONFIGURED) { diff --git a/firmware/libcommon/source/usb.c b/firmware/libcommon/source/usb.c index 0868263..d86fc92 100644 --- a/firmware/libcommon/source/usb.c +++ b/firmware/libcommon/source/usb.c @@ -690,7 +690,7 @@ unsigned int i; /* Signal USB reset by disabling the pull-up on USB D+ for at least 10 ms */ USBD_HAL_Suspend(); - mdelay(20); + mdelay(500); USBD_HAL_Activate(); // Get std USB driver -- To view, visit https://gerrit.osmocom.org/c/simtrace2/+/26028 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: simtrace2 Gerrit-Branch: master Gerrit-Change-Id: I9b8c8bf794ad5b94fc7ea2a01d1ebf4e36862c36 Gerrit-Change-Number: 26028 Gerrit-PatchSet: 1 Gerrit-Owner: Hoernchen <ew...@sysmocom.de> Gerrit-MessageType: newchange