📄 avrdude.texi
字号:
%% -*-texinfo-*-\input texinfo@c $Id: avrdude.texi,v 1.37 2005/09/18 20:12:23 joerg_wunsch Exp $@setfilename avrdude.info@settitle AVRDUDE@finalout@include version.texi@c@c These are set in version.texi which is automatically generated by automake.@c@c @set UPDATED 26 Febuary 2003@c @set EDITION 3.2.0@c @set VERSION 3.2.0@c This is a dir.info fragment to support semi-automated addition of@c manuals to an info tree.@dircategory AVR Programming & development tools.@direntry* AvrDude: (avrdude). AVR program downloader/uploader.@end direntry@ifinfoThis file documents the avrdude program.For avrdude version @value{VERSION}, @value{UPDATED}.Copyright @copyright{} 2003,2005 Brian DeanPermission is granted to make and distribute verbatim copies ofthis manual provided the copyright notice and this permission noticeare preserved on all copies.@ignorePermission is granted to process this file through TeX and print theresults, provided the printed document carries copying permissionnotice identical to this one except for the removal of this paragraph(this paragraph not being relevant to the printed manual).@end ignorePermission is granted to copy and distribute modified versions of thismanual under the conditions for verbatim copying, provided that the entireresulting derived work is distributed under the terms of a permissionnotice identical to this one.Permission is granted to copy and distribute translations of this manualinto another language, under the above conditions for modified versions,except that this permission notice may be stated in a translation approvedby the Free Software Foundation.@end ifinfo@titlepage@title AVRDUDE@subtitle A program for download/uploading AVR microcontroller flash and eeprom.@subtitle For AVRDUDE, Version @value{VERSION}, @value{UPDATED}.@author by Brian S. Dean@page@hfill (Send bugs and comments on AVRDUDE to @w{@email{avrdude-dev@@nongnu.org}}.)@vfillCopyright @copyright{} 2003,2005 Brian S. Dean@sp 2Permission is granted to make and distribute verbatim copies ofthis manual provided the copyright notice and this permission noticeare preserved on all copies.Permission is granted to copy and distribute modified versions of thismanual under the conditions for verbatim copying, provided that the entireresulting derived work is distributed under the terms of a permissionnotice identical to this one.Permission is granted to copy and distribute translations of this manualinto another language, under the above conditions for modified versions,except that this permission notice may be stated in a translation approvedby the Free Software Foundation.@end titlepage@contents@c@c Top Node@c@node Top, Introduction, (dir), (dir)@comment node-name, next, previous, up@ifinfoThis file documents the avrdude program for downloading/uploadingprograms to Atmel AVR microcontrollers.For avrdude version @value{VERSION}, @value{UPDATED}.@end ifinfo@menu* Introduction:: * Command Line Options::* Terminal Mode Operation::* Configuration File:: * Platform Dependent Information::* Troubleshooting::@end menu@c@c Node@c@node Introduction, Command Line Options, Top, Top@comment node-name, next, previous, up@chapter Introduction@cindex introductionAVRDUDE - AVR Downloader Uploader - is a program for downloading anduploading the on-chip memories of Atmel's AVR microcontrollers. It canprogram the Flash and EEPROM, and where supported by the serialprogramming protocol, it can program fuse and lock bits. AVRDUDE alsosupplies a direct instruction mode allowing one to issue any programminginstruction to the AVR chip regardless of whether AVRDUDE implementsthat specific feature of a particular chip.AVRDUDE can be used effectively via the command line to read or writeall chip memory types (eeprom, flash, fuse bits, lock bits, signaturebytes) or via an interactive (terminal) mode. Using AVRDUDE from thecommand line works well for programming the entire memory of the chipfrom the contents of a file, while interactive mode is useful forexploring memory contents, modifing individual bytes of eeprom,programming fuse/lock bits, etc.AVRDUDE supports six basic programmer types: Atmel's STK500,Atmel's JTAG ICE mkII, appnoteavr910, appnote avr109 (including the AVR Butterfly),serial bit-bang adapters,and the PPI (parallel port interface). PPI represents a classof simple programmers where the programming lines are directlyconnected to the PC parallel port. Several pin configurations existfor several variations of the PPI programmers, and AVRDUDE can be beconfigured to work with them by either specifying the appropriateprogrammer on the command line or by creating a new entry in itsconfiguration file. All that's usually required for a new entry is totell AVRDUDE which pins to use for each programming function.A number of equally simple bit-bang programming adapters that connectto a serial port are supported as well, among them the popularPonyprog serial adapter, and the DASA and DASA3 adapters that used tobe supported by uisp(1). Note that these adapters are meant to beattached to a physical serial port. Connecting to a serial portemulated on top of USB is likely to not work at all, or to workabysmally slow.The STK500, JTAG ICE, avr910, and avr109/butterfly use the serial port to communicate with the PC.The STK500, JTAG ICE, and avr910 contain on-board logic to control the programming of the targetdevice.The avr109 bootloader implements a protocol similar to avr910, but isactually implemented in the boot area of the target's flash ROM, asopposed to being an external device.The fundamental difference between the two types lies in theprotocol used to control the programmer. The avr910 protocol is verysimplistic and can easily be used as the basis for a simple, home madeprogramer since the firmware is available online. On the other hand,the STK500 protocol is more robust and complicated and the firmware isnot openly available.The JTAG ICE also uses a serial communication protocol which is similarto the STK500 firmware version 2 one. However, as the JTAG ICE isintented to allow on-chip debugging as well as memory programming, theprotocol is more sophisticated.(This protocol can also be run on top of USB.)Only the memory programming functionality of the JTAG ICE is supportedby AVRDUDE.@menu* History:: @end menu@c@c Node@c@node History, , Introduction, Introduction@section History and CreditsAVRDUDE was written by Brian S. Dean under the name of AVRPROG to run onthe FreeBSD Operating System. Brian renamed the software to be calledAVRDUDE when interest grew in a Windows port of the software so that thename did not conflict with AVRPROG.EXE which is the name of Atmel'sWindows programming software.The AVRDUDE source now resides in the public CVS repository onsavannah.gnu.org (@url{http://savannah.gnu.org/projects/avrdude/}),where it continues to be enhanced and ported to other systems. Inaddition to FreeBSD, AVRDUDE now runs on Linux and Windows. Thedevelopers behind the porting effort primarily were Ted Roth, EricWeddington, and Joerg Wunsch.And in the spirit of many open source projects, this manual also drawson the work of others. The initial revision was composed of parts ofthe original Unix manual page written by Joerg Wunsch, the original website documentation by Brian Dean, and from the comments describing thefields in the AVRDUDE configuration file by Brian Dean. The texiformatting was modeled after that of the Simulavr documentation by TedRoth.@c@c Node@c@node Command Line Options, Terminal Mode Operation, Introduction, Top@chapter Command Line Options@cindex options@menu* Option Descriptions::* Example Command Line Invocations::@end menu@c@c Node@c@node Option Descriptions, Example Command Line Invocations, Command Line Options, Command Line Options@section Option Descriptions@noindentAVRDUDE is a command line tool, used as follows:@exampleavrdude -p partno @var{options} @dots{}@end example@noindentCommand line options are used to control AVRDUDE's behaviour. Thefollowing options are recognized:@table @code@item -p @var{partno}This is the only mandatory option and it tells AVRDUDE what type of part(MCU) that is connected to the programmer. The @var{partno} parameteris the part's id listed in the configuration file. Specify -p ? to listall parts in the configuration file. If a part is unknownto AVRDUDE, it means that there is no config file entry for that part,but it can be added to the configuration file if you have the Atmeldatasheet so that you can enter the programming specifications.Currently, the following MCU types are understood:@table @code@itemx c128AT90CAN128@itemx pwm2AT90PWM2@itemx pwm3AT90PWM3@itemx 1200AT90S1200@itemx 2313AT90S2313@itemx 2333AT90S2333@itemx 2343AT90S2343 (*)@itemx 4414AT90S4414@itemx 4433AT90S4433@itemx 4434AT90S4434@itemx 8515AT90S8515@itemx 8535AT90S8535@itemx m103ATmega103@itemx m128ATmega128@itemx m16ATmega16@itemx m161ATmega161@itemx m162ATmega162@itemx m163ATmega163@itemx m164ATmega164@itemx m169ATmega169@itemx m32ATmega32@itemx m324ATmega324@itemx m329ATmega329@itemx m3290ATmega3290@itemx m48ATmega48@itemx m64ATmega64@itemx m644ATmega644@itemx m649ATmega649@itemx m6490ATmega6490@itemx m8ATmega8@itemx m8515ATmega8515@itemx m8535ATmega8535@itemx m88ATmega88@itemx t12ATtiny12@itemx t13ATtiny13@itemx t15ATtiny15@itemx t2313ATtiny2313@itemx t25ATtiny25@itemx t26ATtiny26@itemx t45ATtiny45@itemx t85ATtiny85@end table(*) The AT90S2323 and ATtiny22 use the same algorithm.@item -b @var{baudrate}Override the RS-232 connection baud rate specified in the respectiveprogrammer's entry of the configuration file.@item -B @var{bitclock}Specify the bit clock period for the JTAG interface (JTAG ICE only).The value is a floating-point number in microseconds.The default value of the JTAG ICE results in about 1 microsecond bitclock period, suitable for target MCUs running at 4 MHz clock andabove.Unlike certain parameters in the STK500, the JTAG ICE resets all itsparameters to default values when the programming software signsoff from the ICE, so for MCUs running at lower clock speeds, thisparameter must be specified on the command-line.@item -c @var{programmer-id}Specify the programmer to be used. AVRDUDE knows about several commonprogrammers. Use this option to specify which one to use. The@var{programmer-id} parameter is the programmer's id listed in theconfiguration file. Specify -c ? to list all programmers in theconfiguration file. If you have a programmer that is unknown toAVRDUDE, and the programmer is controlled via the PC parallel port,there's a good chance that it can be easily added to the configurationfile without any code changes to AVRDUDE. Simply copy an existing entryand change the pin definitions to match that of the unknown programmer.Currently, the following programmer ids are understood and supported:@table @code@itemx abcminiABCmini Board, aka Dick Smith HOTCHIP@itemx alfNightshade ALF-PgmAVR, http://nightshade.homeip.net/@itemx avr109Atmel AppNote AVR109 Boot Loader@itemx avr910Atmel Low Cost Serial Programmer@itemx avr911Atmel AppNote AVR911 AVROSP (an alias for avr109)@itemx avrispAtmel AVR ISP@itemx bascomBascom SAMPLE programming cable@itemx bsdBrian Dean's Programmer, http://www.bsdhome.com/avrdude/@itemx butterflyAtmel Butterfly Development Board@itemx dt006Dontronics DT006@item jtagmkII@itemx jtag2slowAtmel JTAG ICE mkII (default speed 19200 Bd)@itemx jtag2fastAtmel JTAG ICE mkII, running at 115200 Bd@itemx jtag2Same as before.@itemx pavrJason Kyle's pAVR Serial Programmer@itemx picowebPicoweb Programming Cable, http://www.picoweb.net/@itemx pony-stk200Pony Prog STK200@itemx sp12Steve Bolt's Programmer@itemx stk200STK200@itemx stk500Atmel STK500
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -