Back to main page
AVR UC3 Series Software Framework: the UTILS folder
Copyright © 2006-2008 Atmel Corporation
Introduction
This directory contains files that are used by all other directories of
the framework: it holds several linker script files, IAR & GCC pre-compiled
libraries of some Software Framework modules, and C/C++ files with general
usage defines, macros and functions.
UTILS folder Description
This directory consists of the following contents:
This file defines commonly used types and macros.
This module gathers a set of part-specific header files for the avr32-gcc Gnu Compiler Collection
and for the IAR IDE
(see the avr32-headers.zip file).
For installation of these header files, see the installation page.
This module gathers a set of useful functions to print data on the USART.
print_funcs.h is the interface of this module and
print_funcs.c is its implementation.
This module gathers a set of pre-compiled archive files for both GCC and IAR: one set for the DRIVERS, the other for the DSPLIB.
The /UTILS/LIBS/DRIVERS subfolder holds the libraries for some of the modules of the /DRIVERS folder.
It is compiled for all UC3™ A, A3, B, C and L Series devices, and for usual optimisations.
- For GCC, found under /UTILS/LIBS/DRIVERS/AT32UC3A/GCC:
- libdrivers-at32uc3a.a (no optimization)
- libdrivers-at32uc3a-balanced_opt.a
- libdrivers-at32uc3a-debug.a (for debug purpose)
- libdrivers-at32uc3a-size_opt.a (size optimized)
- libdrivers-at32uc3a-speed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DRIVERS/AT32UC3A/IAR:
- libdrivers-at32uc3a.r82 (no optimization)
- libdrivers-at32uc3a-balanced_opt.r82
- libdrivers-at32uc3a-size_opt.r82 (size optimized)
- libdrivers-at32uc3a-speed_opt.r82 (speed optimized)
GCC and IAR libraries share the same API. The header files are found
under /UTILS/LIBS/DRIVERS/AT32UC3A3/INCLUDE/. Note that these are
copies of the original header files from the DRIVERS/ modules.
- For GCC, found under /UTILS/LIBS/DRIVERS/AT32UC3A3/GCC:
- libdrivers-at32uc3a3.a (no optimization)
- libdrivers-at32uc3a3-balanced_opt.a
- libdrivers-at32uc3a3-debug.a (for debug purpose)
- libdrivers-at32uc3a3-size_opt.a (size optimized)
- libdrivers-at32uc3a3-speed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DRIVERS/AT32UC3A3/IAR:
- libdrivers-at32uc3a3.r82 (no optimization)
- libdrivers-at32uc3a3-balanced_opt.r82
- libdrivers-at32uc3a3-size_opt.r82 (size optimized)
- libdrivers-at32uc3a3-speed_opt.r82 (speed optimized)
GCC and IAR libraries share the same API. The header files are found
under /UTILS/LIBS/DRIVERS/AT32UC3B/INCLUDE/. Note that these are
copies of the original header files from the DRIVERS/ modules.
- For GCC, found under /UTILS/LIBS/DRIVERS/AT32UC3B/GCC:
- libdrivers-at32uc3b.a (no optimization)
- libdrivers-at32uc3b-balanced_opt.a
- libdrivers-at32uc3b-debug.a (for debug purpose)
- libdrivers-at32uc3b-size_opt.a (size optimized)
- libdrivers-at32uc3b-speed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DRIVERS/AT32UC3B/IAR:
- libdrivers-at32uc3b.r82 (no optimization)
- libdrivers-at32uc3b-balanced_opt.r82
- libdrivers-at32uc3b-size_opt.r82 (size optimized)
- libdrivers-at32uc3b-speed_opt.r82 (speed optimized)
GCC and IAR libraries share the same API. The header files are found
under /UTILS/LIBS/DRIVERS/AT32UC3C/INCLUDE/. Note that these are
copies of the original header files from the DRIVERS/ modules.
- For GCC, found under /UTILS/LIBS/DRIVERS/AT32UC3C/GCC:
- libdrivers-at32uc3c.a (no optimization)
- libdrivers-at32uc3c-balanced_opt.a
- libdrivers-at32uc3c-debug.a (for debug purpose)
- libdrivers-at32uc3c-size_opt.a (size optimized)
- libdrivers-at32uc3c-speed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DRIVERS/AT32UC3C/IAR:
- libdrivers-at32uc3c.r82 (no optimization)
- libdrivers-at32uc3c-balanced_opt.r82
- libdrivers-at32uc3c-size_opt.r82 (size optimized)
- libdrivers-at32uc3c-speed_opt.r82 (speed optimized)
GCC and IAR libraries share the same API. The header files are found
under /UTILS/LIBS/DRIVERS/AT32UC3L/INCLUDE/. Note that these are
copies of the original header files from the DRIVERS/ modules.
- For GCC, found under /UTILS/LIBS/DRIVERS/AT32UC3L/GCC:
- libdrivers-at32uc3l.a (no optimization)
- libdrivers-at32uc3l-balanced_opt.a
- libdrivers-at32uc3l-debug.a (for debug purpose)
- libdrivers-at32uc3l-size_opt.a (size optimized)
- libdrivers-at32uc3l-speed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DRIVERS/AT32UC3A3/IAR:
- libdrivers-at32uc3l.r82 (no optimization)
- libdrivers-at32uc3l-balanced_opt.r82
- libdrivers-at32uc3l-size_opt.r82 (size optimized)
- libdrivers-at32uc3l-speed_opt.r82 (speed optimized)
Libs can be rebuilt with a script: \UTILS\LIBS\DRIVERS\build.sh (no
argument). The sources used for the build of the libraries are under /DRIVERS/.
Note that USBB and MACB drivers are not part of the libs, since they
require a specific configuration file(respectively named conf_usb.h and
conf_eth.h) which are application-dependent.
The /UTILS/LIBS/DSPLIB subfolder holds the libraries for some of the modules of the /SERVICES/DSPLIB folder.
It is compiled for all UC3 devices, and for usual optimisations.
- The following libraries are optimized for AVR32 UC architecture revision 1 (e.g. AT32UC3B0256):
- For GCC, found under /UTILS/LIBS/DSPLIB/AT32UCR1/GCC:
- libdsp-at32ucr1-dspaccandsize_opt.a (algorithms accuracy and size optimized)
- libdsp-at32ucr1-dspaccuracy_opt.a (algorithms accuracy optimized)
- libdsp-at32ucr1-dspsize_opt.a (size optimized)
- libdsp-at32ucr1-dspspeed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DSPLIB/AT32UCR1/IAR:
- libdsp-at32ucr1-dspaccandsize_opt.r82 (algorithms accuracy and size optimized)
- libdsp-at32ucr1-dspaccuracy_opt.r82 (algorithms accuracy optimized)
- libdsp-at32ucr1-dspsize_opt.r82 (size optimized)
- libdsp-at32ucr1-dspspeed_opt.r82 (speed optimized)
- The following libraries are optimized for AVR32 UC architecture revision 2 (e.g. AT32UC3A0512):
- For GCC, found under /UTILS/LIBS/DSPLIB/AT32UCR2/GCC:
- libdsp-at32ucr2-dspaccandsize_opt.a (algorithms accuracy and size optimized)
- libdsp-at32ucr2-dspaccuracy_opt.a (algorithms accuracy optimized)
- libdsp-at32ucr2-dspsize_opt.a (size optimized)
- libdsp-at32ucr2-dspspeed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DSPLIB/AT32UCR2/IAR:
- libdsp-at32ucr2-dspaccandsize_opt.r82 (algorithms accuracy and size optimized)
- libdsp-at32ucr2-dspaccuracy_opt.r82 (algorithms accuracy optimized)
- libdsp-at32ucr2-dspsize_opt.r82 (size optimized)
- libdsp-at32ucr2-dspspeed_opt.r82 (speed optimized)
- The following libraries are optimized for AVR32 UC architecture revision 2 (e.g. AT32UC3A3256):
- For GCC, found under /UTILS/LIBS/DSPLIB/AT32UCR2/GCC:
- libdsp-at32ucr2-dspaccandsize_opt.a (algorithms accuracy and size optimized)
- libdsp-at32ucr2-dspaccuracy_opt.a (algorithms accuracy optimized)
- libdsp-at32ucr2-dspsize_opt.a (size optimized)
- libdsp-at32ucr2-dspspeed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DSPLIB/AT32UCR2/IAR:
- libdsp-at32ucr2-dspaccandsize_opt.r82 (algorithms accuracy and size optimized)
- libdsp-at32ucr2-dspaccuracy_opt.r82 (algorithms accuracy optimized)
- libdsp-at32ucr2-dspsize_opt.r82 (size optimized)
- libdsp-at32ucr2-dspspeed_opt.r82 (speed optimized)
- The following libraries are optimized for AVR32 UC architecture revision 3 (e.g. AT32UC3L064, AT32UC3C0512C):
- For GCC, found under /UTILS/LIBS/DSPLIB/AT32UCR3/GCC:
- libdsp-at32ucr3-dspaccandsize_opt.a (algorithms accuracy and size optimized)
- libdsp-at32ucr3-dspaccuracy_opt.a (algorithms accuracy optimized)
- libdsp-at32ucr3-dspsize_opt.a (size optimized)
- libdsp-at32ucr3-dspspeed_opt.a (speed optimized)
- For IAR, found under /UTILS/LIBS/DSPLIB/AT32UCR3/IAR:
- libdsp-at32ucr3-dspaccandsize_opt.r82 (algorithms accuracy and size optimized)
- libdsp-at32ucr3-dspaccuracy_opt.r82 (algorithms accuracy optimized)
- libdsp-at32ucr3-dspsize_opt.r82 (size optimized)
- libdsp-at32ucr3-dspspeed_opt.r82 (speed optimized)
GCC and IAR libraries share the same API, described in the dsp.h header
file, found under /UTILS/LIBS/DSPLIB/INCLUDE/. Note that this header file
is a copy of the original header file from the SERVICES/DSPLIB/INCLUDE folder.
Libs can be rebuilt with a script: \UTILS\LIBS\DSPLIB\build.sh (no argument).
The sources used for the build the libraries are under /SERVICES/DSPLIB/.
This module gathers a set of pre-written linker scripts per microcontroller and compiler.
For example, the following linker scripts for the AT32UC3A0512 microcontroller are under the ./LINKER_SCRIPTS/AT32UC3A/0512/ folder:
GCC/link_uc3a0512.lds : this script allows to link code with GCC.
IAR/lnkuc3a0512.xcl : this script allows to link code with IAR.
For example, the following linker scripts for the AT32UC3A3256 microcontroller are under the ./LINKER_SCRIPTS/AT32UC3A3/256/ folder:
GCC/link_uc3a3256.lds : this script allows to link code with GCC.
IAR/lnkuc3a3256.xcl : this script allows to link code with IAR.
For example, the following linker scripts for the AT32UC3B0256 microcontroller are under the ./LINKER_SCRIPTS/AT32UC3B/0256/ folder:
GCC/link_uc3b0256.lds : this script allows to link code with GCC.
IAR/lnkuc3b0256.xcl : this script allows to link code with IAR.
For example, the following linker scripts for the AT32UC3C0512C microcontroller are under the ./LINKER_SCRIPTS/AT32UC3C/0512C/ folder:
GCC/link_uc3c0512c.lds : this script allows to link code with GCC.
IAR/lnkuc3c0512c.xcl : this script allows to link code with IAR.
For example, the following linker scripts for the AT32UC3L064 microcontroller are under the ./LINKER_SCRIPTS/AT32UC3L/064/ folder:
GCC/link_uc3l064.lds : this script allows to link code with GCC.
IAR/lnkuc3l064.xcl : this script allows to link code with IAR.
This module gathers a set of useful C preprocessor macros. It is composed of the files
mrepeat.h: C preprocessor repeating set of macros,
preprocessor.h: include of all header files of this module (so that applications only use to include this file),
stringz.h: C preprocessor stringenizer set of macros,
tpaste.h: C preprocessor token manipulation set of macros.
This module gathers a set of pre-written startup files per compiler.
A startup file gets executed just after the reset vector and before the main() C function (when it's done doing its work, the startup actually jumps to the main() function).
The main mission of a startup file is to initialize critical registers (example: the stack pointer) and memory.
For example, the following GCC startup file is under the ./STARTUP_FILES/GCC/ folder:
crt0.S: example of a basic startup file, completely written in assembly language.
The AVR32 GNU Toolchain v2.1 has removed some newlib addons files that were present in the previous versions: exceptions, interrupts and usart support.
To minimize the effect on the Software Framework and on customers, these files have been added in the Software Framework as a module named NEWLIB_ADDONS.
The
NEWLIB_ADDONS module is organized as follows:
under UTILS/NEWLIB_ADDONS/ the src code,
under UTILS/NEWLIB_ADDONS/Build the scripts to build the libraries,
under UTILS/LIBS/NEWLIB_ADDONS/INCLUDE the nlao interface header files.
under UTILS/LIBS/NEWLIB_ADDONS/ the archive libs for AT32AP7, AT32UCR1, AT32UCR2, AT32UCR3:
- libnewlib_addons-at32xxxx-debug archive lib generated with -O0 -g (for debug)
- libnewlib_addons-at32xxxx archive lib generated with -O0 (no optimization)
- libnewlib_addons-at32xxxx-balanced_opt archive lib generated with -O2 (medium level optimization)
- libnewlib_addons-at32xxxx-speed_opt archive lib generated with -O3 (speed optimization)
- libnewlib_addons-at32xxxx-size_opt archive lib generated with -Os (size optimization)
>