[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
相关推荐
木心术11 天前
基于FPGA+RFIC的5G基站设计方案与5G专用DFE芯片的设计方案区别及优劣势分析
5g·fpga开发
坏孩子的诺亚方舟1 天前
open_prj21_RGB LCD和HDMI
fpga开发·mpsoc
坏孩子的诺亚方舟1 天前
open_prj20_MPSOC概述
fpga开发·正点原子·mpsoc
nature_forest1 天前
DSP与FPGA之间EMIF接口之DSP参数配置下板测试问题总结
fpga开发
小麦嵌入式1 天前
FPGA入门(三):3-8 译码器 仿真波形解读
stm32·单片机·嵌入式硬件·mcu·fpga开发·硬件工程
upper20202 天前
从零开始动手做Verilog实验--04--11阶FIR滤波器
fpga开发
nuoxin1142 天前
SSD201-富利威
arm开发·驱动开发·fpga开发·ffmpeg·射频工程
哄娃睡觉2 天前
FPGA、ARM、MCU、DSP的区别
fpga开发
不会武功的火柴3 天前
ModelSim入门实战(三): 批处理一键仿真与波形调试
嵌入式硬件·fpga·仿真·modelsim·ic验证·rtl
nature_forest3 天前
vivado2018.2固化程序方法之.bin文件固化法
windows·fpga开发