Intel® FPGA University Program
University Program Material, Education Boards, and Laboratory Exercises
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.

VGA assistance

Honored Contributor II

I've been introduced to this altera kit since entering college. May need some assistance on using the VGA output. Anyone of you mind lending assistance to me. Your help will be much appreciated. =) 

*Am a rookie, please pardon me for my greenhorn-ness* 


I'm supposed to construct a code that allows the VGA output ADV7123 produce a coloured screen or even possible, a simple image. The following is what I have done, but doesn't work.  


Am using the old version of cyclone 2. EP2C35F672C6N. 


Am still trying to figure out what values and the various declaration styles. Any kind souls do help me thanks. 





module VGAOUT ( input CLOCK_50, output VGA_HS, output VGA_VS, output [9:0]VGA_R, 

output [9:0]VGA_B, output [9:0]VGA_G); 

reg clk = 1'b0; 


always @ (posedge CLOCK_50) 

clk = ~clk;  

reg [9:0]Counter1= 0; 

reg [8:0]Counter2= 0; 

wire CounterXmaxed = (Counter1== 768); 


always @ (posedge clk) 


Counter1 <= 0; 


Counter1 <= Counter1 + 1; 

always @(posedge clk) 


Counter2 <= Counter2 + 1; 


reg vga_HS, vga_VS; 

always @(posedge clk) 


vga_HS <= (Counter1[9:4]==0);  

vga_VS <= (Counter2==0);  



assign VGA_HS = ~vga_HS 

assign VGA_VS = ~vga_VS;  


assign VGA_R[9:0]=10'hFA; 

assign VGA_G[9:0]=10'hFA; 

assign VGA_B[9:0]=10'hFE; 


0 Kudos
0 Replies