Download Files Properties

Debug ›› Debug Menu ›› Download Files ›› Download Files ››
Parent Previous Next

In the Download File Options dialog properties of a download file are configured.

Download File Options dialog


File Path

Indicates the path of the download file.

Always in project target directory

If this option is checked, then file's directory is ignored and the file is always searched for in the current project target's directory.

By checking this option, you can quickly switch project targets without having to redefine download files paths (remember that Build Manager will move all generated files to target output directory, which is different for every target).


File Format

Setting determines the file format of the download file. winIDEA will attempt to determine the format automatically as a file is added to the download files list, but you have to make sure that this setting is correct. Refer to your linker documentation for information on what formats your linker can generate.


Offset

Determines the value that will be added to address of every absolute object loaded. This includes program code and absolute symbols. Since all absolute object files contain address information, you will always use zero offset except for binary files. The offset can be defined for both symbols and code. Read the chapter below if you need to load the code and the symbols to different addresses.


Options

Load Code - Loads the code.

Load Symbols - Loads symbol information.

Optimize type information - Sometimes the compiler generates multiple type definition tags (typically for every time the header file that contains them is included by some C/C++ file).

The results are multiple entries under Browser/Typedefs, which isn’t wrong, but file conversion can take much longer.

If this option is checked, then types that already exist are not 'multiplied'.

If the program uses structures that have equal names, but different definitions, then variables of the 'optimized' type will not be displayed as expected, but rather using the first type structure with that name.


Advanced

This button opens an advanced options dialog for the selected file format.


Loading code and symbols to different addresses

In some cases it is necessary to load the code to a different address then the symbols. Let's say the code is loaded to 0x0 and after the CPU is started the bootloader loads the code to the execute address, e.g. 0x20000000. The addresses, as specified in the ELF file, are typically provided as depicted in the table below:

Type

Address type

Address

Code

Load address

0x0

Symbols

Execute address

0x20000000


This interferes with winIDEA's internal static code analysis, because winIDEA is not aware that the code will be copied by the bootloader.

To avoid this problem the download file needs to be specified two times:

1.Load symbols only, specify code offset to match the symbol addresses. This will resolve the static code analysis issue.


2.Load code only, do not specify code offset. This will load the code to the initial address, from which the bootloader will copy it to the execute address.