In the game of 10-pin bowling the bowler has two attempts to knock down pins for every frame of 10-pins, and scores a point for each pin knocked down. If all the pins are knocked down with two attempts, the bowler gets a bonus - whatever score they obtain with their next bowl is doubled. If all the pins are knocked down on the 1st attempt, no 2™d attempt is allowed, and the bowler gets a bonus – whatever score they obtain on their next two bowls are doubled. A student attempts to capture this scoring system in VHDL code, a fragment of which is shown in Figure Q4. Q4 (a) Draw the state transition diagram described by the VHDL of Figure Q4. L'J Discuss whether the VHDL of Figure Q4 correctly scores a game of 10-pin bowling. (b) .... elsif CLK='1' and CLK'event and UPD='1' then case present_state is when throwl => frame := frame + 1; + resize (unsigned (N),9) score := score if N = "1010" then present_state <= throwl-strike; else present_state <= throw2; end if; when throw2 => score := score + resize (unsigned (N),9) present state <= throwl; if N = "1010" then present_state <= throwl-spare; end if; when throwl-spare => frame := frame 1; + resize (unsigned (N),9) + resize (unsigned (N),9) score := score if N = "1010" then present state <= throwl-strike; else present state <= throw2; end if; when throwl-strike => frame := frame + 1; + resize (unsigned (N), 9) + resize (unsigned (N), 9) score := score if N = "1010" then present_state <= throwl-strike; else present-state <= throw2; end if; end case; end if; Figure Q4

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question
In the game of 10-pin bowling the bowler has two attempts to knock down pins
for every frame of 10-pins, and scores a point for each pin knocked down. If all
the pins are knocked down with two attempts, the bowler gets a bonus -
whatever score they obtain with their next bowl is doubled. If all the pins are
knocked down on the 1st attempt, no 2nd attempt is allowed, and the bowler gets
a bonus – whatever score they obtain on their next two bowls are doubled. A
student attempts to capture this scoring system in VHDL code, a fragment of
which is shown in Figure Q4.
Q4
(a)
Draw the state transition diagram described by the VHDL of Figure Q4.
Discuss whether the VHDL of Figure Q4 correctly scores a game of 10-pin
bowling.
(b)
elsif CLK='1' and CLK'event and UPD='1' then
case present state is
when throwl =>
frame := frame
+ 1;
+ resize (unsigned (N), 9)
score := score
if N = w1010" then
present state <= throwl-strike;
else
present_state <= throw2;
end if;
when throw2 =>
score := score + resize (unsigned (N), 9)
present state <= throwl;
if N = "1010" then
present_state <= throwl-spare;
end if;
when throwl-spare
frame := frame + 1;
score := score + resize (unsigned (N),9)
=>
+ resize (unsigned (N),9)
if N = "1010" then
present_state <= throw1-strike;
else
present state <= throw2;
end if;
when throwl-strike =>
frame := frame + 1;
score := score + resize (unsigned (N),9)
size (unsigned (N),
if N = "1010" then
present_state <= throwl-strike;
else
present-state <= throw2;
end if;
end case;
end if;
Figure Q4
Transcribed Image Text:In the game of 10-pin bowling the bowler has two attempts to knock down pins for every frame of 10-pins, and scores a point for each pin knocked down. If all the pins are knocked down with two attempts, the bowler gets a bonus - whatever score they obtain with their next bowl is doubled. If all the pins are knocked down on the 1st attempt, no 2nd attempt is allowed, and the bowler gets a bonus – whatever score they obtain on their next two bowls are doubled. A student attempts to capture this scoring system in VHDL code, a fragment of which is shown in Figure Q4. Q4 (a) Draw the state transition diagram described by the VHDL of Figure Q4. Discuss whether the VHDL of Figure Q4 correctly scores a game of 10-pin bowling. (b) elsif CLK='1' and CLK'event and UPD='1' then case present state is when throwl => frame := frame + 1; + resize (unsigned (N), 9) score := score if N = w1010" then present state <= throwl-strike; else present_state <= throw2; end if; when throw2 => score := score + resize (unsigned (N), 9) present state <= throwl; if N = "1010" then present_state <= throwl-spare; end if; when throwl-spare frame := frame + 1; score := score + resize (unsigned (N),9) => + resize (unsigned (N),9) if N = "1010" then present_state <= throw1-strike; else present state <= throw2; end if; when throwl-strike => frame := frame + 1; score := score + resize (unsigned (N),9) size (unsigned (N), if N = "1010" then present_state <= throwl-strike; else present-state <= throw2; end if; end case; end if; Figure Q4
Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY