[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
相关推荐
m0_46644103詹湛6 小时前
(一)FPGA :基础概念详解(Xilinx平台)
笔记·学习·fpga开发·verilog
xyx-3v21 小时前
ZYNQ 简介
fpga开发
xyx-3v21 小时前
Zynq-7000
fpga开发
xyx-3v1 天前
zynq7010和zynq7020的区别
fpga开发
xyx-3v1 天前
LUT(Look-Up Table,查找表)的定义与核心概念
fpga开发
明德扬2 天前
K7+AD9144 多模式实测|8 种 JESD204B 配置全覆盖验证
fpga开发
xyx-3v2 天前
SOC相对于版上系统的优势是什么?
fpga开发
Aaron15883 天前
RFSOC+VU13P+GPU 在6G互联网中的技术应用
大数据·人工智能·算法·fpga开发·硬件工程·信息与通信·信号处理
stars-he3 天前
基于 Design Compiler 的 UDP Payload 追加控制模块综合与门级后仿真
笔记·fpga开发·udp
林伟_fpga3 天前
FPGA助力激光增材制造的熔池实时干预、探索TC11钛合金的类“钢筋混凝土”晶粒结构的优化路径
fpga