关于以下测试程序,其说法正确的是:`timescale 1ns / 1psmodule cout_tp;reg clk,reset;wire [7:0] out;count u0( .clk(clk), .reset(reset), .out(out) );initial begin clk=0;reset=0;#4 reset=1;#4 reset=0;#100 reset=1;#4 reset=0;endinitial begin forever #2 clk=~clk;endendmodule
A: 该程序时间的基准单位是1ns,时间的精度是1ps
B: count 是模块名;u0是例化名
C: 测试程序中,时钟的频率为500MHz
D: 被测模块中clk和reset是输出信号
A: 该程序时间的基准单位是1ns,时间的精度是1ps
B: count 是模块名;u0是例化名
C: 测试程序中,时钟的频率为500MHz
D: 被测模块中clk和reset是输出信号
举一反三
- 下列Moore型状态机采用Verilog语言主控时序部分正确的是: A: always@(posedge clk or negedge reset) begin if(!reset) current_state<=s0; else current_state<=next_state; end B: always@(posedge clk ) begin if(!reset) current_state<=s0; else current_state<=next_state; end C: always@(posedge clk t) if(reset) current_state<=s0; else current_state<=next_state; D: always@(posedge clk or negedge reset) if(reset) current_state<=s0; else current_state<=next_state;
- 下列Moore型状态机采用Verilog语言主控时序部分正确的是: A: always@(posedge clk or negedge reset) begin if(!reset) current_state<=s0; else current_state<=next_state; end B: always@(posedge clk ) begin if(!reset) current_state<=s0; else current_state<=next_state; end C: always@(posedge clk t) if(reset) current_state<=s0; else current_state<=next_state; D: always@(posedge clk or negedge reset) if(reset) current_state<=s0; else current_state<=next_state;
- 根据下面的程序,画出产生的信号clk、phase_clk的波形如图所示`timescale 1ns/10ps module clk_tb2; reg clk; wire phase_clk; initialclk=0; always begin #5 clk=1; #5 clk=0; endassign #2 phase_clk=clk endmodule[img=314x94]17d603ead880b55.png[/img] ( )
- 根据下面的程序,画出产生的信号clk、phase_clk的波形如图所示`timescale 1ns/10ps module clk_tb2; reg clk; wire phase_clk; initialclk=0; always begin #5 clk=1; #5 clk=0; endassign #2 phase_clk=clk endmodule<img src="https://image.zhihuishu.com/zhs/doctrans/docx2html/202012/c171b55c15164ceabf263b09a3e3ab1b.png" /> ( )
- (多选题, 2分)时钟上升沿检测语句可以是? A: CLK'EVENT AND CLK='1' B: CLK'EVENT AND CLK='0' AND CLK'LAST_VALUE='1' C: CLK'LAST_VALUE='1' AND CLK='0' D: RISING_EDGE(CLK) E: FALLING_EDGE(CLK) F: CLK'EVENT AND CLK='1' AND CLK'LAST_VALUE='0' G: CLK'LAST_VALUE='0' AND CLK='1'