[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
相关推荐
星夜离尘561 小时前
FPGA 三点中值滤波:不补零、不丢背压样本的流式实现
fpga开发
t_niu_niu5 小时前
bilateral_filter_paper
图像处理·verilog·双边滤波器
hexiaoyan8279 小时前
互联卡设计方案:504-PCIE X16 金手指 FPGA Aurora协议互联卡
fpga开发·测试载板·互联卡·fpga aurora协议·夹板连接器·板卡互联
星夜离尘569 小时前
FPGA 二进制数如何变成十进制显示:可背压的逐位 BCD 转换器
fpga开发
匠行科技10 小时前
基于VPX架构的4路10GSPS ADC信号采集处理板
fpga开发
FPGA小徐10 小时前
【FPGA数字信号处理】离散信源香农熵计算:原理详解 + 纯Verilog可综合实现 + 全套仿真代码
fpga
幻智星科技1 天前
蒙哥马利模乘FPGA优化实战
fpga开发·密码学
星夜离尘561 天前
FPGA 多通道 DAC 目标码影子寄存器:成组提交、同拍写入与快照边界
fpga开发
t_niu_niu2 天前
基于多帧累加平均的图像传感器暗电流抑制方法与 FPGA 实现
fpga开发·ram·fpn·固定模式噪声·image sensor
幻智星科技2 天前
FPGA纯硬件UDP桥接:微秒级响应新范式
c++·fpga开发·硬件架构