Commit Graph

2114 Commits

Author SHA1 Message Date
Joerg Wunsch ef621bc443 bug #37768 Poll usbtiny 100 times at init time to handle low-clock devices
Add a FAQ entry describing the method to connect to a device
where the firmware has reduced the internal clock speed.


git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1218 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-12 11:20:03 +00:00
Joerg Wunsch a72d7911e1 bug #28344 chip_erase_delay too short for ATmega324P, 644, 644P, and 1284P
* avrdude.conf: Bump the chip_erase_delay for all ATmega*4 devices
to 55 ms.  While the datasheet still claims 9 ms, all the XML files
tell either 45 or 55 ms, depending on STK600 or not.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1217 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-11 16:27:50 +00:00
Joerg Wunsch e814b615b2 * fileio.c (fileio): Don't exit(1) if something goes wrong; return
-1 instead.  Don't refer to obsolete option -f to specify the file
format.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1216 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-11 09:21:37 +00:00
Joerg Wunsch e5501feb43 Submitted by Matthias Trute:
bug #36901 flashing Atmega32U4 EEPROM produces garbage on chip
* avrdude.conf.in (ATmega32U4): Fix EEPROM pagesize to 4, the
datasheet is wrong here.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1215 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-10 15:58:40 +00:00
Joerg Wunsch 1169e1320f Check for ar and ranlib in the target tool namespace, rather than on
the host.


git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1214 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-09 15:00:36 +00:00
Joerg Wunsch 08fc95eb3e Fix variable spelling.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1213 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-09 05:48:11 +00:00
Joerg Wunsch c0d9de9b67 Fix byte-wise EEPROM and flash writes on Xmega
* jtagmkII_private.h (MTYPE_EEPROM_XMEGA): New memory type.
* jtagmkII.c (jtagmkII_write_byte): For Xmega EEPROM, use
memory type MTYPE_EEPROM_XMEGA; for flash writes, always
write 2 bytes starting on an even address.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1212 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-08 19:57:58 +00:00
Joerg Wunsch 44069c7b69 Implement and document the "verbose" terminal mode command.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1211 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-08 19:31:48 +00:00
Joerg Wunsch ee861c4492 * jtag3.c (jtag3_write_byte): Do not attempt to start the paged
algorithm for EEPROM when being connected through debugWIRE.




git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1210 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-07 20:40:29 +00:00
Joerg Wunsch c137e0ea86 Extend the single-byte algorithm to all devices, both flash and
EEPROM.  (Flash cells must have been erased before though.)
* jtag3.c (jtag3_initialize): OCDEN no longer needs to be
considered; a session with "programming" purpose is sufficient
* jtag3.c (jtag3_write_byte): Use the paged algorithm for all
flash and EEPROM areas, not just Xmega.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1209 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-06 07:06:13 +00:00
Joerg Wunsch 9e2a3a9070 Fix single-byte EEPROM updates on Xmega:
* jtag3_private.h (MTYPE_EEPROM_XMEGA): New define.
* jtag3.c (jtag3_write_byte): When updating flash or
EEPROM on Xmega devices, resort to jtag3_paged_write()
after filling and modifying the page cache.
* jtag3.c (jtag3_paged_write): use MTYPE_EEPROM_XMEGA
where appropriate.
* jtag3.c (jtag3_initialize): Open with debugging intent
for Xmega devices, so single-byte EEPROM updates will
work.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1208 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-05 21:18:01 +00:00
Joerg Wunsch e074890fc0 Submitted by Matthias Neeracher:
bug #38732: Support for ATtiny1634



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1207 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-04 06:36:19 +00:00
Joerg Wunsch 715249e2d4 Submitted by Brane Zdralo:
patch #7769: Write flash fails for AVR910 programmers
* avr910.c (avr910_paged_write): Fix flash addresses in
'A' command.




git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1206 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 21:43:24 +00:00
Joerg Wunsch 0f5af86c9f Submitted by Fred (magister):
bug #38951: AVR109 use byte offset instead of word offset
patch #8045: AVR109 butterfly failing
* butterfly.c (butterfly_paged_load, butterfly_paged_write):
fix calculation of 'A' address when operating on flash memory.
It must be given in terms of 16-bit words rather than bytes.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1205 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 21:24:16 +00:00
Rene Liebscher caa061e18c * avrftdi.c, avrftdi_private.h: added tx buffer size, and use smaller block sizes as larger sometimes hang
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1204 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 20:33:52 +00:00
Joerg Wunsch 8ed6920948 Remove the erase cycle counter (options -y / -Y).
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1203 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 20:13:37 +00:00
Joerg Wunsch 770d26689b bug #39691 Buffer overrun when reading EEPROM byte with JTAGICE3
* jtag3.c (jtag3_initialize): initialize the eeprom_pagesize
private attribute so the page cache will actually be usable



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1202 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 11:58:31 +00:00
Joerg Wunsch 05a952b027 bug #38580 Current svn head, xmega and fuses, all fuses tied to fuse0
* jtag3.c (jtag3_read_byte, jtag3_write_byte): Correctly apply the
relevant part of mem->offset as the address to operate on.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1201 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 11:32:47 +00:00
Joerg Wunsch 6c78b35b8f Fix all "unused variable" warnings that were encountered.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1200 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-03 11:05:13 +00:00
Joerg Wunsch e2a78468d0 Submitted by Travis Griggs:
bug #38307: Can't write usersig of an xmega256a3
* stk500v2.c (stk600_xprog_page_erase): allow erasing the usersig space.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1199 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 21:10:44 +00:00
Joerg Wunsch f051a3a6e0 Submitted by Robert Niemi:
bug #35800: Compilation error on certain systems if parport is disabled
* linux_ppdev.h: Conditionalize inclusion of <linux/parport.h> and
<linux/ppdev.h> on HAVE_PARPORT




git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1198 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 20:53:12 +00:00
Joerg Wunsch 412a7be03e bug #39794: warnings when building avrdude 6.0rc1 under CentOS 6.4
* pickit.c (usb_open_device): Use %p rather than %X to print "handle"
which is a pointer
* jtag3.c (jtag3_initialize): Initialize "flashsize" to be sure it
proceeds with a valid value.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1197 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 20:30:09 +00:00
Joerg Wunsch db1cce8bf4 bug #39794: warnings when building avrdude 6.0rc1 under CentOS 6.4
* buspirate.c: Turn the "cmd" argument of the various methods into
a "const unsigned char *"; while doing this, declare all arrays being
passed as arguments to be pointers rather than arrays, as the latter
obfuscates the way arrays are being passed to a callee in C.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1196 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 20:22:53 +00:00
Joerg Wunsch 51da59044e bug #38023: avrdude doesn't return an error code when attempting
to upload an invalid Intel HEX file
* fileio.c (ihex2b): Turn the "No end of file record found" warning
into an error if no valid record was found at all.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1195 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 18:18:15 +00:00
Joerg Wunsch 088ae8196a Submitted by Claus-Justus Heine:
bug #38713: Compilation of the documentation breaks with texinfo-5
* doc/avrdude.texi: Turn @itemx into @item, add @headitem to STK600
Routing/Socket card table



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1194 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 17:56:01 +00:00
Joerg Wunsch 65aa87c714 Add a missing pair of braces.
Thanks to Joakim Lubeck for spotting this.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1193 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 09:57:09 +00:00
Joerg Wunsch 7750c81463 Add -vvv trace code to the non-TPI functions in USBasp, too.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1192 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-02 06:43:06 +00:00
Joerg Wunsch 56fe49f22a * usbasp.c (usbasp_tpi_paged_load): Calculate correct
buffer address.
* usbasp.c (usbasp_tpi_paged_write): Calculate correct
buffer address; don't issue a SECTION_ERASE command for
each page (a CHIP_ERASE has been done before anyway);
remove the code that attempted to handle partial page
writes, as all writes are now done with a full page.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1191 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-01 20:54:56 +00:00
Joerg Wunsch 6483e65ab1 Add more trace output, by now only to the TPI functions.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1190 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-09-01 20:48:17 +00:00
Joerg Wunsch ab68c47c7f Add -vvvv trace output to usbasp_transmit().
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1189 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-08-31 07:32:18 +00:00
Joerg Wunsch 056b5f6e77 bug #39893: Verification failure with AVRISPmkII and Xmega
* stk500v2.c (stk600_xprog_page_erase): Fix argument that is
passed to stk600_xprog_memtype()



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1188 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-08-30 06:49:40 +00:00
Joerg Wunsch 3879e70713 * fileio.c (elf2b): replace elf_getshstrndx() by
elf_getshdrstrndx() as the former one is deprecated



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1187 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-07-11 21:43:11 +00:00
Rene Liebscher 6f8e643ba0 reverted accidently checked in debug setting
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1186 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-06-20 20:45:12 +00:00
Rene Liebscher 1f8462ca58 check more error codes, fixed some leftover parts which still used MPSSE even when using bitbanging, reduced blocksize to get a more stable behaviour of bitbanging
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1185 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-06-20 20:11:49 +00:00
Rene Liebscher da3961e155 use bitbanging on ftdi mpsse when wrong pins are used
* avrftdi.c, avrftdi_private.h: added additional pin check and bitbanging fallback
	* pindefs.[ch]: added a flag to enable/disable output
	* ft245r.c: changes because of added flag above

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1184 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-06-19 17:40:32 +00:00
Joerg Wunsch 46f7b6b470 Submitted by "Malte" and John McCorquodale:
patch #7876 JTAGICE mkII fails to connect to attiny if debugwire
is enabled AND target has a very slow clock
* jtagmkII.c (jtagmkII_getsync): When leaving debugWIRE mode
temporarily, immediately retry with ISP, rather than leaving.
* stk500v2 (stk500v2_program_enable): Implemented similar logic
for the JTAGICE3.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1183 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-17 16:23:55 +00:00
Joerg Wunsch 203fe6d14a Wrap long lines.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1182 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-17 16:09:55 +00:00
Joerg Wunsch 729ef4df18 Try various compiler names until one succeeds.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1181 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-17 14:02:45 +00:00
Rene Liebscher 22477da39e * configure.ac: reactivate check for TYPE_232H, which does not exist in libftdi < 0.20
* avrftdi*.*: changed include check for libftdi/libusb, deactivate 232H if not available
* ft245r.c: changed include check for libftdi/libusb

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1180 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-16 17:11:35 +00:00
Joerg Wunsch d0625e8fec Add option -l logfile to redirect diagnostic messages to a logfile rather
than stderr.



git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1179 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-16 09:11:32 +00:00
Joerg Wunsch 3756a42db1 Break long lines.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1178 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-16 08:11:19 +00:00
Rene Liebscher 8f9bc91d53 * avrftdi*.*: accept also old libftdi (0.20 still works with it), added powerup to initialize
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1177 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-15 20:05:02 +00:00
Rene Liebscher 0fc17a60a6 removed some debug code from file ft245r.c
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1176 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-15 19:03:58 +00:00
Rene Liebscher 7ff877e067 * configure.ac: if both found libftdi and libftdi1 use only libftdi1
* avrdude.conf.in: fixed buff pins of avrftdi programmers (low active buffer need now inverted numbers)
	* avrftdi*.*: accept also old libftdi (0.20 still works with it), added powerup to initialize
	* ft245r.c: accept libftdi1, code cleanup and make it more similar to avrfdti (os they might be merged someday)

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1175 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-15 18:55:19 +00:00
Joerg Wunsch c65f6cbe6c Add a small script to cross-compile a Win32 binary under Unix.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1174 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-14 20:35:41 +00:00
Joerg Wunsch 6599064e4d Bump version to 6.0rc1.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1173 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-08 17:35:28 +00:00
Joerg Wunsch 55d25c0fe9 Add forgotten avrftdi_private.h.
git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1172 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-08 17:34:00 +00:00
Hannes Weisbach 93e940b60a avrftdi: add pgm->power[up|down], fix pgm->enable|disable
avrftdi.c: add pgm->power[up|down] functions and fill
pgm->enable|disable with proper functionality, as suggested by
rliebscher.

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1171 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-07 08:50:13 +00:00
Hannes Weisbach 26ab40f3a5 avrftdi: apply patch by rliebscher.
Use pin_checklist[] of size N_PINS instead N_PINS - 1, to avoid future
problems. Also remove pins_check from set_pin; instead use mask[0] == 0
to check wether to do something or not.

avrftdi_private.h: Change size of pin_checklist[] to N_PINS.
avrftdi.c: Adapt code to new size of pin_checklist. Remove pins_check
from set_pin.

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1170 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-07 08:50:06 +00:00
Rene Liebscher 4fc72c7d58 * pindefs.h: use unsigned int if stdint.h is not available and UINT_MAX is 0xffffffff
otherwise use unsinged long
* ft245r.c: added support for more pin functions led, vcc, buff

git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1169 81a1dc3b-b13d-400b-aceb-764788c761c2
2013-05-06 19:21:38 +00:00