I have an arduino board (nano) connected to my Raspberry Pi via the USB port. If I boot the Raspbery Pi first then plugin my arduino it works fine , the arduino is recognised as "FTDI Serial" and assigned to /dev/ttyUSB0.
However if the power goes off and both devices reboot together the Raspberry Pi doesnt detect the arduino at all. The only trace is the following errors in dmesg
[ 3.345596] usb 1-1.3.1.4: new full-speed USB device number 7 using dwc_otg
[ 3.445581] usb 1-1.3.1.4: device descriptor read/64, error -32
[ 3.655612] usb 1-1.3.1.4: device descriptor read/64, error -32
[ 3.865636] usb 1-1.3.1.4: new full-speed USB device number 8 using dwc_otg
[ 3.965653] usb 1-1.3.1.4: device descriptor read/64, error -32
[ 4.175541] usb 1-1.3.1.4: device descriptor read/64, error -32
[ 4.385593] usb 1-1.3.1.4: new full-speed USB device number 9 using dwc_otg
[ 4.805417] usb 1-1.3.1.4: device not accepting address 9, error -32
[ 4.905650] usb 1-1.3.1.4: new full-speed USB device number 10 using dwc_otg
[ 5.325409] usb 1-1.3.1.4: device not accepting address 10, error -32
[ 5.326977] hub 1-1.3.1:1.0: unable to enumerate USB device on port 4
[ 12.167081] EXT4-fs (mmcblk0p2): recovery complete
[ 12.174735] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[ 12.177542] VFS: Mounted root (ext4 filesystem) on device 179:2.
I'm pretty sure that it doesnt work because the driver isnt yet available due to the unclean shutdown and subsequent recovery. It works OK if the Pi is cleanly shutdown and then power cycled.
I tried modprobe ftdi_sio after an unclean shutdown - it completed without error but doesnt fix the problem- /dev/ttyUSB0 is still missing.
Is there a way to force a rescan ? A way to unplug and replug the device in software? Most of the solutions I've found seem to rely on being able to locate the device in /sys/bus/usb/devices but its not present.