Difference between revisions of "Bootloader Handling In Embedded Studio"

From SEGGER Wiki
Jump to: navigation, search
(Created page with "Whenever a new project is created with Embedded Studio, it is usually assumed that the .elf file points to the starting point of the application. This is usually the case. How...")
 
Line 1: Line 1:
 
Whenever a new project is created with Embedded Studio, it is usually assumed that the .elf file points to the starting point of the application. This is usually the case.
 
Whenever a new project is created with Embedded Studio, it is usually assumed that the .elf file points to the starting point of the application. This is usually the case.
However should you have e.g. a bootloader that needs to be executed first the project must be edited accordingly.
+
However should you have e.g. a bootloader that needs to be executed first the project must be adjusted accordingly.
   
 
__TOC__
 
__TOC__
Line 8: Line 8:
 
Should your setup be that you have a bootloader in ROM that needs to be executed first, simply set ''Debug > Debugger > Start From Entry Point Symbol'' option to ''No''.<br/>
 
Should your setup be that you have a bootloader in ROM that needs to be executed first, simply set ''Debug > Debugger > Start From Entry Point Symbol'' option to ''No''.<br/>
 
This way the target will run like it would after a power-on reset without any debug connection.
 
This way the target will run like it would after a power-on reset without any debug connection.
 
   
 
'''''Note:''''' Some devices require a reset after download. In that case set ''Debug > Target Script > Load End Script'' to ''TargetInterface.resetAndStop();''.<br/>
 
'''''Note:''''' Some devices require a reset after download. In that case set ''Debug > Target Script > Load End Script'' to ''TargetInterface.resetAndStop();''.<br/>
This way the target is explicitly reset another time after the download has finished.
+
This way the target is explicitly reset another time after the download has finished. That is needed e.g. if your ROM bootloader does some signature check of your just downloaded application which would fail if no additional reset is issued.
  +
  +
===Software bootloader===
  +
For a software/"regular" bootloader the ''Start From Entry Point Symbol'' option has also to be set to no as above. The additional reset step is usually not required.

Revision as of 10:23, 19 April 2023

Whenever a new project is created with Embedded Studio, it is usually assumed that the .elf file points to the starting point of the application. This is usually the case. However should you have e.g. a bootloader that needs to be executed first the project must be adjusted accordingly.

ROM bootloader

Should your setup be that you have a bootloader in ROM that needs to be executed first, simply set Debug > Debugger > Start From Entry Point Symbol option to No.
This way the target will run like it would after a power-on reset without any debug connection.

Note: Some devices require a reset after download. In that case set Debug > Target Script > Load End Script to TargetInterface.resetAndStop();.
This way the target is explicitly reset another time after the download has finished. That is needed e.g. if your ROM bootloader does some signature check of your just downloaded application which would fail if no additional reset is issued.

Software bootloader

For a software/"regular" bootloader the Start From Entry Point Symbol option has also to be set to no as above. The additional reset step is usually not required.