Go Down

Topic: bossac: invalid option -- I and other error messages (Read 317 times) previous topic - next topic

ethanhall9

Hi there

When trying to upload the Blink.ino sketch or any other, I get the following error message:

Flashing with command:/Users/[Redacted]/.arduino-create/arduino/bossac/1.7.0/bossac -i -d --port=cu.usbmodem14401 -I -U true -i -e -w /var/folders/kv/_d94_kyn25xd0zy37ndxyp0c0000gn/T/arduino-create-agent546243724/Blink.bin -R

bossac: invalid option -- I

When trying to check the WiFi module firmware version, I get the same error, and this:

WARNING: library SPI claims to run on (samd) architecture(s) and may be incompatible with your current board which runs on (samd_beta) architecture(s).

Any idea what might be wrong/how to fix it?

pert

Hi. This is a known bug with the Arduino Web Editor that also prevents uploading to Due. To get a notification when the issue is fixed, please follow this thread:
http://forum.arduino.cc/index.php?topic=507661.msg4105620#msg4105620

Until then, please just use the standard Arduino IDE. You can download it for free here:
http://www.arduino.cc/en/Main/Software

ethanhall9

I believe I did try both editors, and none of them worked. I will try again and get back to you. Is there a workaround? For example running from the command line and removing the failing option? When I run that version of bossac -h as opposed to another one, I see that -I is listed in help for the other, but not the failing one, although they do have the same version number...

pert

Is there a workaround?
Yes. The problem is that the Arduino Web Editor is using bossac 1.7.0, but the upload recipe is written for bossac 1.7.0-arduino3. 1.7.0 does not have the -I option. So you could replace the bossac 1.7.0, which is installed at /Users/[Redacted]/.arduino-create/arduino/bossac/1.7.0/, with bossac 1.7.0-arduino3. The download URLs for bossac1.7.0-arduino3 are listed in Arduino's package_index.json file:
Code: [Select]
        {
          "name": "bossac",
          "version": "1.7.0-arduino3",
          "systems": [
            {
              "host": "i686-mingw32",
              "url": "http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-windows.tar.gz",
              "archiveFileName": "bossac-1.7.0-arduino3-windows.tar.gz",
              "checksum": "SHA-256:62745cc5a98c26949ec9041ef20420643c561ec43e99dae659debf44e6836526",
              "size": "3607421"
            },
            {
              "host": "x86_64-apple-darwin",
              "url": "http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-osx.tar.gz",
              "archiveFileName": "bossac-1.7.0-arduino3-osx.tar.gz",
              "checksum": "SHA-256:adb3c14debd397d8135e9e970215c6972f0e592c7af7532fa15f9ce5e64b991f",
              "size": "75510"
            },
            {
              "host": "x86_64-pc-linux-gnu",
              "url": "http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-linux64.tar.gz",
              "archiveFileName": "bossac-1.7.0-arduino3-linux64.tar.gz",
              "checksum": "SHA-256:1ae54999c1f97234a5c603eb99ad39313b11746a4ca517269a9285afa05f9100",
              "size": "207271"
            },
            {
              "host": "i686-pc-linux-gnu",
              "url": "http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-linux32.tar.gz",
              "archiveFileName": "bossac-1.7.0-arduino3-linux32.tar.gz",
              "checksum": "SHA-256:4ac4354746d1a09258f49a43ef4d1baf030d81c022f8434774268b00f55d3ec3",
              "size": "193577"
            },
            {
              "host": "arm-linux-gnueabihf",
              "url": "http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-linuxarm.tar.gz",
              "archiveFileName": "bossac-1.7.0-arduino3-linuxarm.tar.gz",
              "checksum": "SHA-256:626c6cc548046901143037b782bf019af1663bae0d78cf19181a876fb9abbb90",
              "size": "193941"
            },
            {
              "host": "aarch64-linux-gnu",
              "url": "http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-linuxaarch64.tar.gz",
              "archiveFileName": "bossac-1.7.0-arduino3-linuxaarch64.tar.gz",
              "checksum": "SHA-256:a098b2cc23e29f0dc468416210d097c4a808752cd5da1a7b9b8b7b931a04180b",
              "size": "268365"
            }
          ]
        },

Make sure to grab the right one for your operating system. If you're using 64 bit Linux, the correct download is:
http://downloads.arduino.cc/tools/bossac-1.7.0-arduino3-linux64.tar.gz

For example running from the command line and removing the failing option?
I don't actually know what the purpose of -I is, but I'm sure they added it for a reason. I would recommend against removing it. If you don't like the idea of replacing bossac 1.7.0 with bossac 1.7.0-arduino3, you could install 1.7.0-arduino3 to a separate location and then run the upload command from the command line, but modify the path to point to the installation of bossac 1.7.0-arduino3.

If you are going to upload from the command line, you should be aware that the Arduino IDE automatically resets the board to put it in bootloader mode before running the bossac command. So you can't do an upload from command line by only running the bossac command. You'll need to first manually put the board in bootloader mode by quickly pressing and releasing the reset button. Note that this may change the port of the board (maybe that's only on Windows?) and you need to specify the correct port in your bossac command.

ethanhall9

Awesome, thank you. :)

I will try replacing the binary this and let you know if it works or not.

pert

You're welcome. I should make a correction to this statement:
You'll need to first manually put the board in bootloader mode by quickly pressing and releasing the reset button.
I left something out. You need to press the reset button quickly twice to activate the bootloader.

Go Up