diff --git a/src/avrdude.1 b/src/avrdude.1 index 660f21c8..afe180d9 100644 --- a/src/avrdude.1 +++ b/src/avrdude.1 @@ -155,7 +155,7 @@ for the Arduino Uno Rev3 or any AVR that runs the Optiboot bootloader. .Pp Urprotocol is a leaner version of the STK500 1.x protocol that is designed to be backwards compatible with STK500 v1.x, and allows bootloaders to be -much smaller, eg, as implemented in the urboot project +much smaller, e.g., as implemented in the urboot project https://github.com/stefanrueger/urboot. The programmer type ``urclock'' caters for these urboot programmers. Owing to its backward compatibility, bootloaders that can be served by the arduino programmer can normally @@ -338,6 +338,11 @@ and bit-bang programmers. The ATtiny11 can only be programmed in high-voltage serial mode. .El +.It Fl p Ar wildcard/flags +Run developer options for MCUs that are matched by wildcard. Whilst +their main use is for developers some flags can be of utility for users, e.g., +avrdude -p m328p/S outputs AVRDUDE's understanding of ATmega328P MCU properties; +for more information run avrdude -p x/h. .It Fl b Ar baudrate Override the RS-232 connection baud rate specified in the respective programmer's entry of the configuration file. @@ -381,6 +386,11 @@ If -c ? is specified with a specific part, see to be able to handle this part, together with the programming interface(s) that can be used in that combination. In reality there can be deviations from this list, particularly if programming is directly via a bootloader. +.It Fl c Ar wildcard/flags +Run developer options for programmers that are matched by wildcard. Whilst +their main use is for developers some flags can be of utility for users, e.g., +avrdude -c usbtiny/S shows AVRDUDE's understanding of usbtiny's properties; +for more information run avrdude -c x/h. .It Fl C Ar config-file Use the specified config file to load configuration data. This file contains all programmer and part definitions that @@ -867,7 +877,7 @@ or C-style strings and characters. For integers, an optional case-insensitive suffix specifies the data size: HH 8 bit, H/S 16 bit, L 32 bit, LL 64 bit. Suffix D indicates a 64-bit double, F a 32-bit float, whilst a floating point number without suffix defaults to 32-bit float. Hexadecimal floating point -notation is supported. An ambiguous trailing suffix, eg, 0x1.8D, is read as +notation is supported. An ambiguous trailing suffix, e.g., 0x1.8D, is read as no-suffix float where D is part of the mantissa; use a zero exponent 0x1.8p0D to clarify. .Pp @@ -901,7 +911,7 @@ item. Synchronise with the device all pending cached writes to EEPROM or flash. With some programmer and part combinations, flash (and sometimes EEPROM, too) looks like a NOR memory, ie, one can only write 0 bits, not 1 bits. -When this is detected, either page erase is deployed (eg, with parts that +When this is detected, either page erase is deployed (e.g., with parts that have PDI/UPDI interfaces), or if that is not available, both EEPROM and flash caches are fully read in, a chip erase command is issued and both EEPROM and flash are written back to the device. Hence, it can take diff --git a/src/doc/avrdude.texi b/src/doc/avrdude.texi index 0ffb58c0..e9630e90 100644 --- a/src/doc/avrdude.texi +++ b/src/doc/avrdude.texi @@ -290,7 +290,7 @@ below for details. Urprotocol is a leaner version of the STK500 1.x protocol that is designed to be backwards compatible with STK500 v1.x; it allows bootloaders to be -much smaller, eg, as implemented in the urboot project +much smaller, e.g., as implemented in the urboot project @uref{https://github.com/stefanrueger/urboot}. The programmer type ``urclock'' caters for these urboot programmers. Owing to its backward compatibility, bootloaders that can be served by the arduino programmer can normally @@ -444,6 +444,12 @@ from that of other AVRs. Thus, not all programmers support this device. Known to work are all direct bitbang programmers, and all programmers talking the STK500v2 protocol. +@item -p @var{wildcard/flags} +Run developer options for MCUs that are matched by @var{wildcard}. Whilst +their main use is for developers some @var{flags} can be of utility for +users, e.g., @code{avrdude -p m328p/S} outputs AVRDUDE's understanding of +ATmega328P MCU properties; for more information run @code{avrdude -p x/h}. + @item -b @var{baudrate} Override the RS-232 connection baud rate specified in the respective programmer's entry of the configuration file. @@ -484,12 +490,18 @@ programmer ids are understood and supported: @cindex Programmer support -@multitable @columnfractions .2 .6 +@multitable @columnfractions .3 .68 @include programmers.texi @end multitable +@item -c @var{wildcard/flags} +Run developer options for programmers that are matched by @var{wildcard}. +Whilst their main use is for developers some @var{flags} can be of utility +for users, e.g., @code{avrdude -c usbtiny/S} shows AVRDUDE's understanding of +usbtiny's properties; for more information run @code{avrdude -c x/h}. + @item -C @var{config-file} Use the specified config file for configuration data. This file contains all programmer and part definitions that AVRDUDE knows about. @@ -1539,7 +1551,7 @@ suffix specifies the data size as in the table below: Suffix @code{D} indicates a 64-bit double, @code{F} a 32-bit float, whilst a floating point number without suffix defaults to 32-bit float. Hexadecimal -floating point notation is supported. An ambiguous trailing suffix, eg, +floating point notation is supported. An ambiguous trailing suffix, e.g., @code{0x1.8D}, is read as no-suffix float where @code{D} is part of the mantissa; use a zero exponent @code{0x1.8p0D} to clarify. @@ -1577,7 +1589,7 @@ needed. Synchronise with the device all pending cached writes to EEPROM or flash. With some programmer and part combinations, flash (and sometimes EEPROM, too) looks like a NOR memory, ie, one can only write 0 bits, not 1 bits. -When this is detected, either page erase is deployed (eg, with parts that +When this is detected, either page erase is deployed (e.g., with parts that have PDI/UPDI interfaces), or if that is not available, both EEPROM and flash caches are fully read in, a chip erase command is issued and both EEPROM and flash are written back to the device. Hence, it can take @@ -1912,7 +1924,7 @@ programmer desc = ; # quoted string type = ; # programmer type, quoted string # supported types can be listed by "-c ?type" - prog_modes = PM_ @{ | PM_ @} # interfaces, eg, PM_SPM|PM_PDI + prog_modes = PM_ @{ | PM_ @} # interfaces, e.g., PM_SPM|PM_PDI connection_type = parallel | serial | usb | spi baudrate = ; # baudrate for avr910-programmer vcc = [, ... ] ; # pin number(s) @@ -1981,8 +1993,8 @@ The following programmer types are currently implemented: part desc = ; # quoted string id = ; # quoted string - family_id = ; # quoted string, eg, "megaAVR" or "tinyAVR" - prog_modes = PM_ @{| PM_@} # interfaces, eg, PM_SPM|PM_ISP|PM_HVPP|PM_debugWIRE + family_id = ; # quoted string, e.g., "megaAVR" or "tinyAVR" + prog_modes = PM_ @{| PM_@} # interfaces, e.g., PM_SPM|PM_ISP|PM_HVPP|PM_debugWIRE mcuid = ; # unique id in 0..2039 for 8-bit AVRs n_interrupts = ; # number of interrupts, used for vector bootloaders n_page_erase = ; # if set, number of pages erased during SPM erase @@ -2098,7 +2110,7 @@ is used for numerics (except for @code{mcuid}, @code{hvupdi_variant} and which defaults to 0x30) or the empty string @code{""} for string values. If a required parameter is left empty, AVRDUDE will complain. Almost all occurrences of numbers (with the exception of pin numbers and where they -are separated by space, eg, in signature and readback) can also be given +are separated by space, e.g., in signature and readback) can also be given as simple expressions involving arithemtic and bitwise operators. @menu @@ -2121,7 +2133,7 @@ new memory definition refers to an existing one of the same name for that part then, from v7.1, the existing memory definition is extended, and components overwritten with new values. Assigning @code{NULL} removes an inherited SPI instruction format, memory definition, control -stack, eeprom or flash instruction, eg, as in @code{memory "efuse" = +stack, eeprom or flash instruction, e.g., as in @code{memory "efuse" = NULL;} @noindent diff --git a/src/main.c b/src/main.c index 691369cf..22e430d1 100644 --- a/src/main.c +++ b/src/main.c @@ -166,10 +166,12 @@ static void usage(void) "Usage: %s [options]\n" "Options:\n" " -p Specify AVR device\n" + " -p / Run developer options for matched AVR devices\n" " -b Override RS-232 baud rate\n" " -B Specify bit clock period (us)\n" " -C Specify location of configuration file\n" " -c Specify programmer type\n" + " -c / Run developer options for matched programmers\n" " -A Disable trailing-0xff removal from file and AVR read\n" " -D Disable auto erase for flash memory; implies -A\n" " -i ISP Clock Delay [in microseconds]\n"