[HDLBits] Tb/clock

You are provided a module with the following declaration:

复制代码
module dut ( input clk ) ;

Write a testbench that creates one instance of module dut (with any instance name), and create a clock signal to drive the module's clk input. The clock has a period of 10 ps. The clock should be initialized to zero with its first transition being 0 to 1.

051015202530354045...

复制代码
`timescale 1ps/1ps

//注意仿真单位ps
module top_module ( );
	parameter clk_period = 10;  
	reg clk;  
	initial
    	clk = 0;  
	always #(clk_period/2) clk = ~clk;  

    dut instance1(clk);
endmodule
相关推荐
啊阿狸不会拉杆6 小时前
《数字信号处理》第10章-数字信号处理中的有限字长效应
算法·matlab·fpga开发·信号处理·数字信号处理·dsp
雨洛lhw1 天前
24bit AD采样高效数据打包方案解析
fpga开发·数据打包方式·ddr突发读写注意事项
XiaoChaoZhiNeng1 天前
Xilinx Vivado18.3 Modelsim 库编译与仿真
fpga开发
Flamingˢ1 天前
FPGA 显示系统学习路线:从 VGA 到 RGB TFT
学习·fpga开发
tiantianuser1 天前
RDMA设计37:RoCE v2 子系统模型设计
fpga开发·rdma·高速传输·cmac·roce v2
8K超高清1 天前
博冠8K广播级讯道摄像机获国际设计大奖
网络·算法·fpga开发·接口隔离原则·智能硬件
ooo-p2 天前
FPGA学习篇——Verilog学习之“呼吸灯”
学习·fpga开发
雨洛lhw2 天前
STFT性能测试记录笔记(verilog )
fpga开发
runningshark2 天前
【FPGA】频率计(等精度测量法)
fpga开发
坏孩子的诺亚方舟2 天前
FPGA设计基于团队的最佳实践0
fpga开发·团队设计