-
Notifications
You must be signed in to change notification settings - Fork 3k
Description
Description of defect
The USBSerial device on mbed-os-6.10.0 results in a "USB Device not recognized" popup and "Device descriptor request failed" when connected to a host. Returning to mbed-os-6.9.0 resolves the issue and USB serial device is detected and works fine.
Target(s) affected by this defect ?
STM32F103RB (Also tested on custom PCB with STM32F103 and Blue Pill dev board)
Nucleo has 8MHz HSE crystal soldered.
Toolchain(s) (name and version) displaying this defect ?
Mbed Studio with ARMC6 compiler. Also tested with GCC 10_2020-q4-major
What version of Mbed-os are you using (tag or sha) ?
mbed-os-6.10.0
What version(s) of tools are you using. List all that apply (E.g. mbed-cli)
Mbed Studio v1.4.1
How is this defect reproduced ?
Create a blank program in Mbed Studio and update the mbed-os library to mbed-os-6.10.0
mbed_app.json
"requires": ["bare-metal","drivers-usb","events"],
"target_overrides": {
"*": {
"target.c_lib": "small"
},
"NUCLEO_F103RB": {
"target.clock_source": "USE_PLL_HSE_XTAL",
"target.clock_source_usb": "1",
"target.device_has_add": ["USBDEVICE"],
"target.lse_available": 1,
"target.rtc_clock_source": "USE_RTC_CLK_LSE_OR_LSI"
}
}
}
main.cpp
#include "mbed.h"
#include "USBSerial.h"
USBSerial usb(false); //Do not block until connected
int i = 0;
FileHandle *mbed::mbed_override_console(int fd)
{
return &usb;
}
int main()
{
while (true) {
printf("Program has been running for %d seconds.\r\n", i++);
ThisThread::sleep_for(1000ms);
}
}
Power up target and then connect to the host. Windows displays USB error.
Remove mbed-os library and reinstall mbed-os with version: mbed-os-6.9.0
Build and program target and connect to host. Usb serial port now works properly.