• No results found

How Do I Create a Launch Configuration?

In document Wr Workbench Vxworks 6 by Example 3.3 (Page 118-121)

PART III: CUSTOMIZING THE OPERATING SYSTEM

8.3 How Do I Create a Launch Configuration?

This section provides instructions for the following tasks:

„ Creating a Launch Configuration For an Existing Project.

„ Creating a Launch Configuration Using the Run Menu.

„ Creating a Launch Configuration From a Target Connection.

„ Attaching to Running Tasks or Processes.

Running kernel tasks and real-time processes are similar procedures. Each has its own type of launch configuration, but there are only a few options and settings that differ between the two.

Attach Target Context launch configurations are different from the other launch configurations in that they do not actually run a program, but just connect a target and attach the debugger to some context that must already exist. Also, the information on the Launch Context tab is for review only, and cannot be changed.

This is because it reflects information about an actual running process.

NOTE: Some launch types may only be available in one mode, while other may have multiple launch types. For example, a DKM launch type is available in run, debug, and download launch mode.

8 Running and Debugging VxWorks Applications 8.3 How Do I Create a Launch Configuration?

Creating a Launch Configuration For an Existing Project

This is the easiest way to create a launch configuration for your project. In this task, you select a project in the Project Explorer, then select the Run or Debug command from the context menu.

To create a launch configuration for an existing project, do the following:

1. In the Project Explorer, select a project, right-click the project folder and from the context menu, select the appropriate command for your project type:

„ For DKMs, select one of the following: Run | Debug | Download VxWorks Kernel Task.

„ For RTP applications, select one of the following: Run | Debug VxWorks Real-Time Process | Download VxWorks Real-Time Process.

The Launch Configuration wizard opens to display configuration tabs for the type of launch you are creating.

2. Give the launch configuration a name.

At the top of the wizard, the Name field reflects the information Workbench knows about your project: the executable name, and the most recently active target connection, for example helloworld.vxe - vxsim0. You can change this name to anything you want.

Since kernel tasks also require you to specify an entry point, a kernel task launch configuration name will include noEntryPoint until you specify one.

3. Configure the settings on the Launch Context tab, in the following way:

a. Verify that Workbench selected the correct target connection, or specify multiple targets for the launch.

b. In the General section, specify an Entry Point for a kernel task, and verify the Exec Path on Host for an RTP application. None of the other fields are editable unless your target connection is active.

c. To edit them, click Close to close the wizard, activate the target connect you want to use, then right-click your project and reopen the launch configuration wizard. For details on each field, press the help key for your host.

d. If this is a debug mode launch configuration, a Debug section appears:

For a kernel task—specify whether it should break on entry and if Workbench should automatically attach spawned kernel tasks.

For an RTP application—specify where it should break.

4. (Optional) Configure the settings on the following tabs. You do not need to adjust these settings, unless the defaults are not optimum for your project.

a. On the Projects to Build tab, the project you selected appears by default.

If you want any others to be built as well, click Add and select them from the dialog.

b. On the Source tab, configure the source lookup path for your program. For details on how to do this, see Wind River Workbench User’s Guide: Debugging Projects.

c. On the Common tab, specify whether this launch should be available to you, or shared with your team. If it should be shared, type in the path or click Browse and navigate to the location where you want to store the launch configuration.

d. Also on this tab, specify whether this launch configuration should always appear in the Run, Debug (or for a kernel task, Download) Favorites menu.

e. If you are creating a kernel task launch configuration, you should see a Downloads tab. This tab displays a list of the build targets Workbench should download when you run this launch. The build target of the project you chose appears automatically. Click Add to include additional build targets.

5. Do one of the following:

„ To run your launch configuration now, click Run or Debug.

„ To save your configured launch configuration and run it later, click Apply, then Close.

Creating a Launch Configuration Using the Run Menu

The Workbench toolbar Run menu is another way to access the launch

configuration wizard. In this task, you select one of the Run or Debug commands from the Workbench Run menu.

To create a launch configuration using the Run menu, do the following:

1. Select Run > Run Configurations or Run > Debug Configurations. The Create, manage, and run configurations dialog box appears.

2. Select VxWorks Kernel Task or VxWorks Real-Time Process, then click New (or double-click the launch type).

3. Continue with the steps outlined in Creating a Launch Configuration For an Existing Project, p.111, starting with step 2.

Creating a Launch Configuration From a Target Connection

You can create a launch configuration based on a specific target connection in the Remote Systems view. In this task, you select a target connection, then select the Run or Debug command.

To create a launch configuration from a target connection, do the following:

1. Right-click a target connection, then select Run or Debug, then VxWorks Kernel Task or VxWorks Real-Time Process.

2. If Workbench finds an existing launch configuration whose settings match your selection, a dialog appears prompting you to select an action:

„ Use the selected launch configuration.

„ Edit the configuration, for example, to change the target.

„ Copy the configuration and then edit it (thereby preserving the original).

8 Running and Debugging VxWorks Applications

In document Wr Workbench Vxworks 6 by Example 3.3 (Page 118-121)