get_clocks (::quartus::project)
The following table displays information for the get_clocks Tcl command:
| Tcl Package and Version |
Belongs to ::quartus::project 2.0 |
||
| Syntax | get_clocks [-h | -help] [-long_help] | ||
| Arguments | -h | -help | Short help | |
| -long_help | Long help with examples and possible return values | ||
| Description |
Returns a list of lists consisting of node name and clock
setting name. The output has the following format:
{{<node name #1> <clock setting name #1>}
{<node name #2> <clock setting name #2>}
...
{<node name #N> <clock setting name #N>}}
If <node name> is empty, <clock setting name> was not assigned
to any node. If <clock setting name> is empty, <node name>
was assigned to an undefined <clock setting name>.
You can create <clock setting name> using the
"create_base_clock" or "create_relative_clock" commands. You
can create node names using the following command:
set_instance_assignment -name CLOCK_SETTINGS -to <clock setting name> <node name>
|
||
| Example Usage |
# Search for all pairs of node names and clock setting names
# and print the information
set clock_lists [get_clocks]
foreach clock_asgn $clock_lists {
set node_name [lindex $clock_asgn 0]
set clock_setting_name [lindex $clock_asgn 1]
if { $node_name == "" } {
puts "No node uses the clock \"$clock_setting_name\""
} elseif {$clock_setting_name == ""} {
puts "The node \"$node_name\" uses an undefined clock setting";
} else {
puts "The node \"$node_name\" uses the clock \"$clock_setting_name\""
}
}
|
||
| Return Value | Code Name | Code | String Return |
| TCL_OK | 0 | INFO: Operation successful | |