02.03.2014 Views

Tornado

Tornado

Tornado

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

7<br />

Debugger<br />

wtx-tool-name<br />

The name supplied for the debugger session to the target server. This is the<br />

name reported in the launcher’s list of tools attached to a target. Default:<br />

crosswind. If you often run multiple debugger sessions, you can use this<br />

parameter to give each session a distinct name.<br />

7.5 System-Mode Debugging<br />

7<br />

By default, in CrossWind you debug only one task at a time. The task is selected<br />

either by using the run command to create a new task, or by using attach to debug<br />

an existing task. When the debugger is attached to a task, debugger commands<br />

affect only that particular task. For example, when a breakpoint is set it applies<br />

only to that task. When the task reaches a breakpoint, only that task stops, not the<br />

entire system. This form of debugging is called task mode.<br />

<strong>Tornado</strong> also supports an alternate form of debugging, where you can switch<br />

among multiple tasks (also called threads) and even examine execution in system<br />

routines such as ISRs. This alternative mode is called system mode debugging; it is<br />

also sometimes called external mode.<br />

Most of the debugger features described elsewhere in this manual, and the<br />

debugging commands described in GDB User’s Guide, are available regardless of<br />

which debugging mode you select. However, certain debugging commands<br />

(discussed below in 7.5.2 Thread Facilities in System Mode, p.262) are useful only in<br />

system mode.<br />

NOTE: The run command is not available in system mode, because its use of a new<br />

subordinate task is more intrusive in that mode. In system mode, use the shell to<br />

start new tasks as discussed in 5.2.6 Using the Shell for System Mode Debugging,<br />

p.170, then attach to them with the thread command.<br />

7.5.1 Entering System Mode<br />

To debug in system mode, first make sure your debugger session is not attached to<br />

any task (type the command detach, or select Detach from the Targets menu).<br />

Then issue the following command:<br />

261

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!