Skip to content

Commit

Permalink
Add exitspec section and add new -x parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
MCUdude committed Aug 1, 2024
1 parent 6bb8b52 commit 62f808b
Showing 1 changed file with 71 additions and 58 deletions.
129 changes: 71 additions & 58 deletions src/avrdude.1
Original file line number Diff line number Diff line change
Expand Up @@ -500,65 +500,13 @@ case before programming the cell.
.It Xo Fl E Ar exitspec Ns
.Op \&, Ns Ar exitspec
.Xc
By default,
.Nm
leaves the parallel port in the same state at exit as it has been
found at startup. This option modifies the state of the
.Ql /RESET
and
.Ql Vcc
lines the parallel port is left at, according to the
Pass
.Ar exitspec
arguments provided, as follows:
.Bl -tag -width noreset
.It Ar reset
The
.Ql /RESET
signal will be left activated at program exit, that is it will be held
.Em low ,
in order to keep the MCU in reset state afterwards. Note in particular
that the programming algorithm for the AT90S1200 device mandates that
the
.Ql /RESET
signal is active
.Em before
powering up the MCU, so in case an external power supply is used for this
MCU type, a previous invocation of
to the chosen programmer. The interpretation of the exitspec arguments
depends on the programmer itself. See below for a list of programmers
accepting extended parameters or issue
.Nm
with this option specified is one of the possible ways to guarantee this
condition.
.Em reset
is supported by the linuxspi and flip2 programmer options, as well as all
parallel port based programmers.
.It Ar noreset
The
.Ql /RESET
line will be deactivated at program exit, thus allowing the MCU target
program to run while the programming hardware remains connected.
.Em noreset
is supported by the linuxspi and flip2 programmer options, as well as all
parallel port based programmers.
.It Ar vcc
This option will leave those parallel port pins active
.Pq \&i. \&e. Em high
that can be used to supply
.Ql Vcc
power to the MCU.
.It Ar novcc
This option will pull the
.Ql Vcc
pins of the parallel port down at program exit.
.It Ar d_high
This option will leave the 8 data pins on the parallel port active.
.Pq \&i. \&e. Em high
.It Ar d_low
This option will leave the 8 data pins on the parallel port inactive.
.Pq \&i. \&e. Em low
.El
.Pp
Multiple
.Ar exitspec
arguments can be separated with commas.
-E help ... to see the extended options of the chosen programmer.
.It Fl F
Normally,
.Nm
Expand Down Expand Up @@ -828,7 +776,6 @@ of that by erasing pages before programming them unless -e (chip erase) or
-D (do not erase before writing) was requested. It should be noted that in
absence of the -e chip erase option any ATxmega or UPDI flash pages not
affected by the programming will retain their previous content.

.Pp
Classic devices may have the following memories in addition to eeprom, flash, signature and lock:
.Bl -tag -width " calibration" -compact
Expand Down Expand Up @@ -1854,6 +1801,13 @@ original STK500. Used by avrdude for the correct calculation of fosc and sck.
.It Ar help
Show help menu and exit.
.El
.It Ar AVR109
.Bl -tag -offset indent -width indent
.It Ar autoreset
Toggle RTS/DTR lines on port open to issue a hardware reset.
.It Ar help
Show help menu and exit.
.El
.It Ar AVR910
.Bl -tag -offset indent -width indent
.It Ar devcode=VALUE
Expand Down Expand Up @@ -1886,6 +1840,8 @@ Show help menu and exit.
.It Ar attemps[=<1..99>]
Specify how many connection retry attemps to perform before exiting.
Defaults to 10 if not specified.
.It Ar noautoreset
Don't toggle RTS/DTR lines on port open to prevent a hardware reset.
.It Ar help
Show help menu and exit.
.El
Expand Down Expand Up @@ -1984,6 +1940,8 @@ title) and no date either.
On writing to flash do not store metadata except the metadata code byte
0xff saying there are no metadata. In particular, no data store frame is
programmed.
.It Ar noautoreset
Don't toggle RTS/DTR lines on port open to prevent a hardware reset.
.It Ar nometadata
Do not support any metadata. The full flash besides the bootloader is
available for the application. If the application is smaller than the
Expand Down Expand Up @@ -2131,6 +2089,8 @@ Add a <n> milliseconds delay after resetting the part through toggling the
DTR/RTS lines. This can be useful if a board takes a particularly long
time to exit from external reset. <n> can be negative, in which case the
default 100 ms delay after issuing reset will be shortened accordingly.
.It Ar noautoreset
Don't toggle RTS/DTR lines on port open to prevent a hardware reset.
.It Ar help
Show help menu and exit.
.El
Expand Down Expand Up @@ -2213,6 +2173,59 @@ This option allows to choose these additional CSes (1, 2, ...) for programming t
Show help menu and exit.
.El
.El
.Ss Programmers accepting exitspec arguments
Currently, only the flip2, linuxspi and old school parallel port programmers
such as stk200 and dapa support exitspec arguments. These lets the user
decide in which state the programmer pins after ended programming session.
Multiple exitspec arguments can be separated with commas.
.Bl -tag -offset indent -width indent
.It Ar flip2
.It Ar linuxspi
.It Parallel port programmers
.Bl -tag -offset indent -width indent
.It Ar help
Show help menu and exit.
.It Ar reset
The
.Ql /RESET
signal will be left activated at program exit, that is it will be held
.Em low ,
in order to keep the MCU in reset state afterwards. Note in particular
that the programming algorithm for the AT90S1200 device mandates that
the
.Ql /RESET
signal is active
.Em before
powering up the MCU, so in case an external power supply is used for this
MCU type, a previous invocation of
.Nm
with this option specified is one of the possible ways to guarantee this
condition.
.It Ar noreset
The
.Ql /RESET
line will be deactivated at program exit, thus allowing the MCU target
program to run while the programming hardware remains connected.
.El
.It Parallel port programmers
.Bl -tag -offset indent -width indent
.It Ar vcc
This option will leave those parallel port pins active
.Pq \&i. \&e. Em high
that can be used to supply
.Ql Vcc
power to the MCU.
.It Ar novcc
This option will pull the
.Ql Vcc
pins of the parallel port down at program exit.
.It Ar d_high
This option will leave the 8 data pins on the parallel port active.
.Pq \&i. \&e. Em high
.It Ar d_low
This option will leave the 8 data pins on the parallel port inactive.
.Pq \&i. \&e. Em low
.El
.Sh FILES
.Bl -tag -offset indent -width /dev/ppi0XXX
.It Pa /dev/ppi0
Expand Down

0 comments on commit 62f808b

Please sign in to comment.