Jump to content

Error: (E112) get interface failed: port is not bound: port 'vcn_lcm_init_bfm.wr_snd' (sc_out)


Recommended Posts

//Question: i am using a inititator BFm to trigger as you can see and i am binding in sc_main but i sm getting error as discribed in the title, any suggestion ?




SC_MODULE( initiator_bfm) 
{
  
  SC_HAS_PROCESS( initiator_bfm );
  
public:
       typedef vcn_lcm::initiator_bfm<AWIDTH, DWIDTH>    this_int;
         
         
sc_core::sc_in< bool > clk;
sc_core::sc_in< bool > rst;
sc_out< bool >         wr_snd; 
         
initiator_bfm(sc_core::sc_module_name name_, if_int* pins_)
  : sc_core::sc_module(name_), 

 pins(pins_),    
 clk("clk"),
 rst("rst"),
 wr_snd("wr_snd")
{}
 
void run()
{
  SC_CTHREAD(write_req , clk.pos() );
  SC_CTHREAD(read_req  , clk.pos() );
}
         
void write_req(sc_dt::sc_uint<10>     wr_addr_y, 
                    sc_dt::sc_uint<10>     wr_addr_x, 
		    sc_dt::sc_uint<3>      wr_num_qwords,
		    sc_dt::sc_uint<7>      wr_buff_id, 
		    sc_dt::sc_uint<16>     wr_subbuf_id, 
		    sc_dt::sc_uint<2>      wr_lcm_num,
		    sc_dt::sc_biguint<320> wr_data )
{  
 wr_snd.write(0);
 wait();
 wr_snd.write(1);
 this->wr_addr_y.write(wr_addr_y);        
 }
         
 }
         
         
int sc_main(int, char*[])
{        
         typedef vcn_lcm::vcn_lcm_if<10,320>             vcn_lcm_if_t;
         typedef vcn_lcm::initiator_bfm<10,320>          vcn_lcm_initiator_t;
         
         vcn_lcm_if_t*         vcn_lcm_bus;
         vcn_lcm_initiator_t*  vcn_lcm_init_bfm;
         
         vcn_lcm_bus = new vcn_lcm_if_t("vcn_lcm_bus");
         vcn_lcm_init_bfm = new vcn_lcm_initiator_t("vcn_lcm_init_bfm",vcn_lcm_bus );
         
         vcn_lcm_init_bfm->write_req(1,1,2,1,1,1,5);
         
           sc_signal< bool > wr_snd;
           vcn_lcm_bus->wr_snd(wr_snd);
           vcn_lcm_init_bfm->wr_snd(wr_snd);
           sc_start(100, SC_SEC);
  return 0;
  
  
}

 

Link to comment
Share on other sites

Hi,

Could you post the full source code, or better, a subset of your current example that reproduces the problem? In your code above, several parts are missing like a systemc header include, class vcn_lcm, if_int definition etc.. and compilation gives also errors on missing scope like sc_core for sc_out.

On a side note, this is a UVM-SystemC/SCV forum whereas your problem is purely SystemC related.

--

Bas

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...