Package: axi_bfm_pkg

Description

=================================================================================================

Constants

Name Type Value Description
C_SCOPE string "AXI_BFM"
C_EMPTY_SLV_ARRAY t_slv_array(0 to 0)(0 downto 0) (others=>"U")
C_EMPTY_XRESP_ARRAY t_xresp_array(0 to 0) (others=>ILLEGAL)
C_AXI_BFM_CONFIG_DEFAULT t_axi_bfm_config ( max_wait_cycles => 1000,
max_wait_cycles_severity => TB_FAILURE,
clock_period => -1 ns,
clock_period_margin => 0 ns,
clock_margin_severity => TB_ERROR,
setup_time => -1 ns,
hold_time => -1 ns,
bfm_sync => SYNC_ON_CLOCK_ONLY,
match_strictness => MATCH_EXACT,
num_aw_pipe_stages => 1,
num_w_pipe_stages => 1,
num_ar_pipe_stages => 1,
num_r_pipe_stages => 1,
num_b_pipe_stages => 1,
id_for_bfm => ID_BFM,
id_for_bfm_wait => ID_BFM_WAIT,
id_for_bfm_poll => ID_BFM_POLL )

Types

Name Type Description
t_xresp ( OKAY,
EXOKAY,
SLVERR,
DECERR,
ILLEGAL )
t_xresp_array array (natural range <>) of t_xresp
t_axprot ( UNPRIVILEGED_NONSECURE_DATA,
UNPRIVILEGED_NONSECURE_INSTRUCTION,
UNPRIVILEGED_SECURE_DATA,
UNPRIVILEGED_SECURE_INSTRUCTION,
PRIVILEGED_NONSECURE_DATA,
PRIVILEGED_NONSECURE_INSTRUCTION,
PRIVILEGED_SECURE_DATA,
PRIVILEGED_SECURE_INSTRUCTION )
t_axburst ( FIXED,
INCR,
WRAP )
t_axlock ( NORMAL,
EXCLUSIVE )
t_axi_bfm_config Configuration record to be assigned in the test harness.
t_axi_write_address_channel AXI Interface signals
t_axi_write_data_channel
t_axi_write_response_channel
t_axi_read_address_channel
t_axi_read_data_channel
t_axi_if

Functions

Description

BFM procedures


init_axi_if_signals

  • This function returns an AXI interface with initialized signals.
  • All AXI input signals are initialized to 0
  • All AXI output signals are initialized to Z

Description

axi_write

This procedure writes data to the AXI interface specified in axi_if

  • When the write is completed, a log message is issued with log ID id_for_bfm

Description

axi_read

This procedure reads data from the AXI interface specified in axi_if,
and returns the read data in rdata_value.

Description

axi_check

This procedure reads data from the AXI interface specified in axi_if,
and compares it to the data in data_exp.

  • If the received data inconsistent with data_exp, an alert with severity
    alert_level is issued.
  • If the received data was correct, a log message with ID id_for_bfm is issued.