24.03.2013 Views

ModelSim SE User's Manual - Electrical and Computer Engineering

ModelSim SE User's Manual - Electrical and Computer Engineering

ModelSim SE User's Manual - Electrical and Computer Engineering

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Using the Tcl source comm<strong>and</strong> with DO files<br />

Macros (DO files) UM-491<br />

Either the do comm<strong>and</strong> or Tcl source comm<strong>and</strong> can execute a DO file, but they behave<br />

differently.<br />

With the source comm<strong>and</strong>, the DO file is executed exactly as if the comm<strong>and</strong>s in it were<br />

typed in by h<strong>and</strong> at the prompt. Each time a breakpoint is hit, the Source window is updated<br />

to show the breakpoint. This behavior could be inconvenient with a large DO file<br />

containing many breakpoints.<br />

When a do comm<strong>and</strong> is interrupted by an error or breakpoint, it does not update any<br />

windows, <strong>and</strong> keeps the DO file "locked". This keeps the Source window from flashing,<br />

scrolling, <strong>and</strong> moving the arrow when a complex DO file is executed. Typically an<br />

onbreak resume comm<strong>and</strong> is used to keep the macro running as it hits breakpoints. Add<br />

an onbreak abort comm<strong>and</strong> to the DO file if you want to exit the macro <strong>and</strong> update the<br />

Source window.<br />

<strong>ModelSim</strong> <strong>SE</strong> User’s <strong>Manual</strong>

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

Saved successfully!

Ooh no, something went wrong!