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

Subversion Repositories dma_axi

[/] [dma_axi/] [trunk/] [src/] [dma_axi32/] [prgen_mux8.v] - Blame information for rev 4

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 4 eyalhoc
/////////////////////////////////////////////////////////////////////
2
////                                                             ////
3
////  Author: Eyal Hochberg                                      ////
4
////          eyal@provartec.com                                 ////
5
////                                                             ////
6
////  Downloaded from: http://www.opencores.org                  ////
7
/////////////////////////////////////////////////////////////////////
8
////                                                             ////
9
//// Copyright (C) 2010 Provartec LTD                            ////
10
//// www.provartec.com                                           ////
11
//// info@provartec.com                                          ////
12
////                                                             ////
13
//// This source file may be used and distributed without        ////
14
//// restriction provided that this copyright statement is not   ////
15
//// removed from the file and that any derivative work contains ////
16
//// the original copyright notice and the associated disclaimer.////
17
////                                                             ////
18
//// This source file is free software; you can redistribute it  ////
19
//// and/or modify it under the terms of the GNU Lesser General  ////
20
//// Public License as published by the Free Software Foundation.////
21
////                                                             ////
22
//// This source is distributed in the hope that it will be      ////
23
//// useful, but WITHOUT ANY WARRANTY; without even the implied  ////
24
//// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR     ////
25
//// PURPOSE.  See the GNU Lesser General Public License for more////
26
//// details. http://www.gnu.org/licenses/lgpl.html              ////
27
////                                                             ////
28
/////////////////////////////////////////////////////////////////////
29 2 eyalhoc
//---------------------------------------------------------
30
//-- File generated by RobustVerilog parser
31
//-- Version: 1.0
32
//-- Invoked Fri Mar 25 23:34:52 2011
33
//--
34
//-- Source file: prgen_mux.v
35
//---------------------------------------------------------
36
 
37
 
38
 
39
 
40
module prgen_mux8(sel,ch_x,x);
41
 
42
   parameter                  WIDTH      = 8;
43
 
44
 
45
   input [3-1:0]     sel;
46
   input [8*WIDTH-1:0]     ch_x;
47
   output [WIDTH-1:0]           x;
48
 
49
 
50
   reg [WIDTH-1:0]              x;
51
 
52
 
53
   always @(/*AUTOSENSE*/ch_x or sel)
54
     begin
55
    case (sel)
56
      3'd0 :x = ch_x[WIDTH-1+WIDTH*0:WIDTH*0];
57
      3'd1 :x = ch_x[WIDTH-1+WIDTH*1:WIDTH*1];
58
      3'd2 :x = ch_x[WIDTH-1+WIDTH*2:WIDTH*2];
59
      3'd3 :x = ch_x[WIDTH-1+WIDTH*3:WIDTH*3];
60
      3'd4 :x = ch_x[WIDTH-1+WIDTH*4:WIDTH*4];
61
      3'd5 :x = ch_x[WIDTH-1+WIDTH*5:WIDTH*5];
62
      3'd6 :x = ch_x[WIDTH-1+WIDTH*6:WIDTH*6];
63
      3'd7 :x = ch_x[WIDTH-1+WIDTH*7:WIDTH*7];
64
 
65
      default :
66
        x = ch_x[WIDTH-1:0];
67
    endcase
68
     end
69
 
70
 
71
endmodule
72
 
73
 
74
 

powered by: WebSVN 2.1.0

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