1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Maksim231197 [3]
3 years ago
9

Design a Verilog module that takes a high frequency clock input and outputs a clock signal at 1/1000 of the input frequency. The

output clock signals should be 50% duty cycle, which means they should be high in half of the period and low in the other half.

Computers and Technology
1 answer:
JulsSmile [24]3 years ago
8 0

Answer:

// Code your design here

module clk_div

#(

parameter WIDTH = 7,// width of register

parameter N = 100// value of division here 100

)

(clk,reset, clk_out);

input clk;

input reset;

output clk_out;

reg [WIDTH-1:0] r_reg;// counting register

wire [WIDTH-1:0] r_nxt;

reg clk_track;// clock value

always at(posedge clk or posedge reset)

begin

if (reset)// reset

begin

r_reg <= 0;

  clk_track <= 1'b0;

end

else if (r_nxt == N)

   begin

  r_reg <= 0;

  clk_track <= ~clk_track;

  end

else

r_reg <= r_nxt;

end

assign r_nxt = r_reg+1;    

assign clk_out = clk_track;

endmodule

testbench:

// Code your testbench here

// or browse Examples

module clkdiv2n_tb;

reg clk,reset;

wire clk_out;

clk_div t1(clk,reset,clk_out);

initial

clk= 1'b0;

always

#5 clk=~clk;

initial

begin

#5 reset=1'b1;

#10 reset=1'b0;

#5000 $finish;

end

initial

$monitor("clk=%b,reset=%b,clk_out=%b",clk,reset,clk_out);

initial

begin

$dumpfile("dump.vcd");

$dumpvars(2);

end

endmodule

Explanation:

see waveform

You might be interested in
If a business industry does not meet OSHA standards
soldi70 [24.7K]

Explanation:

USE SOCRACTIC IT WOULD REALLY HELP

7 0
4 years ago
Read 2 more answers
Digital manufacturing has impacted our world today! List a reasons why.
Maru [420]
Because we can get manufacturing faster than usual
6 0
4 years ago
Match each career to its various job roles. digital media coordinator digital media specialist photographer sound producer creat
Morgarella [4.7K]

Answer:

1. Digital media coordinator.

2. Sound producer.

3. Digital media specialist.

4. Photographer.

Explanation:

1. Digital media coordinator: he or she is saddled with the responsibility of creating audio and video content for use on websites.

2. Sound producer: he or she records and modifies sound and music for video games and movies through the use of specialized software application such as fruity loops.

3. Digital media specialist: he or she is saddled with the responsibility of posting content such as news, pictures, graphic designs, etc., on the Internet.

4. Photographer: he or she captures images using a camera or camcorder and edits the images using a graphic design software such as Adobe Photoshop.

3 0
3 years ago
Design the logic for a program that allows a usher to continuously enter numbers until the usher enters 0. Display the sum of th
uysha [10]

int sum = 0, n;

do {cin>>n; sum+=n;}while (n!=0);

cout<<sum;

5 0
4 years ago
What does the following code print? time_of_day = ["morning", "afternoon", "evening"] for word in time_of_day: print "Good " + w
jek_recluse [69]

Answer:

syntaxerror

Explanation:

the print is missing a parenthesis - it will give the error:

SyntaxError: Missing parentheses in call to 'print'.

if you did put parenthesis it would say

Good morning

Good afternoon

Good evening

8 0
2 years ago
Other questions:
  • A ____ is any manipulation of data, usually with the goal of producing information.
    9·1 answer
  • PLEASE HELP ITS EASY I JUST BIG STOOPYHEAD!!!!
    5·2 answers
  • A​ _______ variable is a variable that has a single numerical​ value, determined by​ chance, for each outcome of a procedure.
    7·1 answer
  • If you are working with a team of students on a class project and your team chooses to share content by uploading Word and Excel
    13·1 answer
  • What is Digital Etiquette? Explain in your own words
    13·1 answer
  • Answer if you know Javascript, html, css, python, and Ruby.
    12·1 answer
  • Question 3 of 10
    12·1 answer
  • Which is the base class in the following statement? class car : public vehicle
    13·1 answer
  • Two negative reviews and no positive reviews is enough to consider the website to have a negative reputation.
    11·1 answer
  • if you are using an administrator account during a software installation and you get prompted by the uac, you should
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!