1a427f265cXmega page erase implementation for JTAGICEmkII * jtagmkII.c: Handle flash pages sizes > 256 bytes, implement page_erase() method * avrdude.conf.in: Change flash pagesize for all Xmega devices to 512 bytes * avr.c: Implement auto_erase, using page_erase if available * avr.h: Remove unused parameters from avr_read(), replace unused parameter in avr_write)() by auto_erase * stk500v2.c: Handle flash page sizes > 256 bytes * update.c (do_op): Handle new updateflags parameter * main.c: Implement auto_erase as page_erase if possible * update.h (enum updateflags): New enum * pgm.h (struct programmer_t): Add page_erase method
Joerg Wunsch
2012-05-04 10:02:30 +00:00
36ca4dce5cFix for previous fix: add memtype for "flash".
Joerg Wunsch
2012-04-26 11:01:19 +00:00
61c41f321dFix for previous fix: add memtype for "flash".
Joerg Wunsch
2012-04-26 11:01:19 +00:00
f2f59a2d2e* jtagmkII.c (jtagmkII_paged_load, jtagmkII_paged_write): fix bug in memory type calculation for Xmega "boot" memory region.
Joerg Wunsch
2012-04-26 10:57:09 +00:00
1e9003943e* jtagmkII.c (jtagmkII_paged_load, jtagmkII_paged_write): fix bug in memory type calculation for Xmega "boot" memory region.
Joerg Wunsch
2012-04-26 10:57:09 +00:00
c4bcc20e07* update.c (parse_op): do not assume default memtype here * main.c: after locating the part information, determine default memtype for all update options that didn't have a memtype specified; this is "application" for Xmega parts, and "flash" for everything else.
Joerg Wunsch
2012-04-25 16:32:23 +00:00
2616b4663d* update.c (parse_op): do not assume default memtype here * main.c: after locating the part information, determine default memtype for all update options that didn't have a memtype specified; this is "application" for Xmega parts, and "flash" for everything else.
Joerg Wunsch
2012-04-25 16:32:23 +00:00
0bda6f26d1* fileio.c: Rework the way ELF file sections are considered: while scanning the program header table, the offsets from a program header entry must never be used directly when checking the bounds of the current AVR memory region. Instead, they must always be checked based on the corresponding section's entry. That way, Xmega devices now properly take into account whether the segment fits into any of the application/apptable/boot memory region.
Joerg Wunsch
2012-04-24 15:41:02 +00:00
1ee3bad56f* fileio.c: Rework the way ELF file sections are considered: while scanning the program header table, the offsets from a program header entry must never be used directly when checking the bounds of the current AVR memory region. Instead, they must always be checked based on the corresponding section's entry. That way, Xmega devices now properly take into account whether the segment fits into any of the application/apptable/boot memory region.
Joerg Wunsch
2012-04-24 15:41:02 +00:00
2343e419d3bug #30756: When setting SUT to 64ms on XMEGA, avrdude doesn't read device signature * main.c: When reading the signature yields 0x000000 or 0xffffff, retry (up to twice) after some progressive delay.
Joerg Wunsch
2012-04-20 12:33:15 +00:00
258caa132fbug #30756: When setting SUT to 64ms on XMEGA, avrdude doesn't read device signature * main.c: When reading the signature yields 0x000000 or 0xffffff, retry (up to twice) after some progressive delay.
Joerg Wunsch
2012-04-20 12:33:15 +00:00
973e615dbe* avrdude.conf.in (ATxmega16D4, ATxmega32D4, ATxmega64D4, ATxmega128D4): New devices. As Xmega D doesn't feature a fuse0 memory cell, move that one out from the generic .xmega part into the individual Xmega A parts.
Joerg Wunsch
2012-04-20 11:03:51 +00:00
bc4a31e7c3* avrdude.conf.in (ATxmega16D4, ATxmega32D4, ATxmega64D4, ATxmega128D4): New devices. As Xmega D doesn't feature a fuse0 memory cell, move that one out from the generic .xmega part into the individual Xmega A parts.
Joerg Wunsch
2012-04-20 11:03:51 +00:00
269bb7e2a4bug #29019: pagel/bs2 warning when uploading using stk500 to xmega * stk500.c (stk500_initialize): Insert dummy values for PAGEL and BS2 if they are not present in the config file, in order to be able to proceed with the stk500_set_extended_parms() anyway.
Joerg Wunsch
2012-04-19 13:59:09 +00:00
229c4d9237bug #29019: pagel/bs2 warning when uploading using stk500 to xmega * stk500.c (stk500_initialize): Insert dummy values for PAGEL and BS2 if they are not present in the config file, in order to be able to proceed with the stk500_set_extended_parms() anyway.
Joerg Wunsch
2012-04-19 13:59:09 +00:00
f4db29d983* stk500v2_private.h (struct pdata): add boot_start * stk500v2.c: For the "flash" pseudo-memory of Xmega devices, distinguish addresses between "application" and "boot" area.
Joerg Wunsch
2012-04-19 13:32:34 +00:00
c215c7c574* stk500v2_private.h (struct pdata): add boot_start * stk500v2.c: For the "flash" pseudo-memory of Xmega devices, distinguish addresses between "application" and "boot" area.
Joerg Wunsch
2012-04-19 13:32:34 +00:00
c1a5d32c87* fileio.c (elf2b): When checking the bounds of the current program header segment, subtract `low' from ph[n].p_paddr in order to correct the magic section offsets for the AVR's non-flash memory regions.
Joerg Wunsch
2012-04-18 16:00:21 +00:00
3d7d68054f* fileio.c (elf2b): When checking the bounds of the current program header segment, subtract `low' from ph[n].p_paddr in order to correct the magic section offsets for the AVR's non-flash memory regions.
Joerg Wunsch
2012-04-18 16:00:21 +00:00
f8e99df355* fileio.c (elf_get_scn): Rather than trying to just match whether any given section maps straight to a program header segment, use a more sophisticated decision that matches any section as long as it fits into the segment. This is needed for situations where the program header segment spans a larger area than the section data provided. (This can e.g. happen in an ELF file that contains no data at address 0, like a bootloader only.)
Joerg Wunsch
2012-04-18 15:47:57 +00:00
39cdc50871* fileio.c (elf_get_scn): Rather than trying to just match whether any given section maps straight to a program header segment, use a more sophisticated decision that matches any section as long as it fits into the segment. This is needed for situations where the program header segment spans a larger area than the section data provided. (This can e.g. happen in an ELF file that contains no data at address 0, like a bootloader only.)
Joerg Wunsch
2012-04-18 15:47:57 +00:00
3a4b48b583bug #28744: Can't load bootloader to xmega128a1 (part 2, fix for firmware >= V7.x) * jtagmkII.c: Add firmware-version dependent handling of Xmega parameters. V7.x firmware expects the NVM offsets being specified through the Xmega parameters command, but left out as part of the memory address itself. * jtagmkII_private.h: Add CMND_SET_XMEGA_PARAMS, and struct xmega_device_desc. * config_gram.y: Add mcu_base keyword. * avrpart.h: (Dito.) * lexer.l: (Dito.) * avrdude.conf.in (.xmega): add mcu_base, and data memory segment.
Joerg Wunsch
2012-04-13 15:25:41 +00:00
841f1bdac6bug #28744: Can't load bootloader to xmega128a1 (part 2, fix for firmware >= V7.x) * jtagmkII.c: Add firmware-version dependent handling of Xmega parameters. V7.x firmware expects the NVM offsets being specified through the Xmega parameters command, but left out as part of the memory address itself. * jtagmkII_private.h: Add CMND_SET_XMEGA_PARAMS, and struct xmega_device_desc. * config_gram.y: Add mcu_base keyword. * avrpart.h: (Dito.) * lexer.l: (Dito.) * avrdude.conf.in (.xmega): add mcu_base, and data memory segment.
Joerg Wunsch
2012-04-13 15:25:41 +00:00
df6f97d78cbug #28744: Can't load bootloader to xmega128a1 (part 1, fix for firmware < V7.x) * jtagmkII.c: When going to write to the boot section of flash, use MTYPE_BOOT_FLASH rather than MTYPE_FLASH * jtagmkII_private.h: add MTYPE_BOOT_FLASH constant
Joerg Wunsch
2012-03-30 16:19:13 +00:00
f9c8307273bug #28744: Can't load bootloader to xmega128a1 (part 1, fix for firmware < V7.x) * jtagmkII.c: When going to write to the boot section of flash, use MTYPE_BOOT_FLASH rather than MTYPE_FLASH * jtagmkII_private.h: add MTYPE_BOOT_FLASH constant
Joerg Wunsch
2012-03-30 16:19:13 +00:00
8074c2539fSort commands, response codes and events into numerical order.
Joerg Wunsch
2012-03-30 14:03:38 +00:00
7bf57779e0Sort commands, response codes and events into numerical order.
Joerg Wunsch
2012-03-30 14:03:38 +00:00
0025747234bug #30451: Accessing some Xmega memory sections gives not supported error * stk500v2.c: Handle all Xmega memory sections (except "prodsig" which is not documented in AVR079) * fileio.c: Treat the "boot", "application", and "apptable" regions (which are actually subregions of "flash") all as being flash, i.e. suppress trailing 0xFF bytes when reading them * avr.c: (Dito.)
Joerg Wunsch
2012-03-29 14:32:18 +00:00
566adf1e2dbug #30451: Accessing some Xmega memory sections gives not supported error * stk500v2.c: Handle all Xmega memory sections (except "prodsig" which is not documented in AVR079) * fileio.c: Treat the "boot", "application", and "apptable" regions (which are actually subregions of "flash") all as being flash, i.e. suppress trailing 0xFF bytes when reading them * avr.c: (Dito.)
Joerg Wunsch
2012-03-29 14:32:18 +00:00
d3a655ae58Shesh. The previous commit was a little premature. Drag the "GO" code in again, but only activate it when programming an Xmega device through PDI.
Joerg Wunsch
2012-03-20 14:42:20 +00:00
6f5273657aShesh. The previous commit was a little premature. Drag the "GO" code in again, but only activate it when programming an Xmega device through PDI.
Joerg Wunsch
2012-03-20 14:42:20 +00:00
229b7cd075* jtagmkII.c (jtagmkII_close): The GO command before signing off turned out to do more harm than good; on the Xmega, it caused exactly the opposite reaction, the CPU stopped. Even without it, after the RESET command, the target is running already. So, drop the GO.
Joerg Wunsch
2012-03-20 14:21:33 +00:00
b30793d6fa* jtagmkII.c (jtagmkII_close): The GO command before signing off turned out to do more harm than good; on the Xmega, it caused exactly the opposite reaction, the CPU stopped. Even without it, after the RESET command, the target is running already. So, drop the GO.
Joerg Wunsch
2012-03-20 14:21:33 +00:00
19b0f84db1Print a configuration summary at the end of the configure run.
Joerg Wunsch
2012-03-20 14:13:18 +00:00
71e9429f1aPrint a configuration summary at the end of the configure run.
Joerg Wunsch
2012-03-20 14:13:18 +00:00
165d526d98patch #7718: Merge global data of avrftdi in a private data structure * avrftdi.[ch]: moved global data into private data structure, moved private defines from header file into source file
Rene Liebscher
2012-02-11 19:55:22 +00:00
2caa743379patch #7718: Merge global data of avrftdi in a private data structure * avrftdi.[ch]: moved global data into private data structure, moved private defines from header file into source file
Rene Liebscher
2012-02-11 19:55:22 +00:00
e28f48d296patch #7720 Bug in EEPROM write * avrftdi.c: fixed wrong buffer address initialization in paged_write
Rene Liebscher
2012-02-06 19:41:36 +00:00
3ff232b966patch #7720 Bug in EEPROM write * avrftdi.c: fixed wrong buffer address initialization in paged_write
Rene Liebscher
2012-02-06 19:41:36 +00:00
f92e91d08ebug #30559 Ft232 bit-bang support * ft245r.c: cancel reader thread before exiting program
Rene Liebscher
2012-02-05 19:58:59 +00:00
4c71539cf1bug #30559 Ft232 bit-bang support * ft245r.c: cancel reader thread before exiting program
Rene Liebscher
2012-02-05 19:58:59 +00:00
10c078e7f3patch #7717 avrftdi_flash_write is broken * avrftdi.c: fixed wrong buffer address initialization in paged_write bug #35296 Extraneous newlines in output. * main.c: fixed output of newlines at 100% progress
Rene Liebscher
2012-02-04 16:43:37 +00:00
f639ccc9a6patch #7717 avrftdi_flash_write is broken * avrftdi.c: fixed wrong buffer address initialization in paged_write bug #35296 Extraneous newlines in output. * main.c: fixed output of newlines at 100% progress
Rene Liebscher
2012-02-04 16:43:37 +00:00
583ce458f9patch #7714 Missing stdint.h include in ft245r.c
Rene Liebscher
2012-02-03 21:49:45 +00:00
37e0f0e0b1patch #7714 Missing stdint.h include in ft245r.c
Rene Liebscher
2012-02-03 21:49:45 +00:00
3c374a8b3dpatch #7687: Autogenerating programmers and parts lists for docs (generating the programmers lists) * doc/avrdude.texi: Add include of generated table of programmers * doc/Makefile.am: Add generating of table of programmers in programmers.texi
Rene Liebscher
2012-02-03 20:23:32 +00:00
576c41605cpatch #7687: Autogenerating programmers and parts lists for docs (generating the programmers lists) * doc/avrdude.texi: Add include of generated table of programmers * doc/Makefile.am: Add generating of table of programmers in programmers.texi
Rene Liebscher
2012-02-03 20:23:32 +00:00
229abf6f7bbug #34768 Proposition: Change the name of the AVR32 devices * avrdude.conf.in: renamed ucr2 to uc3a0512 * avrpart.c: added cast to avoid compiler warning
Rene Liebscher
2012-02-03 20:07:54 +00:00
6e88b88505bug #34768 Proposition: Change the name of the AVR32 devices * avrdude.conf.in: renamed ucr2 to uc3a0512 * avrpart.c: added cast to avoid compiler warning
Rene Liebscher
2012-02-03 20:07:54 +00:00
7fa0f7146aMention we can read ELF files now.
Joerg Wunsch
2012-02-03 08:35:59 +00:00
1a97b41cb8Mention we can read ELF files now.
Joerg Wunsch
2012-02-03 08:35:59 +00:00
a74cd4d03dFix a copy'n-paste-o.
Joerg Wunsch
2012-02-03 08:34:39 +00:00
6dc51ef1beFix a copy'n-paste-o.
Joerg Wunsch
2012-02-03 08:34:39 +00:00
c4c6734f16Move par_desc[] to end of file, outside the #if HAVE_PARPORT.
Joerg Wunsch
2012-02-03 07:21:39 +00:00
2e0129c1f1Move par_desc[] to end of file, outside the #if HAVE_PARPORT.
Joerg Wunsch
2012-02-03 07:21:39 +00:00
bc83547bf1Sort new filename entries into alphabetical order.
Joerg Wunsch
2012-02-02 19:29:34 +00:00
8304b149a3Sort new filename entries into alphabetical order.
Joerg Wunsch
2012-02-02 19:29:34 +00:00
86ad524ea2Implement ELF file reading (finally). Requires libelf(3) to be present on the host system.
Joerg Wunsch
2012-02-02 16:52:45 +00:00
ab116c9ef7Implement ELF file reading (finally). Requires libelf(3) to be present on the host system.
Joerg Wunsch
2012-02-02 16:52:45 +00:00
7240bbec2fbug #30559 Ft232 bit-bang support * ft245r.[ch]: new programmer type implementation * configure.ac: add pthread as link library * avrdude.conf.in: added some new programmers * Makefile.am: added new source files to compile * pindefs.h: change PIN_MASK, PIN_INVERSE to highest bit of unsigned int * pgm.[ch]: added generic function to print pin assignments (taken from par.c) * par.c: moved pin assigment print function to pgm.c
Rene Liebscher
2012-02-01 22:26:58 +00:00
9f8d07859bbug #30559 Ft232 bit-bang support * ft245r.[ch]: new programmer type implementation * configure.ac: add pthread as link library * avrdude.conf.in: added some new programmers * Makefile.am: added new source files to compile * pindefs.h: change PIN_MASK, PIN_INVERSE to highest bit of unsigned int * pgm.[ch]: added generic function to print pin assignments (taken from par.c) * par.c: moved pin assigment print function to pgm.c
Rene Liebscher
2012-02-01 22:26:58 +00:00
058a3b9dab* config_gram.y, lexer.l: removed unused ID/TKN_ID definitions * config.[hc]: removed unused function id(), use value.type to select values
Rene Liebscher
2012-01-31 19:28:01 +00:00
78caacd7cc* config_gram.y, lexer.l: removed unused ID/TKN_ID definitions * config.[hc]: removed unused function id(), use value.type to select values
Rene Liebscher
2012-01-31 19:28:01 +00:00
fa5e2bb849patch #7437 modifications to Bus Pirate module patch #7686 Updating buspirate ascii mode to current firmware, use AUX as clock generator, and setting of serial receive timeout * buspirate.c: added paged_write, changed binary mode setup/detection, added clock output on AUX pin * avrdude.1: updated documentation * doc/avrdude.texi: updated documentation
Rene Liebscher
2012-01-31 19:01:00 +00:00
c535035a57patch #7437 modifications to Bus Pirate module patch #7686 Updating buspirate ascii mode to current firmware, use AUX as clock generator, and setting of serial receive timeout * buspirate.c: added paged_write, changed binary mode setup/detection, added clock output on AUX pin * avrdude.1: updated documentation * doc/avrdude.texi: updated documentation
Rene Liebscher
2012-01-31 19:01:00 +00:00
c1095de822Parser does not need to know all programmer types now, new programmers will update only the table in pgm_type.c. * config_gram.y, lexer.l: removed programmer type keywords, use now locate_programmer_type() function * pgm_type.[ch]: added new files for table of programmer types * main.c: allow list of programmer types by -c ?type * avrdude.conf.in: changed all type keywords to quoted strings * doc/avrdude.texi: changed description of type definition, list of valid types is now included from generated file * doc/Makefile.am: generate list of programmer types for doc * all programmers [hc]: add xxx_desc string for description of programmer
Rene Liebscher
2012-01-31 17:03:43 +00:00
08365693b8Parser does not need to know all programmer types now, new programmers will update only the table in pgm_type.c. * config_gram.y, lexer.l: removed programmer type keywords, use now locate_programmer_type() function * pgm_type.[ch]: added new files for table of programmer types * main.c: allow list of programmer types by -c ?type * avrdude.conf.in: changed all type keywords to quoted strings * doc/avrdude.texi: changed description of type definition, list of valid types is now included from generated file * doc/Makefile.am: generate list of programmer types for doc * all programmers [hc]: add xxx_desc string for description of programmer
Rene Liebscher
2012-01-31 17:03:43 +00:00
1a154d2fcdBump required autoconf version to 2.60, as AC_PROG_SED requires this.
Joerg Wunsch
2012-01-31 09:52:41 +00:00
25433c4f08Bump required autoconf version to 2.60, as AC_PROG_SED requires this.
Joerg Wunsch
2012-01-31 09:52:41 +00:00
0cbe3c4705* configure.ac: fixed detection of yylex_destroy availability by checking the version number of flex
Rene Liebscher
2012-01-30 20:47:26 +00:00
6ebc317942* configure.ac: fixed detection of yylex_destroy availability by checking the version number of flex
Rene Liebscher
2012-01-30 20:47:26 +00:00
0b92bf9a17Replace the old, now-defunct #define YY_NO_UNPUT by the new %option nounput. This gets rid of a compiler warning, so we are warning-free again.
Joerg Wunsch
2012-01-30 20:31:29 +00:00
90fae5f375Replace the old, now-defunct #define YY_NO_UNPUT by the new %option nounput. This gets rid of a compiler warning, so we are warning-free again.
Joerg Wunsch
2012-01-30 20:31:29 +00:00
a68791b705Add a connection_type attribute to each programmer, rather than trying to hard-code the default port name in main.c.
Joerg Wunsch
2012-01-30 17:08:48 +00:00
793591c158Add a connection_type attribute to each programmer, rather than trying to hard-code the default port name in main.c.
Joerg Wunsch
2012-01-30 17:08:48 +00:00
d02083b738* avrdude.conf.in: used parent parts for some other parts, added abstract .xmega part as parent for xmegas * main.c: hide parts starting with '.' from parts list
Rene Liebscher
2012-01-27 21:14:34 +00:00
a3ac01c572* avrdude.conf.in: used parent parts for some other parts, added abstract .xmega part as parent for xmegas * main.c: hide parts starting with '.' from parts list
Rene Liebscher
2012-01-27 21:14:34 +00:00
d72a56ef01patch #7688: Implement parent programmers feature * avrdude.conf.in: updated documentation comment and some programmers have now parents * config_gram.y: initpgm will now called at first use of programmer in main. parser sets only the function pointer in the pgm structure. Pin and pin lists definitions can now be empty to remove the parents setting. * doc/avrdude.texi: updated documentation * main.c: added call to pgm->initpgm after locate_programmer * pgm.[hc]: added field initpgm in structure, added function pgm_dup
Rene Liebscher
2012-01-22 12:31:54 +00:00
86c30c0cf0patch #7688: Implement parent programmers feature * avrdude.conf.in: updated documentation comment and some programmers have now parents * config_gram.y: initpgm will now called at first use of programmer in main. parser sets only the function pointer in the pgm structure. Pin and pin lists definitions can now be empty to remove the parents setting. * doc/avrdude.texi: updated documentation * main.c: added call to pgm->initpgm after locate_programmer * pgm.[hc]: added field initpgm in structure, added function pgm_dup
Rene Liebscher
2012-01-22 12:31:54 +00:00
0e14a476f5bug #21797: AT90PWM316: New part description * avrdude.conf.in: added pwm316 with parent pwm3b but 16KB flash
Rene Liebscher
2012-01-22 09:24:22 +00:00
381ea18b08bug #21797: AT90PWM316: New part description * avrdude.conf.in: added pwm316 with parent pwm3b but 16KB flash
Rene Liebscher
2012-01-22 09:24:22 +00:00
9250b467f7libusb-win32 recently changed the name of their header file from usb.h to lusb0_usb.h (for whatever reason). Autoprobe for the filename during configure, and include whatever is appropriate.
Joerg Wunsch
2012-01-20 09:39:56 +00:00
b403105824libusb-win32 recently changed the name of their header file from usb.h to lusb0_usb.h (for whatever reason). Autoprobe for the filename during configure, and include whatever is appropriate.
Joerg Wunsch
2012-01-20 09:39:56 +00:00
7c85f6875e* avr.c: Unsigned variable was used for return code of paged_write/load functions. So a negative return code led never to a fallback to byte functions.
Rene Liebscher
2012-01-19 20:06:52 +00:00
af991085ca* avr.c: Unsigned variable was used for return code of paged_write/load functions. So a negative return code led never to a fallback to byte functions.
Rene Liebscher
2012-01-19 20:06:52 +00:00
0a84dcee24bug #34302: Feature request : device configuration with parent classes * config_gram.y: if memory section is overwritten old entry is removed
Rene Liebscher
2012-01-17 20:56:37 +00:00
459aa147e7bug #34302: Feature request : device configuration with parent classes * config_gram.y: if memory section is overwritten old entry is removed
Rene Liebscher
2012-01-17 20:56:37 +00:00
572d3236bf* usbasp.c: USB vid/pid/vendor/product from config file are used, for id "usbasp" nibobee and old usbasp are tried as they were currently implemented within usbasp * avrdude.conf.in: added usb params to "usbasp", added new entry "nibobee" with params which were hardcoded in usbasp.c, and added an entry "usbasb-clone" which only checks vid/pid.
Rene Liebscher
2012-01-17 17:37:23 +00:00
fe7be6301e* usbasp.c: USB vid/pid/vendor/product from config file are used, for id "usbasp" nibobee and old usbasp are tried as they were currently implemented within usbasp * avrdude.conf.in: added usb params to "usbasp", added new entry "nibobee" with params which were hardcoded in usbasp.c, and added an entry "usbasb-clone" which only checks vid/pid.
Rene Liebscher
2012-01-17 17:37:23 +00:00
f39e538c6bbug #35261 avrftdi uses wrong interface in avrftdi_paged_(write|load) * avrftdi.c: Fixed interface and implementation of avrftdi_paged_(write|load) patch #7672 adding support for O-Link (FTDI based JTAG) as programmer * avrdude.conf.in: added o-link entry
Rene Liebscher
2012-01-10 18:19:40 +00:00