In reply to dave_59:
In reply to shaky005:
One problem with your code is you need to declare intr_txn locally in each begin/end block, otherwise the handle will get overwritten.
Hi Dave,
I am not sure if I missed what you want to convey, however I thought that he has already done what you have mentioned to do, isn’t it?
task run_phase(uvm_phase phase);
forever begin
fork
begin
if(intr_vif.controller_int_0_timeout) begin
**intr_txn = interrupt_transaction::type_id::create("intr_txn");
** intr_txn.controller_int_0_timeout = intr_vif.controller_int_0_timeout;
intr_txn.trans_num += 1;
`uvm_info("DATA FROM MON", $sformatf("DATA received from Interrupt MONITOR is : [%p] \n", intr_txn.controller_int_0_timeout),UVM_LOW)
ap.write(intr_txn);
end
end
begin
if(intr_vif.ch1_controller_int_0_timeout) begin
**intr_txn = interrupt_transaction::type_id::create("intr_txn");
** intr_txn.ch1_controller_int_0_timeout = intr_vif.ch1_controller_int_0_timeout;
intr_txn.trans_num += 1;
`uvm_info("DATA FROM MON", $sformatf("DATA received from Interrupt MONITOR is : [%p] \n", intr_txn.ch1_controller_int_0_timeout),UVM_LOW)
ap.write(intr_txn);
end
end
...
Or you are saying it has to be different names?
Thank you,
Mega