mirror of
https://github.com/mariusgreuel/avrdude.git
synced 2025-12-16 02:31:06 +00:00
bug #37942: Latest SVN can't program in dragon_jtag mode
* jtagmkII.c (jtagmkII_initialize): For Xmega devices, and firmware >= 7.x, don't trigger a RESET, in order to work around a firmware bug that appears to be present in at least firmware 7.24 for the Dragon. git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1125 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
18
jtagmkII.c
18
jtagmkII.c
@@ -1435,8 +1435,22 @@ static int jtagmkII_initialize(PROGRAMMER * pgm, AVRPART * p)
|
||||
}
|
||||
PDATA(pgm)->flash_pageaddr = PDATA(pgm)->eeprom_pageaddr = (unsigned long)-1L;
|
||||
|
||||
if (jtagmkII_reset(pgm, 0x01) < 0)
|
||||
return -1;
|
||||
if (PDATA(pgm)->fwver >= 0x700 && (p->flags & AVRPART_HAS_PDI)) {
|
||||
/*
|
||||
* Work around for
|
||||
* https://savannah.nongnu.org/bugs/index.php?37942
|
||||
*
|
||||
* Firmware version 7.24 (at least) on the Dragon behaves very
|
||||
* strange when it gets a RESET request here. All subsequent
|
||||
* responses are completely off, so the emulator becomes unusable.
|
||||
* This appears to be a firmware bug (earlier versions, at least
|
||||
* 7.14, didn't experience this), but by omitting the RESET for
|
||||
* Xmega devices, we can work around it.
|
||||
*/
|
||||
} else {
|
||||
if (jtagmkII_reset(pgm, 0x01) < 0)
|
||||
return -1;
|
||||
}
|
||||
|
||||
if ((pgm->flag & PGM_FL_IS_JTAG) && !(p->flags & AVRPART_HAS_PDI)) {
|
||||
strcpy(hfuse.desc, "hfuse");
|
||||
|
||||
Reference in New Issue
Block a user