Closed
Description
When uploading using the native usb port, uploading fails every other time. I think that after the first failed upload the board is left running the bootloader, which is what allows the second attempt to succeed. This happens both with the arduino zero (native usb port) and my own modulo controller. It does not happen will non-samd boards such as the arduino micro.
Here's the sequence of events that I'm seeing:
- Press upload (using the Blink sketch for this test)
- 1200bps reset occurs
- upload port is found
- bossac FALS with the error: "No device found on cu.usbmodemXXXX"
- Press upload
- 1200bps reset occurs
- upload port is found
- bossac succeeds.
Here's the output from a failed upload:
Sketch uses 10,988 bytes (4%) of program storage space. Maximum is 262,144 bytes.
Forcing reset using 1200bps open/close on port /dev/cu.usbmodem1411
PORTS {/dev/cu.Bluetooth-Incoming-Port, /dev/cu.usbmodem1411, /dev/tty.Bluetooth-Incoming-Port, /dev/tty.usbmodem1411, } / {/dev/cu.Bluetooth-Incoming-Port, /dev/tty.Bluetooth-Incoming-Port, } => {}
PORTS {/dev/cu.Bluetooth-Incoming-Port, /dev/tty.Bluetooth-Incoming-Port, } / {/dev/cu.Bluetooth-Incoming-Port, /dev/tty.Bluetooth-Incoming-Port, } => {}
PORTS {/dev/cu.Bluetooth-Incoming-Port, /dev/tty.Bluetooth-Incoming-Port, } / {/dev/cu.Bluetooth-Incoming-Port, /dev/tty.Bluetooth-Incoming-Port, } => {}
PORTS {/dev/cu.Bluetooth-Incoming-Port, /dev/tty.Bluetooth-Incoming-Port, } / {/dev/cu.Bluetooth-Incoming-Port, /dev/cu.usbmodem1411, /dev/tty.Bluetooth-Incoming-Port, /dev/tty.usbmodem1411, } => {/dev/cu.usbmodem1411, /dev/tty.usbmodem1411, }
Found upload port: /dev/cu.usbmodem1411
/Users/ekt/Library/Arduino15/packages/arduino/tools/bossac/1.6.1-arduino/bossac -i -d --port=cu.usbmodem1411 -U true -i -e -w -v /var/folders/7z/hphfkcsx0nq7cdntfsf967g00000gn/T/buildd5ae82e677127ac286f51de66781d807.tmp/Blink.ino.bin -R
No device found on cu.usbmodem1411
Is it possible that the bootloader takes too long to initialize the port and bossac runs before the port is ready?
Also I think this may have started happening after upgrading to OS X El Capitan. I haven't tested it on other operating systems but can do so if that's helpful.
Thanks a lot!