Skip to main content
Loading Explore guides…
Digital Circuits · Acedra
Home
Explore
Computer Science
Digital Circuits
Sign in to save
Chat
If YouTube asks you to sign in, open the video on YouTube.
Watch on YouTube
Reload player
Transcript
41 segments
Copy
Hide video
0:23
Until now we learned about analogous electronics. Analogous means that typical values for our parts can be chosen from infinitely many. Analogous devices create a series of problems with repeatability. Digital circuits are characterized by greater resistance to problems where the number of possible values is limited. Thanks to this it is easier to achieve better repeatability of digital systems than analogue ones.
0:54
Bits and words. The logic state of one element is called a bit. At this point our element can take only two states, high and low, because it has only one input and one output. However, devices often have more inputs and more outputs.
1:18
This means they can take much more states. And what should you do then? Any number of bits can be called a word and can be used to save information in a binary system. Each bit has a corresponding weight assigned to it. Here you can see four different combinations of output states that can be saved as binary words. On a daily basis use decimal system with ten digits from 0 to 9. Every number is built from these digits. For example, if you want to write information with number 103
1:58
use 3 digits but there are a thousand combinations because on each of these places can be one of ten digits. Digital circuits use only 0 and 1. At first it seems that you cannot write this information with only 2 digits, you can only construct 101 and 110. However, with 2 digits you have only 8 possibilities so there are too few digits to write this information. In order to convert this number into a binary word you need to understand how to interpret
2:37
binary numbers. The youngest bit is at the right and its value is 2 to the power of 0, the power increases by one with each position to the left so the value of the first bit is 1, the value of the second bit is 2 the value of the third bit is 4 value of the fourth bit is 8 and so on. To get a given number you need to multiply value of each bit by 0 or 1 and add values from each position. So in this example from the first bit we've
3:14
got 1 from the second 2, from the third, 4, from the fourth, 0, from the fifth, 0, from the sixth 32 and from the seventh 64 which gives us 103 8-bit must be 0 because 2 to the power of 7 gives you 128 which is more than 103. Let's do another example. Here we've got only 3 "1" on 4th, 5th and 8th bit. So here 2 to the power of 3 gives 8 plus 2 to the power of 4 gives 16 plus 2 to the power of 7 gives 128 which altogether give us 152.
4:14
In order to convert a decimal number into a binary number you need to divide your number by 2 and write down the reminder. So with our previous example 152 divided by 2 gives you 76 and your reminder is 0, 76 divided by 2 is 38 and the remainder is 0, 38 divided by 2 is 19 and your reminder is still 0, 19 divided by 2 gives you 9 and reminder equal to 1, 9 divided by 2 is 4 with reminder 1, 4 divided by 2 is 2 off reminder 0, 2 divided
5:01
by 2 is 1 with reminder 0, and 1 divided by 2 is 0 with reminder 1. In order to write down the binary number you need to go up so your binary number is 1 0 0 1 1 0 0 0.
5:32
Two state systems are described using boolean algebra, the most basic operations in these systems are logical product, logical sum and negation. Results of these operations may be easily presented in from of tables called truth tables. They consist of information on the status of the output depending on the logical states of inputs. Systems performing these operations are called logic gates and they're available in form of integrated circuits AND gate performs an operation called conjunction.
6:15
Which is a simple multiplication. Output is true only when all of the inputs are true OR gate performs an operation called alternative which is a simple sum. Output is true when at least one of the inputs is true. NOT gate performs an operation called negation and it changes values from true to false and vice versa. It is also worth mentioning that there are more advanced gates that utilize basic logical operations. You have negative OR, and
6:55
negative AND gates which are negations of OR and AND gates. Exclusive OR is a disjunctive alternative and exclusive negative OR is exclusive OR gate's negation.
7:12
There are also other more advanced logic circuits which are multiplexersand demultiplexers. Multiplexers have many inputs and one output while demultiplexers have only one input and many outputs. Both have address lines which are required to differentiate data input. You can send a batch of data on one line and multiplexer will select the input giving data a corresponding address while demultiplexer will transmit this data to a specific output
7:49
Previously mentioned logic circuits are combinational systems which means that their output state depends only on logic state of the inputs. However, there are also more complex logic systems in which output state depends not only on the logic states of the inputs but also on the internal state of the system. Such systems are called triggers and they can be built basing on logic gates. They are used to memorize current state and they often
8:19
have an additional input to synchronize changes with the clock signal.
8:27
We can do basic logic system on our own performing specify logic operations. However, when making more complexsystem using and producing many inputs it is certain that we'll use too many logic gates and it is worth we optimizing. The basic optimizing technique is called Karnaugh method. Later we'll learn how to create Karnaugh table but first of all we have to know how to write function equation from this table
8:57
In logic, if you want to present a value which is true we just write its symbol as if you want present value it is false we rewrite the negation so this means the true A and this means the false A So if you have two groups of "1s" here this group of "1s" depends only on A when it's false because doesn't matter whether B or C are true or false. Here we will have only "1s" so this group can be represented as A false and this group depends only on B and
9:36
C, doesn't matter whether A is 0 or 1 here we have also 1 and 1 so this group can be represented as no B and no C. We have to do logic device performing specified operation. In this device we have 3 inputs represented in a rows and columns. Rows and columns in Karnaugh method are represented with a Gray code that means that two subsequent numbers differ only in one position, each field of a Karnaugh board is filled with a number representing logical state on output with a given input values.
10:22
So let's suppose we have to make our logical device. Our logical device have three inputs each row shows the different combination of states on an input. 0 means negative and 1 means positive. The output value of our device is illogical state based on inputs of different combination of inputs. Now we can convert the value of inputs into normally numbers, so this means the zero combination. This is the first, the second the third, the fourth, the fifth, the sixth and the seventh
11:06
combination. Seventh mean the binary number of this is equal to seven. Now we have to draw the Karnaugh table with l8 fields, so eight different output states we have three inputs A, B and C put it in a rows and in a column with a Gray code. Now we put the valuein each field, so for example 0 0 0 means 0, and 0 1 0 means 2 the same as in the previous example when we have those inputs on the left side and output on the right side. Now we put the output values in all fields.
11:54
This mathematical equation shows the positive state of our inputs of our device in every combination of inputs, so for example negative A, B and negative C means that position. Negative A, B and C is that position, but we can also group those "1s" into bigger groups that only one, so for example this is a group of two and this is also a group of two. Now, after grouping all those "1s" we can write another mathematical equation representing our logical state and it is much shorter and easier than
12:42
the previous one. Negative A and B means those two "1s" and B and C are those two "1s". And this is quicker and easier to cope with logical devices using optimized functions. Now, from our equations we can build a logical system based on gates AND like this and OR which is here. Now let's practice more on other examples, let's suppose that our device logic device has only two inputs - A and B but the State on output when A and B are negative,
13:25
is not 0 and not 1, it means there isn't such a state in our device so we can assume that this 1 or 0, it doesn't matter. Now we can draw the Karnaugh table from our function, we see that it's only one positive state in this field so our function is negative A and B, but let's suppose that this unknown state is also positive so now we can group those two "1s" and our function will be only negative A. This is much simpler. All logic gates, it is
14:10
also visible that assuming the unknown state is equal to 1, is much easier because we have less number of logic gates. Now let's move to the more complex example, these are logical values of a more complex example. We have 4 inputs A, B, C, D and 1 output . Each combination represents one output value. There are 16 combination. So let's put decimal numbers next to binary ones, so it's 0 the first state, second, third and so on.
15:02
This is blind Karnaugh board for our logical device. For beginners it is easier to put all those numbers in that fields. Numbers are equal to the binary value of inputs, so this is zero, one, two and three, four, five, six, and seven, eight, nine, ten, and eleven, twelve, thirteen, fourteen, and fifteen. Now we have to group all those positive states of "1s" The bigger those group of "1s" are the easier is to build the logic device so this is the
15:50
one group, the second and the third. As you see, those two unknown states are treated as "1s" in our example. Our logic and function can be presented as this group so this is A, B plus this group small, so this is negative A, negative B and negative D plus this big group. So this is C. This is our logical device of that more complex example. As we see it is made with two gates "AND" and one gate "OR" according to that equation.
16:49
In this part we'll talk about one of the most important branches in electronics. Integrated digital circuits. So far we have discussed logic gates and we got to know simple layouts created from such gates. These were basic functional blocks, if you wanted to design a robot it would turn out that you need so many gates, multiplexers and triggers that it would make your machine large and inefficient.
17:19
As you remember, operational amplifiers perform arithmetic operations and comparators perform logic operations. Microprocessors are state machines that perform actions to retrieve orders from memory, decode them and execute them. Orders are elementary activities like operations on data or making decisions based on program's history. Data may be either values or addresses of information storage in memory. A microprocessor receives information about what to do and it downloads
17:56
from memory data on which it will work. After order execution you get the result. Processor commands are as simple as possible, adding or moving a bit can be done in a single approach However, mathematical calculations must be done step-by-step taking into consideration the sequence of actions. This is because such systems use only logic states and interpret arithmetic operations using binary operations.
18:29
Memory is a system which stores data. Usually, information can be saved, read or overwrote unless you deal with a type of memory that can only be written once. Memory is divided into two groups: volatile and non-volatile. Volatile memory, also called RAM or cache, erases all stored data when the power source is turned off. Non-volatile memory ,known as ROM or flash, stores data permanently.Another difference is that non-volatile memory is cheaper but also slower than volatile memory. For the
19:11
same price you can either have a fast Ram with low capacity or slow flash with high capacity. To sum up, storing data are requires non-volatile memory and performing operations and calculations requires fast volatile memory.
19:32
In previous classes we have learned about basic electrical quantities such as voltage and current and we have learned also about the elements that can influence them. We have learned also that there are elements that can influence data presented in bits. One can say that digital and analog are completely different words and it's hard to combine them. That's why we have converters. Analog to digital converters, ADC's convert the value of voltage
20:07
or current such as 2 Volts into corresponding digital signal represented by bits. DAC`s, so digital to analog converters, convert the digital signal into voltages. Reference voltage is the maximum voltage in each converter system. In DAC converters it is the maximum voltage that can be received on output when we put the maximum bit value to the input and an ADC converters this is the maximum voltage that can be put to the input to receive the
20:41
maximum bit value. Exceeding the value of the voltage reference may cause damage to the system, but sometimes we have to measure the voltages that are exceeding our range or they are so low that we cannot optimally use the range of our converter. Then it is important to condition the signal. There are many different treatments that allow our signal match the expectations of the convent converter. For example, when we have 7V signal and the maximum value of our input in converter
21:21
is 5V, we can use the voltage divider made of two resistors. For example 30 and 75 kilo ohms each.
21:31
Resolution this is with how many bits we can represent our voltage. For example 8-bit converter has 256 states because a 2 to the power of 8 is 256. So now let's suppose that we have 10 bit converter and the reference value of 5V. Each step value is around 4.88 millivolts, so for example if you have 0 on data that means we have 0 voltage, if you have 512 it means that we have 2.5 volts. Changing values in the DAC's and ADC's is not very fast and it's slower than
22:15
the normal operating time of our digital or analog device. The time of changing those values is called conversion time. It is often that high-resolution converters are much slower but sometimes we have to compromise how quick we want to convert the data and how accurate the data has to be, however, technology is still developing, so there are more and more converters that have high resolution and there are very quick but they are also very expensive.
22:47
Ok, now we will learn how converters work. Here we have a voltage characteristic, we see that the voltage have different value in every time moment. So how to change that voltage into the digital number or digital number into that voltage? Our minimum voltage is 0 volts and the maximum voltage is 5 volts, we have 4 bit converter so it has around 16 different states, so every state, every byte can represent 5/16 volts so it is around
23:27
0.3125 volts. So if we have the number 0 0 0 1 digital number it means it is 0.3125V and this if we have 0 0 1 0, it means we have 0.62 5 volts
23:59
Processor memories converters are systems that mix together. Can create a very developmental device.If we planned and designed everything properly we could create a system that without changing its mechanical structure could depending on what is stored in a memory, perform various operations. We could program such a system and perform different functions every time. Nowadays we do not need to construct such
24:24
a system ourselves. Those integrated circuits are called microcontrollers. They are a complete set of microprocessor system offered with a large set of peripherals. It is probably the largest family of digital integrated circuits. Even 15 years ago, such systems were very poor, had little memory and their computing power left much to be desired.Today for an affordable price we can get microcontrollers which are very fast, have a lot of memory and they have a lot of good quantity peripherals.
24:59
Now we have ended the journey of electronic components, laws of physics and electronics In the next episode we'll learn something in practice. We'll learn how to work safely, how to handle all the tools used in workshops and will start to project our own first electronic devices.
Here to help you learn
Sign in to keep a private conversation with your course tutor.
Ask me anything about the material…
Sign in to chat