4

I'm working on a small weather station and yesterday everything was working well. This morning I changed some code and suddenly this came up when I wanted to upload the code to my Adafruit:

java.io.IOException: Cannot run program "{runtime.tools.bossac- 
1.7.0.path}/bossac": CreateProcess error=2, The system cannot find the file 
specified

at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048)
at processing.app.helpers.ProcessUtils.exec(ProcessUtils.java:26)
at cc.arduino.packages.Uploader.executeUploadCommand(Uploader.java:129)
at cc.arduino.packages.uploaders.SerialUploader.uploadUsingPreferences(SerialUploader.java:207) 

at cc.arduino.UploaderUtils.upload(UploaderUtils.java:78)
at processing.app.SketchController.upload(SketchController.java:713)
at processing.app.SketchController.exportApplet(SketchController.java:686)
at processing.app.Editor$DefaultExportHandler.run(Editor.java:2168)
at java.lang.Thread.run(Thread.java:748)

Caused by: java.io.IOException: CreateProcess error=2, The system cannot 
find 
the file specified

at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.<init>(ProcessImpl.java:386)
at java.lang.ProcessImpl.start(ProcessImpl.java:137)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
... 8 more
An error occurred while uploading the sketch

Even simple code won't upload anymore. Could someone help me with this? I tried so many things already and I can't figure it out.

Thanks.

dda
  • 6,030
  • 2
  • 25
  • 34
BramAdafruit
  • 81
  • 2
  • 6

3 Answers3

3

I had the same problem with my Adafruit Feather M0. I opened the platform.txt file (running Wordpad as an administrator) located at

C:\Users\[yourPC]\AppData\Local\Arduino15\packages\adafruit\hardware\samd\1.2.9\platform.txt

and changed the line

tools.bossac.path={runtime.tools.bossac-1.7.0.path}

to reflect the actual path of the bossac.exe file (mine was at)

C:\Users\[yourPC]\AppData\Local\Arduino15\packages\adafruit\hardware\samd\1.2.9\tools\

After restarting Arduino, I was finally able to upload a sketch to my M0.

acheroncaptain
  • 348
  • 1
  • 2
  • 13
0

I have been experiencing the same issue. I found that if I went to my Board Manager and downgraded my Feather boards from 1.6.18 to 1.6.17 it fixed the problem.

noPwRon
  • 1
  • 1
0
java.io.IOException: Cannot run program "{runtime.tools.bossac- 
1.7.0.path}/bossac": CreateProcess error=2, The system cannot find the file 
specified

The above line says the path to bossac.exe command line application for ATSAMD micro was not found.

Simply Goto --> C:\Users[yourPCnamehere]\AppData\Local\Arduino15\packages\arduino\tools\bossac

Did you find bossac.exe file there? If not then that's the problem. Simply uninstall the Arduino from your PC and delete the above directory Arduino15 if you have an offline copy of Arduino and then install new version. bossac.exe tool will come with the Arduino package.

Please try this and see if it helps.

nar0909
  • 135
  • 2
  • 14