Skip Nav
Home » Forums » SystemC Forum

Icon - KMLM List KMLM List

View email archives for the history of this mailing list.

List Home All Archives Dates Threads Authors Subjects
systemc-forum - Port name initialization for array of ports Message Thread: Previous | Next
  • To: <systemc-forum@xxxxxxxxxxxxxxxxx>
  • From: SANTHARAM GURUMANI <gshant@xxxxxxxxxxx>
  • Date: Mon, 4 Jan 2010 10:44:58 -0500
Send Email to systemc-forum@lists.systemc.org:
Send new message
Reply to this message

Hi,

   In the normal process for attaching a name to a sc_in port we do the 
following.

 

SC_METHOD(myblock) {

       sc_in<int>      in_port;

       sc_out<int>    out_port;

 

       SC_CTOR(myblock): in_port("input port"), out_port("output port") //this 
works!

       {

           .....

       }

}

 

How to assign a name in case the port declaration is an array?

 

SC_METHOD(myblock2) {

        sc_in<int>     in_ports[2];

        sc_out<int>   out_port;

 

        SC_CTOR(myblock2):in_ports[0]("input port0"),in_ports[1]("input port1") 
//DOES NOT WORK

         {

              ......

          }

}

 

Is there an sc_object method which will work to assign a name to the array of 
ports?

 

Thanks

Shantharam

 
                                          
_________________________________________________________________
Hotmail: Trusted email with powerful SPAM protection.
http://clk.atdmt.com/GBL/go/177141665/direct/01/

By Date: Previous | Next Current Thread By Thread: Previous | Next