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

Subversion Repositories or1k

[/] [or1k/] [tags/] [stable/] [mp3/] [lib/] [xilinx/] [unisims/] [SRLC16_1.v] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 266 lampret
// $Header: /home/marcus/revision_ctrl_test/oc_cvs/cvs/or1k/mp3/lib/xilinx/unisims/SRLC16_1.v,v 1.1.1.1 2001-11-04 19:00:00 lampret Exp $
2
 
3
/*
4
 
5
FUNCTION        : 16 bit Shift Register LUT with Carry Negative_edge Clock and Clock Enable
6
 
7
*/
8
 
9
`timescale  100 ps / 10 ps
10
 
11
`celldefine
12
 
13
module SRLC16_1 (Q, Q15, A0, A1, A2, A3, CLK, D);
14
 
15
    parameter cds_action = "ignore";
16
 
17
    parameter INIT = 16'h0000;
18
 
19
    output Q, Q15;
20
 
21
    input  A0, A1, A2, A3, CLK, D;
22
 
23
    reg  [5:0]  count;
24
    reg  [15:0] data;
25
    wire [3:0]  addr;
26
    wire        clk_;
27
    wire        q_int;
28
 
29
    buf b_a3 (addr[3], A3);
30
    buf b_a2 (addr[2], A2);
31
    buf b_a1 (addr[1], A1);
32
    buf b_a0 (addr[0], A0);
33
 
34
    buf b_q_int (q_int, data[addr]);
35
    buf b_q (Q, q_int);
36
    buf b_q15_int (q15_int, data[15]);
37
    buf b_q15 (Q15, q15_int);
38
 
39
    not i_c (clk_, CLK);
40
 
41
    initial begin
42
        while (CLK === 1'bx)
43
            #2;
44
        for (count = 0; count < 16; count = count + 1)
45
            data[count] <= INIT[count];
46
    end
47
 
48
    always @(posedge clk_) begin
49
        {data[15:0]} <= {data[14:0], D};
50
    end
51
 
52
    specify
53
        (CLK => Q) = (1, 1);
54
        (CLK => Q15) = (1, 1);
55
    endspecify
56
 
57
endmodule
58
 
59
`endcelldefine

powered by: WebSVN 2.1.0

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