[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
相关推荐
逐步前行1 小时前
STM32_SysTick_寄存器操作
stm32·嵌入式硬件·fpga开发
良许Linux8 小时前
FPGA的选型和应用
数据库·图像处理·计算机视觉·fpga开发
上班最快乐8 小时前
基于FPGA的APS6404L-3SQR QSPI PSRAM驱动设计(3)
fpga开发
CoderIsArt8 小时前
FPGA实现量子计算机仿真器重要论文
fpga开发·量子计算
上班最快乐10 小时前
基于FPGA的APS6404L-3SQR QSPI PSRAM驱动设计(4)
fpga开发
LCMICRO-133108477461 天前
长芯微LDC64115完全P2P替代AD4115,是一款低功耗、低噪声、24位、Σ-Δ(Σ-Δ)模数转换器(ADC)
stm32·单片机·嵌入式硬件·fpga开发·硬件工程·模数转换器
inquisiter1 天前
plic中断级联设计和使用
fpga开发·riscv
JSMSEMI111 天前
JSM3488E RS‑485/RS‑422 收发器芯片
fpga开发
学习永无止境@2 天前
Vivado FPGA程序压缩
fpga开发
daxi1502 天前
Verilog入门实战——第2讲:核心语法基础(数据类型+赋值语句)
fpga开发·fpga