Sei sulla pagina 1di 11

Kallas 1

Gavin Kallas

Professor Cassel

ENG 1201

4 August 2019

Digital Design-A World of One’s and Zero’s

From creating LEGO masterpieces to designing programs embedded into a computer, one

may say I have always had a knack for creating something from nothing. As a youngster, I was

very curious about how things worked, and this spark of interest ignited an intense curiosity on

the topic of digital design. This subject is a crucial area in the world of electrical engineering and

my dad, a senior electrical engineer, has worked with FPGAs previously throughout his career.

Now, I am an electrical engineering intern for a defense contracting company which is why the

topic of digital design is important to me. Digital design, while being implemented in an FPGA,

essentially allows the developer to create a virtual circuit within a board using a programming

language. The basic knowledge of digital design will allow one to attain a finer understanding of

how modern-day technology works with regards to 1’s and 0’s.

If one were to take a step back from this paper and look around, one may find a profuse

amount of technology encompassing them. From the phone used to communicate, to the watch

used to tell time, technology is everywhere. With such an overwhelming surplus of tech, people

begin to question whether it is possible to fix devices without taking them to the shop. Well, in

order to diagnose most issues with their devices, one will need to know how they work. Despite

the different functions of technology, there is one major commonality-these devices are made

using digital design. Digital design is a concept that uses the works of digital logic-the

manipulation of binary numbers (1’s and 0’s)-to create a digital circuit. In the book, Digital

Design Principles and Practices, John F. Wakerly describes the fundamental information in the
Kallas 2

world of technology. Wakerly writes, “Digital systems are built from circuits that process binary

digits-0’s and 1’s…” (Wakerly, 1). In order to understand how the manipulation of binary data

can create a digital circuit, one must first understand what a binary number is.

Throughout childhood, one may recall they were taught the (decimal) number system.

The decimal number system goes from 0 to 9 and then stops. Once one gets past 9, one puts a 0

in the first digit and carries the 1 to the next digit, and 10 (or ten) is the result. If one was to do

the math, there is only a possible combination of 10 different numbers within one digit- also

known as a radix of 10. Therefore, another way to write ten is with a subscript of the radix to

show that the value is represented by the decimal number system (i.e. 1010). For example, 1110 is

what most would call eleven. This is important to understand as the binary number system only

has 2 possible values for each digit- 1 or 0. Wakerly says, “digital circuits have signals that are

normally in one of only two conditions-low or high, discharged or charged, off or on. The signals

in these circuits are interpreted to represent binary digits (or bits) that have only two values, 0

and 1.” (2). Therefore, a binary number will be represented with a radix of 2. This means once a

binary value exceeds 1 within a digit, a 1 will be carried to the next digit and the old digit will

turn to 0. This would be seen as 12 + 12 = 102. Like fractions and decimals or the metric system

and the imperial system, one can convert from a binary value to a decimal number. As mentioned

previously, the radix for a binary value is 2. Knowing this is astronomically important when

preparing to convert a number. The formula to convert a binary value to a decimal value is
𝑝−1
𝐷 = Σ𝑖=−𝑛 𝑑𝑖 × 𝑟 𝑖 where p is the number of digits to the left of the radix point (decimal

point), n to the right, and r is the radix of the number d. Therefore the binary number 0101 can be

converted as follows: 01012 = (0 × 23 ) + (1 × 22 ) + (0 × 21 ) + (1 × 20 ) = 0 + 4 + 0 +

1 = 510 .
Kallas 3

Understanding how to convert binary data to decimal data is only one small piece of a

much larger puzzle. However, it can be extremely useful for simplifying and checking binary

computations. Everyone is familiar with decimal numbers; therefore, changing their answers

from a binary number to a decimal value can be simpler than trying to first determine which

binary number they have before checking their work. This comes into play when learning how to

add and subtract binary data. As mentioned earlier, once a binary value exceeds 1 within a digit,

a 1 will be carried to the next digit and the old digit will return to 0. Wakerly says, “To add two

binary numbers X and Y, we add together the least significant bits…We continue processing bits

from right to left, including the carry out of each column in the next column’s sum” (6). After

that, binary math is just like basic math, 1 + 0 = 1 and 0 + 0 = 0. For example, 0101 + 0101 =

1010. One may notice in that example, the first digit of the two numbers being added were 1.

Therefore, the sum will be 0 in the first digit and the 1 will be carried and added to the second

digit of the sum.

Binary subtraction works a lot like addition except a digit can be borrowed from the digit

to the left instead of being carried from the digit to the right. One can think of this when they are

doing normal subtraction, if the value of the minuend is lesser than the subtrahend, a 1 is carried

from the decimal place to the left. By now, one may be wondering why they would ever use

addition-or in this case subtraction-within a circuit. Wakerly says, “A very common use of

subtraction in computers is to compare two numbers. For example, if the operation X – Y

produces a borrow out of the most significant bit position, then X is less than Y; otherwise X is

greater than or equal to Y” (9). Remember, computers see everything in 1’s and 0’s so each bit

could represent a piece of information (or a command) that one may use on a computer like a
Kallas 4

mouse click or pressing down on a key on a keyboard. Therefore, these binary computations can

allow the computer to determine what to do with the information it received.

So far, the data represented has only been a few digits long. However, what happens

when one may have to look at a set data that is 16 digits long? The hexadecimal number system

can ease these situations as there are a total of 16 different possible values per hexadecimal digit.

This means a hexadecimal number will have a radix of 16 and can be represented with a 16 as its

subscript. The article “Numeration”, written in the Columbia Electronic Encyclopedia (CEE),

says, “The hexadecimal system, or base 16, uses the digits 0 through 9 and the letters A through

F (or a through f) to represent 16 different digits” (“Numeration”). In other words, counting up

from zero looks like: 0 (+1) = 1(+1) = 2 (+1) = 3(+1) = 4(+1) = 5(+1) = 6(+1) =

7(+1) = 8(+1) = 9(+1) = 𝐴(+1) = 𝐵(+1) = 𝐶(+1) = 𝐷(+1) = 𝐸(+1) = 𝐹. In other

words, one may also think of A-F as the decimal values 10-15. This comes in handy as one

hexadecimal value can represent four bits- also known as a nibble-or 2 hexadecimal numbers can

represent eight bits of data-also known as a byte. Therefore, when dealing with longer binary

numbers, it is known to be easier to convert them to hexadecimal to make computations easier.

Figure 1. A comparison between the decimal number system, hexadecimal number system, and binary number system (“I Will
Design Digital Logic Gates, Truth Tables, K Maps”).
Kallas 5

When dealing with data, it is great to know how to convert back and forth between

number systems but what happens when the decimal number is a negative? With decimal

numbers, a sign is used to determine whether a value is a positive or negative number; this is not

the case for binary numbers. Binary numbers use a system called the 2’s-Complement which

allows a person to convert from a positive value to a negative value using just two steps. In the

first step, the person must flip every binary digit value. This means if a bit is a 1, then convert it

to a 0 and vice versa. Next, the person must add 1 to the flipped number. For example, turning 1

(00012) to -1 (11112) in binary can be seen as 0001 → 1110 + 1 = 1111.

The binary signals received and transmitted do not alone make up a digital circuit, but the

logic functions that manipulate them do. Joseph Dewey, a PhD holder, wrote an article in the

Salem Press Encyclopedia about digital circuits. Dewey explains, “Computer circuits, the

workhorses that actualize ideas into real-time computer functions, operate according to specific

binary instructions—mapped sequences of logical steps, also called logic gates…” (Dewey).

There are three main logic gates within the realm of digital logic-AND, OR, and NOT. A NOT

gate allows the designer the opportunity to flip the inputted data value. The gate takes an

electrical signal-on or off-and inverts it. The function-or gate-gets its name since the signal going

in is not the signal coming out. The NOT gate can also be referred to as an inverter. The AND

gate works a lot like a “&&” statement for programmers using the “C” programming language.

Richard Renneboog held a master’s degree in science when he wrote the article, “Digital Logic”,

for the Salem Press Encyclopedia of Science in 2018. When discussing logic gates, Renneboog

mentioned, “An AND gate transforms two or more input signals to produce a corresponding

output signal only when all input signals are present” (Renneboog). In other words, the AND

gate accepts multiple sets of data and if all of them are 1, then the output will be a 1. Otherwise,
Kallas 6

the output will be a zero. Another way to think of this is like multiplication: 0 × 1 = 0, 0 × 0 =

0, and 1 × 1 = 1. The answer will only be one if both signals, comprised of binary numbers, are

equal to 1. The OR logic gate is also similar to an “||” statement in “C” programming language.

Renneboog says “An OR gate transforms two or more input signals to produce an output signal if

any of the input signals are present” (Renneboog). This means the output of an OR gate will be 1

so long as only one of the inputs are 1. Despite the AND, NOT, and OR logic gates being the

most popular, there are others. Renneboog mentions, “Combinations of these three basic gate

structures in integrated circuits are used to construct NAND (or not-AND) and NOR (or not-OR)

gates, accumulators, flip-flops, and numerous other digital devices that make up the functioning

structures of integrated circuits and computer chips” (Renneboog). As previously stated, the

NAND gate is similar to an AND gate, except a NOT gate is added to it. This means if the inputs

of the NAND gate are 1 (high), then the outputs will be 0 (low).

Figure 2. A display of each type of logic gate. The truth tables below show the inputs-A and B-and the corresponding output-X
(“Ch 3. Logic gates and logic circuits”).

Similar to a NAND gate, a NOR gate is the combination of a NOT and an OR gate. John

Sieffertt explains in his book, Digital Logic for Computing, “Whereas OR will return 1 when at

least one input is 1, NOR returns 0 when at least one input is 1” (Seiffertt, 73). In other words,

the output of the NOR gate is 1 only when all inputs are 0. An Exclusive-OR -also known as
Kallas 7

XOR- is another gate derived from the OR gate. Seiffertt later explains the XOR gate, “…is the

same as OR except for the case when both inputs are 1, then it returns a 0” (Seiffertt, 73). This

means an XOR gate will only return a value of high so long as only one inputted value is high.

The last logic gate in digital design is called an Exclusive-NOR gate-also known as an XNOR

gate. In the book, Digital Logic Design, the author-Brian Holdsworth-says, “The XNOR

operation gives an output of logic 1 whenever the two input binary digits are equal…”

(Holdsworth, 11). However, if the signals inputted are different, the XNOR gate will return low.

By now, one may be wondering why they would ever use these extra logic gates. For the past

fifty years, different digital design programs have come out and each individual program only

allows the designer to use certain logic gates. Holdsworth mentions, “…in practice, logic circuits

are often actually implemented using NAND and NOR gates” (Holdsworth11). This is because

the NAND and NOR gates are universal and a combination of them can be used to simulate gates

that the designers are missing because their software doesn’t support them. Therefore, it is up to

the designer to find a way to use a combination of the two logic gates to create the missing gates

they do not have. Also, each individual logic gate can be used for certain tasks. For example, an

XNOR gate can be used to determine if two sets of data are the same. If the data are, it will

output a 1 or true; but if they are not the same, it will output a 0.

There are two divisions within digital logic-combinational logic and sequential logic. So

far, everything discussed in this paper has been about combinational logic. However, it is funny

because no computer really uses combinational logic any more. Instead, modern day computers

use sequential logic, an upgraded version of combinational logic. So, what is the difference

between combinational logic and sequential logic? Sequential logic allows the designer to add in

one more element to a digital circuit. “Such circuits have many applications in the digital field
Kallas 8

and consist of both combinational and memory elements.” (Holdsworth, 15). This means

sequential circuitry is what adds memory into the world of digital design. Data transferring

within combinational logic can be very sketchy as the gates wait for each individual input. What

happens if one input comes first and the other input takes a minute to get to the gate? This

occurrence is known as a glitch which can occur frequently when a circuit involves more than

one logic gate. However, a sequential circuit does not have to worry about this issue as it only

looks at the output of the logic gates during specific times. Any change in data in between the

designated times is not used. The time it waits to test the data inputs and outputs throughout the

circuit is called the “clock”. The clock ticks the moment it samples data. These “ticks” are

always synchronous over the circuit and are known to occur on the rising edge of the clock. In

other words, if one were to imagine the clock as a sinusoidal wave; the tick occurs upon the

rising edge of the wave. Unlike most technology in the world of electrical engineering, there are

actually more than one tick used in each clock period for computers. This is because the

concerning feature with computers these days are their speeds. In fact, if one were to listen to

someone discuss their computer speeds, they are actually explaining how many ticks occur

within one clock period. Another feature to the clock element is its delay time. A clock element

has both, a maximum delay time and a minimum delay time. If the circuit is slower than

expected-or the maximum delay time fails-then the clock speed can be diminished to compensate

for the lagging circuit. Maximum delay time usually increases as the temperature of the silicon

material surrounding the circuit gets hotter, which can result in computers becoming unreliable

as they warm up or as the clock speed rises. The sequential element, clock speed, is a key factor

in everyday computers, phones, digital watches, etc. and can determine whether or not a circuit

may overheat.
Kallas 9

Just like how combinational logic has its basic circuits like an adder-adds two data inputs

together-or a subtractor, there are also basic circuits that are the pillars of everyday sequential

logic. One example of these basic building blocks that uses feedback from the output as an input

is a flip-flop. A common flip-flop is the D-type. D flip-flops’ input is latched to the output upon

the rising side of a clock edge. It has become customary to denote the clock input-within the

circuit-by the triangular engraving of the component on the lower left corner. Flip flops usually

provide the normal output and the complemented output. Another type of flip-flop is called the

T-type flip-flop. This flip-flop works like a toggle. If the input is a 1, the output will change but;

if the input is a 0, the output stays the same. This process only occurs on each of the clock’s

ticks.

Setup times, hold times, and propagation delays are another commonality within

sequential circuitry. The setup time frame is the least amount of time a signal has to reach the

input before the rising clock edge occurs. While the hold time frame is the minimum amount of

time a signal has to hold the same value after a rising clock edge. Understanding the setup and

hold time frames along with propagation delay is important because if the circuit exceeds the

time frames, the data stability of the second component will not be ensured which may cause the

circuit to react unexpectedly.

Chris Leigeiber is an Electrical Engineer who has worked in the defense contracting area

for a while. Despite many years of doing FPGA work, Chris holds a degree in software

engineering and has even been a nurse in Texas. For a large portion of his career, Chris has

worked on FPGAs-or field programmable gate arrays-using what he has learned from classes on

digital design. When asked to define digital design, Chris explains “It is all around us-we cannot

escape it. We depend on it every day; from awakening us from deep slumber, to the Fitbits
Kallas 10

monitoring our vitals on the wrists, to the phones with which people communicate across the

world. Digital design uses basic logic gates to create circuits by manipulating the given values

into the result you want.” (Leigeiber). When asked how he uses digital design every day, Chris

responds with, “I use it when I am designing the functionality of a board. I work with FPGA’s

which is a board that I can program to do anything I want. These boards have all these little

components on them that can be controlled by a few key strokes. FPGAs are basically blank

canvases-you decide what the circuit will end up being! So, to answer the question, I use digital

design when I am writing code in VHDL. VHDL is a language used with VIVADO to design the

functionality of an FPGA. When finished designing the digital circuitry, the application,

VIVADO, will synthesize the circuit and decide the best possible combination of logic gates to

use when embedding the schematics onto the board. The next time the board is used, only the

peripherals on it-determined by the designer-will be utilized in the actual circuit” (Leigeiber).

The FPGA is not the actual circuit board, but a chip embedded on the board-also known as an

SOC or system on chip. The FPGA allows anyone to set an idea into fruition by creating a circuit

board with just a single book’s worth of knowledge.

In conclusion, digital design is all around us. This technology of 1’s and 0’s is

everywhere and all of it is built using the basic concepts of digital design. The basic knowledge

of digital design will allow anybody to attain a finer understanding of how modern-day

technology works with regards to 1’s and 0’s. Although basic in theory, it is simply complex.
Kallas 11

Works Cited

“3.2 – Logic Gates.” Ch 3. Logic Gates and Logic Circuits, 31 Aug. 2016,

michellescomputerscience.wordpress.com/2016/08/31/ch-3-logic-gates-and-logic-

circuits/.

Audrey. “Discover Ideas about Computer Coding.” Pinterest,

www.pinterest.com/pin/395472411026396188/.

Dewey, Joseph, PhD. “Logic Synthesis.” Salem Press Encyclopedia, 2019. EBSCOhost,

search.ebscohost.com/login.aspx?direct=true&db=ers&AN=90558379&site=eds-live.

Holdsworth, B., and R. C. Woods. Digital Logic Design. [Electronic Resource]. Newnes,

2002. EBSCOhost,

search.ebscohost.com/login.aspx?direct=true&db=cat01128a&AN=scc.b1944548&site=e

ds-live.

Leihgeiber, Chris. Personal interview. 21 June 2019.

“Numeration.” Columbia Electronic Encyclopedia, 6th Edition, May 2019, p. 1. EBSCOhost,

search.ebscohost.com/login.aspx?direct=true&db=mih&AN=134485340&site=eds-live.

Renneboog, Richard M. M.Sc. “Digital Logic.” Salem Press Encyclopedia of Science,

2018. EBSCOhost,

search.ebscohost.com/login.aspx?direct=true&db=ers&AN=89250419&site=eds-live.

Seiffertt, John. Digital Logic for Computing. Springer, 2017. EBSCOhost,

search.ebscohost.com/login.aspx?direct=true&db=cat01128a&AN=scc.b1791026&site=e

ds-live.

Wakerly, John F. Digital Design: Principles and Practices. Pearson Education, Inc., 2018.

Potrebbero piacerti anche