Comments (13)
I had exactly the same error with an Atmega644PA-AU programming with a USBASP. The strange thing was when I tried to load the bootloader in other unit of the same microcontroller in other board with simpler circuit there were no problem.
After debugging we have realized the problem was that we were supplying power only by the avcc input, not by the vcc.
Check if it is correctly powered.
from megacore.
Please turn on verbose upload in the IDE settings and post your full error message. What programmer are you using? This may be a lockbit issue, but I can't tell before the full error message is posted 😉
from megacore.
`C:\Arduino\hardware\tools\avr/bin/avrdude -CC:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf -v -patmega64 -cusbasp -Pusb -e -Ulock:w:0x3f:m -Uefuse:w:0xff:m -Uhfuse:w:0xc6:m -Ulfuse:w:0xbf:m
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf"
Using Port : usb
Using Programmer : usbasp
AVR Part : ATmega64
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PA0
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 64 0 no 2048 8 0 9000 9000 0xff 0xff
flash 33 6 128 0 yes 65536 256 256 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
efuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
lock 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : usbasp
Description : USBasp, http://www.fischl.de/usbasp/
avrdude: auto set sck period (because given equals null)
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.01s
avrdude: Device signature = 0x1e9602
avrdude: erasing chip
avrdude: auto set sck period (because given equals null)
avrdude: reading input file "0x3f"
avrdude: writing lock (1 bytes):
C:\Arduino\hardware\tools\avr/bin/avrdude -CC:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf -v -patmega64 -cusbasp -Pusb -Uflash:w:C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega64/optiboot_flash_atmega64_115200_16MHz.hex:i -Ulock:w:0x0f:m
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf"
Using Port : usb
Using Programmer : usbasp
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of lock written
avrdude: verifying lock memory against 0x3f:
avrdude: load data lock data from input file 0x3f:
avrdude: input file 0x3f contains 1 bytes
avrdude: reading on-chip lock data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of lock verified
avrdude: reading input file "0xff"
avrdude: writing efuse (1 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of efuse written
avrdude: verifying efuse memory against 0xff:
avrdude: load data efuse data from input file 0xff:
avrdude: input file 0xff contains 1 bytes
avrdude: reading on-chip efuse data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of efuse verified
avrdude: reading input file "0xc6"
avrdude: writing hfuse (1 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of hfuse written
avrdude: verifying hfuse memory against 0xc6:
avrdude: load data hfuse data from input file 0xc6:
avrdude: input file 0xc6 contains 1 bytes
avrdude: reading on-chip hfuse data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of hfuse verified
avrdude: reading input file "0xbf"
avrdude: writing lfuse (1 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of lfuse written
avrdude: verifying lfuse memory against 0xbf:
avrdude: load data lfuse data from input file 0xbf:
avrdude: input file 0xbf contains 1 bytes
avrdude: reading on-chip lfuse data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of lfuse verified
avrdude done. Thank you.
AVR Part : ATmega64
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PA0
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 64 0 no 2048 8 0 9000 9000 0xff 0xff
flash 33 6 128 0 yes 65536 256 256 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
efuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
lock 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : usbasp
Description : USBasp, http://www.fischl.de/usbasp/
avrdude: auto set sck period (because given equals null)
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.01s
avrdude: Device signature = 0x1e9602
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: auto set sck period (because given equals null)
avrdude: reading input file "C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega64/optiboot_flash_atmega64_115200_16MHz.hex"
avrdude: writing flash (65536 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 65536 bytes of flash written
avrdude: verifying flash memory against C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega64/optiboot_flash_atmega64_115200_16MHz.hex:
avrdude: load data flash data from input file C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega64/optiboot_flash_atmega64_115200_16MHz.hex:
avrdude: input file C:\Users\Mehdi\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega64/optiboot_flash_atmega64_115200_16MHz.hex contains 65536 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% -0.00s
avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0xfd00
0xff != 0x09
avrdude: verification error; content mismatch
avrdude done. Thank you.
Error while burning bootloader.`
from megacore.
Have you tried using an other programmer? I've experienced some issues with the USBasp. The USBtinyISP works just fine
from megacore.
Please try the 1MHz option also. Does this option return the same error?
from megacore.
Yes, I tried 1Mhz option, and returns same error.
from megacore.
Have you tried using an other programmer? I've experienced some issues with the USBasp. The USBtinyISP works just fine
from megacore.
I'm actually able to reproduce this exact error using my own USBasp. Personally I prefer to use the USBtinyISP (~3$) instead. It's ALWAYS working, and I'll never experienced any issues with it. I've had several issues with the USBasp, and that's why I rarely use it when burning fuses, uploading bootloader or using AVRdude in general 😉
TL;DR
There is an issue with the USBasp, and nothing I can do about it. I suggest you try another programmer
from megacore.
I have same error with USBTinyISP:
C:\Arduino\hardware\tools\avr/bin/avrdude -CC:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf -v -patmega128 -cusbtiny -e -Ulock:w:0x3f:m -Uefuse:w:0xff:m -Uhfuse:w:0xc6:m -Ulfuse:w:0xbf:m
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf"
Using Port : usb
Using Programmer : usbtiny
avrdude: usbdev_open(): Found USBtinyISP, bus:device: bus-0:.\libusb0-0001--0x1781-0x0c9f
AVR Part : ATmega128
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PA0
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 12 64 0 no 4096 8 0 9000 9000 0xff 0xff
flash 33 6 128 0 yes 131072 256 512 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
efuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
lock 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : USBtiny
Description : USBtiny simple USB programmer, http://www.ladyada.net/make/usbtinyisp/
avrdude: programmer operation not supported
avrdude: Using SCK period of 10 usec
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.01s
avrdude: Device signature = 0x1e9702
avrdude: erasing chip
avrdude: Using SCK period of 10 usec
avrdude: reading input file "0x3f"
avrdude: writing lock (1 bytes):
C:\Arduino\hardware\tools\avr/bin/avrdude -CC:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf -v -patmega128 -cusbtiny -Uflash:w:C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega128/optiboot_flash_atmega128_115200_16MHz.hex:i -Ulock:w:0x0f:m
avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/avrdude.conf"
Using Port : usb
Using Programmer : usbtiny
avrdude: usbdev_open(): Found USBtinyISP, bus:device: bus-0:.\libusb0-0001--0x1781-0x0c9f
AVR Part : ATmega128
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PA0
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 12 64 0 no 4096 8 0 9000 9000 0xff 0xff
flash 33 6 128 0 yes 131072 256 512 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
efuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
lock 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : USBtiny
Description : USBtiny simple USB programmer, http://www.ladyada.net/make/usbtinyisp/
avrdude: programmer operation not supported
avrdude: Using SCK period of 10 usec
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of lock written
avrdude: verifying lock memory against 0x3f:
avrdude: load data lock data from input file 0x3f:
avrdude: input file 0x3f contains 1 bytes
avrdude: reading on-chip lock data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of lock verified
avrdude: reading input file "0xff"
avrdude: writing efuse (1 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of efuse written
avrdude: verifying efuse memory against 0xff:
avrdude: load data efuse data from input file 0xff:
avrdude: input file 0xff contains 1 bytes
avrdude: reading on-chip efuse data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of efuse verified
avrdude: reading input file "0xc6"
avrdude: writing hfuse (1 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of hfuse written
avrdude: verifying hfuse memory against 0xc6:
avrdude: load data hfuse data from input file 0xc6:
avrdude: input file 0xc6 contains 1 bytes
avrdude: reading on-chip hfuse data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of hfuse verified
avrdude: reading input file "0xbf"
avrdude: writing lfuse (1 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 1 bytes of lfuse written
avrdude: verifying lfuse memory against 0xbf:
avrdude: load data lfuse data from input file 0xbf:
avrdude: input file 0xbf contains 1 bytes
avrdude: reading on-chip lfuse data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: 1 bytes of lfuse verified
avrdude done. Thank you.
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.01s
avrdude: Device signature = 0x1e9702
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: Using SCK period of 10 usec
avrdude: reading input file "C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega128/optiboot_flash_atmega128_115200_16MHz.hex"
avrdude: writing flash (131072 bytes):
Writing | ################################################## | 100% 0.00s
avrdude: 131072 bytes of flash written
avrdude: verifying flash memory against C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega128/optiboot_flash_atmega128_115200_16MHz.hex:
avrdude: load data flash data from input file C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega128/optiboot_flash_atmega128_115200_16MHz.hex:
avrdude: input file C:\Users\Mehdi.BARNAMENEVIS.000\AppData\Local\Arduino15\packages\MegaCore\hardware\avr\1.0.3/bootloaders/optiboot_flash/atmega128/optiboot_flash_atmega128_115200_16MHz.hex contains 131072 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 0.00s
avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x1fc00
0xff != 0x01
avrdude: verification error; content mismatch
avrdude done. Thank you.
Error while burning bootloader.
from megacore.
And here is schematic of my board, if it helps.
from megacore.
Yes, the USBtinyISP doesn't officially support chips larger than 64kB. I suggested that one because you used the ATmega64 in your previous post. I get the exact same error as you with the USBtinyISP and the ATmega128, but the bootloader is still working. If you attach an LED to PB5 you'll see that it's flashing twice every seconds or so, indicating that the bootloader is running
from megacore.
I'm having the same problem with my USBtinyISP. It worked great for about a year and then one day it started giving verification errors on every board that I own. I tried a new ICSP cable, a different PC, several Arduino boards and it consistently corrupts flash (verification errors!). The board seems to work fine as far as my PC is concerned. I've ordered another USBtinyISP, hopefully this next one will last longer than the first.
from megacore.
I just installed the bootloader with the USBtinyISP. It gave me the error but then uploading the firmware via USB worked. That mean it has installed the bootloader properly.
from megacore.
Related Issues (20)
- ATmega 128 I2C doesn't work HOT 2
- Incorrect clock timing HOT 1
- How to wake up from sleep using WDT reset? (atmega64) HOT 3
- arduino framework does'nt work on ATmega128 HOT 2
- Trouble uploading sketch to Arduino Mega2560 after burning bootloader HOT 1
- unable to burn bootloader for mega2560 HOT 40
- stk500v2 bootloader potential issues HOT 4
- To adopt urboot for MegaCore HOT 2
- Is it possible to program with FT232 programming? Is there a schematic drawing available? HOT 5
- Customizable LED_BUILTIN HOT 4
- Arduino Mega OTEthernet not working HOT 6
- generation of the file .hex HOT 11
- cannot be compiled when using the Wire library HOT 5
- Cannot upload sketch to mega without bootloader using arduinoISP HOT 5
- Original Mega 2560 bootloader HOT 4
- Doesn't work on arduino mega 2560 (clone) HOT 2
- ArduinoOTA problems on Mega2560 using Megacore >= 3 HOT 2
- Erase bootloader
- Support for multiple UARTs at same time?
- ATmega64a serial upload problem HOT 13
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from megacore.