diff --git a/LUFA/Build/DMBS/.gitignore b/LUFA/Build/DMBS/.gitignore new file mode 100644 index 00000000000..938768908a1 --- /dev/null +++ b/LUFA/Build/DMBS/.gitignore @@ -0,0 +1,9 @@ +*.lss +*.bin +*.elf +*.hex +*.eep +*.map +*.o +*.d +*.sym diff --git a/LUFA/Build/DMBS/DMBS/Modules.md b/LUFA/Build/DMBS/DMBS/Modules.md new file mode 100644 index 00000000000..65caf8a605a --- /dev/null +++ b/LUFA/Build/DMBS/DMBS/Modules.md @@ -0,0 +1,26 @@ +DMBS - Dean's Makefile Build System +=================================== + + +Modules Overview +--------------- + +The following modules are currently included: + + - [ATPROGRAM](atprogram.md) - Device Programming + - [AVRDUDE](avrdude.md) - Device Programming + - [CORE](core.md) - DMBS Core Functionality + - [CPPCHECK](cppcheck.md) - Static Code Analysis + - [DFU](dfu.md) - Device Programming + - [DOXYGEN](doxygen.md) - Automated Source Code Documentation + - [GCC](gcc.md) - Compiling/Assembling/Linking with GCC + - [HID](hid.md) - Device Programming + +To use a module, you will need to add the following boilerplate to your +makefile: + + # Include DMBS build script makefiles + DMBS_PATH ?= ../DMBS + +Which is then used to indicate the location of your DMBS installation, relative +to the current directory. diff --git a/LUFA/Build/DMBS/DMBS/atprogram.md b/LUFA/Build/DMBS/DMBS/atprogram.md new file mode 100644 index 00000000000..d84cc9860c0 --- /dev/null +++ b/LUFA/Build/DMBS/DMBS/atprogram.md @@ -0,0 +1,111 @@ +DMBS - Dean's Makefile Build System +=================================== + + +Module: ATPROGRAM +----------------- + +The ATPROGRAM module provides build targets for use with the official +`ATPROGRAM` back-end utility distributed with the free +[Atmel Studio](http://www.atmel.com) software released by Atmel. + +## Importing This Module into a Makefile: + +To use this module in your application makefile, add the following code to your +makefile: + + include $(DMBS_PATH)/atprogram.mk + +## Prerequisites: + +This module requires the `atprogram.exe` utility to be available in your +system's `PATH` variable. The `atprogram.exe` utility is distributed in Atmel +Studio (usually) inside the application install folder's `atbackend` +subdirectory. + +## Build Targets: + +The following targets are supported by this module: + +
atprogram | +Program the device FLASH memory with the application's executable data. | +
atprogram-ee | +Program the device EEPROM memory with the application's EEPROM data. | +
MCU | +Name of the Atmel processor model (e.g. `at90usb1287`). | +
TARGET | +Name of the application output file prefix (e.g. `TestApplication`). | +
ATPROGRAM_PROGRAMMER | +Name of the Atmel programmer or debugger tool to communicate with (e.g. `jtagice3`). Default is `atmelice`. | +
ATPROGRAM_INTERFACE | +Name of the programming interface to use when programming the target (e.g. `spi`). Default is `jtag`. | +
ATPROGRAM_PORT | +Name of the communication port to use when when programming with a serially connected tool (e.g. `COM2`). Default is `usb`. | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +
avrdude | +Program the device FLASH memory with the application's executable data. | +
avrdude-ee | +Program the device EEPROM memory with the application's EEPROM data. | +
MCU | +Name of the Atmel processor model (e.g. `at90usb1287`). | +
TARGET | +Name of the application output file prefix (e.g. `TestApplication`). | +
AVRDUDE_PROGRAMMER | +Name of the programmer/debugger tool or bootloader to communicate with (e.g. `jtagicemkii`). Default is `jtagicemkii`. | +
AVRDUDE_PORT | +Name of the communication port to use when when programming with a serially connected tool (e.g. `COM2`). Default is `usb`. | +
AVRDUDE_FLAGS | +Additional flags to pass to `avrdude` when invoking the tool. Default is empty (no additional flags). | +
AVRDUDE_MEMORY | +Memory space to program when executing the `avrdude` target (e.g. 'application` for an XMEGA device). Default is `flash`. | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +
help | +Show help for the current project, including a list of all available targets, variables and macros from the imported modules. | +
list_targets | +Show a list of all build targets from the imported modules. | +
list_modules | +Show a list of all imported modules. | +
list_mandatory | +Show a list of all mandatory variables from the imported modules. | +
list_optional | +Show a list of all optional variables from the imported modules. | +
list_provided | +Show a list of all variables provided by the imported modules. | +
list_macros | +Show a list of all macros provided by the imported modules. | +
N/A | +This module has no mandatory variables. | +
N/A | +This module has no optional variables. | +
DMBS_VERSION | +Current version of this DMBS release. | +
N/A | +This module provides no macros. | +
cppcheck | +Scan the project with CPPCHECK, and show all discovered issues. | +
cppcheck-config | +Check the project with CPPCHECK, to find missing header paths. | +
SRC | +List of all project source files to scan. | +
CPPCHECK_INCLUDES | +Extra include paths to search, for any missing header files. Default is empty (no additional paths). | +
CPPCHECK_EXCLUDES | +List of source files, file paths or path fragments to exclude from the scan. Default is empty (no exclusions). | +
CPPCHECK_MSG_TEMPLATE | +Template for error and warning message output. Default is `{file}:{line}: {severity} ({id}): {message}`. | +
CPPCHECK_ENABLE | +List of CPPCHECK checks to enable. Default is `all`. | +
CPPCHECK_SUPPRESS | +List of CPPCHECK checks to ignore. Default is `variableScope missingInclude`. | +
CPPCHECK_FAIL_ON_WARNING | +Boolean, if `Y` the build will fail if CPPCHECK discovers any errors or warnings. If `N`, fail only on errors. Default is `Y`. | +
CPPCHECK_QUIET | +Boolean, if `Y` CPPCHECK will suppress all output except for discovered errors or warnings. If `N`, scan progress will be emitted. Default is `Y`. | +
CPPCHECK_FLAGS_ | +Additional flags to pass to CPPCHECK when scans are started. Default is empty (no additional flags). | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +
flip | +Program the application into the device's flash memory, using Atmel FLIP. | +
flip-ee | +Program the application's EEPROM data into the device's EEPROM memory, using Atmel FLIP. | +
dfu | +Program the application into the device's flash memory, using `dfu-programmer`. | +
dfu-ee | +Program the application's EEPROM data into the device's EEPROM memory, using `dfu-programmer`. | +
MCU | +Name of the Atmel processor model (e.g. `at90usb1287`). | +
TARGET | +Name of the application output file prefix (e.g. `TestApplication`). | +
N/A | +This module has no optional variables. | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +
doxygen | +Generate project documentation, via Doxygen. | +
doxygen-create | +Create a new project Doxygen template, which can then be customized. | +
doxygen-upgrade | +Upgrade an existing project Doxygen template to the latest Doxygen version. | +
N/A | +This module has no mandatory variables. | +
DOXYGEN_CONF | +Name of the Doxygen project configuration file that should be used when generating documentation, or creating/upgrading the configuration file. | +
DOXYGEN_FAIL_ON_WARNING | +Boolean, if `Y` the build will fail if Doxygen encounters any errors or warnings. If `N`, fail only on errors. Default is `Y`. | +
DOXYGEN_OVERRIDE_PARAMS | +List of `NAME=VALUE` parameters which should override the values specified in the project configuration file, when building documentation. | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +
size | +Show the compiled binary size for the various memory segments. | +
symbol-sizes | +Show the size of each symbol in the compiled binary (useful to find large functions to optimize further). | +
all | +Build application and generate all binary (BIN, ELF, HEX) and auxiliary (LSS, MAP, SYM, etc.) output files. | +
lib | +Generate a static `.a` library from the application code, containing the flash region's data. | +
elf | +Generate an ELF debug file from the application code, containing all region's data. | +
bin | +Generate a flat BIN binary file from the application code, containing the flash region's data. | +
hex | +Generate a pair of Intel HEX files from the application code, containing the flash region's data (HEX) and EEPROM data (EEP). | +
lss | +Generate a LSS listing file showing the disassembly of the compiled application. | +
clean | +Remove all generated project intermediary and binary output files. | +
mostlyclean | +Remove all generated project intermediary output files, but preserve the binary output files. | +
MCU | +Name of the Atmel processor model (e.g. `at90usb1287`). | +
TARGET | +Name of the application output file prefix (e.g. `TestApplication`). | +
ARCH | +Target device architecture (e.g. `AVR8`). | +
SRC | +List of all project source files (C, C++, ASM). | +
OPTIMIZATION | +Optimization level to use when compiling C and C++ source files. Default is `s` (optimize for smallest size). | +
C_STANDARD | +C language standard used when compiling C language source files. Default is `gnu99` (C99 standard with GNU extensions)./td> + |
CPP_STANDARD | +C++ language standard used when compiling C++ language source files. Default is `gnu++98` (C++98 standard with GNU extensions)./td> + |
F_CPU | +Processor core clock frequency, in Hz. This is used by some architectures for functions such as software spin-loop delays. Default is blank (no value defined). | +
C_FLAGS | +Common GCC flags passed to the compiler for C language (C) input files. Default is blank (no additional flags). | +
CPP_FLAGS | +Common GCC flags passed to the compiler for C++ language (CPP) input files. Default is blank (no additional flags). | +
ASM_FLAGS | +Common GCC flags passed to the assembler for assembly language (S) input files. Default is blank (no additional flags). | +
CC_FLAGS | +Common GCC flags passed to the compiler for all source file types. Default is blank (no additional flags). | +
LD_FLAGS | +Extra flags to pass to the GNU linker when linking the compiled object files into the resulting binary. Default is blank (no additional flags). | +
LINKER_RELAXATIONS | +Boolean, if `Y` linker relaxations will be enabled to slightly reduce the resulting binary's size. Default is `Y`. | +
OBJDIR | +Directory to store the intermediate object files, as they are generated from the source files. Default is `obj`. | +
OBJECT_FILES | +List of additional `.o` object files to link into the final binary. Default is blank (no additional objects). | +
DEBUG_FORMAT | +Debug ELF file format to generate. Default is `dwarf-2`. | +
DEBUG_LEVEL | +Level of the debugging information to generate in the compiled object files. Debug is 2 (medium level debugging information). | +
COMPILER_PATH | +Path to the compiler to use, in case a specific compiler should be substituted for the one in the system's `PATH` variable. Default is blank (use `PATH` provided compiler). | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +
hid | +Program a LUFA HID class bootloader device, using the `hid_bootloader_cli.py` Python script. | +
hid-ee | +Program a LUFA HID class bootloader device's EEPROM, using the `hid_bootloader_cli.py` Python script and a shim application which is programmed into the target's flash. | +
teensy | +Program a LUFA HID class bootloader device or Teensy board, using the `teensy_loader_cli` tool. | +
teensy-ee | +Program a LUFA HID class bootloader device's EEPROM, using the `teensy_loader_cli` tool and a shim application which is programmed into the target's flash. | +
MCU | +Name of the Atmel processor model (e.g. `at90usb1287`). | +
TARGET | +Name of the application output file prefix (e.g. `TestApplication`). | +
N/A | +This module has no optional variables. | +
N/A | +This module provides no variables. | +
N/A | +This module provides no macros. | +