Specifications
CHAPTER 1: DESIGN FLOW
COMMAND-LINE DESIGN FLOW
26 ■ INTRODUCTION TO QUARTUS II ALTERA CORPORATION
Figure 12 shows an example of a Tcl script.
Figure 12. Example of a Tcl Script (Part 1 of 2)
# Since ::quartus::report is not pre-loaded
# by quartus_sh, load this package now
# before using the report Tcl API
load_package report
# Since ::quartus::flow is not pre-loaded
# by quartus_sh, load this package now
# before using the flow Tcl API
# Type "help -pkg flow" to view information
# about the package
load_package flow
#------ Get Actual Fmax data from the Report File ------#
proc get_fmax_from_report {} {
#-------------------------------------------------------#
global project_name
# Load the project report database
load_report $project_name
# Get the actual Fmax
set actual_fmax [get_timing_analysis_summary_results -clock_setup
clock -actual]
# Now unload the project report database
unload_report
return $actual_fmax
}
#------ Set the project name to chiptrip ------#
set project_name chiptrip
#------ Create or open project ------#
if {project_exists $project_name} {
#------ Project already exists -- open project -------#
project_open $project_name
} else {
#------ Project does not exist -- create new project ------#
project_new $project_name
}
#------ Fmax requirement: 155.55MHz ------#
set required_fmax 155.55MHz










