Download VCS user guide

Transcript
vmm_tlm::phase_e)
nb_export = new(this,"target_export");
...
function vmm_tlm::sync_e nb_transport_fw(
int id=-1,
my_trans trans,
ref vmm_tlm ph,
ref int delay);
trans.display("From Target"); //execute transaction
return vmm_tlm::TLM_ACCEPTED; //finish completion
//model
endfunction: nb_transport
endclass: target
Example 5-24 shows how to connect the initiator's blocking transport
port to the target's non-blocking transport export using the
vmm_connect#(.D(d))::tlm_transport_interconnect
utility class method.
Example 5-24
Connecting Blocking Port to Non-blocking Export
class subenv extends vmm_group;
initiator i0;
target t0;
...
virtual function void connect_ph();
vmm_connect
#(.D(my_trans))::tlm_transport_interconnect(
t0.b_port,
i0.nb_export,
vmm_tlm::TLM_NONBLOCKING_EXPORT);
endfunction: connect_ph
...
endclass: subenv
VMM User Guide
5-28