2025-06-11 1:07 AM
Hello! everyone.
I use the stm32 Nucleo-L476RG to read the total size of USB flash drive and external hard drives, respectively.
It works with USB flash drives, but not with external hard drives. The error message from STM32 is
FR_DISK_ERR (A hard error occurred in the low level disk I/O layer ) when I try to mount the external hard drives.
The wiring diagram is following
Please give me some suggestions to fix this issue. Thanks in advance.
2025-06-18 3:21 AM
Hello @LeonSu ,
Seems the NUCLEO-L476RG is not layout optimized to interface on PA11/PA12 like a clean USB D+/D- differential tracks. Even if it is only USB Full-Speed, If you add long connection to your external drive, it may not work properly.
5V Power may also be an issue in your context of external drive.
If you don't succeed to solve the problem, other fallback solution could be to use :
- a X-NUCLEO shield (USB host) if compatible with this NUCLEO Board.
- Another Nucleo of another STM32 series offering a true on-board USB Host mode (if it exists)
- More commonly, use Discovery boards or other evaluation boards that offer this kind of feature on a true USB User connector (USB type-C Host capable, or equipped with USB OTG micro A).
Best Regards,