current_board_part - 2023.1 English

Vivado Design Suite Tcl Command Reference Guide (UG835)

Document ID
UG835
Release Date
2023-05-16
Version
2023.1 English

Get the current board_part object

Syntax

current_board_part [‑quiet] [‑verbose]

Returns

Current board_part object.

Usage

Name Description
[-quiet] Ignore command errors
[-verbose] Suspend message limits during command execution

Categories

Object, Project, Board

Description

Return the Xilinx® device used in the current project or design.

The board file, board.xml located in the data/boards folder of the Vivado® Design Suite installation area, stores information regarding board attributes. The board provides a representation of the overall system that the Xilinx device is a part of, and can help define key aspects of the design, such as clock constraints, I/O port assignments, and supported interfaces. You can create custom boards by defining a custom Board Interface file, as described in the Vivado Design Suite User Guide: System-Level Design Entry (UG895).

The board part provides a representation of the Xilinx device in the context of the board-level system, and is represented by the part0 component in the Board Interface file.

The board can be specified:

  • When the project is created by selecting Boards from the Default Part dialog box.
  • By setting the BOARD_PART property on the current project as shown in the example.
  • By selecting the Project Device in the Settings dialog box in an open project in the Vivado IDE.

Refer to the Vivado Design Suite User Guide: System-Level Design Entry (UG895) for information on creating projects, and on configuring project settings.

Important: When you specify the board with the set_property command, the target part is also changed to match the part required by the specified BOARD_PART property.

The current_board_part command returns the NAME property of the current board part. The command returns a warning when the project targets a Xilinx FPGA instead of a board, or when the BOARD_PART property has not been defined. The command returns an error if it fails.

Arguments

-quiet - (Optional) Execute the command quietly, returning no messages from the command. The command also returns TCL_OK regardless of any errors encountered during execution.
Note: Any errors encountered on the command-line, while launching the command, will be returned. Only errors occurring inside the command will be trapped.
-verbose - (Optional) Temporarily override any message limits and return all messages from this command.
Note: Message limits can be defined with the set_msg_config command.

Example

The following example sets the BOARD_PART property for the current project, then reports the board part in use by the project:

set_property BOARD_PART xilinx.com:kc705:part0:1.0 [current_project]
current_board_part
   xilinx.com:kc705:part0:1.0

This example shows the results of setting the BOARD_PART property, causing the target part to be changed as well. The target part is changed automatically, and a warning is returned:

set_property BOARD_PART xilinx.com:ac701:part0:1.0 [current_project]
WARNING: [Project 1-153] The current project part 'xc7k325tffg900-2'
   does not    match with the 'XILINX.COM:AC701:PART0:1.0' board part
   settings. The project part will be reset to 'XILINX.COM:AC701:PART0:1.0'
   board part.
INFO: [Project 1-152] Project part set to artix7 (xc7a200tfbg676-2)
Note: You can use the report_property command to check the BOARD_PART and PART property on the current_project to see the changes.

The following example shows how to get DEVICE, PACKAGE, SPEED and FAMILY properties for the part defined by the PART_NAME property of the current board part:

get_property DEVICE [get_parts [get_property PART_NAME \
   [current_board_part]]]
get_property PACKAGE [get_parts [get_property PART_NAME \
   [current_board_part]]]
get_property SPEED [get_parts [get_property PART_NAME \
   [current_board_part]]]
get_property FAMILY [get_parts [get_property PART_NAME \
   [current_board_part]]]