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

Subversion Repositories cxd9731

[/] [cxd9731/] [Top.v] - Blame information for rev 5

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 5 regttycomi
`timescale 1ns / 1ps
2
module  Top(
3
        input                           reset,
4
        input                           clk4,
5
        input                           IDE_CS,
6
        output                  dna_pass,
7
        output [3:0]     KILL
8
);
9
 
10
 
11
wire [63:0] dna64bits;
12
wire dna_valid;
13
 
14
wire    SR_ena;
15
 
16
wire [9:0] addra;
17
wire [15:0] douta;
18
 
19
// constant holder for RAM implementation
20
// begin
21
//wire [15:0] dina;
22
//wire wea;
23
// end of constant holder
24
 
25
dna_p1 inst_ReadDNA(
26
        .ATV(~reset),                           // Active and arm signal
27
   .CLK4(clk4),                                 // very fast clock
28
   .DNA_64(dna64bits),          // 64 bit DNA code with check bits
29
   .DNA_Valid(dna_valid)        // the code now is valid
30
);
31
 
32
CheckDNA inst_CheckDNA (
33
        .clk4                   (clk4),
34
        .reset          (reset),
35
        .DNA_64         (dna64bits),                    // The DNA code
36
        .dna_valid      (dna_valid),
37
 
38
        .ROM_Data       (douta),                                        // ROM data
39
        .IDE_CS         (IDE_CS),                               // chip select
40
        .DNA_ENA                (SR_ena),                               // the enable signal to reduce power consumption
41
        .DNA_REG                (SR_reg),                               // enable output register for faster RAM access
42
        .DNA_Addr       (addra),                                        // RAM address
43
 
44
        .dna_pass       (dna_pass),                             // result of check
45
        .KILL                   (KILL)                                          // Killing signals
46
);
47
 
48
// Inst as block ROM
49
// begin
50
RAM inst_RAM (
51
        .clka(clk4),
52
        .addra(addra),
53
        .ena(SR_ena),                                   // 1 serial register
54
        .regcea(SR_reg),
55
        .douta(douta));
56
// end of block ROM
57
 
58
// Inst as block RAM
59
// begin
60
//RAM inst_RAM (
61
//      .clka(clk4),
62
//      .ena(SR_ena),
63
//      .regcea(SR_reg),
64
//      .wea(wea), // Bus [0 : 0] 
65
//      .addra(addra), // Bus [9 : 0] 
66
//      .dina(douta), // Bus [15 : 0] 
67
//      .douta(douta)); // Bus [15 : 0] 
68
 
69
//assign dina = 16'b0000_0000_0000_0000;        // no dangling pins
70
//assign wea = 1'b0;                            // no writing
71
// end of block RAM
72
endmodule
73
 
74
 
75
 
76
 
77
 
78
 
79
 
80
 
81
 
82
 

powered by: WebSVN 2.1.0

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