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

Subversion Repositories z80control

[/] [z80control/] [trunk/] [CII_Starter_USB_API_v1/] [HW/] [Multi_Sdram/] [sdr_data_path.v] - Blame information for rev 12

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 12 tylerapohl
//Legal Notice: (C)2006 Altera Corporation. All rights reserved. Your
2
//use of Altera Corporation's design tools, logic functions and other
3
//software and tools, and its AMPP partner logic functions, and any
4
//output files any of the foregoing (including device programming or
5
//simulation files), and any associated documentation or information are
6
//expressly subject to the terms and conditions of the Altera Program
7
//License Subscription Agreement or other applicable license agreement,
8
//including, without limitation, that your use is for the sole purpose
9
//of programming logic devices manufactured by Altera and sold by Altera
10
//or its authorized distributors.  Please refer to the applicable
11
//agreement for further details.
12
 
13
module sdr_data_path(
14
        CLK,
15
        RESET_N,
16
        DATAIN,
17
        DM,
18
        DQOUT,
19
        DQM
20
        );
21
 
22
`include        "Sdram_Params.h"
23
 
24
input                           CLK;                    // System Clock
25
input                           RESET_N;                // System Reset
26
input   [`DSIZE-1:0]            DATAIN;                 // Data input from the host
27
input   [`DSIZE/8-1:0]          DM;                     // byte data masks
28
output  [`DSIZE-1:0]            DQOUT;
29
output  [`DSIZE/8-1:0]          DQM;                    // SDRAM data mask ouputs
30
reg     [`DSIZE/8-1:0]          DQM;
31
 
32
// internal 
33
reg     [`DSIZE-1:0]            DIN1;
34
reg     [`DSIZE-1:0]            DIN2;
35
 
36
reg     [`DSIZE/8-1:0]          DM1;
37
 
38
 
39
 
40
// Allign the input and output data to the SDRAM control path
41
always @(posedge CLK or negedge RESET_N)
42
begin
43
        if (RESET_N == 0)
44
        begin
45
                DIN1    <= 0;
46
                DIN2    <= 0;
47
                DM1     <= 0;
48
        end
49
        else
50
        begin
51
                DIN1    <=      DATAIN;
52
                DIN2    <=      DIN1;
53
                                DQM             <=      DM;
54
        end
55
end
56
 
57
assign DQOUT = DIN2;
58
 
59
endmodule
60
 

powered by: WebSVN 2.1.0

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