/usr/share/doc/avrdude/avrdude-html/Example-Command-Line-Invocations.html is in avrdude-doc 6.3-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- Created by GNU Texinfo 6.4.90, http://www.gnu.org/software/texinfo/ -->
<head>
<title>Example Command Line Invocations (AVRDUDE)</title>
<meta name="description" content="Example Command Line Invocations (AVRDUDE)">
<meta name="keywords" content="Example Command Line Invocations (AVRDUDE)">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href="index.html#Top" rel="start" title="Top">
<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
<link href="Command-Line-Options.html#Command-Line-Options" rel="up" title="Command Line Options">
<link href="Terminal-Mode-Operation.html#Terminal-Mode-Operation" rel="next" title="Terminal Mode Operation">
<link href="Programmers-accepting-extended-parameters.html#Programmers-accepting-extended-parameters" rel="prev" title="Programmers accepting extended parameters">
<style type="text/css">
<!--
a.summary-letter {text-decoration: none}
blockquote.indentedblock {margin-right: 0em}
blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
blockquote.smallquotation {font-size: smaller}
div.display {margin-left: 3.2em}
div.example {margin-left: 3.2em}
div.lisp {margin-left: 3.2em}
div.smalldisplay {margin-left: 3.2em}
div.smallexample {margin-left: 3.2em}
div.smalllisp {margin-left: 3.2em}
kbd {font-style: oblique}
pre.display {font-family: inherit}
pre.format {font-family: inherit}
pre.menu-comment {font-family: serif}
pre.menu-preformatted {font-family: serif}
pre.smalldisplay {font-family: inherit; font-size: smaller}
pre.smallexample {font-size: smaller}
pre.smallformat {font-family: inherit; font-size: smaller}
pre.smalllisp {font-size: smaller}
span.nolinebreak {white-space: nowrap}
span.roman {font-family: initial; font-weight: normal}
span.sansserif {font-family: sans-serif; font-weight: normal}
ul.no-bullet {list-style: none}
-->
</style>
</head>
<body lang="en">
<a name="Example-Command-Line-Invocations"></a>
<div class="header">
<p>
Previous: <a href="Programmers-accepting-extended-parameters.html#Programmers-accepting-extended-parameters" accesskey="p" rel="prev">Programmers accepting extended parameters</a>, Up: <a href="Command-Line-Options.html#Command-Line-Options" accesskey="u" rel="up">Command Line Options</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
</div>
<hr>
<a name="Example-Command-Line-Invocations-1"></a>
<h3 class="section">2.3 Example Command Line Invocations</h3>
<p>Download the file <code>diag.hex</code> to the ATmega128 chip using the
STK500 programmer connected to the default serial port:
</p>
<div class="smallexample">
<table class="cartouche" border="1"><tr><td>
<pre class="smallexample">% avrdude -p m128 -c stk500 -e -U flash:w:diag.hex
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.03s
avrdude: Device signature = 0x1e9702
avrdude: erasing chip
avrdude: done.
avrdude: performing op: 1, flash, 0, diag.hex
avrdude: reading input file "diag.hex"
avrdude: input file diag.hex auto detected as Intel Hex
avrdude: writing flash (19278 bytes):
Writing | ################################################## | 100% 7.60s
avrdude: 19456 bytes of flash written
avrdude: verifying flash memory against diag.hex:
avrdude: load data flash data from input file diag.hex:
avrdude: input file diag.hex auto detected as Intel Hex
avrdude: input file diag.hex contains 19278 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 6.83s
avrdude: verifying ...
avrdude: 19278 bytes of flash verified
avrdude: safemode: Fuses OK
avrdude done. Thank you.
%
</pre></td></tr></table>
</div>
<p>Upload the flash memory from the ATmega128 connected to the STK500
programmer and save it in raw binary format in the file named
<code>c:/diag flash.bin</code>:
</p>
<div class="smallexample">
<table class="cartouche" border="1"><tr><td>
<pre class="smallexample">% avrdude -p m128 -c stk500 -U flash:r:"c:/diag flash.bin":r
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.03s
avrdude: Device signature = 0x1e9702
avrdude: reading flash memory:
Reading | ################################################## | 100% 46.10s
avrdude: writing output file "c:/diag flash.bin"
avrdude: safemode: Fuses OK
avrdude done. Thank you.
%
</pre></td></tr></table>
</div>
<p>Using the default programmer, download the file <code>diag.hex</code> to
flash, <code>eeprom.hex</code> to EEPROM, and set the Extended, High, and Low
fuse bytes to 0xff, 0x89, and 0x2e respectively:
</p>
<div class="smallexample">
<table class="cartouche" border="1"><tr><td>
<pre class="smallexample">
% avrdude -p m128 -u -U flash:w:diag.hex \
> -U eeprom:w:eeprom.hex \
> -U efuse:w:0xff:m \
> -U hfuse:w:0x89:m \
> -U lfuse:w:0x2e:m
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.03s
avrdude: Device signature = 0x1e9702
avrdude: NOTE: FLASH memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "diag.hex"
avrdude: input file diag.hex auto detected as Intel Hex
avrdude: writing flash (19278 bytes):
Writing | ################################################## | 100% 7.60s
avrdude: 19456 bytes of flash written
avrdude: verifying flash memory against diag.hex:
avrdude: load data flash data from input file diag.hex:
avrdude: input file diag.hex auto detected as Intel Hex
avrdude: input file diag.hex contains 19278 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 6.84s
avrdude: verifying ...
avrdude: 19278 bytes of flash verified
[ ... other memory status output skipped for brevity ... ]
avrdude done. Thank you.
%
</pre></td></tr></table>
</div>
<p>Connect to the JTAG ICE mkII which serial number ends up in 1C37 via
USB, and enter terminal mode:
</p>
<div class="smallexample">
<table class="cartouche" border="1"><tr><td>
<pre class="smallexample">
% avrdude -c jtag2 -p m649 -P usb:1c:37 -t
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.03s
avrdude: Device signature = 0x1e9603
[ ... terminal mode output skipped for brevity ... ]
avrdude done. Thank you.
</pre></td></tr></table>
</div>
<p>List the serial numbers of all JTAG ICEs attached to USB. This is
done by specifying an invalid serial number, and increasing the
verbosity level.
</p>
<div class="smallexample">
<table class="cartouche" border="1"><tr><td>
<pre class="smallexample">
% avrdude -c jtag2 -p m128 -P usb:xx -v
[...]
Using Port : usb:xxx
Using Programmer : jtag2
avrdude: usbdev_open(): Found JTAG ICE, serno: 00A000001C6B
avrdude: usbdev_open(): Found JTAG ICE, serno: 00A000001C3A
avrdude: usbdev_open(): Found JTAG ICE, serno: 00A000001C30
avrdude: usbdev_open(): did not find any (matching) USB device "usb:xxx"
</pre></td></tr></table>
</div>
<hr>
<div class="header">
<p>
Previous: <a href="Programmers-accepting-extended-parameters.html#Programmers-accepting-extended-parameters" accesskey="p" rel="prev">Programmers accepting extended parameters</a>, Up: <a href="Command-Line-Options.html#Command-Line-Options" accesskey="u" rel="up">Command Line Options</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
</div>
</body>
</html>
|