From d7a6b620a3b148ef86125bba2e6612a766e0d9b9 Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 14:52:40 +0100 Subject: [PATCH 1/7] Fix typos --- src/doc/avrdude.texi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index 847a2928..b5074bc1 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -206,7 +206,7 @@ programmer type can be used to directly connect to and program a chip using the built in interfaces on the computer. The requirements to use this type are that an SPI interface is exposed along with one GPIO pin. The GPIO serves as the reset output since the Linux SPI drivers -do not hold chip select down when a transfer is not occuring and thus +do not hold chip select down when a transfer is not occurring and thus it cannot be used as the reset pin. A readily available level translator should be used between the SPI bus/reset GPIO and the chip to avoid potentially damaging the computer's SPI controller in the @@ -383,7 +383,7 @@ below for details. @cindex CH341A programmer The USBasp ISP, USBtinyISP and CH341A adapters are also supported, provided AVRDUDE has been compiled with libusb support. -They former two feature simple firmware-only USB implementations, running on +The former two feature simple firmware-only USB implementations, running on an ATmega8 (or ATmega88), or ATtiny2313, respectively. CH341A programmers connect directly to the AVR target. Their SPI bit clock is approximately 1.7@w{ }MHz and cannot be changed. As a consequence, the @@ -727,7 +727,7 @@ In absence of an explicit @code{-e} or @code{-D} option avrdude tries to augur from the command line whether or not the chip should be auto-erased at the beginning. If avrdude detects a @code{-U} command that writes to flash then auto-erase will be carried out before any other programming -unless a @code{-T} erase commad has been detected beforehand and unless +unless a @code{-T} erase command has been detected beforehand and unless flash is read before writing to it. For the purpose of this analysis any terminal command is considered to possibly read flash. @@ -5349,7 +5349,7 @@ Windows serial port device names such as: com1, com2, etc. @noindent AVRDUDE does not support parallel port programming in Windows. -If you need to run AVRDUDE using programmer on a parallel port, +If you need to run AVRDUDE using a programmer on a parallel port, you might want to try one of the BSDs or Linux. @ignore From 104814346b4c8a04acf49e1453cb300a27d0a1d9 Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 14:53:28 +0100 Subject: [PATCH 2/7] Update Windows serial ports description --- src/doc/avrdude.texi | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index b5074bc1..e328ad9f 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -5337,8 +5337,16 @@ The directories that are listed in the PATH environment variable. @cindex Windows serial ports @noindent -When you select a serial port (i.e. when using an STK500) use the -Windows serial port device names such as: com1, com2, etc. + +When you select a serial port (i.e. when using an STK500) use the Windows +serial port device names such as: COM1, COM2, etc. If the board in +question uses an USB-serial adapter, or is connected via one, there +are several ways to identify the correct port name: +@itemize @bullet{} +@item In the Windows Device Manager under Ports, then COM & LPT +@item Enquiring @code{avrdude -P "?s"} if compiled with libserialport +@item Use the serial adapter name instead of COMx, e.g., @code{-P ft232r} +@end itemize @c @c Node From 7baf8345635b2eebb706bafee8384a1495f8add2 Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 14:58:17 +0100 Subject: [PATCH 3/7] Fix typo --- src/avrdude.1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/avrdude.1 b/src/avrdude.1 index 0287a21b..21d3a23d 100644 --- a/src/avrdude.1 +++ b/src/avrdude.1 @@ -521,7 +521,7 @@ auto-erased at the beginning. If detects a .Fl U command that writes to flash then auto-erase will be carried out before -any other programming unless a -T erase commad has been detected +any other programming unless a -T erase command has been detected beforehand and unless flash is read before writing to it. For the purpose of this analysis any terminal command is considered to possibly read flash. From c88ca5ac0bbbfb1912aaf276c3b590631bb2019a Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 15:05:06 +0100 Subject: [PATCH 4/7] Document parallel ports are only available in Linux/BSD --- src/avrdude.1 | 12 ++++++------ src/doc/avrdude.texi | 37 ++++++++++++++++++------------------- 2 files changed, 24 insertions(+), 25 deletions(-) diff --git a/src/avrdude.1 b/src/avrdude.1 index 21d3a23d..56d8d7e1 100644 --- a/src/avrdude.1 +++ b/src/avrdude.1 @@ -63,8 +63,8 @@ supports Atmel's STK500 programmer, Atmel's AVRISP and AVRISP mkII devices, Atmel's STK600, Atmel's JTAG ICE (mkI, mkII and 3, the latter two also in ISP mode), -programmers complying to AppNote AVR910 and AVR109 (including the Butterfly), -as well as a simple hard-wired +programmers complying to AppNote AVR910 and AVR109 (including the Butterfly) +as well as, on Linux or BSD systems, a simple hard-wired programmer connected directly to a .Xr ppi 4 or @@ -598,14 +598,14 @@ Note that the result will be stored in the EEPROM cell at address 0. Use .Ar port to identify the connection through which the programmer is attached. This -can be a parallel, serial, spi or linuxgpio connection. The programmer -normally specifies the connection type; in absence of a -P specification, +can be a serial, spi, linuxgpio or, on Linux or BSD systems, a parallel connection. +The programmer normally specifies the connection type; in absence of -P, system-dependent default values -.Pa default_parallel , .Pa default_serial , .Pa default_spi , -or .Pa default_linuxgpio +or +.Pa default_parallel from the configuration file are used. If you need to use a different port, use this option to specify the alternate port name. .Pp diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index e328ad9f..f88b2e22 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -164,19 +164,17 @@ needing to have, or connect, a real physical programmer. Similarly, without connecting an AVR part. AVRDUDE supports the following basic programmer types: Atmel's STK500, -Atmel's AVRISP and AVRISP mkII devices, -Atmel's STK600, -Atmel's JTAG ICE (the original one, mkII, and 3), appnote -avr910, appnote avr109 (including the AVR Butterfly), -serial bit-bang adapters, -and the PPI (parallel port interface). PPI represents a class -of simple programmers where the programming lines are directly -connected to the PC parallel port. Several pin configurations exist -for several variations of the PPI programmers, and AVRDUDE can be -configured to work with them by either specifying the appropriate -programmer on the command line or by creating a new entry in its -configuration file. All that's usually required for a new entry is to -tell AVRDUDE which pins to use for each programming function. +Atmel's AVRISP and AVRISP mkII devices, Atmel's STK600, Atmel's JTAG ICE +(the original one, mkII, and 3), appnote avr910, appnote avr109 (including +the AVR Butterfly), serial bit-bang adapters, and, on Linux and BSD +systems, the PPI (parallel port interface). PPI represents a class of +simple programmers where the programming lines are directly connected to +the PC parallel port. Several pin configurations exist for several +variations of the PPI programmers, and AVRDUDE can be configured to work +with them by either specifying the appropriate programmer on the command +line or by creating a new entry in its configuration file. All that's +usually required for a new entry is to tell AVRDUDE which pins to use for +each programming function. A number of equally simple bit-bang programming adapters that connect to a serial port are supported as well, among them the popular @@ -831,12 +829,13 @@ Note that the result will be stored in the EEPROM cell at address 0. @cindex @code{-P} @var{port} @cindex @code{--port} @var{port} Use @var{port} to identify the connection through which the programmer is -attached. This can be a parallel, serial, spi or linuxgpio connection. The -programmer normally specifies the connection type; in absence of a @code{-P} -specification, system-dependent default values @code{default_parallel}, -@code{default_serial}, @code{default_spi}, or @code{default_linuxgpio} from -the configuration file are used. If you need to use a different port, use this -option to specify the alternate port name. +attached. This can be a serial, spi, linuxgpio or, on a Linux or BSD +system, parallel connection. The programmer normally specifies the +connection type; in absence of a @code{-P} specification, system-dependent +default values @code{default_serial}, @code{default_spi}, +@code{default_linuxgpio} or @code{default_parallel} from the configuration +file are used. If you need to use a different port, use this option to +specify the alternate port name. USB-only programmers normally do not need the port option be specified as they are automatically identified via their vendor and product IDs from From 1cc8dde0236f795b3b38a4ec5d1f4deb44b82a0c Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 15:11:50 +0100 Subject: [PATCH 5/7] Update troubleshooting entries --- src/doc/avrdude.texi | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index f88b2e22..eb70c31c 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -5671,24 +5671,11 @@ Problem: My ATxmega@dots{}A1/A2/A3 cannot be programmed through PDI with my AVR Dragon. Programming through a JTAG ICE mkII works though, as does programming through JTAG. -Solution: None by this time (2010 Q1). +Solution: None (may be a firmware issue of the AVR Dragon). It is said that the AVR Dragon can only program devices from the A4 Xmega sub-family. -@item -Problem: when programming with an AVRISPmkII or STK600, AVRDUDE hangs -when programming files of a certain size (e.g. 246 bytes). Other -(larger or smaller) sizes work though. - -Solution: This is a bug caused by an incorrect handling of zero-length -packets (ZLPs) in some versions of the libusb 0.1 API wrapper that ships -with libusb 1.x in certain Linux distributions. All Linux systems with -kernel versions < 2.6.31 and libusb >= 1.0.0 < 1.0.3 are reported to be -affected by this. - -See also: @url{http://www.libusb.org/ticket/6} - @item Problem: after flashing a firmware that reduces the target's clock speed (e.g. through the @code{CLKPR} register), further ISP connection From 9dfd785154d4f30b314e52481577727b20d46675 Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 15:14:30 +0100 Subject: [PATCH 6/7] Remove reference to outdated kolev.info site --- src/avrdude.1 | 3 +-- src/doc/avrdude.texi | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/avrdude.1 b/src/avrdude.1 index 56d8d7e1..eb2c4fce 100644 --- a/src/avrdude.1 +++ b/src/avrdude.1 @@ -112,8 +112,7 @@ be taken about voltage level compatibility. Also, although not strictly required, it is strongly advisable to protect the GPIO pins from overcurrent situations in some way. The simplest would be to just put some resistors in series or better yet use a 3-state buffer driver like -the 74HC244. Have a look at https://kolev.info/blog/2013/01/06/avrdude-linuxgpio/ for a more -detailed tutorial about using this programmer type. +the 74HC244. .Pp Under a Linux installation with direct access to the SPI bus and GPIO pins, such as would be found on a Raspberry Pi, the ``linuxspi'' diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index eb70c31c..68b7fe1e 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -194,9 +194,7 @@ be taken about voltage level compatibility. Also, although not strictly required, it is strongly advisable to protect the GPIO pins from overcurrent situations in some way. The simplest would be to just put some resistors in series or better yet use a 3-state buffer driver like -the 74HC244. Have a look at -@url{https://kolev.info/blog/2013/01/06/avrdude-linuxgpio/} for a more -detailed tutorial about using this programmer type. +the 74HC244. Under a Linux installation with direct access to the SPI bus and GPIO pins, such as would be found on a Raspberry Pi, the ``linuxspi'' From 5cefd01635c37a40ad1fa11cd66e73925be01469 Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Sun, 14 Jun 2026 15:19:17 +0100 Subject: [PATCH 7/7] Qualify savannah.org as read-only --- src/doc/avrdude.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index 68b7fe1e..773da2fe 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -456,7 +456,7 @@ name did not conflict with AVRPROG.EXE which is the name of Atmel's Windows programming software. For many years, the AVRDUDE source resided in public repositories on -savannah.nongnu.org, +the now read-only savannah.nongnu.org, where it continued to be enhanced and ported to other systems. In addition to FreeBSD, AVRDUDE now runs on Linux, macOS and Windows. The developers behind the porting effort primarily were Ted Roth, Eric