Difference between revisions of "CSC103: DT's Notes 1"
Line 1,066: | Line 1,066: | ||
When you play some more with this circuit you will discover that what it does is remember which input is the last one you set to 0. If the last input that was 0 before you brought both of them back to 1 1 is the top input, then the output will be 1 (red). If the last input that was 0 is the bottom one, then the output will be 0 (black). | When you play some more with this circuit you will discover that what it does is remember which input is the last one you set to 0. If the last input that was 0 before you brought both of them back to 1 1 is the top input, then the output will be 1 (red). If the last input that was 0 is the bottom one, then the output will be 0 (black). | ||
− | This circuit has '''memory'''! That's magic. We are using purely combinational gates, gates that have no memory whatsoever in them, but by creating a loop ( | + | This circuit has '''memory'''! That's magic. We are using purely combinational gates, gates that have no memory whatsoever in them, but by creating a loop (look for the figure 8 in the logic diagram above) with the wiring, we create a ''feedback'' loop that helps information cycle around the loop. We won't study this more, as it is beyond the scope of our study, but if you are interested in this circuit, it is refered to in digital design as a ''flipflop''. The idea is that it behaves like a ''scale'' with two platters to weigh produce. The scale can be tilting left, or tilting right, and remains stable in that state until one of the inputs is activated. That's the idea of a digital flipflop. We are in the presence of a '''bit'''! |
<br /><center>[[Image:animatedScale.gif]]</center> | <br /><center>[[Image:animatedScale.gif]]</center> | ||
<br /> | <br /> | ||
− | + | A bit of trivia: when you have 4 bits together, for example 1011, this group of four bits is called a ''nybble'' (note the y instead of the i). When we have a grouping of 8 bits, this is called a ''byte'' (again, note the y instead of the i). When we have more, the definitions get a bit loose, and we usually refer them as ''words'', specifying how many bits they contain. For example: 16-bit words, or 32-bit words, or 64-bit words. The Intel or AMD processor inside your laptop or desktop computer operates with 32- and 64-bit words. | |
− | |||
+ | The memory is a collection of billions of memory words, each one storing a collection of bits. We saw earlier that a collection of bits can actually represents a binary number, and each binary number has an equivalent decimal number. So we can actually say that the memory is a collection of cells that contain numbers. It's easier for us human beings to deal with decimal numbers, so that's what we are going to do in the remainder of this section, but actually all the numbers in questions are binary. Does it make sense? | ||
− | + | So, here's how we can view the memory: | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
+ | |||
+ | +-------------+ | ||
+ | 1000000000 | 45 | | ||
+ | +-------------+ | ||
+ | . . | ||
+ | . . | ||
+ | . . | ||
+ | +-------------+ | ||
+ | 10 | 1103 | | ||
+ | +-------------+ | ||
+ | 9 | 0 | | ||
+ | +-------------+ | ||
+ | 8 | 7 | | ||
+ | +-------------+ | ||
+ | 7 | 1 | | ||
+ | +-------------+ | ||
+ | 6 | 13 | | ||
+ | +-------------+ | ||
+ | 5 | 7 | | ||
+ | +-------------+ | ||
+ | 4 | 0 | | ||
+ | +-------------+ | ||
+ | 3 | 10 | | ||
+ | +-------------+ | ||
+ | 2 | 5 | | ||
+ | +-------------+ | ||
+ | 1 | 103 | | ||
+ | +-------------+ | ||
+ | 0 | 3 | | ||
+ | +-------------+ | ||
+ | |||
It's a long structure made up of words. Words are numbered, from 0, to a large number, which is actually equal to the size of the memory, in increment of 1. For example, when you read the sticker for a computer on sale at the local store, it may say that the computer sports 4 gigabytes of RAM. What this means is that the memory, the ''Random Access Memory'' (RAM), is comprised of words containing numbers, the first one associated with a label of 0, the last one with a label (almost) equal to 4,000,000,000. | It's a long structure made up of words. Words are numbered, from 0, to a large number, which is actually equal to the size of the memory, in increment of 1. For example, when you read the sticker for a computer on sale at the local store, it may say that the computer sports 4 gigabytes of RAM. What this means is that the memory, the ''Random Access Memory'' (RAM), is comprised of words containing numbers, the first one associated with a label of 0, the last one with a label (almost) equal to 4,000,000,000. |
Revision as of 09:51, 22 September 2013
--© D. Thiebaut 08:10, 30 January 2012 (EST)