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

Subversion Repositories alu_with_selectable_inputs_and_outputs

[/] [alu_with_selectable_inputs_and_outputs/] [trunk/] [rtl/] [dut.v] - Blame information for rev 2

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 dragos_don
/////////////////////////////////////////////////////////////////////
2
////                                                             ////
3
////      This project has been provided to you on behalf of:    ////
4
////                                                             ////
5
////            S.C. ASICArt S.R.L.                              ////
6
////                            www.asicart.com                  ////
7
////                            eli_f@asicart.com                ////
8
////                                                             ////
9
////        Author: Dragos Constantin Doncean                    ////
10
////        Email: doncean@asicart.com                           ////
11
////        Mobile: +40-740-936997                               ////
12
////                                                             ////
13
////      Downloaded from: http://www.opencores.org/             ////
14
////                                                             ////
15
/////////////////////////////////////////////////////////////////////
16
////                                                             ////
17
//// Copyright (C) 2007 Dragos Constantin Doncean                ////
18
////                         www.asicart.com                     ////
19
////                         doncean@asicart.com                 ////
20
////                                                             ////
21
//// This source file may be used and distributed without        ////
22
//// restriction provided that this copyright statement is not   ////
23
//// removed from the file and that any derivative work contains ////
24
//// the original copyright notice and the associated disclaimer.////
25
////                                                             ////
26
////     THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY     ////
27
//// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED   ////
28
//// TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS   ////
29
//// FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL THE AUTHOR      ////
30
//// OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,         ////
31
//// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES    ////
32
//// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE   ////
33
//// GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR        ////
34
//// BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF  ////
35
//// LIABILITY, WHETHER IN  CONTRACT, STRICT LIABILITY, OR TORT  ////
36
//// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT  ////
37
//// OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE         ////
38
//// POSSIBILITY OF SUCH DAMAGE.                                 ////
39
////                                                             ////
40
/////////////////////////////////////////////////////////////////////
41
 
42
 
43
//DUT
44
 
45
module DUT(dut_clk, dut_res, dut_stb,
46
        dut_sel,
47
        dut_data_in_0, dut_data_in_1, dut_data_in_2,
48
        dut_data_valid_in,
49
        dut_valid_0, dut_valid_1,
50
        dut_out_0, dut_out_1,
51
        dut_parity_0, dut_parity_1);
52
 
53
input dut_clk, dut_res, dut_stb;
54
input [1:0] dut_sel;
55
input [7:0] dut_data_in_0, dut_data_in_1, dut_data_in_2;
56
input dut_data_valid_in;
57
output dut_valid_0, dut_valid_1;
58
output [15:0] dut_out_0, dut_out_1;
59
output dut_parity_0, dut_parity_1;
60
 
61
wire [7:0] dut_data_out;
62
wire dut_data_valid_out;
63
wire dut_selector_alu_stb;
64
wire dut_alu_dmux_stb;
65
wire [15:0] dut_alu_result;
66
wire dut_parity;
67
wire dut_output_channel;
68
wire dut_parity_0, dut_parity_1;
69
 
70
//Modules' instantiations
71
 
72
SELECTOR selector(.clk(dut_clk), .res(dut_res), .stb(dut_stb),
73
                .sel(dut_sel),
74
                .data_in_0(dut_data_in_0), .data_in_1(dut_data_in_1), .data_in_2(dut_data_in_2),
75
                .data_valid_in(dut_data_valid_in),
76
                .data_out(dut_data_out), .data_valid_out(dut_data_valid_out),
77
                .stb_out(dut_selector_alu_stb));
78
 
79
ALU alu(.clk(dut_clk), .res(dut_res), .alu_stb_in(dut_selector_alu_stb),
80
                .alu_data_in(dut_data_out), .alu_data_valid_in(dut_data_valid_out),
81
                .alu_result(dut_alu_result), .result_parity(dut_parity),
82
                .output_channel(dut_output_channel),
83
                .alu_stb_out(dut_alu_dmux_stb));
84
 
85
DMUX dmux(.clk(dut_clk), .res(dut_res), .dmux_stb_in(dut_alu_dmux_stb),
86
                .alu_result(dut_alu_result), .result_parity(dut_parity),
87
                .output_channel(dut_output_channel),
88
                .valid_0(dut_valid_0), .valid_1(dut_valid_1),
89
                .out_0(dut_out_0), .out_1(dut_out_1),
90
                .parity_0(dut_parity_0), .parity_1(dut_parity_1));
91
 
92
endmodule

powered by: WebSVN 2.1.0

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