Line 47... |
Line 47... |
sc_out<sc_logic> rtoa;
|
sc_out<sc_logic> rtoa;
|
sc_out<sc_lv<SubChN> > rtoc;
|
sc_out<sc_lv<SubChN> > rtoc;
|
sc_in<sc_lv<SubChN> > rtoca;
|
sc_in<sc_lv<SubChN> > rtoca;
|
|
|
// local variable
|
// local variable
|
sc_signal<bool> out_cred; /* the input credit */
|
sc_signal<bool> out_cred[SubChN]; /* the input credit */
|
sc_signal<bool> out_cred_ack; /* the input credit ack */
|
sc_signal<bool> out_cred_ack[SubChN]; /* the input credit ack */
|
|
|
|
|
SC_HAS_PROCESS(RTDriver);
|
SC_HAS_PROCESS(RTDriver);
|
RTDriver(sc_module_name name);
|
RTDriver(sc_module_name name);
|
|
|
void IPdetect(); // Method to detect the router input port
|
void IPdetect(); // Method to detect the router input port
|
void OPdetect(); // Method to detect the router output port
|
void OPdetect(); // Method to detect the router output port
|
void Creditdetect(); // Method to detect the credit ports
|
void Creditdetect(); // Method to detect the credit ports
|
void send(); // thread of sending a flit
|
void send(); // thread of sending a flit
|
void recv(); // thread to recveive a flit
|
void recv(); // thread to recveive a flit
|
void credit(unsigned int); // handle the output credit
|
|
|
|
sc_signal<bool> rtinp_sig; // fire when the router input port is ready for a new flit
|
sc_signal<bool> rtinp_sig; // fire when the router input port is ready for a new flit
|
sc_signal<bool> rtoutp_sig; // fire when the router output port has a new flit
|
sc_signal<bool> rtoutp_sig; // fire when the router output port has a new flit
|
|
|
unsigned int c1o42b(unsigned int); // convert 1-of-4 to binary
|
unsigned int c1o42b(unsigned int); // convert 1-of-4 to binary
|