URL
https://opencores.org/ocsvn/eco32/eco32/trunk
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 27 |
Rev 123 |
Line 1... |
Line 1... |
|
//
|
|
// dsp.v -- character display interface
|
|
//
|
|
|
|
|
module dsp(clk, reset,
|
module dsp(clk, reset,
|
addr, en, wr, wt,
|
addr, en, wr, wt,
|
data_in, data_out,
|
data_in, data_out,
|
hsync, vsync,
|
hsync, vsync,
|
r, g, b);
|
r, g, b);
|
|
// internal interface
|
input clk;
|
input clk;
|
input reset;
|
input reset;
|
input [13:2] addr;
|
input [13:2] addr;
|
input en;
|
input en;
|
input wr;
|
input wr;
|
output wt;
|
output wt;
|
input [15:0] data_in;
|
input [15:0] data_in;
|
output [15:0] data_out;
|
output [15:0] data_out;
|
|
// external interface
|
output hsync;
|
output hsync;
|
output vsync;
|
output vsync;
|
output [2:0] r;
|
output [2:0] r;
|
output [2:0] g;
|
output [2:0] g;
|
output [2:0] b;
|
output [2:0] b;
|
|
|
reg state;
|
reg state;
|
|
|
display display1 (.clk(clk),
|
display display1(
|
|
.clk(clk),
|
.dsp_row(addr[13:9]),
|
.dsp_row(addr[13:9]),
|
.dsp_col(addr[8:2]),
|
.dsp_col(addr[8:2]),
|
.dsp_en(en),
|
.dsp_en(en),
|
.dsp_wr(wr),
|
.dsp_wr(wr),
|
.dsp_wr_data(data_in[15:0]),
|
.dsp_wr_data(data_in[15:0]),
|
.dsp_rd_data(data_out[15:0]),
|
.dsp_rd_data(data_out[15:0]),
|
.hsync(hsync),
|
.hsync(hsync),
|
.vsync(vsync),
|
.vsync(vsync),
|
.r(r[2:0]),
|
.r(r[2:0]),
|
.g(g[2:0]),
|
.g(g[2:0]),
|
.b(b[2:0]));
|
.b(b[2:0])
|
|
);
|
|
|
always @(posedge clk) begin
|
always @(posedge clk) begin
|
if (reset == 1) begin
|
if (reset == 1) begin
|
state <= 1'b0;
|
state <= 1'b0;
|
end else begin
|
end else begin
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.