Everything
2.6.1 Execute downloading

Download the load module file to be debugged to the debug tool that is currently connected.

Follow the steps below on the [Download File Settings] tab in the Property panel for the downloading, and then execute the downloading.

Caution

By default, CPU reset automatically occurs after downloading the file, and then the program is executed to the specified symbol position. If this operation above is not needed, specify [No] with both of the [CPU Reset after download] and [Execute to the specified symbol after CPU Reset] property.

(1)

Setting the [Download] category

Figure 2.13

[Download] Category

(a)

[Download files]

The names of files to be downloaded and download conditions are displayed (the number enclosed with "[ ]" indicates the number of files to be download).

Files that are specified as build target files in the main project or subprojects will automatically be selected as the files to be downloadedNote 1.

However, you can manually change the download files and the condition. In this case, see "2.6.2 Advanced downloading".Note 2

Note 1.

To download the load module files created by an external build tool (e.g., compilers and assemblers other than the build tools supplied with CS+), a debug-dedicated project needs to be created.
If you use a debug-dedicated project as the subject to debug, add your a download file to Download files node on project tree. The file to be downloaded will be reflected in this property.
See "CS+ Project Operation" for details on the using an external build tool and a debug-dedicated project.

Note 2.

The emulator does not support downloading to external flash memory.

(b)

[CPU Reset after download]

Specify whether to reset the CPU after downloading.

Select [Yes] to reset the CPU (default).

(c)

[Erase flash ROM before download] [Full-spec emulator][E1][E20]

Specify whether to erase the flash ROM before downloading.

Select [Yes] to erase the flash ROM (default: [No]).

If this property is set to [Yes], an erase will be performed in the area where the downloaded data exists.

(d)

[Automatic change method of event setting position]

If the file is downloaded again during debugging then the location (address) set for the currently configured event may change to midway in the instruction.

Specify with this property how to handle the target event in this circumstance.

Select one of the options from the following drop-down list.

Move to the head of instruction

Resets the subject event at the beginning address of the instruction.

Suspend event

Leaves the subject event pending (default).

Note, however, that this property setting only applies to the location setting of events without debugging information. The location setting of events with debug information is always moved to the beginning of the source text line.

(e)

[Allow downloading to Configuration Setting Area] [E2][IE850A]

Select whether to allow downloading to the Configuration Setting Area.

Select [Yes] to allow downloading to the Configuration Setting Area (default: [No]).

Reconnect to the debug tools when after downloading to the Configuration Setting Area.

Note that this property is set to [No] after downloading.

This property will not be saved in the project information.

(f)

[Allow downloading to Block Protection Area] [E2][IE850A]

Select whether to allow downloading to the Block Protection Area.

Select [Yes] to allow downloading to the Block Protection Area (default: [No]).

Reconnect to the debug tools when after downloading to the Block Protection Area.

Note that this property is set to [No] after downloading.

This property will not be saved in the project information.

(g)

[Allow downloading to Security Setting Area] [E2][IE850A]

Select whether to allow downloading to the Security Setting Area.

Select [Yes] to allow downloading to the Security Setting Area (default: [No]).

Reconnect to the debug tools when after downloading to the Security Setting Area.

Note that this property is set to [No] after downloading.

This property will not be saved in the project information.

(h)

[Allow downloading to Switch Area] [E2][IE850A]

Select whether to allow downloading to the Switch Area.

Select [Yes] to allow downloading to the Switch Area (default: [No]).

Reconnect to the debug tools when after downloading to the Switch Area.

Note that this property is set to [No] after downloading.

This property will not be saved in the project information.

(2)

Setting the [Debug Information]

Figure 2.14

[Debug information] Category

(a)

[Execute to the specified symbol after CPU Reset]

Specify whether to execute the program to the specified symbol position after CPU reset or downloading (for only when the [CPU Reset after download] property is set to [Yes]).

Select [Yes] to execute the program to the specified symbol position after CPU reset (default).

Remark

When the [CPU Reset after download] property is set to [Yes], the operation after downloading is as follows:

-

If [Yes] is selected for this property, the Editor panel will open automatically with displaying source text of the position specified with the [Specified symbol] property after downloading.

-

If [No] is selected for this property, the Editor panel will open with displaying source text of the reset address (when if the source text has not been allocated to the reset address, the contents of the reset address is displayed in the Disassemble panel).

(b)

[Specified symbol]

This property appears only when the [Execute to the specified symbol after CPU Reset] property is set to [Yes].

Specify the position at which the program is stop after CPU reset.

Directly enter an address expression between 0 and "last address in address space" (default: [_main]).

Note, however, that the program will not be executed if the specified address expression cannot be converted into an address.

Remark

Normally, specify the following.
For assembly source: Start label corresponding to main function
For C source: Symbol assigned to the start of the main function name

(c)

[The upper limit size of the memory usage [Mbytes]]

Specify the upper limit on the amount of memory to be used in reading the debug information.

When the amount of memory being used exceeds the upper limit specified here, memory is made available by discarding debug information that has been read until the amount of memory in use is reduced to half of this upper limit (lowering the upper limit might improve the situation when shortages of memory are arising).

Directly enter a decimal number between 100 and 1000 (unit: Mbyte) (default: [500]).

Caution

In some cases, lowering the upper limit may lead to poorer responsiveness since it leads to more frequent discarding and re-reading of debug information.

(3)

Executing a download

Click the button on the Debug toolbar.

If this operation is performed while disconnecting from the debug tool, the application automatically connects to the debug tool, and then performs the download.

Remark

When a program that has been modified during debugging is re-downloaded, you can easily build and download it by selecting [Build & Download] from the [Debug] menu on the Main window.

(4)

Canceling a download

To cancel a download, click the [Cancel] button on the Progress Status dialog box, which displays the progress of downloading, or press the [Esc] key.

 

If the load module file is successfully downloaded, the Editor panel opens automatically, and the contents of the downloaded file's source text are displayed.

Remark

You can automatically overwrite the value of I/O register/CPU register with the specified values before and after performing the download (see "2.20 Use Hook Function" for details).