Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork213
Description
Ubuntu bricking Arduino port.
Curious if anyone else has these issues. This is the second ubuntu machine I have had that seems to brick a Portenta, Nicla Vision and now esp32s3 com port.
Works on ubuntu vscode or arduino IDE then does not work on windows either vscode or arduino IDE. Sometimes it then doesn't work on the ubuntu machine.
I think the ubuntu machine is reconfiguring the port which then bricks it on windows. Anyone any suggestions?
@facchinm I really go to stop bricking my Arduinos. I thought this was just a PortentaH7 issue but now I have bricked two Nicla Visions. My latest the esp32S3, does still work on ubuntu both vscode and the arduino IDE but does not work on windows, and I have tested the code on a different esp3s3 and the code and ports work fine.
P.S. This latest one is a seeedstudion XIAO esp32S3 so not an Arduino issues, but the solution might be useful.
I tried a chatGPT solution but it did nothing useful.
resetports.sh bash file for ubuntu
#!/bin/bashecho "Identifying USB serial devices..."USB_DEVICES=$(ls /dev/ttyUSB* /dev/ttyACM* 2>/dev/null)if [ -z "$USB_DEVICES" ]; then echo "No USB serial devices found."else for myPort in $USB_DEVICES; do echo "Releasing $myPort..." sudo fuser -k $myPort 2>/dev/null donefiecho "Stopping ModemManager (if installed)..."sudo systemctl stop ModemManager 2>/dev/nullsudo systemctl disable ModemManager 2>/dev/nullecho "Resetting USB hubs..."for myUSB in $(ls /sys/bus/usb/drivers/usb/*/unbind); do echo "Unbinding: $myUSB" echo "${myUSB##*/}" | sudo tee /sys/bus/usb/drivers/usb/unbind sleep 1 echo "Rebinding: $myUSB" echo "${myUSB##*/}" | sudo tee /sys/bus/usb/drivers/usb/binddoneecho "Power cycling USB ports (turning off and back on)..."echo '1' | sudo tee /sys/bus/usb/devices/usb1/removesleep 3echo '1' | sudo tee /sys/bus/usb/devices/usb1/addecho "USB reset complete. Safe to reboot into Windows."
anyone got any other suggestions. By the way the above code kills your mouse so make sure your shutdown the ubuntu with
sudo shutdown -r now