STM32H7RS USB_HS failure (Device Descriptor Request Failed)
I cannot get OTG_HS to communicate with a USB host, and I'm out of ideas. Any help would be greatly appreciated.
The problem:
I've instrumented HAL_PCD_IRQHandler to print whenever an interrupt occurs. Right after USBD_Start, I get:
- 0x800 (USBSUSP)
- 0x1000 (USBRST)
- 0x2000 (ENUMDNE)
It then repeats 2 then 3 a few times until the OS gives up. I do not get any other interrupts (I'm expecting at least RXFLVL after USBRST to transfer the Setup packet). Windows reports Device Descriptor Request failed. Linux reports "device descriptor read/64, error -71".
Things I've tried:
- DMA Mode and Not
- Data Caching universally disabled
- Putting hpcd_USB_OTG_HS into noncacheable memory. (Strangely, this prevents any USB interrupts from arriving for some reason)
- I've tried enabling Activate-VBUS. This changes the behavior (I get SRQSINT, USBRST, and that's it)
- I've tried initializing as PCD_SPEED_FULL instead of PCD_SPEED_HIGH with no changes.
Possibly relevant details:
- VDD50USB is driven by VUSB at 5V, and VDD33USB is properly generating 3.3V internally.
- Everything else is driven by 1.8V, and the internal SMPS regulator is used to generate Vcore, and is producing expected voltages.
- Calling LL_PWR_IsEnabledUSBReg(), ...HSPHYReg, ...VoltageDetector() all show they are enabled. Also USB33RDY is true.
- The HSI is driving the PLL3Q, which is divided down to 16MHz. This matches the setting in "OTG PHY reference clock selection".
- My SYSCLK is 600MHz, divided down to CPUCLK of 75MHz. All AHBs are running at 75MHz.
- DVDD is connected to VCAPx which are connected to the output of VLXSMPS (after inductor and caps). (This seems correct from AN5935, page 39, where Vcore connected to DVDD)
- VCAPx has no per-pin capacitors (this seems correct from AN5935, page 8, VCAP only used for LDO, not SMPS)
- The USB D+/D- traces come from a USB-C port, are 90 ohm differential pair controlled impedance, and less than 30mm.
Thank you in advance for any help!
