Compare commits

...

3 Commits

Author SHA1 Message Date
0015a0d7bc Merge pull request 'added headers/ updated old ones' (#3) from header_changes into master
All checks were successful
ci/woodpecker/push/test-workflow Pipeline was successful
Reviewed-on: #3
2025-06-03 00:51:19 +00:00
b9b6be7cbe
Typo fixup 2025-06-02 17:47:35 -07:00
636b375c48 added headers/ updated old ones 2025-06-02 17:36:27 -07:00
9 changed files with 63 additions and 6 deletions

View File

@ -1,6 +1,15 @@
/****
* audio_buffer.sv - holds a 2KiB audio buffer of 16-bit pcm audio
* samples (with pcm being the audio format we are using)
*
* @author: Waylon Cude, Dilanthi
* @date: 6/12/2025
*
* */
`ifdef VERILATOR
`include "sdvd_defs.sv"
`endif
import sdvd_defs::SPEED;
//this interfaces with block ram

View File

@ -1,8 +1,9 @@
/****
* pwm.sv - [must edit in future]
* pwm.sv - drives the pwm audio output on the FPGA given a single 16-bit
* sample.
*
* @author: Dilanthi Prentice, Waylon Cude
* @date: [not sure when due yet]
* @date: 6-12-2025
*
*
* */

View File

@ -1,3 +1,11 @@
/***
* debouncer.sv - generates a debounced button press and turns it into
* a single pulse.
*
* @author: Waylon Cude, Dilanthi Prentice
* @date: 6-12-25
*
* */
//NOTE: you should drive this with a slow clock to actually debounce input
module debouncer(input logic clk, input reset, input source, output logic out);

View File

@ -1,3 +1,12 @@
/****
* low_freq_clock_gen.sv - Generates different clock frequencies to drive
* different state machines and different parts of
* the design.
*
* @author: Waylon Cude, Dilanthi Prentice
* @date: 6/12/2025
* */
`ifdef VERILATOR
`include "sdvd_defs.sv"
`endif

View File

@ -1,3 +1,10 @@
/***
* nexys_a7_top.sv - top level design module specific to Nexys A7100T.
*
* @author: Waylon Cude, Dilanthi Prentice
* @date: 6/12/2025
*
* **/
`ifdef VERILATOR
`include "sdvd_defs.sv"
`endif

View File

@ -1,4 +1,16 @@
// NOTE: This expects to be driven with a 100khz clock
/***
* display_anode_driver.sv - Turns on a single anode of a single digit at a time,
* rapidly rotating through all of them, generating
* a solid-looking display even though only one digit
* is on at a time.
*
* @author: Waylon Cude, Dilanthi Prentice
* @date: 6-12-2025
*
* */
// NOTE: This expects to be driven with a 100khz clock but can be altered in
// the nexys_a7_top.sv file.
module display_anode_driver(
input logic clk,
input logic reset,

View File

@ -1,12 +1,12 @@
/**
* display_converter.sv - decodes a 5 bit digit input into its seven segment
* display equivalent using a lookup table. Display can
* do 0 - 9, A - F, individual segmentsm and special
* do 0 - 9, A - F, individual segments and special
* characters.
*
* @author: Dilanthi Prentice, Waylon Cude
* @date: 6/12/25
*
*
****/
module display_converter(
input logic [4:0] digit,
@ -16,6 +16,7 @@ module display_converter(
localparam ROM_SIZE=32;
//ROM lookup table for seven segment display
//blanks are unused space we could add characters to.
localparam logic [6:0] segment_rom [0:ROM_SIZE-1] = '{
7'b1111110, //0
7'b0000110, //1
@ -54,6 +55,7 @@ localparam logic [6:0] segment_rom [0:ROM_SIZE-1] = '{
7'b0000000, //blank
7'b0000000 //blank
};
//use digit input to index segment_rom lookup table.
assign segment = segment_rom[digit];

View File

@ -1,10 +1,11 @@
/***
* seconds_display.sv - convert a seconds counter to a seven segement display.
* seconds_display.sv - converts a five bit seconds counter to its seven segement display equivalent.
*
* @author: Dilanthi Prentice, Waylon Cude
* @date: 6/12/25
*
*/
module seconds_display
(
input [$clog2(60)-1:0] seconds,

View File

@ -1,3 +1,11 @@
/****
* seconds_display_tb.sv - testbench for the seconds_display module.
*
* @author: Waylon Cude, Dilanthi Prentice
* @date: 6/12/2025
*
* */
`timescale 1ns / 1ps
module seconds_display_tb;
int errors = 0;