Using Vivado Debug Cores - 2020.2 English

Vivado Design Suite User Guide: Dynamic Function eXchange (UG909)

Document ID
Release Date
2020.2 English

Vivado debug cores (ILA, VIO, etc.) can be placed in any part of a Dynamic Function eXchange design, including within RMs. A specific design methodology is necessary to connect these cores to a central Debug Hub for communication throughout the device.

The connectivity between the central Debug Hub in static can be set up automatically, and this is triggered by a specific naming convention for the port names on the RP. These twelve pins are required, and the hub will be inferred if these exact names are used. Examples in Verilog and VHDL are below.

Verilog instantiation in the static design:

my_count counter_inst (

VHDL component declaration and instantiation in the static design:

component my_count is
Port ( clk : in STD_LOGIC;
dout : out STD_LOGIC;
S_BSCAN_drck: IN std_logic := '0';
S_BSCAN_shift: IN std_logic := '0';
S_BSCAN_tdi: IN std_logic := '0';
S_BSCAN_update: IN std_logic := '0';
S_BSCAN_sel: IN std_logic := '0';  
S_BSCAN_tdo: OUT std_logic;
S_BSCAN_tms: IN std_logic := '0';
S_BSCAN_tck: IN std_logic := '0';
S_BSCAN_runtest: IN std_logic := '0';
S_BSCAN_reset: IN std_logic := '0';
S_BSCAN_capture: IN std_logic := '0';
S_BSCAN_bscanid_en: IN std_logic := '0'
end component;
counter_inst: my_count
port map (clk => my_clk,
dout => dout,
S_BSCAN_drck => open, 
S_BSCAN_shift => open, 
S_BSCAN_tdi => open, 
S_BSCAN_update => open, 
S_BSCAN_sel => open, 
S_BSCAN_tdo => open, 
S_BSCAN_tms => open, 
S_BSCAN_tck => open, 
S_BSCAN_runtest => open, 
S_BSCAN_reset => open, 
S_BSCAN_capture => open, 
S_BSCAN_bscanid_en => open
Note: These input ports must receive an initial value to use the open keyword, and that initial value must be 0. Ports tied to 1 will not connect to the local debug hub.

Within the RM top-level RTL, leave these twelve ports unconnected. Debug Hubs are inserted as black boxes, one in static and one in each RM during synthesis. These inserted IP are then expanded during opt_design. This is done for each RM, even if there are no debug cores within that RM (including greybox RMs).

If these exact port names cannot be used for any reason, such as the need to explicitly connect to multiple BSCAN instances, attributes can be used to drive the Debug Hub insertion. This approach must also be used if the first configuration processed does not have any debug cores present; inference of Debug Hubs is not done if no debug cores within the RM can be found byVivado implementation tools.

In the syntax shown below, do not change anything other than the port names in order to assign Debug ports. These attributes are to be used in all RM top level source files.

Verilog attributes in the RM top level:

expanse="page">(* X_INTERFACE_INFO = " S_BSCAN drck" *) (* DEBUG="true" *) 
input my_drck; 
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN shift" *) (* DEBUG="true" *) 
input my_shift;     
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN tdi" *) (* DEBUG="true" *) 
input my_tdi;      
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN update" *) (* DEBUG="true" *)   
input my_update;     
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN sel" *) (* DEBUG="true" *)    
input my_sel;      
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN tdo" *) (* DEBUG="true" *)    
output my_tdo;      
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN tms" *) (* DEBUG="true" *)    
input my_tms;      
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN tck" *) (* DEBUG="true" *)    
input my_tck;      
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN runtest" *) (* DEBUG="true" *)  
input my_runtest;    
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN reset" *) (* DEBUG="true" *) 
input my_reset;     
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN capture" *) (* DEBUG="true" *)  
input my_capture;    
expanse="page">(* X_INTERFACE_INFO = " S_BSCAN bscanid_en" *) 
(* DEBUG="true" *) input my_bscanid_en; 

VHDL attributes in the RM top level:

expanse="page">attribute X_INTERFACE_INFO : string; 
expanse="page">attribute DEBUG : string; 
expanse="page">attribute X_INTERFACE_INFO of my_drck: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_drck: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_shift: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_shift: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_tdi: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_tdi: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_update: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_update: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_sel: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_sel: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_tdo: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_tdo: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_tms: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_tms: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_tck: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_tck: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_runtest: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_runtest: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_reset: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_reset: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_capture: signal is " S_BSCAN 
expanse="page">attribute DEBUG of my_capture: signal is "true"; 
expanse="page">attribute X_INTERFACE_INFO of my_bscanid_en: signal is " 
S_BSCAN bscanid_en"; 
expanse="page">attribute DEBUG of my_bscanid_en: signal is "true"; 

There are currently two limitations to this solution:

  1. All debug cores within RMs must be instantiated. The MARK_DEBUG insertion flow is not yet supported.
  2. A greybox configuration cannot be the first one processed. The debug bridge must be established within an RM with debug cores to establish connectivity with the debug hub before moving to versions that do not contain debug cores.

For an example of this core insertion as well as functionality within the Vivado Hardware Manager, see this link in Vivado Design Suite Tutorial: Dynamic Function eXchange (UG947).