Software

Object File Formats

While Microchip Studio uses ELF/DWARF as the preferred object file-/debug info-format, you may debug other formats. Several object file formats from various compiler vendors are supported. You can open and debug these files, but you may be unable to edit the code within Microchip Studio. Using your editor to edit code and Microchip Studio to debug (use the reload button), you will still have a powerful code/debug environment.

All external debug sessions require you to load an object file supported by Microchip Studio. Generally, an object file for debugging contains symbolic information not included in a release file. The debug information enables Microchip Studio to give extended possibilities when debugging, e.g., the source file stepping and breakpoints set in a high-level language like C.

Open the precompiled object files using the menu command Open fileOpen Object File for Debugging. See section Debug Object File in Microchip Studio for more info.

Table 1. Object File Formats Supported by Microchip Studio

Object File Format

Extension

Description

UBROF

.d90

UBROF is an IAR proprietary format. The debug output file contains a complete set of debugging information and symbols to support all types of watches. UBROF8 and earlier versions are supported. This is the default output format of IAR EW 2.29 and earlier versions. See below how to force IAR EW 3.10 and later versions to generate UBROF8.

ELF/DWARF

.elf

ELF/DWARF debug information is an open standard. The debug format supports a complete set of debugging information and symbols to support all types of watches. The version of the format read by Microchip Studio is DWARF2. AVR-GCC versions configured for DWARF2 output can generate this format.

AVRCOFF

.cof

COFF is an open standard intended for 3rd party vendors creating extensions or tools supported by the Microchip Studio

AVR Assembler format

.obj

The AVR assembler output file format contains source file info for source stepping. It is an internal Microchip format only. The .map file is automatically parsed to get some watch information.

Before debugging, make sure you have set up your external compiler/assembler to generate an object file with debug information in one of the formats above.

3rd party compiler vendors should output the ELF/DWARF object file format to ensure support in Microchip Studio. Optionally, you could provide an extension to have both debugging and compile support. See Contact Information for more information.

Tip:

How to generate an AVR-compatible ELF file in IARW32:

In the Project optionsOutput format dialog, choose elf/dwarf, and in the Project optionsFormat variant, select Arm-compatible '-yes'.

Tip:

How to force IAR EW 3.10 and later versions to generate UBROF8:

By default IAR EW 3.10 and later versions output UBROF9. Currently, Microchip Studio cannot read this format. To force the debug format to UBROF8, open the project options dialog, and change the Output format setting to ubrof 8 (forced). Note that the default filename extension is changed from '.d90' to '.dbg' when selecting this option. To keep the '.d90' extension, click the Override default check button and change the extension.