Can't upload anything on Arduino Nano Every

Can't upload any sketch on arduino nano every, because of an error:

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description
avrdude: jtagmkII_reset(): timeout/error communicating with programmer (status -1)
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.

avrdude: jtagmkII_close(): timeout/error communicating with programmer (status -1)
avrdude: jtagmkII_close(): timeout/error communicating with programmer (status -1)
Failed uploading: uploading error: exit status 1

Any thoughts how to fix it?

Can't upload any sketch on arduino nano every, because of an error

What OS and what IDE version are you using?

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description

This message is normal and does not indicate an issue.

If you are loading over USB, then at the end of the compiling you should see a message like this

Sketch uses 3017 bytes (6%) of program storage space. Maximum is 49152 bytes.
Global variables use 177 bytes (2%) of dynamic memory, leaving 5967 bytes for local variables. Maximum is 6144 bytes.
Performing 1200-bps touch reset on serial port COM9
"C:\Users\YourName\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude" "-CC:\Users\YourName\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf" -v -V -patmega4809 -cjtag2updi -PCOM9  -b115200 -e -D "-Uflash:w:C:\Users\YourName\AppData\Local\Temp\arduino-sketch-C9CE475480A4AC17AE4E1828E62F9009/integer_read_write.ino.hex:i" "-Ufuse2:w:0x01:m" "-Ufuse5:w:0xC9:m" "-Ufuse8:w:0x00:m" {upload.extra_files}

It is the 1200 bps touch which puts the Nano Every into the programming mode.

If you go to Preferences in the ide window you can enable verbose output upload can you post the complete message you receive.

I am using Windows 10, IDE 2.0.3 (also tried 1.8.1.9).

Received message:

Performing 1200-bps touch reset on serial port COM3

avrdude: Version 6.3-20190619
Copyright (c) 2000-2005 Brian "C:\Users\nikit\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude" "-CC:\Users\nikit\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf" -v -V -patmega4809 -cjtag2updi -PCOM3 -b115200 -e -D "-Uflash:w:C:\Users\nikit\AppData\Local\Temp\arduino-sketch-8571B255817263B56A74F836EE64EFB4/sketch_feb27a.ino.hex:i" "-Ufuse2:w:0x01:m" "-Ufuse5:w:0xC9:m" "-Ufuse8:w:0x00:m" {upload.extra_files}
Dean, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch

     System wide configuration file is "C:\Users\nikit\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"

     Using Port                    : COM3
     Using Programmer              : jtag2updi
     Overriding Baud Rate          : 115200

avrdude: ser_open(): can't open device "\.\COM3": �������� � �������.

avrdude done. Thank you.

Failed uploading: uploading error: exit status 1

Have you tried a different USB cable?
Have you reset the computer?
Does the Nano Every show under Ports in the device manager?

Tried 3 cables
Reseted computer
Yes, it shows COM3 (Arduino Nano Every).

Also got new information:

Performing 1200-bps touch reset on serial port COM3
"C:\Users\nikit\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude" "-CC:\Users\nikit\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf" -v -V -patmega4809 -cjtag2updi -PCOM3 -b115200 -e -D "-Uflash:w:C:\Users\nikit\AppData\Local\Temp\arduino-sketch-5906C46E78B8D9A73595B476A73CE17D/sketch_feb28a.ino.hex:i" "-Ufuse2:w:0x01:m" "-Ufuse5:w:0xC9:m" "-Ufuse8:w:0x00:m" {upload.extra_files}

avrdude: Version 6.3-20190619
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch

     System wide configuration file is "C:\Users\nikit\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"
         Using Port                    : COM3
         Using Programmer              : jtag2updi
         Overriding Baud Rate          : 115200
JTAG ICE mkII sign-on message:
Communications protocol version: 1
M_MCU:
  boot-loader FW version:        1
  firmware version:              1.07
  hardware version:              1
S_MCU:
  boot-loader FW version:        1
  firmware version:              6.07
  hardware version:              1
Serial number:                   00:00:00:00:00:00
Device ID:                       JTAGICE mkII
         AVR Part                      : ATmega4809
         Chip Erase delay              : 0 us
         PAGEL                         : P00
         BS2                           : P00
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 0
         StabDelay                     : 0
         CmdexeDelay                   : 0
         SyncLoops                     : 0
         ByteDelay                     : 0
         PollIndex                     : 0
         PollValue                     : 0x00
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
           prodsig        0     0     0    0 no         61   61      0     0     0 0x00 0x00
           fuses          0     0     0    0 no          9    0      0     0     0 0x00 0x00
           fuse0          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse1          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse2          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse4          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse5          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse6          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse7          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse8          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           lock           0     0     0    0 no          1    0      0     0     0 0x00 0x00
           data           0     0     0    0 no          0    0      0     0     0 0x00 0x00
           usersig        0     0     0    0 no         64   64      0     0     0 0x00 0x00
           flash          0     0     0    0 no      49152  128      0     0     0 0x00 0x00
           eeprom         0     0     0    0 no        256   64      0     0     0 0x00 0x00

         Programmer Type : JTAGMKII_PDI
         Description     : JTAGv2 to UPDI bridge
         M_MCU hardware version: 1
         M_MCU firmware version: 1.07
         S_MCU hardware version: 1
         S_MCU firmware version: 6.07
         Serial number:          00:00:00:00:00:00
         Vtarget         : 5.0 V

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description
avrdude: jtagmkII_reset(): timeout/error communicating with programmer (status -1)
avrdude: initialization failed, rc=-1
         Double check connections and try again, or use -F to override
         this check.

avrdude: jtagmkII_close(): timeout/error communicating with programmer (status -1)
avrdude: jtagmkII_close(): timeout/error communicating with programmer (status -1)

avrdude done.  Thank you.

Failed uploading: uploading error: exit status 1

Tried 3 cables
Reseted computer
Yes, it shows COM3 (Arduino Nano Every).

In most cases this would have fixed things. Do you have any other Arduino and can confirm that the usb cable works correctly with it?

Everything from this last download report looks correct until

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description
avrdude: jtagmkII_reset(): timeout/error communicating with programmer (status -1)
avrdude: initialization failed, rc=-1

Which should be

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description
avrdude: AVR device initialized and ready to accept instructions

This means that the jtag to updi programmer software in the samd11 chip which handles the usb interface is either not getting the 1200 bps touch to trigger the programming mode, or the firmware in the samd11 is corrupted.

Since you are using the Arduino IDE with Windows 10, I think the problem is likely to be with the samd11 chip itself and not with the 1200 bps touch.

Is this a new board which has never worked, or did it once work properly?
Is it an official Nano Every from Arduino, or is it a clone? Some clones use an atMega 4808. and not the 4809 of the official nano every.

With the board connected to usb and you select "Get board info" in the ide Tools, what do you see? You may need 2.0.4 (or 1.8.19) to see the correct information. I'm thinking that if you get this information back, the usb to ttl part of the samd11 is working correctly.
Board Info

If this is a new board and can be returned to the vendor I would recommend that.

If it once worked and you want to try and fix it there are ways to reprogram the samd11 with the correct firmware in a file called MuxTOBin. I have never done this and is an advanced procedure. https://github.com/arduino/ArduinoCore-megaavr/issues/51#issuecomment-522905679
https://www.avrfreaks.net/s/topic/a5C3l000000UbGqEAK/t157060

I seem to remember that I've read that 1.8.x and 2.0.x work differently. 1.8.x (and other legacy IDEs) communicate with the board, 2.0.x pulls the information from the boards.txt file. @ptillisch can advise if I'm talking nonsense or if this information is correct.

To play it safe, use the legacy IDE for this test.

That was the behavior up to 2.0.3. As of Arduino IDE 2.0.4, the Tools > Get Board Info feature works the same as it did in Arduino IDE 1.x, showing data for the selected port:

1 Like

I have the same problem: New Nano Every board, puchased from Arduino. I am in contact with them now, but trying to figure out what the problem is and if you were able to solve problem.

Please provide the details about the upload (enable verbose output during upload under file → preferences in the IDE) like OP did in post #3 as well as the screenshot in post #6.

Some details: 1)Using Windows 10; 2) IDE:2.1.0; 3) This circuit works with the UNO chip (so circuit is good); 4)
This is an authentic NANO board that is brand new.
The messages:

  1. Sketch uses 11903 bytes (24%) of program storage space. Maximum is 49152 bytes.

Global variables use 250 bytes (4%) of dynamic memory, leaving 5894 bytes for local variables. Maximum is 6144 bytes.

Performing 1200-bps touch reset on serial port COM4

  1. avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description

avrdude: AVR device initialized and ready to accept instructions
It states that this is not a big problem, but there is no output on the LCD (should be showing message with humidity and temperature settings
When I checked Preferences and enable Verbose output, both Compile and Upload are checked

Bug in your program? Not necessarily the part that you wrote, might be in a library? Libraries are compiled differently for Uni and Nano Every. Please post your code.

Can you upload e.g. blink or other simple examples and do they behave as expected?

I do not have a Nano Every to check the exact behaviour of the upload.

Good point. Even though the program ran on the UNO, the libraries could be the problem. Here is the libraries that my program is trying to use:

#include <DHT.h>
#include <JSON.h>
#include <LiquidCrystal.h>
I did notice that for each invoking of a library there seems to be an alternative. Here is an example of DHT to show what I mean.
Detecting libraries used...
"C:\Users\Dominic\AppData\Local\Arduino15\packages\arduino\tools\avr-gcc\7.3.0-atmel3.6.1-arduino5/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega4809 -DF_CPU=16000000L -DARDUINO=10607 -DARDUINO_AVR_NANO_EVERY -DARDUINO_ARCH_MEGAAVR -DAVR_NANO_4809_328MODE -DMILLIS_USE_TIMERB3 -DNO_EXTERNAL_I2C_PULLUP "-IC:\Users\Dominic\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.8\cores\arduino/api/deprecated" "-IC:\Users\Dominic\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.8\cores\arduino" "-IC:\Users\Dominic\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.8\variants\nona4809" "C:\Users\Dominic\AppData\Local\Temp\arduino\sketches\B4A71C9AA578FD01246B496014AE5D54\sketch\Humidity_and_temp.ino.cpp" -o nul
Alternatives for DHT.h: [DHT sensor library@1.4.4]
ResolveLibrary(DHT.h)
-> candidates: [DHT sensor library@1.4.4]

Is this a problem (i.e, alternative library)? It seems like it gets resolved???

The message is not very clear, but this is actually saying that only one library was found matching the #include directive for DHT.h. If multiple libraries were found matching the #include directive, you would see multiple elements in the square bracketed list. So don't worry about this message. It is normal and expected and doesn't indicate any problem.

Please answer this question.

Not really sure what you are asking

Can you load simple code to the board (like the Blink example sketch)?

The output you posted from the verbose upload was not complete, there is much more output missing, and I'm not clear if you are getting a normal response, or if you are not able to upload.

This the full output of a successful upload

avrdude: Version 6.3-20190619
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "C:\Users\yourName\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"

         Using Port                    : COM9
         Using Programmer              : jtag2updi
         Overriding Baud Rate          : 115200
JTAG ICE mkII sign-on message:
Communications protocol version: 1
M_MCU:
  boot-loader FW version:        1
  firmware version:              1.07
  hardware version:              1
S_MCU:
  boot-loader FW version:        1
  firmware version:              6.07
  hardware version:              1
Serial number:                   00:00:00:00:00:00
Device ID:                       JTAGICE mkII
         AVR Part                      : ATmega4809
         Chip Erase delay              : 0 us
         PAGEL                         : P00
         BS2                           : P00
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 0
         StabDelay                     : 0
         CmdexeDelay                   : 0
         SyncLoops                     : 0
         ByteDelay                     : 0
         PollIndex                     : 0
         PollValue                     : 0x00
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
           prodsig        0     0     0    0 no         61   61      0     0     0 0x00 0x00
           fuses          0     0     0    0 no          9    0      0     0     0 0x00 0x00
           fuse0          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse1          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse2          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse4          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse5          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse6          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse7          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           fuse8          0     0     0    0 no          1    0      0     0     0 0x00 0x00
           lock           0     0     0    0 no          1    0      0     0     0 0x00 0x00
           data           0     0     0    0 no          0    0      0     0     0 0x00 0x00
           usersig        0     0     0    0 no         64   64      0     0     0 0x00 0x00
           flash          0     0     0    0 no      49152  128      0     0     0 0x00 0x00
           eeprom         0     0     0    0 no        256   64      0     0     0 0x00 0x00

         Programmer Type : JTAGMKII_PDI
         Description     : JTAGv2 to UPDI bridge
         M_MCU hardware version: 1
         M_MCU firmware version: 1.07
         S_MCU hardware version: 1
         S_MCU firmware version: 6.07
         Serial number:          00:00:00:00:00:00
         Vtarget         : 5.0 V

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description
avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.15s

avrdude: Device signature = 0x1e9651 (probably m4809)
avrdude: erasing chip
avrdude: reading input file "C:\Users\RICHAR~1\AppData\Local\Temp\arduino_build_373291/Blink.ino.hex"
avrdude: writing flash (1382 bytes):

Writing | ################################################## | 100% 1.04s

avrdude: 1382 bytes of flash written
avrdude: verifying flash memory against C:\Users\RICHAR~1\AppData\Local\Temp\arduino_build_373291/Blink.ino.hex:
avrdude: load data flash data from input file C:\Users\RICHAR~1\AppData\Local\Temp\arduino_build_373291/Blink.ino.hex:
avrdude: input file C:\Users\RICHAR~1\AppData\Local\Temp\arduino_build_373291/Blink.ino.hex contains 1382 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.21s

avrdude: verifying ...
avrdude: 1382 bytes of flash verified
avrdude: reading input file "0x01"
avrdude: writing fuse2 (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of fuse2 written
avrdude: verifying fuse2 memory against 0x01:
avrdude: load data fuse2 data from input file 0x01:
avrdude: input file 0x01 contains 1 bytes
avrdude: reading on-chip fuse2 data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of fuse2 verified
avrdude: reading input file "0xC9"
avrdude: writing fuse5 (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of fuse5 written
avrdude: verifying fuse5 memory against 0xC9:
avrdude: load data fuse5 data from input file 0xC9:
avrdude: input file 0xC9 contains 1 bytes
avrdude: reading on-chip fuse5 data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of fuse5 verified
avrdude: reading input file "0x00"
avrdude: writing fuse8 (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of fuse8 written
avrdude: verifying fuse8 memory against 0x00:
avrdude: load data fuse8 data from input file 0x00:
avrdude: input file 0x00 contains 1 bytes
avrdude: reading on-chip fuse8 data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of fuse8 verified

avrdude done.  Thank you.

I ran the blink sketch and the LED blinks but I get same output. Here is some of the output:
avrdude: Version 6.3-20190619
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch

System wide configuration file is "C:\Users\Dominic\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf"

Using Port : COM4
Using Programmer : jtag2updi
Overriding Baud Rate : 115200
JTAG ICE mkII sign-on message:
Communications protocol version: 1
M_MCU:
boot-loader FW version: 1
firmware version: 1.07
hardware version: 1
S_MCU:
boot-loader FW version: 1
firmware version: 6.07
hardware version: 1
Serial number: 00:00:00:00:00:00
Device ID: JTAGICE mkII
AVR Part : ATmega4809
Chip Erase delay : 0 us
PAGEL : P00
BS2 : P00
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 0
StabDelay : 0
CmdexeDelay : 0
SyncLoops : 0
ByteDelay : 0
PollIndex : 0
PollValue : 0x00
Memory Detail :

Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack


signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
prodsig 0 0 0 0 no 61 61 0 0 0 0x00 0x00
fuses 0 0 0 0 no 9 0 0 0 0 0x00 0x00
fuse0 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse1 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse2 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse4 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse5 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse6 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse7 0 0 0 0 no 1 0 0 0 0 0x00 0x00
fuse8 0 0 0 0 no 1 0 0 0 0 0x00 0x00
lock 0 0 0 0 no 1 0 0 0 0 0x00 0x00
data 0 0 0 0 no 0 0 0 0 0 0x00 0x00
usersig 0 0 0 0 no 64 64 0 0 0 0x00 0x00
flash 0 0 0 0 no 49152 128 0 0 0 0x00 0x00
eeprom 0 0 0 0 no 256 64 0 0 0 0x00 0x00

Programmer Type : JTAGMKII_PDI
Description : JTAGv2 to UPDI bridge
M_MCU hardware version: 1
M_MCU firmware version: 1.07
S_MCU hardware version: 1
S_MCU firmware version: 6.07
Serial number: 00:00:00:00:00:00
Vtarget : 5.0 V

avrdude: jtagmkII_initialize(): Cannot locate "flash" and "boot" memories in description
avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.27s

avrdude: Device signature = 0x1e9651 (probably m4809)
avrdude: erasing chip
avrdude: reading input file "C:\Users\Dominic\AppData\Local\Temp\arduino\sketches\E0DC067A1D08B72623EFB8D763E9CFDC/Blink.ino.hex"
avrdude: writing flash (1118 bytes):

Writing | ################################################## | 100% 0.84s

avrdude: 1118 bytes of flash written
avrdude: reading input file "0x01"
avrdude: writing fuse2 (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of fuse2 written
avrdude: reading input file "0xC9"
avrdude: writing fuse5 (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of fuse5 written
avrdude: reading input file "0x00"
avrdude: writing fuse8 (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of fuse8 written

avrdude done. Thank you.

That is the output from a successful upload.

"Can't upload anything on Arduino Nano Every" is no longer accurate.

Are you still having issues with code and the Nano Every? If so, can you please post the complete code and any errors you are seeing.