digsystemexample

# digsystemexample - CS2204 DIGITAL LOGIC & STATE MACHINE...

This preview shows pages 1–3. Sign up to view the full content.

DIGITAL SYSTEM DESIGN EXAMPLE CS2204 DIGITAL LOGIC & STATE MACHINE DESIGN FALL 2010 Polytechnic Institute of NYU Page 1 of 8 Handout No: 15 October 28, 2010 A Vending Machine Controller We will design a vending machine controller as a digital system by using the ﬁnite state machine (FSM) technique. The design is done through seven steps as discussed in class and in the lab. 1) The black-box view and the textual input/output relationship A vending machine, by means of its controller, delivers gums and chips, both costing 35 cents. One can input only Dimes (10 cents) and Nickels (5 cents). There is no Coin Return button. D DG clock DC RetCoin N G C 14 Amount Inputs D : Dime is input N : Nickel is input G : Gum is selected C : Chips is selected Outputs Amount : 1) Value of gum and chips (35 cents) or 2) The coin input so far shown on two 7-segment displays DG : Deliver Gum DC : Deliver chips RetCoin : Return 5 cents Textual Input/Output Relationship After receiving the necessary amount (35 cents or 40 cents) and the selection is made, deliver gum or chips and if necessary return 5 cents 2) Obtain the operation diagram from the black-box view and the textual input/output rela- tionship Reset & show 35 cents 0 10 cents received 1 D 5 cents received 3 N 2 SumLT35cents SumLT35cents D N 4 SumGE35cents coin if necessary 5 coin if necessary 6 G C

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

View Full Document
Polytechnic Institute of NYU Page 2 of 8 CS2204 Handout No : 15 October 28, 2010 3) Obtain the high-level state diagram from the operation diagram A 0 0 1 D 3 N 2 LT LT D N Amount = A 4 L T DG = 1 If GT then RetCoin = 1 5 6 G C A A + 10 A A + 5 Amount = A Amount = 35 DC = 1 If GT then RetCoin = 1 Amount = A Amount = A Amount = 35 Amount = 35 4) Obtain the datapath from the high-level state diagram 6-bit 2-to-1 MUX 6 1 6 0 10 5 R L D C Sel Dime Clr
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 10/02/2011 for the course HNRS 1003 taught by Professor Zerba during the Spring '08 term at LSU.

### Page1 / 8

digsystemexample - CS2204 DIGITAL LOGIC & STATE MACHINE...

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

View Full Document
Ask a homework question - tutors are online