Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Parameterized interface in uvm

Status
Not open for further replies.

karalamoorthy_p

Newbie level 5
Newbie level 5
Joined
Jun 6, 2013
Messages
9
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Visit site
Activity points
1,358
Hi,

Shall we use parameterized interface in UVM. Actually I want to use parameterized interface in uvm top.

I am trying to use this way, but it's not working properly.

In top module I am instantiating interface like this,

a = 3; b = 1;
para_interface #(.A(a),.B(b)) para_if();

In Interface file I am using like this,

interface para_interface #(A = 2,B = 1)();
logic high[A-1:0];

In base test I am setting the interface like this,
uvm_config_db #(virtual para_interface) :: set(null,"*","sigs",top_tb.para_if);

When I do like this I am getting the following error.

uvm_config_db #(virtual rst_clk_interface)::set(null,"*","sigs",top_tb.rst_clk_if);

when I do like this I am getting the following error.
|
ncelab: *E,TYCMPAT (/home/karlamoorthy.duraipandi/accurev/SDIL-HW/SDR4/SDR4_SOC_Ver_dev/sdr4/src_env/library/tests/test_base.sv,50|84): formal and actual do not have assignment compatible data types (expecting datatype compatible with 'virtual interface rst_clk_interface#(.NO_CLK(2),.NO_RST(1))' but found an incompatible 'rst_clk_interface#(.NO_CLK(3),.NO_RST(1)) instance' instead).


Please correct if I do anything wrong.

Thanks.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top