Professional Documents
Culture Documents
Chapter 3
Chapter 3
Chapter 3
Explain the differences between Random Access Memory (RAM) and Read Only Memory
(ROM)
Explain the differences between Static RAM (SRAM) and Dynamic RAM (DRAM)
Construct the truth table for each of the logic gates above
Definitions
Part of the computer memory which can be accessed
Primary Memory
directly by the CPU
Volatile Memory Memory contents are lost on powering off the computer
Random-Access Memory Volatile Memory that can be read from or written to any
(RAM) number of times
Part of the disk drive which moves above the disk platter
Read/Write Head
that reads from and writes data to the disk
Thermal Bubble (for localized heat from tiny resistors causes the ink to vaporize
producing ink droplets) and form a tiny bubble, which is ejected by the print head
Resistive Screen Uses a top polyester and bottom glass layer and touching
the top player completes the circuit, which determines
where the screen was touched
Truth Tables Used to trace the output from a logic gate or a logic circuit
NAND (NOT AND) Gate The output is 1 only if all inputs are NOT 1
NOR (NOT OR) Gate The output is 1 only if all outputs are 0
RAM vs ROM
Non-Volatile Volatile
RAM
Faster Data Access Time than DRAM Less expensive than SRAM
ROM
Requires the use of a PROM writer which Uses floating gate transistors and
uses an electric current to alter specific capacitors; UV light is used to program an
cells by ‘burning’ fuses in the matrix EPROM through a quartz window
EEPROM (Electrically Erasable PROM) is similar to EPROM, except an electrical signal can
be used to remove existing data. Therefore, the chip can remain in the circuit when the
contents are changed
Embedded System
devices such as cookers, refrigerators and central heating systems can now all be
activated by a web-enabled device (such as a phone) anywhere in the world
Benefits:
Since it is difficult to upgrade and to find faults, devices are often thrown away, hence
wasteful
Buffers
Short-term memory storage that stores data right before it’s used, typically in RAM
Enables CPU to manipulate data before transferring to a device
Secondary Memory
Secondary Memory devices store files for long-term access
Have platters (disks) made of aluminium or glass whose surfaces are covered with a
material capable of being magnetized
Platters are mounted on a central spindle and rotated at high speed
Each surface is accessed by a read/write head mounted on an arm positioned just above
the surface, which is controlled by electrical circuits
The surface of platters divided into concentric tracks and sectors
One track in one sector is the basic unit called the block, each of which has data encoded
as a magnetic pattern
When writing, current variation in the head causes magnetic field variation on the disk
When reading, magnetic field variation from the disk produces current variation in the
read head
The two transistors are the floating gate and the control gate
Memory cells store voltages that represent either 0 or 1
Optical Media
CDs and DVDs can be designated R (write once only) or RW (can be written to or read
from many times)
The disc surface has a reflective metal layer and is spun using drive motors
The tracking mechanism moves the laser assembly
When reading, the reflected light from the different states on the track is encoded as bit
patterns
When writing, the laser changes surface to pits and lands along the track, which
correspond to 1s or 0s
Blu-ray has the highest storage capacity
Laser beams and rotating mirrors are used to draw images of pages on a
photosensitive drum
Image converted to electric charge, attracting toner to stick to it
The heat was applied in the fuser to fuse toner on the paper
Electrical charge removed from drum
Inkjet Printer
The print head moves from side to side across the paper being fed
Colours from nozzles are exactly sprayed to get the desired colour
After each pass of the print head, the paper slightly advances to print the next line
Until the buffer not empty, the steps repeat
Ink droplets are produced by using one of two technologies:
Thermal Bubble - localized heat from tiny resistors causes the ink to vaporize and
form a tiny bubble, which is ejected by the print head
Piezoelectric - crystal at the back of the ink reservoir for each nozzle is given a
charge making it vibrate, which forces ink to be ejected onto paper
For both Laser and Inkjet Printers, the following process takes place initially:
Data is sent to the driver, which ensures that data is in a format, the printer can
understand
The driver checks if the printer is available, and if yes, sends it to a temporary
memory known as a printer buffer
3D Printer
The process starts with a digital file containing the blueprint
The software splits the object into pieces and sends to the printer
Solid plastic is melted and transferred to the nozzle, which is moved by stepper motor
into position
Change in digital audio signal causes current direction to change, changing field
polarity
Electromagnet either attracted or repelled to a permanent magnet, causing the
diaphragm attached to the coil to vibrate
Vibration causes sound waves to be produced
Microphone
Incoming sound waves enter the screen and cause the diaphragm to vibrate
This causes the coil to move past a magnetic core
Screens
Both an input and output device
2 types:
Resistive Capacitive
When the top layer is touched, the When the top glass is touched, the
two layers complete a circuit. The electric current changes and the
signal is sent out and the coordinate of touch is determined by
microprocessor determines the the onboard microprocessor.
coordinates of where the screen was Coordinates sent to touch screen
touched driver
Cheap Expensive
Virtual Headsets
Video sent from computer to headset
Two feeds sent to an LCD/OLED display
Lenses placed between eyes and screen allow for focusing and reshaping of images or
video for each eye, giving a 3D effect
Sensors and LED measure the movement when the user moves their head, to coordinate
the visuals according to this movement
Binaural sound is used to create a 3D sound effect by making the sound appear from
multiple angles and distance
Sensors
Input devices reading or measuring physical quantities
Converts real data, which is analogue, to digital format by Analogue to Digital Converter
(ADC) so that the computer can understand it
A Digital to Analogue Converter (DAC) is used by computers to convert digital data to
analogue to control physical devices
An actuator compares the output given by the DAC to the actual output stored and stores
the approved output
A feedback system is in place, where readings from sensors cause microprocessors
controlling devices such as a valve or motor, to alter them. This altering affects the next
readings of the sensor and is often used to bring the system within the required limits
Some of the sensors along with their applications are:
Sensors are used in monitoring and control systems as visualized in this flowchart
Solution
‣
Truth Table:
Inpu Outpu
t t
AND Gate
Truth Table:
Input Outpu
s t
Description: The output, X , is 1 if all inputs A B X
are 1.
Logic Notation: A AND B 0 0 0
0 1 0
1 0 0
1 1 1
OR Gate
Truth Table:
Input
Output
s
Description: The output, X , is 1 if any
A B X
input is 1.
Logic Notation: A OR B 0 0 0
0 1 1
1 0 1
1 1 1
Truth Table:
Input Output
Description: The output, X , is 1 if all inputs s
are not 1.
A B X
Logic Notation: A NAND B
0 0 1
0 1 1
1 0 1
1 1 0
Truth Table:
Input Outpu
s t
0 1 0
1 0 0
1 1 0
XOR Gate
Truth Table:
Input Outpu
s t
A B X
Description: The output, X , is 1 if both
outputs are different. 0 0 0
1 0 1
1 1 0
The following examples show how to produce a truth table, design a logic circuit from a
given logic statement, and design a logic circuit to carry out an actual safety function.
Skill Check 2
The following example shows how to produce a truth table, design logic circuit from
a given logic statement, and design a logic circuit to carry out an actual safety
function.
A safety system uses three inputs to a logic circuit. An alarm, X , sounds if input A
represents ON and input B represents OFF, or if input B represents ON and input C
represents OFF.
Produce a logic circuit and truth table to show the conditions which cause the output
X to be 1.
Solution
‣
Input
Values Output
s Intermediate
0 0 0 0 0 0
0 0 1 0 0 0
0 1 0 0 1 1
0 1 1 0 0 0
1 0 0 1 0 1
1 0 1 1 0 1
1 1 0 0 1 1
1 1 1 0 0 0
Skill Check 3
Cristiano has to attend school if it’s a weekday AND NOT a holiday, OR if it’s NOT a
weekday AND a sports week AND NOT a holiday.
Let the parameter used to represent Cristiano attending school be given by X , where
X = 1 represents Cristiano attending school.
Using suitable inputs, Produce a logic circuit and truth table to show the conditions
which cause the output X to be 1.
Solution
‣
1. Assign suitable parameters to represent each event/input. For this solution,
the following example parameters are used.
A = 1: It is a weekday.
B = 1: It is a holiday.
C = 1: It is a sports week.
2. Convert to a logic statement by breaking down the problem statement.
X = 1 if (A = 1 AND B = NOT 1) OR (A = NOT 1 AND B = NOT 1 AND C =
1)
3. Construct the logic gate for the first and third parts of the logic statement.
For the third part, it’s recommended to break down the circuit into smaller
circuits such as (A = NOT 1 AND B = NOT 1) AND C = 1, so that each
circuit uses 2 inputs. However, although not recommended, three inputs to
the logic gate also work.
4. Combine both parts with Part 2 (the OR gate).
5. Produce the truth table either by tracing through the logic circuit or by using
the original logic statement. Use intermediate values to make it easier to
produce the table.
Input
Values Output
s Intermediate
D (A = 1 E (A = NOT 1
A B C AND B = AND B = NOT 1 X
NOT 1) AND C = 1)
0 0 0 0 0 0
0 0 1 0 1 1
0 1 0 0 0 0
0 1 1 0 0 0
1 0 0 1 0 1
1 0 1 1 0 1
1 1 0 0 0 0
1 1 1 0 0 0
NOT gate
Points to Note
Primary storage is main memory, consisting of RAM (DRAM or SRAM) and ROM (possibly
PROM, EPROM or EEPROM)
Secondary storage includes magnetic, optical and solid-state media
Output devices include screens, printers, plotters and speakers
Input devices include the keyboard, scanner and microphone
Screens can be used for both input and output
A monitoring system requires sensors
A sensor measures a physical quantity; there are many examples, such as temperature,
humidity, pH, infrared, pressure, sound and carbon monoxide
A monitoring and control system requires sensors and actuators
A program used for a monitoring and control system has to operate in real-time with an
infinite loop that accepts input from the sensors at timed intervals
The program transmits signals to the actuators if the values received from the sensors
indicate a need for control measures to be taken
A logic scenario can be described by a problem statement or a logic expression
A logic expression comprises logic propositions and Boolean operators
Logic circuits are constructed from logic gates