Intel® Quartus® Prime Standard Edition用户指南: 调试工具

ID 683552
日期 9/24/2018
Public
文档目录

2.8.1. 查找可用服务

System Console使用一个虚拟文件系统来组织可用服务,这类似于Linux系统中的/dev location 板级连接,器件类型和IP名称都是服务路径的一部分。服务实例由它们在文件系统中的唯一服务路径引用。要检索特定服务的服务路径,请使用命令get_service_paths <service-type>

查找服务路径

#We are interested in master services.
set service_type "master"

#Get all the paths as a list.
set master_service_paths [get_service_paths $service_type]

#We are interested in the first service in the list.
set master_index 0

#The path of the first master.
set master_path [lindex $master_service_paths $master_index]

#Or condense the above statements into one statement:
set master_path [lindex [get_service_paths master] 0]

System Console命令需要服务路径来标识要访问的服务实例。不同组件的路径可以在System Console的运行之间和版本之间进行更改。使用get_service_paths命令获取服务路径。

服务路径的字符串值取决于工具的不同版本。使用marker_node_info命令从路径获取信息。

System Console在启动时自动发现大多数服务。System Console自动扫描所有基于JTAG和USB的服务实例并检索它们的服务路径。System Console不会自动发现诸如TCP/IP的某些服务。使用add_service通知System Console有关这些服务的信息。

marker_node_info

使用marker_node_info命令获取关于已发现服务的信息。

set slave_path [get_service_paths -type altera_avalon_uart.slave slave]
array set uart_info [marker_node_info $slave_path]
echo $uart_info(full_hpath)