Source window. Model Technology Special EE/SE, Elite EE/SE
Pubblicità
Pubblicità
Source window
Source window
The Source window allows you to view and edit your HDL source code. Select an item in the
or use the File menu to add a source file to
the window, then select a process in the Process window
process; an arrow next to the line numbers indicates the selected process. (Your source code can remain hidden if you wish, see
"Source code security and nodebug"
. A dot next to a line number indicates a breakpoint. Breakpoints can only occur at executable lines, which are indicated by green line numbers.
If any breakpoints have been set, each is signified by a colored dot next to a line number at the left side of the window pane. To set a breakpoint, click at or near the line number in the numbered area at the left side of the window. The breakpoints are toggles, so you can click again to delete an existing breakpoint.
There is no limit to the number of breakpoints you can set. See also the
bp
command
(CR-40)
(breakpoint) command.
To look at a file that is not currently being displayed, use the Structure window
to select a different design unit or use the Source menu selection: File >
Open. The pathname of the source file is indicated in the header of the Source window.
You can copy and paste text between the Source window and the
; select the text you want to copy, then paste it into the Main window with the middle button (3-button mouse), right button (2-button mouse).
10-200
ModelSim EE Graphic Interface ModelSim EE/SE User’s Manual
Source window
The Source window menu bar
The following menu commands are available from the Source window menu bar.
File menu
New
Open
Use Source
Source Directory
Save
Save_As
Compile
Close edit a new (VHDL, Verilog or Other) source file select a source file to open specifies an alternative file to use for the current source file; this alternative source mapping exists for the current simulation only add to a list of directories (the SourceDir variable in modelsim.tcl) to search for source files save the current source file save the current source file with a different name complies HDL source files close this copy of the Source window; you can create a new window with
View > New from the "The Main window menu bar"
Edit menu
<editing option>
Find...
read only
To edit a source file, make sure the Read Only option in the Source Options dialog box is not selected (use the Source menu Edit > read only selection). basic editing options include: Cut, Copy, Paste, Select All, and Unselect All; see:
"Editing the command line, the current source file, and notepads"
find the specified text string within the source file; match case option toggles the read-only status of the current source file
Object menu
Describe
Examine displays information about the selected HDL item; same as the
describe
command
(CR-63)
; the item name is shown in the title bar displays the current value of the selected HDL item; same as the
examine
(CR-81) command; the item name is shown in the title bar
ModelSim EE/SE User’s Manual ModelSim EE Graphic Interface
10-201
Source window
Options menu
Options
Window menu
Initial Layout
Cascade
Tile Horizontally
Tile Vertically
Icon Children
Icon All
Deicon All
Customize
<window_name> open the Source Options dialog box, see
"Setting Source window options"
restore all windows to the size and placement of the initial full-screen layout cascade all open windows tile all open windows horizontally tile all open windows vertically icon all but the Main window icon all windows deicon all windows use
to define and add a button to either the menu bar, tool bar, or status bar of the specified window lists the currently open windows; select a window name to switch to, or show that window if it is hidden; when the source window is available, the source file name
is also indicated; open additional windows from the "View menu"
Main window, or use the
view
command
(CR-180)
10-202
ModelSim EE Graphic Interface ModelSim EE/SE User’s Manual
Source window
The Source window tool bar
Buttons on the Source window tool bar gives you quick access to these ModelSim commands and functions.
open ile
s ou rc e f sa ve sou rc e fil e cu t co py pas te find st ep st ep ov er
Source window tool bar buttons
Button
Open Source File
open the Open dialog box
(you can open any text file for editing in the Source window)
Save Source File
save the file in the Source window
Menu equivalent
File > Open
File > Save
Cut
cut the selected text within the Source window
Edit > Cut
Copy
copy the selected text within the Source window
Edit > Copy
Other equivalents
select an HDL item in the
Structure window, the associated source file is loaded into the
Source window none see:
"Editing the command line, the current source file, and notepads"
see:
"Editing the command line, the current source file, and notepads"
ModelSim EE/SE User’s Manual ModelSim EE Graphic Interface
10-203
Source window
Source window tool bar buttons
Button
Paste
paste the copied text to the cursor location
Menu equivalent
Edit > Paste
Find
find the specified text string within the source file; match case option
Step
steps the current simulation to the next
HDL statement
Step Over
HDL statements are executed but treated as simple statements instead of entered and traced line by line
Edit > Find none none
Other equivalents
see:
"Editing the command line, the current source file, and notepads"
none use step command at the VSIM prompt see:
step
(CR-151)
command use the step -over command at the
VSIM prompt see:
step
(CR-151)
command
Editing the source file in the Source window
Several tool bar buttons (shown above), mouse actions, and special keystrokes can be used to edit the source file in the Source window. See
"Editing the command line, the current source file, and notepads"
keyboard editing options.
Checking HDL item values and descriptions
There are two quick methods to determine the value and description of an HDL item displayed in the Source window:
• select an item, then chose Object > Examine or Object > Description from the
Source window menu
• select an item with the right mouse button to view examine pop-up (select "now" to examine the current simulation time in VHDL code)
10-204
ModelSim EE Graphic Interface ModelSim EE/SE User’s Manual
Source window
You can also invoke the
examine
(CR-81)
and/or
describe
(CR-63)
command on the command line or in a macro.
Setting Source window options
Access the Source window options with this Source menu selection: Options >
Options.
• Colorize Source colorize key words, variables and comments
• Highlight Executable Lines highlights the line number of executable lines
The Source Options dialog box includes these options:
• Language select either VHDL or Verilog; sets language for key word colorizing
• Source Update Mode select freeze file to maintain the same source file in the Source window (useful when you have two Source windows open; one can be updated from the
, the other frozen) or freeze view to disable updating the source view from the
ModelSim EE/SE User’s Manual ModelSim EE Graphic Interface
10-205
Scarica
Pubblicità