Skip to content

BlagojeBlagojevic/vga_verilog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Implementation of a vga controller on a Basys 3 FPGA

This code defines a VGA controller that generates a 640x480 pixels VGA screen with a 25MHz pixel rate based on a 60 Hz refresh rate. The VGA controller has several inputs and outputs, including clk_100MHz, reset, video_on, hsync, vsync, p_tick, x, and y.

The clk_100MHz input is the clock signal that is generated by the FPGA and is used to drive the VGA controller. The reset input is a signal that is used to reset the VGA controller.

The video_on output is a signal that is high while the pixel counts for x and y are within the display area. The hsync and vsync outputs are signals that are used to synchronize the horizontal and vertical scanning of the display. The p_tick output is a signal that has a frequency of 25MHz and is used as a pixel tick. The x and y outputs are signals that represent the position of the current pixel in the display.

The VGA controller uses several parameters to define the size of the display and the timing of the horizontal and vertical scanning. The HD parameter defines the horizontal display area width in pixels, the HF parameter defines the horizontal front porch width in pixels, the HB parameter defines the horizontal back porch width in pixels, and the HR parameter defines the horizontal retrace width in pixels. The VD parameter defines the vertical display area length in pixels, the VF parameter defines the vertical front porch length in pixels, the VB parameter defines the vertical back porch length in pixels, and the VR parameter defines the vertical retrace length in pixels.

The VGA controller also generates a 25MHz clock signal from the 100MHz clock signal that is provided by the FPGA. The VGA controller uses this clock signal to drive the pixel tick signal.

Finally, the code defines a test module that is used to test the VGA controller. The test module has an input for the 12-bit color values and outputs for the hsync, vsync, red, green, and blue color signals.

About

Implementation of a vga interface on a Basys 3 FPGA

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published