1DFU-UTIL(1)                 General Commands Manual                DFU-UTIL(1)
2
3
4

NAME

6       dfu-util - Device firmware update (DFU) USB programmer
7

SYNOPSIS

9       dfu-util  -l  [-v]  [-d vid:pid[,vid:pid]] [-p path] [-c configuration]
10              [-i interface] [-a alt-intf] [-S serial[,serial]]
11
12       dfu-util [-v] [-d vid:pid[,vid:pid]] [-p path] [-c  configuration]  [-i
13              interface]  [-a  alt-intf]  [-S  serial[,serial]]  [-t size] [-Z
14              size] [-s address] [-R] [-D|-U file]
15
16       dfu-util [-hV]
17

DESCRIPTION

19       dfu-util is a program that implements the host (computer) side  of  the
20       USB DFU (Universal Serial Bus Device Firmware Upgrade) protocol.
21
22       dfu-util  communicates  with  devices that implement the device side of
23       the USB DFU protocol, and is often used to upgrade the firmware of such
24       devices.
25

OPTIONS

27       -l, --list
28              List the currently attached DFU capable USB devices.
29
30       -d,  --device  [Run-Time  VENDOR]:[Run-Time  PRODUCT][,[DFU  Mode  VEN‐
31       DOR]:[DFU Mode PRODUCT]]
32              Specify run-time and/or DFU mode vendor and/or  product  IDs  of
33              the  DFU device to work with. VENDOR and PRODUCT are hexadecimal
34              numbers (no prefix needed), "*" (match any), or "-" (match noth‐
35              ing).  By  default, any DFU capable device in either run-time or
36              DFU mode will be considered.
37
38              If you only have one standards-compliant DFU device attached  to
39              your  computer,  this parameter is optional. However, as soon as
40              you have multiple DFU devices connected,  dfu-util  will  detect
41              this and abort, asking you to specify which device to use.
42
43              If  only run-time IDs are specified (e.g. "--device 1457:51ab"),
44              then in addition to the specified run-time  IDs,  any  DFU  mode
45              devices  will  also be considered. This is beneficial to allow a
46              DFU capable device to be found again after a switch to DFU mode,
47              since  the  vendor and/or product ID of a device usually changes
48              in DFU mode.
49
50              If only DFU mode IDs are specified  (e.g.  "--device  ,951:26"),
51              then  all  run-time  devices  will be ignored, making it easy to
52              target a specific device in DFU mode.
53
54              If both run-time and DFU mode IDs are specified (e.g.  "--device
55              1457:51ab,:2bc"),  then unspecified DFU mode components will use
56              the run-time value specified.
57
58              Examples:
59
60              --device 1457:51ab,951:26
61                     Work with a device in run-time mode with vendor ID 0x1457
62                     and  product  ID  0x51ab,  or  in DFU mode with vendor ID
63                     0x0951 and product ID 0x0026
64
65
66              --device 1457:51ab,:2bc
67                     Work with a device in run-time mode with vendor ID 0x1457
68                     and  product  ID  0x51ab,  or  in DFU mode with vendor ID
69                     0x1457 and product ID 0x02bc
70
71
72              --device 1457:51ab
73                     Work with a device in run-time mode with vendor ID 0x1457
74                     and product ID 0x51ab, or in DFU mode with any vendor and
75                     product ID
76
77
78              --device ,951:26
79                     Work with a device in DFU mode with vendor ID 0x0951  and
80                     product ID 0x0026
81
82
83              --device *,-
84                     Work  with  any  device  in run-time mode, and ignore any
85                     device in DFU mode
86
87
88              --device ,
89                     Ignore any device in run-time mode,  and  Work  with  any
90                     device in DFU mode
91
92       -p, --path BUS-PORT. ... .PORT
93              Specify the path to the DFU device.
94
95       -c, --cfg CONFIG-NR
96              Specify  the  configuration of the DFU device. Note that this is
97              only used for matching, the configuration is  not  set  by  dfu-
98              util.
99
100       -i, --intf INTF-NR
101              Specify the DFU interface number.
102
103       -a, --alt ALT
104              Specify  the  altsetting of the DFU interface by name or by num‐
105              ber.
106
107       -S, --serial [Run-Time SERIAL][,[DFU Mode SERIAL]]
108              Specify the run-time and DFU mode serial numbers used to further
109              restrict device matches.  If multiple, identical DFU devices are
110              simultaneously connected to a system then vendor and product  ID
111              will  be  insufficient  for  targeting a single device.  In this
112              situation, it may be possible to use this parameter to specify a
113              serial number which also must match.
114
115              If  only  a  single  serial  number  is specified, then the same
116              serial number is used in both run-time and DFU  mode.  An  empty
117              serial  number will match any serial number in the corresponding
118              mode.
119
120       -t, --transfer-size  SIZE
121              Specify the number of bytes per USB transfer. The optimal  value
122              is  usually  determined  automatically  so this option is rarely
123              useful. If you need to use this  option  for  a  device,  please
124              report it as a bug.
125
126       -Z, --upload-size  SIZE
127              Specify the expected upload size, in bytes.
128
129       -U, --upload FILE
130              Read firmware from device into FILE.
131
132       -D, --download FILE
133              Write  firmware  from  FILE  into  device.  When  FILE is -, the
134              firmware is read from stdin.
135
136       -R, --reset
137              Issue USB reset signalling after upload  or  download  has  fin‐
138              ished.
139
140       -s, --dfuse-address address
141              Specify  target  address for raw binary download/upload on DfuSe
142              devices. Do not use this for  downloading  DfuSe  (.dfu)  files.
143              Modifiers  can be added to the address, separated by a colon, to
144              perform special DfuSE commands such as "leave" DFU mode, "unpro‐
145              tect" and "mass-erase" flash memory.
146
147       -v, --verbose
148              Print  more  information about dfu-util's operation. A second -v
149              will turn on verbose logging of USB requests. Repeat this option
150              to further increase verbosity.
151
152       -h, --help
153              Show a help text and exit.
154
155       -V, --version
156              Show version information and exit.
157

EXAMPLES

159   Using dfu-util in the OpenMoko project
160       (with the Neo1973 hardware)
161
162       Flashing the rootfs:
163         $ dfu-util -a rootfs -R -D /path/to/openmoko-devel-image.jffs2
164
165       Flashing the kernel:
166         $ dfu-util -a kernel -R -D /path/to/uImage
167
168       Flashing the bootloader:
169         $ dfu-util -a u-boot -R -D /path/to/u-boot.bin
170
171       Copying a kernel into RAM:
172         $ dfu-util -a 0 -R -D /path/to/uImage
173
174       Once  this  has  finished,  the kernel will be available at the default
175       load address of 0x32000000 in Neo1973 RAM.  Note: You  cannot  transfer
176       more than 2MB of data into RAM using this method.
177
178
179   Using dfu-util with a DfuSe device
180       Flashing a .dfu (special DfuSe format) file to the device:
181         $ dfu-util -a 0 -D /path/to/dfuse-image.dfu
182
183       Reading out 1 KB of flash starting at address 0x8000000:
184         $ dfu-util -a 0 -s 0x08000000:1024 -U newfile.bin
185
186       Flashing  a  binary  file to address 0x8004000 of device memory and ask
187       the device to leave DFU mode:
188         $ dfu-util -a 0 -s 0x08004000:leave -D /path/to/image.bin
189

BUGS

191       Please report any bugs to the dfu-util bug  tracker  at  http://source
192       forge.net/p/dfu-util/tickets/.    Please   use   the  --verbose  option
193       (repeated as necessary) to provide more information in your bug report.
194

SEE ALSO

196       The dfu-util home page is http://sourceforge.net/p/dfu-util/
197

HISTORY

199       dfu-util was originally written for  the  OpenMoko  project  by  Weston
200       Schmidt  <weston_schmidt@yahoo.com>  and  Harald Welte <hwelte@hmw-con‐
201       sulting.de>. Over time, nearly complete support of DFU 1.0, DFU 1.1 and
202       DfuSe ("1.1a") has been added.
203

LICENCE

205       dfu-util  is covered by the GNU General Public License (GPL), version 2
206       or later.
207
209       This manual page was originally written by  Uwe  Hermann  <uwe@hermann-
210       uwe.de>, and is now part of the dfu-util project.
211
212
213
214                              September 23, 2012                   DFU-UTIL(1)
Impressum