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

Subversion Repositories wb_lpc

[/] [wb_lpc/] [trunk/] [examples/] [lpc_7seg/] [top_lpc_7seg.v] - Blame information for rev 22

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

Line No. Rev Author Line
1 7 hharte
//////////////////////////////////////////////////////////////////////
2
////                                                              ////
3 17 hharte
////  $Id: top_lpc_7seg.v,v 1.2 2008-07-26 19:15:29 hharte Exp $  ////
4 7 hharte
////  top_lpc_7seg.v - LPC Peripheral to 7-Segment Display for    ////
5
////  Enterpoint Raggedstone1 card.                               ////
6
////                                                              ////
7
////  This file is part of the Wishbone LPC Bridge project        ////
8
////  http://www.opencores.org/projects/wb_lpc/                   ////
9
////                                                              ////
10
////  Author:                                                     ////
11
////      - Howard M. Harte (hharte@opencores.org)                ////
12
////                                                              ////
13
//////////////////////////////////////////////////////////////////////
14
////                                                              ////
15
//// Copyright (C) 2008 Howard M. Harte                           ////
16
////                                                              ////
17
//// This source file may be used and distributed without         ////
18
//// restriction provided that this copyright statement is not    ////
19
//// removed from the file and that any derivative work contains  ////
20
//// the original copyright notice and the associated disclaimer. ////
21
////                                                              ////
22
//// This source file is free software; you can redistribute it   ////
23
//// and/or modify it under the terms of the GNU Lesser General   ////
24
//// Public License as published by the Free Software Foundation; ////
25
//// either version 2.1 of the License, or (at your option) any   ////
26
//// later version.                                               ////
27
////                                                              ////
28
//// This source is distributed in the hope that it will be       ////
29
//// useful, but WITHOUT ANY WARRANTY; without even the implied   ////
30
//// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR      ////
31
//// PURPOSE.  See the GNU Lesser General Public License for more ////
32
//// details.                                                     ////
33
////                                                              ////
34
//// You should have received a copy of the GNU Lesser General    ////
35
//// Public License along with this source; if not, download it   ////
36
//// from http://www.opencores.org/lgpl.shtml                     ////
37
////                                                              ////
38
//////////////////////////////////////////////////////////////////////
39
 
40
module lpc_7seg
41
(
42
    RST, // Active Low (From PCI bus)
43
    DISP_SEL,
44
    DISP_LED,
45
 
46
    LPC_CLK,
47
    LFRAME,
48
    LAD,
49
    LAD_OE
50
);
51
 
52
input          RST ;
53
 
54
output   [3:0] DISP_SEL ;
55
output   [6:0] DISP_LED ;
56
 
57
input          LPC_CLK;
58
input          LFRAME;
59
inout    [3:0] LAD;
60
output         LAD_OE;
61
 
62
wire     [2:0] dma_chan_i = 3'b000;
63
wire           dma_tc_i = 1'b0;
64
wire     [3:0] lad_i;
65
wire     [3:0] lad_o;
66
wire           periph_lad_oe;
67 17 hharte
 
68 7 hharte
assign LAD = (periph_lad_oe ? lad_o : 4'bzzzz);
69
assign LAD_OE = periph_lad_oe;
70
 
71
wire    [24:0] wb_adr_o;
72
wire    [31:0] wb_dat_i;
73
wire    [31:0] wb_dat_o;
74
wire     [3:0] wb_sel_o;
75
wire           wb_we_o;
76
wire           wb_stb_o;
77
wire           wb_cyc_o;
78 17 hharte
wire           wb_ack_i;
79 7 hharte
wire           wb_rty_i;
80
wire           wb_err_i;
81
wire           wb_int_i;
82
 
83
// Instantiate the module
84
wb_lpc_periph lpc_periph (
85
    .clk_i(LPC_CLK),
86
    .nrst_i(RST),
87
    .wbm_adr_o(wb_adr_o),
88
    .wbm_dat_o(wb_dat_o),
89
    .wbm_dat_i(wb_dat_i),
90
    .wbm_sel_o(wb_sel_o),
91
    .wbm_tga_o(wb_tga_o),
92
    .wbm_we_o(wb_we_o),
93
    .wbm_stb_o(wb_stb_o),
94
    .wbm_cyc_o(wb_cyc_o),
95 17 hharte
    .wbm_ack_i(wb_ack_i),
96
    .wbm_err_i(wb_err_i),
97 7 hharte
    .dma_chan_o(dma_chan_i),
98
    .dma_tc_o(dma_tc_i),
99
    .lframe_i(~LFRAME),
100
    .lad_i(LAD),
101
    .lad_o(lad_o),
102
    .lad_oe(periph_lad_oe)
103
    );
104
 
105
// Instantiate the 7-Segment module
106
wb_7seg seven_seg0 (
107
    .clk_i(LPC_CLK),
108
    .nrst_i(RST),
109
    .wb_adr_i(wb_adr_o),
110
    .wb_dat_o(wb_dat_i),
111
    .wb_dat_i(wb_dat_o),
112
    .wb_sel_i(wb_sel_o),
113
    .wb_we_i(wb_we_o),
114
    .wb_stb_i(wb_stb_o),
115
    .wb_cyc_i(wb_cyc_o),
116
    .wb_ack_o(wb_ack_i),
117
    .wb_err_o(wb_err_i),
118
    .wb_int_o(wb_int_i),
119
    .DISP_SEL(DISP_SEL),
120
    .DISP_LED(DISP_LED)
121
    );
122
 
123
endmodule

powered by: WebSVN 2.1.0

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