This preview shows page 1-2-15-16-31-32 out of 32 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 32 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

Approaches to Digital System DesignA Computer!!Components of any Computer SystemProblem DefinitionTwo Approaches for Solving this ProblemASM chart for 324 8561FSM ImplementationFSM Implementation (cont.)FSM OperationComputer System ImplementationWhat do We Need?Input/Output First, same as FSMRegister for holding DIGIT output valueMemory for holding instructionsRegister for specifying address – Use counterWhat Instructions do we need?Needed InstructionsInstruction EncodingInstruction TableA Program for 324 8561Convert Program to Binary, Put in MemoryConvert Program to Binary, Put in Memory(final)Add control Logic to Execute InstructionsWhat is control Logic?Decode Boolean EquationsTimingCommentsProgram CounterImplementation ComparisonsVocabularyVocabulary (cont.)How are modern Computers different from Number Sequencing Computer?What do you need to know?V 0.5 1Approaches to Digital System Design• In Digital Devices, you learned how to create a logic network (Flip-flops + combinational gates) to solve a problem– The logic network was SPECIFIC to the problem. To solve a different problem, needed a different logic network• Another approach is to design a logic network that can used to solve many different problems–This general purpose logic network might not be as efficient (speed, cost) as a special purpose logic network, but hopefully can be used to solve multiple problems!V 0.5 2A Computer!!•A Computer is a digital system whose operation can be specified via a Program .– Changing the program changes the computer behavior! (solves a different problem!!!).• A Program is simply a sequence of binary codes that represent instructions for the computer. The Program is stored in a Memory . • External inputs to the Computer can also alter the behavior the computer. The computer will have Outputs that can be set/reset via program instructions. – These external inputs/output are know as the I/O section of the computer.V 0.5 3Components of any Computer System• Control – logic that controls fetching/execution of instructions• Memory – area where instructions/data are stored• Input/Output – external interaction with computerControlMemoryAddress busDatabus busInput/OutputdevicesV 0.5 4Problem DefinitionBuild a Digital System based upon your phone number, assumed to be of the form Y1Y2Y3-Z1Z2Z3Z4The Digital System will have one external input called LOC. If LOC is true, then the system will display only the digits Z1Z2Z3Z4.If LOC is false, then the system will display all seven digits.V 0.5 5Two Approaches for Solving this ProblemFinite State MachineWill only work for one number sequenceControlMemoryAddress busDatabus busInput/OutputdevicesComputer SystemWill only work for any number sequence, change program to change sequenceV 0.5 6ASM chart for 324 8561Odd only affects sequence in State S* (Reset state)Copyright Thomson/Delmar Learning 2005. All Rights Reserved.V 0.5 7FSM ImplementationOne-Hot encoding: one DFF per state, requires 1 DFF per state but simplifies combinational logic.Binary Encoding: use minimal number of DFFs, but makes combinational logic more complex.V 0.5 8FSM Implementation (cont.)Use one hot encoding, D-FFs for the 8 states.DffsDQR, SCombinationalLogicCircuitDOUT[3:0]LOCOutputs7-bitNext StateValue7-bitPresent StateValue77ClkLogic designed fora particular number sequence.Reset logic, DFF S0 set to a ‘1’ on reset, other DFFs reset to ‘0’See textbook for combinational logic derivation.V 0.5 9FSM OperationCopyright 2005. Thomson/Delmar Learning, All rights reserved.Each state requires one clock cycleV 0.5 10Computer System ImplementationWhat do We Need?Input/Output First, same as FSM 4DOUT[3:0]LOCDOUT[3:0] - 4 bit output bus that has the value of the digitLOC – 1 bit input that controls whether or not the full number sequence is displayedV 0.5 11Register for holding DIGIT output value4DOUT[3:0]D4LDREGRLOCRegister loads D on rising clock edge when LD = 1.R is an asynchronous clear.V 0.5 12Memory for holding instructionsLOCMEMData[?:0]Address[?:0]Memory is KxN (K locations, each location N bits wide).Don’t know values of K, N yet.4DOUT[3:0]D4LDREGRV 0.5 13Register for specifying address – Use counterOddMEMData[?:0]Addr[?:0]?LDcntrINCCounter increments on rising clock edge when INC = 1.Loads on rising clock edge when LD = 1. R is an asynchronous clear.Din[?:0]4DOUT[3:0]D4LDREGRRProgram CounterProgram MemoryV 0.5 14What Instructions do we need?Start:If (LOC = 1) goto localoutput Y1output Y2output Y3local:output Z1output Z2output Z3output Z4goto StartPsuedo Code foroperationsV 0.5 15Needed Instructions1. Jc location Jump conditionallyIf LOC = 1, then jump to location (counter set equal to specified location). If LOC = 0, then fetch next instruction (counter increments by 1).2. Jmp location Jump unconditionalFetch next instruction from location (counter loaded with specified location).3. out dataload output register with data. Used for setting the DOUT[3:0] value.V 0.5 16Instruction Encoding The binary encoding for instructions is usually divided into different fields; with each field representing part of the information needed by the instruction.Our instructions require two fields: Operation Code and DataOpcode | DataHow many bits for the Opcode? Have 3 instructions, need at least 2 bits! (2 bits can encode 22items)How many bits for Data? The data field must specify the 4 bits for the DOUT number, and also specify a memory location. For now, lets use 4 bits for data. Instruction is 6 bits total.I5 I4 I3 I2 I1 I0Opcode | DataV 0.5 17Instruction Table0 0 | 4-bit locationJMP locationI5 I4 I3 I2 I1 I00 1 | 4-bit locationJC location1 0 | 4-bit dataOUT dataNote that Opcode = 11 is unused.The opcode assignment was chosen so that the OUT instruction could be distinguished from the two jump instructions by only the most significant bit of the opcode.Could have chosen another opcode assignment, but this could make the decode logic more complex.means memory will have maximum of 24= 16 locations.Each location will contain 6 bits.V 0.5 18A Program for 324 8561start: JC local ; jump only if LOC input=1OUT 3OUT 2OUT 4local: OUT 8OUT 5OUT 6OUT 1JMP startV 0.5 19Convert Program to Binary, Put in MemoryMemory Location Machine Code Instruction0x0 01 ????START: JC LOCAL0x1 10 0011OUT 30x2 10 0010OUT 20x3 10 0100OUT 40x4 10 1000LOCAL: OUT 80x5 10 0101OUT 50x6


View Full Document

MSU ECE 3724 - Approaches to Digital System Design

Documents in this Course
Timers

Timers

38 pages

TEST 4

TEST 4

9 pages

Flags

Flags

6 pages

Timers

Timers

6 pages

Timers

Timers

54 pages

TEST2

TEST2

8 pages

Load more
Download Approaches to Digital System Design
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Approaches to Digital System Design and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Approaches to Digital System Design 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?