Upload fails: "Upload using programmer is not supported on optiboot boards"

Continuing the discussion from Problem with drazzy.com:

I'm struggling with this too. The official link appear to be bad agiin but the alternative one still allows you to load the boards:
raw.githubusercontent.com/SpenceKonde/ReleaseScripts/master/package_drazzy.com_index.json
you can put this in the
PREFERANCES > Additional Boards Management URLs
however I now get an error, after following the rest of the adafruit instructions, when I try to compile I get a error that ends with "python3" does not exist. If I navigate to the folder in question the file "python3.exe" does exist though.
Anyone got any ideas?

arduino 1.8.13

ERROR: Upload using programmer is not supported on optiboot boards""C:\Users\ThinkPad\AppData\Local\Arduino15\packages\megaTinyCore\tools\python3\3.7.2-post1/python3 -u C:\Users\ThinkPad\AppData\Local\Arduino15\packages\megaTinyCore\hardware\megaavr\2.6.8/tools/prog.py -t uart -u COM9 -b 57600 -d attiny412 --fuses 0:0x00 2:0x02 6:0x04 7:0x00 8:0x02 -fC:\Users\ThinkPad\AppData\Local\Temp\arduino_build_784944/ZXSpectrumIF2.ino.hex -a write -v 
java.io.IOException: Cannot run program "ERROR: Upload using programmer is not supported on optiboot boards\"\"C:\Users\ThinkPad\AppData\Local\Arduino15\packages\megaTinyCore\tools\python3\3.7.2-post1/python3": 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.runCommand(SerialUploader.java:383)
	at cc.arduino.packages.uploaders.SerialUploader.uploadUsingProgrammer(SerialUploader.java:315)
	at cc.arduino.packages.uploaders.SerialUploader.uploadUsingPreferences(SerialUploader.java:90)
	at cc.arduino.UploaderUtils.upload(UploaderUtils.java:77)
	at processing.app.SketchController.upload(SketchController.java:732)
	at processing.app.SketchController.exportApplet(SketchController.java:703)
	at processing.app.Editor$UploadHandler.run(Editor.java:2071)
	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)
	... 10 more
An error occurred while uploading the sketch

Hi @clockworkrobot. There are two variants of each of the board definitions in the "DxCore" boards platform (as indicated by the suffix on the board name in the Tools > Board menu):

  • "no bootloader"
  • "Optiboot"

The "no bootloader" variants are intended to be used when you have a UPDI programmer connected to the microcontroller and are uploading to the microcontroller via that programmer. This is when we use the "Upload Using Programmer" operation in Arduino IDE instead of the normal "Upload".

The "Optiboot" variants are intended to be used with microcontrollers to which you have flashed the bootloader. In this case you will upload via a USB to serial bridge connected to the UART on the microcontroller. This is when we use the "Upload" operation in Arduino IDE.

The error is occurring because you have selected one of the "Optiboot" variants from Arduino IDE's Tools > Board menu, but then are triggering an "Upload Using Programmer" operation instead of a normal "Upload".

If you have a UPDI programmer attached to your microcontroller and want to upload through that programmer, then select the "no bootloader" variant of the board definition and try the "Upload Using Programmer" operation again.

If you have performed a "Burn Bootloader" operation to flash the "Optiboot" bootloader, and have a USB to serial bridge connected to the UART on the microcontroller, then select Sketch > Upload from the Arduino IDE menus (or click the "Upload") button instead of triggering an "Upload Using Programmer" operation.

All this is explained in the DxCore documentation:

https://github.com/SpenceKonde/DxCore/blob/1.5.11/megaavr/extras/Ref_Optiboot.md#upload-using-programmer-is-not-supported

I recommend you read through the documentation as this is quite a complex boards platform.

Thank You!
That's the issue. Got it all working now. Thanks again.

You are welcome. I'm glad it is working now.

Regards,
Per

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.