# Gray Code Generator and Decoder by Carsten Kristiansen Napier University. November 2004

Save this PDF as:

Size: px
Start display at page:

Download "Gray Code Generator and Decoder by Carsten Kristiansen Napier University. November 2004"

## Transcription

1 Gray Code Generator and Decoder by Carsten Kristiansen Napier University November 2004

2

3 Title page Author: Carsten Kristiansen. Napier No: Assignment title: Design of a Gray Code Generator and Decoder. Education: Electronic and Computer Engineering. Module: Electronic Systems SE Place of education: Napier University Edinburgh 10 Colinton Road Edinburgh EH10 5DT Lecturer: Jay Hoy. Assignment period: 27. October December 2004.

4 1. Abstract This report describes how an Gray code generator and decoder are designed and simulated. The report takes a beginning in an introduction to what Gray code is, and can be used for in a practical matter of speaking. There is described the design and simulation process separately for the Gray code generator and the Gray code to binary decoder. This reaches a final and complete schematic as well as a simulation.

5 Contents 1. Abstract Introduction Practical use of the Gray code Assignment specifications Block diagram Gray code generator State transition diagram State table Next state logic Schematic Simulation result Gray code to BCD decoder State transition diagram State table Next state logic Schematic Complete schematic Simulation result Conclusion References Internet Literature Software tools... 21

6 Gray code generator and decoder Carsten Kristiansen Napier No.: Introduction In today's digital electronics, there are many different types of codes. The most used code combination are known as the binary code, which is a code where every bit represents an integer value. There are however also codes where the combination and shifts between a 0 and a 1 that is important like the Gray code. The Gray code are the type that's explained further in this report. It was used for the first time in a telegraph by the French engineer Émile Baudot in 1878, but was not patented before 1953, by the Bell Labs researcher Frank Gray, which also gave the name to the code. The Gray code can best be described as a combination of binary numbers, with the advantage that it only changes one bit at the time in the right sequence. It is possible to make the Gray code up to 4 bits of a maximum, cause more is not a unique sequence. Below in figure 1 it is shown visual how a 4 bit Gray code looks like. D C B A Position Fig. 1: 4 bit Gray code The letters A to D represents the 4 bits, where D is the Least Significant Bit (LSB), and A is the Most Significant Bit (MSB). The 4 bit Gray code starts from the position 0 and ends at position 15. All of the dark circles indicates a logical high ( 1 ), where all the empty boxes indicates a logical zero ( 0 ). Note that with each shifts in position there are only increased or decreased with one (high) logical level. 6 Napier University

7 Carsten Kristiansen Napier No.: Gray code generator and decoder 2.1. Practical use of the Gray code Gray codes are mostly used where a mechanical position needs to be converted to a digital signal. This can be very convenient to use with cogwheels, to determine whether it is at the right position or not. For instance, a production machine are running, and there would be cogwheels inside, where one of them has a Gray code scale (shown below in figure 2) mounted, to be read by photo-sensors and some electronics to decode the signals. Now if the cogwheel had to be very precise adjusted in its position, and at some time it would break a cog, so that the machine wouldn't run as desired (the precision of the wheel would be wrong), it would then be possible for some electronic to read from the Gray code scale, that the sequence of the code would be wrong, set of an alarm and stop the machine immediately. Fig. 2: Gray code vs. binary code The figure 2 also shows the difference between the Gray code and the binary code, if they where both to be used on a cogwheel. The dark part in the circle are the logical high, and the light are the logical low levels. Again it would not be preferable not to use the binary code, because of the many shifts there would be in the logical levels compared to the Gray code. Napier University 7

8 Gray code generator and decoder Carsten Kristiansen Napier No.: Assignment specifications Use JK flip-flops and suitable logic gates to design a 4-bit binary Gray code generator. Use the output of the Gray code generator as inputs to a combinational logic circuit to decode the Gray code to produce the normal binary counting sequence. Use TINA or any other simulation package to produce results to verify the design Block diagram From the specifications a general block diagram can be presented. The block diagram below in figure 3 indicates what the desired options for the assignment are. Display 1MHz Clock source Gray code Generator Gray code Decoder Fig. 3: Gray code generator and decoder block diagram For the Gray code generator, a clock source is needed. This clock source should generate square pulses at 1 Mhz. The Gray code generator should then be able to send a 4 bit code parallel to the Gray code decoder, where the decoder will convert the Gray code to a 4 bit binary code, which can be used as an output to a display. The table below indicates the conversion between the Gray code to the binary output. The time sequence for each of the steps are also shown in micro-seconds. Label Time [µs] Gray code Binary out A B C D Q D Napier University

9 Carsten Kristiansen Napier No.: Gray code generator and decoder 4. Gray code generator To design the Gray code generator, it is analysed what is needed from the input to the output. By looking at the truth table for the Gray code, it is possible to follow the design procedure, and start with a state transition diagram that shows which steps the generator needs to fulfil. To get the generator running there is a synchronous clock pulse between each step State transition diagram Fig. 4: Gray code state transition diagram The state transition diagram in figure 4 indicates that there are 4 bits, and 16 steps that needs to be mapped. For this, 4 JK flip-flops are used, one for each bit. A table for the states of this type of flipflop are shown below. The x's indicates a don't care state. JK Flip-Flop Q Q + J K X X 1 0 X X 0 Napier University 9

10 Gray code generator and decoder Carsten Kristiansen Napier No.: State table A state table can then be made, where it is possible to derive the change state for each of the JK flipflops. This is done by filling out the next state logic for the Gray code. Label Present state Next state Change state Q D Q D + J A K A J B K B J C K C J D K D X 0 X 0 X 1 X X 0 X 1 X X X 0 X X 0 X X 1 X X 0 0 X X X 0 X 0 1 X X X 0 X 1 X X X 0 0 X X X X 0 0 X 0 X X 0 X 0 0 X 1 X X 0 X 0 1 X X X 0 X 0 X 0 X X 0 X 1 X 0 0 X X 0 0 X X 0 1 X X 0 0 X X 1 X X 0 0 X 0 X X X 1 0 X 0 X 0 X 4.3. Next state logic From the change state of the state table, the next state logic can be derived and written into Karnaugh maps. The method used for this, is to draw a map for each output. To illustrate better what is needed on the input to get the required output, the logic gates and connections for each of the reduced expressions are also shown to the right of each Karnaugh maps. Q D X X X X X X X X J A change state /QC /QD U13 SN7411 Fig. 5: J A logic gate JA J A = Q D Q D X X X X X X X X 0 0 K A change state / /QC /QD U14 SN7411 KA K A = Q D Fig. 6: K A logic gate 10 Napier University

11 Carsten Kristiansen Napier No.: Gray code generator and decoder Q D X X X X X X X X 0 J B change state / QC /QD U15 SN7411 Fig. 7: J B logic gate JB J B = Q D Q D X 0 0 X 0 1 X 0 0 X 1 1 X 0 0 X 1 0 X 0 1 X K B change state U16 SN7411 QC /QD Fig. 8: K B logic gate KB K B = Q D Q D X X X X 1 0 X X X X J C change state QD U21!XOR U19 SN7404 U17 SN7408 JC J C = Q D Q D =Q D =Q D Fig. 9: J C logic gates Q D X X X X 0 1 X X X X K C change state QD U21!XOR U18 SN7408 KC K C = Q D Q D =Q D =Q D Fig. 10: K C logic gates Napier University 11

12 Gray code generator and decoder Carsten Kristiansen Napier No.: Q D X X X X 1 1 X X X X J D change state QC U21!XOR U20!XOR U22 SN7404 JD Fig. 11: J D logic gates J D = = = = Q D X X X X X X X X K D change state U21!XOR QC U20!XOR KD Fig. 12: K D logic gates K D = = = = Note that the J C, K C, J D and K D can share some of the gates. Meaning that some of the gates can be spared cause they use the same outputs. This is illustrated better in the schematics. 12 Napier University

13 Carsten Kristiansen Napier No.: Gray code generator and decoder 4.4. Schematic The schematic below in figure 13 shows the diagram from TINA, used for the simulation of the Gray code generator. At each of the JK flip-flop's output, there is a logic indicator connected, which have been used for a step-by-step simulation to indicate if the circuit are working as desired. The clock-output (), sends a 1 MHz clock source synchronously to each of the flip-flop's. This is corresponding to 1 μs for each pulse. U13 SN7411 U14 SN7411 U5 + U1 SN7476 J P A Q K C Q U9 + QC QD U15 SN7411 U16 SN7411 U6 + U2 SN7476 J P B Q K C Q U10 + U21!XOR U19 SN7404 U17 SN7408 U18 SN7408 U7 + U3 SN7476 J P C Q K C Q U11 + QC U20!XOR U22 SN7404 U8 + U4 SN7476 J P D Q K C Q U12 + QD Fig. 13: Gray code generator simulation schematic Napier University 13

14 Gray code generator and decoder Carsten Kristiansen Napier No.: Simulation result The figure 14 below shows the digital timing analysis for the Gray code generator derived from TINA. When looking at the timing for each clock pulse, the output and then compare it with the state table, it is possible to see that the output of the generator matches the specifications. T H QC L H L H L H L H QD L u 10.00u 15.00u 20.00u Time (s) Fig. 14: Gray code generator digital timing analysis 14 Napier University

15 Carsten Kristiansen Napier No.: Gray code generator and decoder 5. Gray code to BCD decoder This type of code converter are used to convert the Gray code to a useful and known code like the binary code. The binary output could then be set to a display where the counting sequence for the Gray code could be visual accomplished. The design procedure is the same as for the Gray code generator, except there will for the BCD decoder only be used logic gates, and no flip-flop's State transition diagram Fig. 15: BCD state transition diagram The input to output conversion to be dealt with, consists of 4 bit for both the input and the output. This can be described best as a parallel input to a parallel output, which each of the clock-pulses in the figure 15 above indicates. Napier University 15

16 Gray code generator and decoder Carsten Kristiansen Napier No.: State table With the known Gray code and binary sequence, the state table can made as shown in the table below. Label Gray code Binary out A B C D Q D Like with the Gray code generator, there are used Karnaugh mapping, to find the boolean expressions for each of the outputs (next state logic). From this the needed logical gates can then be found Next state logic A B C D Output A Fig. 16: logic output = A A B C D Output A B U1!XOR Fig. 17: logic output = A B A B = A B 16 Napier University

17 Carsten Kristiansen Napier No.: Gray code generator and decoder A B C D Output A B C U1!XOR Fig. 18: logic output U2!XOR QC = A B C A B C A B C A B C =C A B A B C A B A B =C A B C A B = A B C A B C D Q D Output A B C D U1!XOR Fig. 19: Q D logic output U2!XOR U3!XOR QD Q D = A B C D A B C D A B C D A B C D A B C D A B C D A B C D A B C D = A B C D C D A B C D C D A B C D C D A B C D C D = A B C D A B C D A B C D A B C D = A B C D A B C D = A B C D 5.4. Schematic By looking at each of the next state logic outputs of the Gray code to BCD decoder, there is one XOR gate added for each output. This means that the final schematic can be reduced quite a lot! When comparing the schematic in figure 20 with all the reduced logic outputs above, it is possible to derive, that the circuits can be reduced from six to three gates. This circuit has not been simulated individually but instead in the final and complete schematic. A U1!XOR B U2!XOR C D Fig. 20: Gray code to BCD schematic U3!XOR QC QD Napier University 17

18 Gray code generator and decoder Carsten Kristiansen Napier No.: Complete schematic The complete schematic drawing from TINA are shown in figure 21 below. The Gray code generator are connected to the decoder, from where the output for the following timing analysis can be derived. Further more an hex display are connected to the output of the decoder, to better visualize the counting sequence in TINA. The schematic are simulated for this, in the digital stepby-step mode, where the display has counted from 0 to 9 then A to F, and over again. Display U13 SN7411 U14 SN7411 U5 + U1 SN7476 J P Q K U9 + C Q U23!XOR U24!XOR QC U15 SN7411 U6 + U2 SN7476 J P Q U25!XOR QD U16 SN7411 K U10 + C Q U21!XOR U19 SN7404 U17 SN7408 U7+ U3 SN7476 J P Q U18 SN7408 K C Q U11 + U20!XOR U22 SN7404 U8 + U4 SN7476 J P Q K U12 + C Q Fig. 21: Gray code generator and decoder complete schematic 18 Napier University

19 Carsten Kristiansen Napier No.: Gray code generator and decoder 6.1. Simulation result The figure 22 shows the final simulation with the complete schematic. The simulation has lasted over a time period of 20 µs, where after the period of 16 µs the final stage where all the outputs are logic high (1111). Each of the output sequences matches those set in the table of specifications, for the Gray code to binary output. T H QC L H L H L H L H QD L u 10.00u 15.00u 20.00u Time (s) Fig. 22: Gray code generator and decoder digital timing analysis Napier University 19

20 Gray code generator and decoder Carsten Kristiansen Napier No.: Conclusion The design and simulation assignment of a Gray code generator and decoder has been completed successfully. The assignment seemed difficult in the beginning, but once a little research about Gray code and its counting sequence was found, everything just went smoothly. Also the part where the logical gates where to be found by reducing the boolean expressions had to be refreshed, before the final design could be a successful possibility. There are though limits to TINA and designing the generator, where TINA don't have XNOR gates. This gate has been achieved by using an inverter before the final output of the logical gate, to make the direct opposite of a XOR. When designing the generator and decoder on paper with the boolean expression and in TINA, it came in handy to give it a extra look to see that some of the gates could share their input to output conversion. The assignment of designing the Gray code generator and decoder has been an interesting assignment, cause of the experiences it has given by the use of boolean algebra, logical gates and flip-flops. The use of this to make generators and decoders has given some second thoughts on how to build these and how the procedures would be to make a complete design. If I as the designer where to build the generator and decoder for practical use, it would be by using either a CPLD or a microprocessor. The CPLD would be the best device to use for this assignment, cause of the analysing, gate outputs and the use of flip-flops, which is very suitable to make a complete design of in a CPLD. The software for this like for instance Xilinx's has also got the neat feature that it is capable of simulating the schematics. An important thing to do, when working with logical devices is also to think logical, and that has been a very stimulating experience in this assignment. A little knowledge to electronic is of course a must, but one can get far just by having a logical mind. Carsten Kristiansen 20 Napier University

21 Carsten Kristiansen Napier No.: Gray code generator and decoder 8. References 8.1. Internet The meaning of Gray code, Gray code from Mathworld, Gray code algorythms, Binary codes, Literature Introduction to electrical engineering, Mulukutla S. Sarma. Handout notes for Sequential synchronous circuits, Jay Hoy. Digital Teknik, Leif Møller Andersen Software tools TINA Pro for Windows, Napier University 21

### Napier University. School of Engineering. Electronic Engineering A Module: SE42205 Digital Design

Napier University School of Engineering Digital Design Clock + U1 out 5V "1" "2" "4" JK-FF D JK-FF C JK-FF B U8 SN7408 signal U4 SN74107 U5 SN74107 U6 SN74107 U3 SN7408 U2 J Q J Q & J Q & K CQ K CQ K CQ

### Lecture 8: Synchronous Digital Systems

Lecture 8: Synchronous Digital Systems The distinguishing feature of a synchronous digital system is that the circuit only changes in response to a system clock. For example, consider the edge triggered

### ETEC 2301 Programmable Logic Devices. Chapter 10 Counters. Shawnee State University Department of Industrial and Engineering Technologies

ETEC 2301 Programmable Logic Devices Chapter 10 Counters Shawnee State University Department of Industrial and Engineering Technologies Copyright 2007 by Janna B. Gallaher Asynchronous Counter Operation

### Counters and Decoders

Physics 3330 Experiment #10 Fall 1999 Purpose Counters and Decoders In this experiment, you will design and construct a 4-bit ripple-through decade counter with a decimal read-out display. Such a counter

### Design Example: Counters. Design Example: Counters. 3-Bit Binary Counter. 3-Bit Binary Counter. Other useful counters:

Design Eample: ers er: a sequential circuit that repeats a specified sequence of output upon clock pulses. A,B,C,, Z. G, O, T, E, R, P, S,!.,,,,,,,7. 7,,,,,,,.,,,,,,,,,,,. Binary counter: follows the binary

### DIGITAL ELECTRONICS. Counters. By: Electrical Engineering Department

Counters By: Electrical Engineering Department 1 Counters Upon completion of the chapter, students should be able to:.1 Understand the basic concepts of asynchronous counter and synchronous counters, and

### Module 3: Floyd, Digital Fundamental

Module 3: Lecturer : Yongsheng Gao Room : Tech - 3.25 Email : yongsheng.gao@griffith.edu.au Structure : 6 lectures 1 Tutorial Assessment: 1 Laboratory (5%) 1 Test (20%) Textbook : Floyd, Digital Fundamental

### Asynchronous Counters. Asynchronous Counters

Counters and State Machine Design November 25 Asynchronous Counters ENGI 25 ELEC 24 Asynchronous Counters The term Asynchronous refers to events that do not occur at the same time With respect to counter

### Digital Fundamentals

Digital Fundamentals Tenth Edition Floyd hapter 8 2009 Pearson Education, Upper 2008 Pearson Saddle River, Education NJ 07458. All Rights Reserved ounting in Binary As you know, the binary count sequence

### Experiment # 9. Clock generator circuits & Counters. Eng. Waleed Y. Mousa

Experiment # 9 Clock generator circuits & Counters Eng. Waleed Y. Mousa 1. Objectives: 1. Understanding the principles and construction of Clock generator. 2. To be familiar with clock pulse generation

### Take-Home Exercise. z y x. Erik Jonsson School of Engineering and Computer Science. The University of Texas at Dallas

Take-Home Exercise Assume you want the counter below to count mod-6 backward. That is, it would count 0-5-4-3-2-1-0, etc. Assume it is reset on startup, and design the wiring to make the counter count

### DIGITAL COUNTERS. Q B Q A = 00 initially. Q B Q A = 01 after the first clock pulse.

DIGITAL COUNTERS http://www.tutorialspoint.com/computer_logical_organization/digital_counters.htm Copyright tutorialspoint.com Counter is a sequential circuit. A digital circuit which is used for a counting

### The components. E3: Digital electronics. Goals:

E3: Digital electronics Goals: Basic understanding of logic circuits. Become familiar with the most common digital components and their use. Equipment: 1 st. LED bridge 1 st. 7-segment display. 2 st. IC

### Digital Electronics Detailed Outline

Digital Electronics Detailed Outline Unit 1: Fundamentals of Analog and Digital Electronics (32 Total Days) Lesson 1.1: Foundations and the Board Game Counter (9 days) 1. Safety is an important concept

### Upon completion of unit 1.1, students will be able to

Upon completion of unit 1.1, students will be able to 1. Demonstrate safety of the individual, class, and overall environment of the classroom/laboratory, and understand that electricity, even at the nominal

### Decimal Number (base 10) Binary Number (base 2)

LECTURE 5. BINARY COUNTER Before starting with counters there is some vital information that needs to be understood. The most important is the fact that since the outputs of a digital chip can only be

### Counters are sequential circuits which "count" through a specific state sequence.

Counters Counters are sequential circuits which "count" through a specific state sequence. They can count up, count down, or count through other fixed sequences. Two distinct types are in common usage:

### Digital Fundamentals. Lab 8 Asynchronous Counter Applications

Richland College Engineering Technology Rev. 0 B. Donham Rev. 1 (7/2003). Horne Rev. 2 (1/2008). Bradbury Digital Fundamentals CETT 1425 Lab 8 Asynchronous Counter Applications Name: Date: Objectives:

### Digital Systems Based on Principles and Applications of Electrical Engineering/Rizzoni (McGraw Hill

Digital Systems Based on Principles and Applications of Electrical Engineering/Rizzoni (McGraw Hill Objectives: Analyze the operation of sequential logic circuits. Understand the operation of digital counters.

### EXPERIMENT 8. Flip-Flops and Sequential Circuits

EXPERIMENT 8. Flip-Flops and Sequential Circuits I. Introduction I.a. Objectives The objective of this experiment is to become familiar with the basic operational principles of flip-flops and counters.

### ASYNCHRONOUS COUNTERS

LB no.. SYNCHONOUS COUNTES. Introduction Counters are sequential logic circuits that counts the pulses applied at their clock input. They usually have 4 bits, delivering at the outputs the corresponding

### Digital Logic Design. Basics Combinational Circuits Sequential Circuits. Pu-Jen Cheng

Digital Logic Design Basics Combinational Circuits Sequential Circuits Pu-Jen Cheng Adapted from the slides prepared by S. Dandamudi for the book, Fundamentals of Computer Organization and Design. Introduction

### EE 42/100 Lecture 24: Latches and Flip Flops. Rev B 4/21/2010 (2:04 PM) Prof. Ali M. Niknejad

A. M. Niknejad University of California, Berkeley EE 100 / 42 Lecture 24 p. 1/20 EE 42/100 Lecture 24: Latches and Flip Flops ELECTRONICS Rev B 4/21/2010 (2:04 PM) Prof. Ali M. Niknejad University of California,

### DEPARTMENT OF INFORMATION TECHNLOGY

DRONACHARYA GROUP OF INSTITUTIONS, GREATER NOIDA Affiliated to Mahamaya Technical University, Noida Approved by AICTE DEPARTMENT OF INFORMATION TECHNLOGY Lab Manual for Computer Organization Lab ECS-453

### Having read this workbook you should be able to: recognise the arrangement of NAND gates used to form an S-R flip-flop.

Objectives Having read this workbook you should be able to: recognise the arrangement of NAND gates used to form an S-R flip-flop. describe how such a flip-flop can be SET and RESET. describe the disadvantage

### CHAPTER 3 Boolean Algebra and Digital Logic

CHAPTER 3 Boolean Algebra and Digital Logic 3.1 Introduction 121 3.2 Boolean Algebra 122 3.2.1 Boolean Expressions 123 3.2.2 Boolean Identities 124 3.2.3 Simplification of Boolean Expressions 126 3.2.4

Experiment No. 1. THE DIGI DESIGNER Experiment 1-1. Socket Connections on the Digi Designer Experiment No. 2. LOGIC LEVELS AND THE 7400 QUADRUPLE 2-INPUT POSITIVE NAND GATE Experiment 2-1. Truth Table

### CHAPTER 11: Flip Flops

CHAPTER 11: Flip Flops In this chapter, you will be building the part of the circuit that controls the command sequencing. The required circuit must operate the counter and the memory chip. When the teach

### BINARY CODED DECIMAL: B.C.D.

BINARY CODED DECIMAL: B.C.D. ANOTHER METHOD TO REPRESENT DECIMAL NUMBERS USEFUL BECAUSE MANY DIGITAL DEVICES PROCESS + DISPLAY NUMBERS IN TENS IN BCD EACH NUMBER IS DEFINED BY A BINARY CODE OF 4 BITS.

### Chapter 2 Logic Gates and Introduction to Computer Architecture

Chapter 2 Logic Gates and Introduction to Computer Architecture 2.1 Introduction The basic components of an Integrated Circuit (IC) is logic gates which made of transistors, in digital system there are

### WEEK 8.1 Registers and Counters. ECE124 Digital Circuits and Systems Page 1

WEEK 8.1 egisters and Counters ECE124 igital Circuits and Systems Page 1 Additional schematic FF symbols Active low set and reset signals. S Active high set and reset signals. S ECE124 igital Circuits

### COMBINATIONAL and SEQUENTIAL LOGIC CIRCUITS Hardware implementation and software design

PH-315 COMINATIONAL and SEUENTIAL LOGIC CIRCUITS Hardware implementation and software design A La Rosa I PURPOSE: To familiarize with combinational and sequential logic circuits Combinational circuits

### List of Experiment. 8. To study and verify the BCD to Seven Segments DECODER.(IC-7447).

G. H. RAISONI COLLEGE OF ENGINEERING, NAGPUR Department of Electronics & Communication Engineering Branch:-4 th Semester[Electronics] Subject: - Digital Circuits List of Experiment Sr. Name Of Experiment

### Online Development of Digital Logic Design Course

Online Development of Digital Logic Design Course M. Mohandes, M. Dawoud, S. Al Amoudi, A. Abul Hussain Electrical Engineering Department & Deanship of Academic Development King Fahd University of Petroleum

### Chapter 5. Sequential Logic

Chapter 5 Sequential Logic Sequential Circuits (/2) Combinational circuits: a. contain no memory elements b. the outputs depends on the current inputs Sequential circuits: a feedback path outputs depends

### Asynchronous counters, except for the first block, work independently from a system clock.

Counters Some digital circuits are designed for the purpose of counting and this is when counters become useful. Counters are made with flip-flops, they can be asynchronous or synchronous and they can

### EE360: Digital Design I Course Syllabus

: Course Syllabus Dr. Mohammad H. Awedh Fall 2008 Course Description This course introduces students to the basic concepts of digital systems, including analysis and design. Both combinational and sequential

### Sequential Logic. (Materials taken from: Principles of Computer Hardware by Alan Clements )

Sequential Logic (Materials taken from: Principles of Computer Hardware by Alan Clements ) Sequential vs. Combinational Circuits Combinatorial circuits: their outputs are computed entirely from their present

### Lab 11 Digital Dice. Figure 11.0. Digital Dice Circuit on NI ELVIS II Workstation

Lab 11 Digital Dice Figure 11.0. Digital Dice Circuit on NI ELVIS II Workstation From the beginning of time, dice have been used for games of chance. Cubic dice similar to modern dice date back to before

### 2011, The McGraw-Hill Companies, Inc. Chapter 3

Chapter 3 3.1 Decimal System The radix or base of a number system determines the total number of different symbols or digits used by that system. The decimal system has a base of 10 with the digits 0 through

### EC313 - VHDL State Machine Example

EC313 - VHDL State Machine Example One of the best ways to learn how to code is seeing a working example. Below is an example of a Roulette Table Wheel. Essentially Roulette is a game that selects a random

### Digital Logic Design Sequential circuits

Digital Logic Design Sequential circuits Dr. Eng. Ahmed H. Madian E-mail: ahmed.madian@guc.edu.eg Dr. Eng. Rania.Swief E-mail: rania.swief@guc.edu.eg Dr. Eng. Ahmed H. Madian Registers An n-bit register

### 1. True or False? A voltage level in the range 0 to 2 volts is interpreted as a binary 1.

File: chap04, Chapter 04 1. True or False? A voltage level in the range 0 to 2 volts is interpreted as a binary 1. 2. True or False? A gate is a device that accepts a single input signal and produces one

### 1.1 The 7493 consists of 4 flip-flops with J-K inputs unconnected. In a TTL chip, unconnected inputs

CALIFORNIA STATE UNIVERSITY LOS ANGELES Department of Electrical and Computer Engineering EE-246 Digital Logic Lab EXPERIMENT 1 COUNTERS AND WAVEFORMS Text: Mano, Digital Design, 3rd & 4th Editions, Sec.

### To design digital counter circuits using JK-Flip-Flop. To implement counter using 74LS193 IC.

8.1 Objectives To design digital counter circuits using JK-Flip-Flop. To implement counter using 74LS193 IC. 8.2 Introduction Circuits for counting events are frequently used in computers and other digital

### PLL frequency synthesizer

ANALOG & TELECOMMUNICATION ELECTRONICS LABORATORY EXERCISE 4 Lab 4: PLL frequency synthesizer 1.1 Goal The goals of this lab exercise are: - Verify the behavior of a and of a complete PLL - Find capture

### A Digital Timer Implementation using 7 Segment Displays

A Digital Timer Implementation using 7 Segment Displays Group Members: Tiffany Sham u2548168 Michael Couchman u4111670 Simon Oseineks u2566139 Caitlyn Young u4233209 Subject: ENGN3227 - Analogue Electronics

### CHAPTER IX REGISTER BLOCKS COUNTERS, SHIFT, AND ROTATE REGISTERS

CHAPTER IX-1 CHAPTER IX CHAPTER IX COUNTERS, SHIFT, AN ROTATE REGISTERS REA PAGES 249-275 FROM MANO AN KIME CHAPTER IX-2 INTROUCTION -INTROUCTION Like combinational building blocks, we can also develop

### DIGITAL TECHNICS II. Dr. Bálint Pődör. Óbuda University, Microelectronics and Technology Institute. 2nd (Spring) term 2012/2013

DIGITAL TECHNICS II Dr. Bálint Pődör Óbuda University, Microelectronics and Technology Institute 4. LECTURE: COUNTERS AND RELATED 2nd (Spring) term 2012/2013 1 4. LECTURE: COUNTERS AND RELATED 1. Counters,

### plc numbers - 13.1 Encoded values; BCD and ASCII Error detection; parity, gray code and checksums

plc numbers - 3. Topics: Number bases; binary, octal, decimal, hexadecimal Binary calculations; s compliments, addition, subtraction and Boolean operations Encoded values; BCD and ASCII Error detection;

### Digital circuits make up all computers and computer systems. The operation of digital circuits is based on

Digital Logic Circuits Digital circuits make up all computers and computer systems. The operation of digital circuits is based on Boolean algebra, the mathematics of binary numbers. Boolean algebra is

### SECTION C [short essay] [Not to exceed 120 words, Answer any SIX questions. Each question carries FOUR marks] 6 x 4=24 marks

UNIVERSITY OF KERALA First Degree Programme in Computer Applications Model Question Paper Semester I Course Code- CP 1121 Introduction to Computer Science TIME : 3 hrs Maximum Mark: 80 SECTION A [Very

### Lab 1: Study of Gates & Flip-flops

1.1 Aim Lab 1: Study of Gates & Flip-flops To familiarize with circuit implementations using ICs and test the behavior of different logic gates and Flip-flops. 1.2 Hardware Requirement a. Equipments -

### RAM & ROM Based Digital Design. ECE 152A Winter 2012

RAM & ROM Based Digital Design ECE 152A Winter 212 Reading Assignment Brown and Vranesic 1 Digital System Design 1.1 Building Block Circuits 1.1.3 Static Random Access Memory (SRAM) 1.1.4 SRAM Blocks in

### Flip-Flops and Sequential Circuit Design. ECE 152A Winter 2012

Flip-Flops and Sequential Circuit Design ECE 52 Winter 22 Reading ssignment Brown and Vranesic 7 Flip-Flops, Registers, Counters and a Simple Processor 7.5 T Flip-Flop 7.5. Configurable Flip-Flops 7.6

### Flip-Flops and Sequential Circuit Design

Flip-Flops and Sequential Circuit Design ECE 52 Winter 22 Reading ssignment Brown and Vranesic 7 Flip-Flops, Registers, Counters and a Simple Processor 7.5 T Flip-Flop 7.5. Configurable Flip-Flops 7.6

### Digital Electronics Part I Combinational and Sequential Logic. Dr. I. J. Wassell

Digital Electronics Part I Combinational and Sequential Logic Dr. I. J. Wassell Introduction Aims To familiarise students with Combinational logic circuits Sequential logic circuits How digital logic gates

### Theory of Logic Circuits. Laboratory manual. Exercise 3

Zakład Mikroinformatyki i Teorii Automatów yfrowych Theory of Logic ircuits Laboratory manual Exercise 3 Bistable devices 2008 Krzysztof yran, Piotr zekalski (edt.) 1. lassification of bistable devices

### COMBINATIONAL CIRCUITS

COMBINATIONAL CIRCUITS http://www.tutorialspoint.com/computer_logical_organization/combinational_circuits.htm Copyright tutorialspoint.com Combinational circuit is a circuit in which we combine the different

### ELEC 2210 - EXPERIMENT 1 Basic Digital Logic Circuits

Objectives ELEC - EXPERIMENT Basic Digital Logic Circuits The experiments in this laboratory exercise will provide an introduction to digital electronic circuits. You will learn how to use the IDL-00 Bit

### Operating Manual Ver.1.1

4 Bit Binary Ripple Counter (Up-Down Counter) Operating Manual Ver.1.1 An ISO 9001 : 2000 company 94-101, Electronic Complex Pardesipura, Indore- 452010, India Tel : 91-731- 2570301/02, 4211100 Fax: 91-731-

### Lab 1: Full Adder 0.0

Lab 1: Full Adder 0.0 Introduction In this lab you will design a simple digital circuit called a full adder. You will then use logic gates to draw a schematic for the circuit. Finally, you will verify

### 3.Basic Gate Combinations

3.Basic Gate Combinations 3.1 TTL NAND Gate In logic circuits transistors play the role of switches. For those in the TTL gate the conducting state (on) occurs when the baseemmiter signal is high, and

### COURSE SYLLABUS. PRE-REQUISITES: Take CETT-1303(41052); Minimum grade C, CR.

COURSE SYLLABUS COURSE NUMBER AND TITLE: CETT 1325- Digital Fundamentals COURSE (CATALOG) DESCRIPTION An entry level course in digital electronics covering number systems, binary mathematics, digital codes,

### Design: a mod-8 Counter

Design: a mod-8 Counter A mod-8 counter stores a integer value, and increments that value (say) on each clock tick, and wraps around to 0 if the previous stored value was 7. So, the stored value follows

### Binary Numbers. Binary Octal Hexadecimal

Binary Numbers Binary Octal Hexadecimal Binary Numbers COUNTING SYSTEMS UNLIMITED... Since you have been using the 10 different digits 0, 1, 2, 3, 4, 5, 6, 7, 8, and 9 all your life, you may wonder how

### Philadelphia University Faculty of Information Technology Department of Computer Science ----- Semester, 2007/2008.

Philadelphia University Faculty of Information Technology Department of Computer Science ----- Semester, 2007/2008 Course Syllabus Course Title: Computer Logic Design Course Level: 1 Lecture Time: Course

### Lab 1: Introduction to Xilinx ISE Tutorial

Lab 1: Introduction to Xilinx ISE Tutorial This tutorial will introduce the reader to the Xilinx ISE software. Stepby-step instructions will be given to guide the reader through generating a project, creating

### LAB #4 Sequential Logic, Latches, Flip-Flops, Shift Registers, and Counters

LAB #4 Sequential Logic, Latches, Flip-Flops, Shift Registers, and Counters LAB OBJECTIVES 1. Introduction to latches and the D type flip-flop 2. Use of actual flip-flops to help you understand sequential

### (Refer Slide Time: 00:01:16 min)

Digital Computer Organization Prof. P. K. Biswas Department of Electronic & Electrical Communication Engineering Indian Institute of Technology, Kharagpur Lecture No. # 04 CPU Design: Tirning & Control

### Systems I: Computer Organization and Architecture

Systems I: omputer Organization and Architecture Lecture 8: Registers and ounters Registers A register is a group of flip-flops. Each flip-flop stores one bit of data; n flip-flops are required to store

### PROGRAMMABLE LOGIC CONTROLLERS Unit code: A/601/1625 QCF level: 4 Credit value: 15 OUTCOME 3 PART 1

UNIT 22: PROGRAMMABLE LOGIC CONTROLLERS Unit code: A/601/1625 QCF level: 4 Credit value: 15 OUTCOME 3 PART 1 This work covers part of outcome 3 of the Edexcel standard module: Outcome 3 is the most demanding

### INTRODUCTION TO DIGITAL SYSTEMS. IMPLEMENTATION: MODULES (ICs) AND NETWORKS IMPLEMENTATION OF ALGORITHMS IN HARDWARE

INTRODUCTION TO DIGITAL SYSTEMS 1 DESCRIPTION AND DESIGN OF DIGITAL SYSTEMS FORMAL BASIS: SWITCHING ALGEBRA IMPLEMENTATION: MODULES (ICs) AND NETWORKS IMPLEMENTATION OF ALGORITHMS IN HARDWARE COURSE EMPHASIS:

### Modeling Sequential Elements with Verilog. Prof. Chien-Nan Liu TEL: 03-4227151 ext:34534 Email: jimmy@ee.ncu.edu.tw. Sequential Circuit

Modeling Sequential Elements with Verilog Prof. Chien-Nan Liu TEL: 03-4227151 ext:34534 Email: jimmy@ee.ncu.edu.tw 4-1 Sequential Circuit Outputs are functions of inputs and present states of storage elements

### Flip-Flops, Registers, Counters, and a Simple Processor

June 8, 22 5:56 vra235_ch7 Sheet number Page number 349 black chapter 7 Flip-Flops, Registers, Counters, and a Simple Processor 7. Ng f3, h7 h6 349 June 8, 22 5:56 vra235_ch7 Sheet number 2 Page number

### AUTOMATIC NIGHT LAMP WITH MORNING ALARM USING MICROPROCESSOR

AUTOMATIC NIGHT LAMP WITH MORNING ALARM USING MICROPROCESSOR INTRODUCTION This Project "Automatic Night Lamp with Morning Alarm" was developed using Microprocessor. It is the Heart of the system. The sensors

### Design and Development of Virtual Instrument (VI) Modules for an Introductory Digital Logic Course

Session ENG 206-6 Design and Development of Virtual Instrument (VI) Modules for an Introductory Digital Logic Course Nikunja Swain, Ph.D., PE South Carolina State University swain@scsu.edu Raghu Korrapati,

### RUTGERS UNIVERSITY Department of Electrical and Computer Engineering 14:332:233 DIGITAL LOGIC DESIGN LABORATORY

RUTGERS UNIVERSITY Department of Electrical and Computer Engineering 14:332:233 DIGITAL LOGIC DESIGN LABORATORY Fall 2012 Contents 1 LABORATORY No 1 3 11 Equipment 3 12 Protoboard 4 13 The Input-Control/Output-Display

### So far we have investigated combinational logic for which the output of the logic devices/circuits depends only on the present state of the inputs.

equential Logic o far we have investigated combinational logic for which the output of the logic devices/circuits depends only on the present state of the inputs. In sequential logic the output of the

### United States Naval Academy Electrical and Computer Engineering Department. EC262 Exam 1

United States Naval Academy Electrical and Computer Engineering Department EC262 Exam 29 September 2. Do a page check now. You should have pages (cover & questions). 2. Read all problems in their entirety.

### Lecture 12: More on Registers, Multiplexers, Decoders, Comparators and Wot- Nots

Lecture 12: More on Registers, Multiplexers, Decoders, Comparators and Wot- Nots Registers As you probably know (if you don t then you should consider changing your course), data processing is usually

### The string of digits 101101 in the binary number system represents the quantity

Data Representation Section 3.1 Data Types Registers contain either data or control information Control information is a bit or group of bits used to specify the sequence of command signals needed for

### IE1204 Digital Design F12: Asynchronous Sequential Circuits (Part 1)

IE1204 Digital Design F12: Asynchronous Sequential Circuits (Part 1) Elena Dubrova KTH / ICT / ES dubrova@kth.se BV pp. 584-640 This lecture IE1204 Digital Design, HT14 2 Asynchronous Sequential Machines

### CS311 Lecture: Sequential Circuits

CS311 Lecture: Sequential Circuits Last revised 8/15/2007 Objectives: 1. To introduce asynchronous and synchronous flip-flops (latches and pulsetriggered, plus asynchronous preset/clear) 2. To introduce

### RETRIEVING DATA FROM THE DDC112

RETRIEVING DATA FROM THE by Jim Todsen This application bulletin explains how to retrieve data from the. It elaborates on the discussion given in the data sheet and provides additional information to allow

### Boole-WebLab-Deusto: Integration of a Remote Lab in a Tool for Digital Circuits Design

Boole-WebLab-Deusto: Integration of a Remote Lab in a Tool for Digital Circuits Design Javier García-Zubía (IEEE Senior Member), Ignacio Angulo, Luis Rodríguez-Gil Faculty of Engineering University of

### Understanding Logic Design

Understanding Logic Design ppendix of your Textbook does not have the needed background information. This document supplements it. When you write add DD R0, R1, R2, you imagine something like this: R1

### Active Learning in the Introduction to Digital Logic Design Laboratory Course

Active Learning in the Introduction to Digital Logic Design Laboratory Course Jing Pang Department of Electrical and Electronic Engineering, Computer Engineering Program, California State University, Sacramento,

### Gates, Circuits, and Boolean Algebra

Gates, Circuits, and Boolean Algebra Computers and Electricity A gate is a device that performs a basic operation on electrical signals Gates are combined into circuits to perform more complicated tasks

### AC 2007-2485: PRACTICAL DESIGN PROJECTS UTILIZING COMPLEX PROGRAMMABLE LOGIC DEVICES (CPLD)

AC 2007-2485: PRACTICAL DESIGN PROJECTS UTILIZING COMPLEX PROGRAMMABLE LOGIC DEVICES (CPLD) Samuel Lakeou, University of the District of Columbia Samuel Lakeou received a BSEE (1974) and a MSEE (1976)

### Digital Systems Laboratory

Eskişehir Osmangazi University Digital Systems Laboratory Rev 3.01 February 2011 LIST OF EXPERIMENTS 1. BINARY AND DECIMAL NUMBERS 2. DIGITAL LOGIC GATES 3. INTRODUCTION TO LOGICWORKS 4. BOOLEAN ALGEBRA

### Fundamentals of Digital Electronics

Fundamentals of Digital Electronics by Professor Barry Paton Dalhousie University March 998 Edition Part Number 32948A- Fundamentals of Digital Electronics Copyright Copyright 998 by National Instruments

### Contents COUNTER. Unit III- Counters

COUNTER Contents COUNTER...1 Frequency Division...2 Divide-by-2 Counter... 3 Toggle Flip-Flop...3 Frequency Division using Toggle Flip-flops...5 Truth Table for a 3-bit Asynchronous Up Counter...6 Modulo

### Digital Systems. Syllabus 8/18/2010 1

Digital Systems Syllabus 1 Course Description: This course covers the design and implementation of digital systems. Topics include: combinational and sequential digital circuits, minimization methods,

### University of St. Thomas ENGR 230 ---- Digital Design 4 Credit Course Monday, Wednesday, Friday from 1:35 p.m. to 2:40 p.m. Lecture: Room OWS LL54

Fall 2005 Instructor Texts University of St. Thomas ENGR 230 ---- Digital Design 4 Credit Course Monday, Wednesday, Friday from 1:35 p.m. to 2:40 p.m. Lecture: Room OWS LL54 Lab: Section 1: OSS LL14 Tuesday

### CpE358/CS381. Switching Theory and Logical Design. Class 10

CpE358/CS38 Switching Theory and Logical Design Class CpE358/CS38 Summer- 24 Copyright 24-373 Today Fundamental concepts of digital systems (Mano Chapter ) Binary codes, number systems, and arithmetic