Replace the LUFA build system with DMBS.
[pub/lufa.git] / LUFA / Build / DMBS / DMBS / avrdude.md
1 DMBS - Dean's Makefile Build System
2 ===================================
3
4
5 Module: AVRDUDE
6 -----------------
7
8 The AVRDUDE module provides build targets for use with the official
9 open source `AVRDUDE` programmer utility, for the reprogramming of Atmel devices
10 using a wide variety of official and non-official programming devices and
11 bootloaders.
12
13 ## Importing This Module into a Makefile:
14
15 To use this module in your application makefile, add the following code to your
16 makefile:
17
18 include $(DMBS_PATH)/avrdude.mk
19
20 ## Prerequisites:
21
22 This module requires the `avrdude` utility to be available in your
23 system's `PATH` variable. The `avrdude` utility is distributed on the project's
24 [official site](https://savannah.nongnu.org/projects/avrdude) but is also
25 made available in many *nix operating system's package managers.
26
27 ## Build Targets:
28
29 The following targets are supported by this module:
30
31 <table>
32 <tbody>
33 <tr>
34 <td>avrdude</td>
35 <td>Program the device FLASH memory with the application's executable data.</td>
36 </tr>
37 <tr>
38 <td>avrdude-ee</td>
39 <td>Program the device EEPROM memory with the application's EEPROM data.</td>
40 </tr>
41 </tbody>
42 </table>
43
44 ## Mandatory Variables:
45
46 The following variables must be defined (with a `NAME = VALUE` syntax, one
47 variable per line) in the user makefile to be able to use this module:
48
49 <table>
50 <tbody>
51 <tr>
52 <td>MCU</td>
53 <td>Name of the Atmel processor model (e.g. `at90usb1287`).</td>
54 </tr>
55 <tr>
56 <td>TARGET</td>
57 <td>Name of the application output file prefix (e.g. `TestApplication`).</td>
58 </tr>
59 </tbody>
60 </table>
61
62 ## Optional Variables:
63
64 The following variables may be defined (with a `NAME = VALUE` syntax, one
65 variable per line) in the user makefile. If not specified, a default value will
66 be assumed.
67
68 <table>
69 <tbody>
70 <tr>
71 <td>AVRDUDE_PROGRAMMER</td>
72 <td>Name of the programmer/debugger tool or bootloader to communicate with (e.g. `jtagicemkii`). Default is `jtagicemkii`.</td>
73 </tr>
74 <tr>
75 <td>AVRDUDE_PORT</td>
76 <td>Name of the communication port to use when when programming with a serially connected tool (e.g. `COM2`). Default is `usb`.</td>
77 </tr>
78 <tr>
79 <td>AVRDUDE_FLAGS</td>
80 <td>Additional flags to pass to `avrdude` when invoking the tool. Default is empty (no additional flags).</td>
81 </tr>
82 <tr>
83 <td>AVRDUDE_MEMORY</td>
84 <td>Memory space to program when executing the `avrdude` target (e.g. 'application` for an XMEGA device). Default is `flash`.</td>
85 </tr>
86 </tbody>
87 </table>
88
89 ## Provided Variables:
90
91 The following variables may be referenced in a user makefile (via `$(NAME)`
92 syntax) if desired, as they are provided by this module.
93
94 <table>
95 <tbody>
96 <tr>
97 <td>N/A</td>
98 <td>This module provides no variables.</td>
99 </tr>
100 </tbody>
101 </table>
102
103 ## Provided Macros:
104
105 The following macros may be referenced in a user makefile (via
106 `$(call NAME, ARG1, ARG2, ...)` syntax) if desired, as they are provided by
107 this module.
108
109 <table>
110 <tbody>
111 <tr>
112 <td>N/A</td>
113 <td>This module provides no macros.</td>
114 </tr>
115 </tbody>
116 </table>
117
118 ## Module Changelog:
119
120 The changes to this module since its initial release are listed below, as of the
121 DMBS version where the change was made.
122
123 ### 20160403
124 Initial release.