aspirinnnnn
Member level 1
- Joined
- Jan 4, 2012
- Messages
- 33
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1,286
- Location
- Beijing,China
- Activity points
- 1,511
I have a interface like
but it seems that the slave_wren[0] and slave_wren[1] parts won't compile, wonder why?
if this is wrong , how can i work it around
Code:
interface mAHB_bus
#(
parameter SLAVE_NUM=8
);
logic [SLAVE_NUM-1:0] slave_wren;
logic [1:0] slave_size;
logic [15:0] slave_wraddr;
logic [31:0] slave_wrdata;
logic [SLAVE_NUM-1:0] slave_rden;
logic [15:0] slave_rdaddr;
modport bus(
output slave_wren,
output slave_size,
output slave_wraddr,
output slave_wrdata,
output slave_rden,
output slave_rdaddr
);
modport slave0(
input slave_wren[0],
input slave_size,
input slave_wraddr,
input slave_wrdata,
input slave_rden,
input slave_rdaddr
);
modport slave1(
input slave_wren[1],
input slave_size,
input slave_wraddr,
input slave_wrdata,
input slave_rden,
input slave_rdaddr
);
but it seems that the slave_wren[0] and slave_wren[1] parts won't compile, wonder why?
if this is wrong , how can i work it around