Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2014
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. `timescale 10us/1us
  2. module clockcheck_tb();
  3. reg refclk_tb;
  4. reg clkin_tb;
  5. reg [31:0] freq_tb;
  6.  
  7. clockcheck U0(.clkin(clkin_tb), .refclk(refclk_tb), .freq(freq_tb));
  8.  
  9. initial begin
  10. refclk_tb = 0;
  11. end
  12. always
  13. #2 refclk_tb = !refclk_tb;
  14.  
  15. initial begin
  16. clkin_tb = 0;
  17. end
  18. always
  19. #20 clkin_tb = !clkin_tb;
  20.  
  21. initial begin
  22. $display("Frequencia = %d", freq_tb);
  23. end
  24.  
  25. endmodule
  26.  
  27. --------------------------------------------------------------------------------------------------------
  28.  
  29. # ** Error: (vsim-3053) C:/Users/Gabriel/Desktop/Faculdade/V-Semestre/Eletrônica-Digital/Eletrônica-Digital/Lista3/Clockcheck/clkcheck_tb.v(7): Illegal output or inout port connection for "port 'freq'".
  30. #
  31. # Region: /clockcheck_tb/U0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement