aboutsummaryrefslogtreecommitdiff
path: root/tests/soc_simple_display
diff options
context:
space:
mode:
authorWojciech Kosior <kwojtus@protonmail.com>2020-11-03 22:01:29 +0100
committerWojciech Kosior <kwojtus@protonmail.com>2020-11-03 22:01:29 +0100
commit31347a54ac571ded6177b68e24aa2d0c2f2cab28 (patch)
tree745db3d5e455d6cad6124672ec304e608ccb4478 /tests/soc_simple_display
parentcd0c787bcfc89a0a1e14f4404a59cb4697854621 (diff)
downloadAGH-engineering-thesis-31347a54ac571ded6177b68e24aa2d0c2f2cab28.tar.gz
AGH-engineering-thesis-31347a54ac571ded6177b68e24aa2d0c2f2cab28.zip
incorporate SPI module into main design
Diffstat (limited to 'tests/soc_simple_display')
-rw-r--r--tests/soc_simple_display/Makefile3
-rw-r--r--tests/soc_simple_display/test.v64
2 files changed, 12 insertions, 55 deletions
diff --git a/tests/soc_simple_display/Makefile b/tests/soc_simple_display/Makefile
index 4506ff7..06bced1 100644
--- a/tests/soc_simple_display/Makefile
+++ b/tests/soc_simple_display/Makefile
@@ -1,6 +1,7 @@
VGA_TEST = 1
-DEPENDS = instructions.mem sram.v vga_display.v ../../design/*.v messages.vh
+DEPENDS = instructions.mem sram.v vga_display.v flash_memory.v \
+ soc_with_peripherals.v ../../design/*.v messages.vh
IVFLAGS = -DROM_WORDS_COUNT=$(call FILE_LINES,instructions.mem)
diff --git a/tests/soc_simple_display/test.v b/tests/soc_simple_display/test.v
index de05ff0..75c2b36 100644
--- a/tests/soc_simple_display/test.v
+++ b/tests/soc_simple_display/test.v
@@ -9,74 +9,30 @@
`endif
module soc_test();
- wire [17:0] sram_addr;
- wire [15:0] sram_io;
- wire sram_cs_n;
- wire sram_oe_n;
- wire sram_we_n;
-
- wire vga_hs;
- wire vga_vs;
- wire [2:0] vga_red;
- wire [2:0] vga_green;
- wire [2:0] vga_blue;
-
- wire led1;
- wire led2;
-
wire [9:0] image_writes;
- reg clock_100mhz;
- reg reset;
-
- VGA_640_480_60Hz vga_display
- (
- .horizontal_sync(vga_hs),
- .vertical_sync(vga_vs),
-
- .red(vga_red),
- .green(vga_green),
- .blue(vga_blue),
+ reg clock_100mhz;
+ reg reset;
- .image_writes(image_writes)
- );
+ wire led1;
+ wire led2;
- K6R4016V1D_TC10_sram sram
- (
- .sram_addr(sram_addr),
- .sram_io(sram_io),
- .sram_cs_not(sram_cs_n),
- .sram_oe_not(sram_oe_n),
- .sram_we_not(sram_we_n)
- );
-
- soc
+ soc_with_peripherals
#(
.FONT_FILE("../../design/font.mem"),
- .ROM_FILE("instructions.mem")
+ .EMBEDDED_ROM_FILE("instructions.mem")
) soc
(
.clock_100mhz(clock_100mhz),
- .sram_addr(sram_addr),
- .sram_io(sram_io),
-
- .sram_cs_n(sram_cs_n),
- .sram_oe_n(sram_oe_n),
- .sram_we_n(sram_we_n),
-
- .vga_hs(vga_hs),
- .vga_vs(vga_vs),
- .vga_red(vga_red),
- .vga_green(vga_green),
- .vga_blue(vga_blue),
-
.button1(!reset),
.button2(1'b1),
.led1(led1),
- .led2(led2)
- );
+ .led2(led2),
+
+ .image_writes(image_writes)
+ );
integer i;