Please enable JavaScript to view this site.

winIDEA Help

Version: 9.21.150

Suspending peripheral devices

This chapter describes how to suspend peripheral devices. You can do this by using of:

  • a preferred solution, i.e., the Suspend peripherals while stopped option, or
  • an alternative solution, i.e., initialization scripts.

 

 

Suspend peripherals while stopped

For suspending peripheral devices (e.g., timers), enable the Hardware menu / CPU Options / Reset / At Initialization / Suspend peripherals while stopped option.

When this option is checked, selected peripheral functions (e.g., timers) are stopped when the application is stopped. Peripheral functions can be selected via the button ThreeDots.

It is generally recommended that this option is checked, as this results in more predictable behavior of the debugged application when using these peripheral functions.

Refer to the microcontroller and architecture reference manuals for details.

 

info-icon

This option, including its peripherals list, is available for specific microcontrollers only. If not supported, the option is greyed out.

 

If the option is not supported (greyed out), you can perform suspending peripheral devices by initialization scripts.

 

 

Initialization scripts

info-icon

Use of initialization scripts for suspending peripheral devices is the alternative solution; if possible, use the Suspend peripherals while stopped option.

 

The initialization scripts for suspending peripheral devices are downloaded in the Examples directory via Download Examples. Note that the downloaded scripts are not available for all devices. Each initialization file contains specific microcontroller configuration, which directly affects the application behavior being debugged. Initialization file configures suspend control of the peripheral modules.

 

Warning40x40

Note that the script may have to enable access to the peripheral in order to configure it, which may result in misbehaving of the application. Inspect the script to be sure of what it does.

 

 

winIDEA Configuration

 

number2

Open Hardware / CPU Options / Debugging dialog and check the Synchronize selected cores (stop/run) when possible check box.

 

number3

For all cores you want to be a part of synchronization, check the Hardware / CPU Options / Cores / <Core> / Synchronize this core option.

 

Number4

Open Hardware / CPU Options / Reset dialog.

 

Number5

Press Default in Initialize / Initialization before Debug session.

 

number6

Select Custom.

 

number7

Click on the arrow button of the Scripts field and select Add from workspace folder.

The initialization file is being executed by the debugger after every debug reset respectively before the debug download takes place.

 

 

The peripheral modules can be suspended along with the cores. To suspend the peripheral modules on a suspend signal, you need to enable some of them before they can be configured. Some peripheral modules are enabled out of reset but not all.

 

To summarize, for a predictable application behavior (from user point of view) in conjunction with the connected debugger, certain microcontroller logic and modules have to be pre-configured before the application can be debugged.

 

Copyright© iSYSTEM AG Carl-Zeiss-Str.1 85247 Schwabhausen Germany