CSE 260: Homework 3

Fall 2015

Due Date: Thursday, October 15th, 4:00 PM



1. (10 points) You are given the following timing diagram:



a.) Sketch the output if these were input into a D Latch.
b.) Sketch the output if these were input into a D Flip-Flop

2.) (15 points) In class we discussed a J/K flip flop (see slide 5 of the lecture from September 29th). Construct a circuit that uses a J/K Flip-Flop along with additional combinational logic gates to construct a D Flip-Flop.

3.) We want to construct a circuit to control a vending machine. The vending machine will dispense an item after 15 cents is inserted. Users may insert either nickels or dimes. If the user inserts too much money, then the item is dispensed and the appropriate change is given. After an item is dispensed, the machine returns to its initial state and waits for another item to be purchased.

a.) (5 points) What are the inputs? The outputs?
b.) (10 points) Create a Moore machine for this problem.
c.) (10 points) Simplify your machine such that it uses the smallest number of states possible. If your machine is already simplified, explain how you know this.
d.) (10 points) Create a Mealy machine for this problem.
e.) (10 points) Construct a transition diagram for your FSM that uses binary encoding for the states.
f.) (10 points) Construct a transition diagram for your FSM that uses one hot encoding for the states.
g.) (20 points) Construct a circuit for your FSM that uses binary encoding for the states. Be as complete as possible.

Submission

Your lab must be submitted to me by 4PM on the due date. You can give it to me in class, put it in my mailbox in Bryan 509, or drop it off during office hours.