hw2 - Homework 2 CSEE W4824 Prof. Luca Carloni Handout 7...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CSEE W4824 Prof. Luca Carloni Homework 2 Handout 7 September 28, 2011 This homework is due at the beginning of class on Monday, October 10. A correct answer without adequate explanation or derivation will have points deducted. To get full credit, write legibly/type, and show all work (label relevant items, show deriviations, include explanations). 1. (10 points) . The operations of a soda vending machine are controlled by a finite state machine (FSM). All soda in the machine cost only 25 cents. At each step the machine accepts exactly one coin. The coin can be one of the following (the corresponding input signal for the FSM is denoted in parenthesis): a nickel (N), a dime (D), or a quarter (Q). When enough coins have been inserted the machine should return a soda (together with any necessary change) and be ready to start accepting coins for a new soda. Consequently, the output signals of the FSM are: DispenseSoda (DS) : asserted only one step after enough coins have been inserted; ReturnNickel (RN) : asserted only one step after enough coins have been inserted if one nickel should be returned as part of the change; ReturnDime (RD) : asserted only one step after enough coins have been inserted if one dime (but not two) should be returned as part of the change; ReturnTwoDimes (RT) : asserted only one step after enough coins have been inserted if two dimes should be returned as part of the change; Derive the state transition diagram (STD) of the FSM (Moore implementation). 2. (15 points) . Consider the code fragment in Figure 1 and start with the following general assumptions: the implementation is based on the classic RISC five-stage integer pipeline; the branch execution is completed in the EX stage; all instructions memory accesses take 1 clock cycle and all data memory accesses take 1 clock cycle. DADDI
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 11/12/2011 for the course CSEE 4824 taught by Professor Carloni during the Fall '11 term at Columbia.

Page1 / 5

hw2 - Homework 2 CSEE W4824 Prof. Luca Carloni Handout 7...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online