OpenCores
URL https://opencores.org/ocsvn/funbase_ip_library/funbase_ip_library/trunk

Subversion Repositories funbase_ip_library

[/] [funbase_ip_library/] [trunk/] [TUT/] [ip.hwp.communication/] [hibi/] [3.0/] [tb/] [sad_tb/] [hibiv3_r3.hh] - Blame information for rev 145

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 145 lanttu
/*
2
 * Author: Lasse Lehtonen
3
 *
4
 * Instantiates hibiv3_r3.vhd VHDL component for SystemC.
5
 * hibi wrapper_r3 has
6
 *   - separate IP interface for regular and hi-prior data
7
 *   - IP writes/gets addr and data in parallel
8
 *
9
 *
10
 * $Id: hibiv3_r3.hh 2002 2011-10-04 13:18:30Z ege $
11
 *
12
 */
13
 
14
 
15
#ifndef _HUUHAA_hibiv3_r3_
16
#define _HUUHAA_hibiv3_r3_
17
 
18
#include 
19
using namespace sc_core;
20
using namespace sc_dt;
21
 
22
template
23
         int addr_width_g,
24
         int data_width_g,
25
         int comm_width_g,
26
         int counter_width_g,
27
         int rel_agent_freq_g,
28
         int rel_bus_freq_g,
29
         int arb_type_g,
30
         int fifo_sel_g,
31
         int rx_fifo_depth_g,
32
         int rx_msg_fifo_depth_g,
33
         int tx_fifo_depth_g,
34
         int tx_msg_fifo_depth_g,
35
         int max_send_g,
36
         int n_cfg_pages_g,
37
         int n_time_slots_g,
38
         int keep_slot_g,
39
         int n_extra_params_g,
40
 
41
         int cfg_re_g,
42
         int cfg_we_g,
43
         int debug_width_g,
44
         int n_agents_g,
45
         int n_segments_g,
46
         int separate_addr_g>
47
class hibiv3_r3 : public sc_foreign_module
48
{
49
public:
50
   sc_in_clk                                         clk_ip;
51
   sc_in_clk                                         clk_noc;
52
   sc_in                                       rst_n;
53
   sc_in >  agent_comm_in;
54
   sc_in >  agent_data_in;
55
   sc_in >  agent_addr_in;
56
   sc_in >                 agent_we_in;
57
   sc_in >                 agent_re_in;
58
   sc_out > agent_comm_out;
59
   sc_out > agent_data_out;
60
   sc_out > agent_addr_out;
61
   sc_out >                agent_full_out;
62
   sc_out >                agent_one_p_out;
63
   sc_out >                agent_empty_out;
64
   sc_out >                agent_one_d_out;
65
   sc_in >  agent_msg_comm_in;
66
   sc_in >  agent_msg_data_in;
67
   sc_in >  agent_msg_addr_in;
68
   sc_in >                 agent_msg_we_in;
69
   sc_in >                 agent_msg_re_in;
70
   sc_out > agent_msg_comm_out;
71
   sc_out > agent_msg_data_out;
72
   sc_out > agent_msg_addr_out;
73
   sc_out >                agent_msg_full_out;
74
   sc_out >                agent_msg_one_p_out;
75
   sc_out >                agent_msg_empty_out;
76
   sc_out >                agent_msg_one_d_out;
77
 
78
 
79
 
80
   hibiv3_r3(sc_module_name nm, const char* hdl_name)
81
      : sc_foreign_module(nm),
82
        clk_ip("clk_ip"),
83
        clk_noc("clk_noc"),
84
        rst_n("rst_n"),
85
        agent_comm_in("agent_comm_in"),
86
        agent_data_in("agent_data_in"),
87
        agent_addr_in("agent_addr_in"),
88
        agent_we_in("agent_we_in"),
89
        agent_re_in("agent_re_in"),
90
        agent_comm_out("agent_comm_out"),
91
        agent_data_out("agent_data_out"),
92
        agent_addr_out("agent_addr_out"),
93
        agent_full_out("agent_full_out"),
94
        agent_one_p_out("agent_one_p_out"),
95
        agent_empty_out("agent_empty_out"),
96
        agent_one_d_out("agent_one_d_out"),
97
        agent_msg_comm_in("agent_msg_comm_in"),
98
        agent_msg_data_in("agent_msg_data_in"),
99
        agent_msg_addr_in("agent_msg_addr_in"),
100
        agent_msg_we_in("agent_msg_we_in"),
101
        agent_msg_re_in("agent_msg_re_in"),
102
        agent_msg_comm_out("agent_msg_comm_out"),
103
        agent_msg_data_out("agent_msg_data_out"),
104
        agent_msg_addr_out("agent_msg_addr_out"),
105
        agent_msg_full_out("agent_msg_full_out"),
106
        agent_msg_one_p_out("agent_msg_one_p_out"),
107
        agent_msg_empty_out("agent_msg_empty_out"),
108
        agent_msg_one_d_out("agent_msg_one_d_out")
109
   {
110
      this->add_parameter("id_width_g", id_width_g);
111
      this->add_parameter("addr_width_g", addr_width_g);
112
      this->add_parameter("data_width_g", data_width_g);
113
      this->add_parameter("comm_width_g", comm_width_g);
114
      this->add_parameter("counter_width_g", counter_width_g);
115
      this->add_parameter("rel_agent_freq_g", rel_agent_freq_g);
116
      this->add_parameter("rel_bus_freq_g", rel_bus_freq_g);
117
      this->add_parameter("arb_type_g", arb_type_g);
118
      this->add_parameter("fifo_sel_g", fifo_sel_g);
119
      this->add_parameter("rx_fifo_depth_g", rx_fifo_depth_g);
120
      this->add_parameter("rx_msg_fifo_depth_g", rx_msg_fifo_depth_g);
121
      this->add_parameter("tx_fifo_depth_g", tx_fifo_depth_g);
122
      this->add_parameter("tx_msg_fifo_depth_g", tx_msg_fifo_depth_g);
123
      this->add_parameter("max_send_g", max_send_g);
124
      this->add_parameter("n_cfg_pages_g", n_cfg_pages_g);
125
      this->add_parameter("n_time_slots_g", n_time_slots_g);
126
      this->add_parameter("keep_slot_g", keep_slot_g);
127
      this->add_parameter("n_extra_params_g", n_extra_params_g);
128
 
129
      this->add_parameter("cfg_re_g", cfg_re_g);
130
      this->add_parameter("cfg_we_g", cfg_we_g);
131
      this->add_parameter("debug_width_g", debug_width_g);
132
      this->add_parameter("n_agents_g", n_agents_g);
133
      this->add_parameter("n_segments_g", n_segments_g);
134
      this->add_parameter("separate_addr_g", separate_addr_g);
135
      elaborate_foreign_module(hdl_name);
136
   }
137
 
138
   ~hibiv3_r3()
139
   {
140
   }
141
 
142
};
143
 
144
#endif
145
 
146
 
147
// Local Variables:
148
// mode: c++
149
// c-file-style: "ellemtel"
150
// c-basic-offset: 3
151
// End:
152
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.