Get_user_data(), Example – Altera Mentor Verification IP Altera Edition AMBA AXI4-Stream User Manual

Page 170

Advertising
background image

Mentor Verification IP AE AMBA AXI4-Stream User Guide, V10.3

170

VHDL Monitor BFM
get_user_data()

April 2014

get_user_data()

This nonblocking procedure gets a user_data field array element for a monitor transaction that
is uniquely identified by the transaction_id field previously created by the

create_monitor_transaction()

procedure.

The user_data array element is identified by the optional index argument. If no index is
supplied, then the first user_data is accessed in the array.

Example

-- Create a monitor transaction.
-- Creation returns tr_id to identify the transaction.
create_monitor_transaction(3, tr_id, bfm_index,

axi4stream_tr_if_0(bfm_index));

-- Get the user_data field for the first transfer
-- of the tr_id transaction.
get_user_data(user_data, 0, tr_id, bfm_index,

axi4stream_tr_if_0(bfm_index));

-- Get the user_data field for the second transfer
-- of the tr_id transaction.
get_user_data(user_data, 1, tr_id, bfm_index,

axi4stream_tr_if_0(bfm_index));

Prototype

get_user_data
(

user_data: out std_logic_vector(AXI4STREAM_MAX_BIT_SIZE-1
downto 0 ) | integer;
index : in integer; --optional
transaction_id : in integer;
bfm_id : in integer;
signal tr_if : inout axi4stream_vhd_if_struct_t

);

Arguments

user_data

User data array values placed on the TUSER signals.

index

(Optional) Array element index number for user_data.

transaction_id

Transaction identifier. Refer to

Overloaded Procedure Common

Arguments

” on page 87 for more details.

bfm_id

BFM identifier. Refer to

Overloaded Procedure Common Arguments

on page 87 for more details.

tr_if

Transaction signal interface. Refer to

Overloaded Procedure Common

Arguments

” on page 87 for more details.

Returns

user_data

Advertising