Fast Models Debugger Configuration: Fast Models Debugger Configuration

Keil, An ARM® Company Fast Models Debugger Configuration

This guide describes the options for configuring the Fast Models Debugger Driver used for debugging applications simulated with Fast Models.

  • Debug Driver Configuration describes the configuration options.
  • Debug Applications running on Fast Models.

Revision History

  • May 2018 - Updated screenshots, link to Fast Models Reference Manual
  • December 2012 - Initial Revision

Copyright © Keil, An ARM Company. All rights reserved.


Fast Models Debugger Configuration: Debug Driver Configuration

Debug Driver Configuration

To configure the driver:

  1. Options for Target Button Open the dialog Options for Target - Debug:

    Set Use: and select Models Cortex-M Debugger.

    Select Target Driver

  2. Click Settings to open the dialog Models Cortex-M Target Driver Setup.

    Target Driver Screen

    The target driver configuration screen consists of two parts:

    • Use: Launch Simulation - the µVision Debugger starts and finishes a simulation model.
    • Use: Running Simulation - the µVision Debugger connects to an already running simulation model.

Configure Launch Simulation

Launch Simulation mode starts and finishes a simulation model whenever a µVision debugging session is started or finished.

Target Driver Setup

  1. Enable Use: Launch Simulation.
  2. In Command enter the simulation model executable file. Usually an *.exe or *.bat file. MDK-Professional users will find all supported Fixed Virtual Platform models under µVision_installation_path\ARM\FVP.
  3. In Arguments specify the values that µVision will pass to the model executable file. The field is optional.
  4. In Timeout area:
    • In Connection specify the maximum time during which µVision tries to connect and start the simulation model. Default is 10 (Sec).
    • In Communication choose whether the debugger shall run other communication timeouts after debug connection is established. Disabling timeouts may be needed for customized Fast Models that perform some operations longer than internal debug timeouts. In such case if the target is not responsive the user would need to manually close the debug session using µVision controls. Default is On.
  5. For setting the Target, click the Browse button and select the simulation target. The list might contain more than one target. Only model targets that correspond to the CPU type of the project are displayed.

    Select Simulation Target

  6. In Coverage File specify a file name. Default location is the µVision project directory. If a file is specified, then the file is passed to the model executable to dump coverage information that is collected during simulation. The field is optional.
    • Enable Store Coverage on Disconnect to dump the coverage information in the specified file.
    • Enable Load Coverage at Connect reads the information from the specified coverage file into the µVision debugger when the next debug session is started. Then, coverage information is annotated in the source code and disassembly as explained in the µVision manual.
  7. In Configuration File specify a file name. Default location is the µVision project directory. If a file is specified, then the file is passed to the model executable file using the argument -f config_file. The field is optional.
    • Click Generate to create a default configuration file. The simulation model is launched with the argument --list-params -o -config_file for generating the file.
    • Click Edit to open the file.

Note

  • Refer to Model Shell for Fast Models Reference Manual for details about arguments, parameters, and configuration file.
  • Use the COVERAGE command to save the coverage information in GCOV format.

Configure Running Simulation

Allows connecting to an already running Fast Models simulation model.

Select Run Simulation

Where

Target | The unique target name within a simulation model. One model can have multiple targets.
CPU | CPU core type. Only model targets that correspond to the CPU type of the project are displayed.
Simulation | Name of the simulation model.
Sim ID | Unique ID for the simulation process. Each simulation model has its own identifier.
Shut Down Simulation | Close the simulation model when finishing the debugging session.
Update List | Refresh the simulation model target list.

To select a running simulation model for debugging:

  1. Enable Use: Running Simulation.
  2. Enable a Target. One target can be selected at a time.
  3. Optionally enable Shut Down Simulation.

Searching a Remote Simulation Model

By default, models with a CADI server search only the local host. Setting the CADI_TARGET_MACHINE environment variable extends that search for running models to a designated host IP address (IPv4) and port. For example:

set CADI_TARGET_MACHINE=10.34.0.4:7002

When CADI_TARGET_MACHINE is set, running models with a CADI Server on the specified machine with the specified port will be searched for and listed in the Running Simulation dialog.

Copyright © Keil, An ARM Company. All rights reserved.


Fast Models Debugger Configuration: Debug Applications

Debug Applications

To debug applications with Fast Models:

  1. Configure the Debugger
  2. Start/Stop Debug Button Start debugging using the menu Debug — Start/Stop Debug Session. Depending on the options set in the dialog Options for Target — Debug, the µVision Debugger starts or connects to an existing Fast Models simulation.

The Status Bar shows the Fast Models target to which the debugging session is connected. Additional information is available in the general description of the Status Bar for CPUs that have enabled TrustZone for Armv8-M.

The following debugging windows and dialogs are supported:

  • Breakpoints allows defining stop conditions for program execution.
  • Call Stack and Locals Window shows objects that are currently in the call tree.
  • Command Window allows entering and viewing executed commands.
  • Disassembly Window allows program testing at the level of assembly instructions.
  • Memory Map displays the memory areas and their access rights.
  • Memory Window displays and allows modifying memory content.
  • Registers Window shows and allows modifying the register content.
  • Symbols Window shows debug symbol information of the application program.
  • System Viewer displays peripheral register information.
  • Toolbox provides configurable buttons for executing debugging commands interactively.
  • Watch Window displays and allows modifying program variable values at runtime.

Copyright © Keil, An ARM Company. All rights reserved.