knowt logo

Computer Science

1 - Data representation

1.1 - Binary and hexadecimal

Humans process data called analogue data. It is a continuous stream of data to our senses.

The data-processing parts of a computer are made up of small logic gates, which cannot process analogue data. These gates can only process digital data, which is stored in registers. Digital data (also called binary data) only has 2 values, 1 and 0.


Number systems

Everyday we use the denary number system. It is called a base-10 system as it only has 10 digits (0-9). The units in a denary system are ones, tens, hundreds, thousands, etc. Each time a unit goes up it increases by the power of 10.

Computers use the binary number system. It is called a base-2 number system as it has 2 digits (0 and 1). Each time the unit goes up, it increases by the power of 2.

Denary values must be converted to binary values to be processed by a computer.


Use the book (page 11) to learn how to convert denary to binary.


Use the book (page 13) to learn how to convert binary to denary.


Hexadecimal (or hex in short) is a number system that can be used by humans but cannot be processed by computers. It must first be converted to binary. Hex is a base-16 system as it uses 16 symbols, 0-9 and A-F. This allows the denary values 0-15 to be represented. t

The symbols A-F are used instead of 10-15 so only one symbol is needed for the characters.


Use the book (page 14) to learn how to convert binary to hexadecimal.


Use the book (page 15) to learn how to convert hexadecimal to binary.


The benefits of using hexadecimal rather than binary

  • Hexadecimal is a shorter way of representing binary, taking up less space on the screen.

  • Hexadecimal is easier to read, write and understand.

  • Hexadecimal makes it easier to debug and locate errors in data.


1.2 - Binary manipulation and negative numbers

Adding binary numbers

Adding binary numbers has rules.

  • 0+0=0

  • 1+0=1

  • 1+1=10

  • 1+1+1=11


Use the book (page 17) to learn how to add binary numbers in detail.


An overflow error may occur when adding binary numbers. This is when a number is generated that is larger than the maximum amount for a register. Each computer has a predefined limit, for example 16-bit registers. If a number larger than the maximum is generated in a process, an overflow error will occur causing the wrong number to be displayed.


Logical binary shifts (multiplication and division)

Another process that can occur is called a logical binary shift. This shift can move the binary values left or right, multiplying or dividing them. This will result in the left-most or right-most digit will be removed from the register, and a new 0 will be added in the left-most or right-most sections.

Each logical shift to the left multiplies the entire number by 2.

Each logical shift to the right divides the entire number by 2.


Use the book (page 19) to learn how to perform logical binary shifts in detail.


Negative binary numbers

Negative numbers can be represented in binary, however there is no “-” symbol in binary so a method exists called two’s complement.

This method is very simple. First, flip all the numbers (1s becomes 0s and 0s becomes 1s), then add 1 to the result (using the binary addition method)


Use the book (page 20) to learn how to use two’s complement in detail with an example.


1.3 - Representing text, images and sound

Text, images and sounds also have to be converted to binary before a computer can process them.


Converting text to binary

To convert text to binary a tool called a character set has to used. There are two main types of character sets, ASCII and Unicode.

ASCII represents characters using 8-bit binary numbers, meaning it can represent up to 256 characters (0-255). Some languages require more than 256 characters, so Unicode was invented, which can represent characters using 16-bit binary numbers, meaning it can represent up to 65536 characters. Many more characters can be developed in different alphabets and also symbols such as emojis can be used.


Converting images to binary

Images are made up of tiny dots called pixels. Each pixel has a color which can be represented with a binary value. If an image only had black and white, each pixel would be either black or white. The binary value 1 could represent white and 0 could represent black.

If each pixel is converted to its binary value, the data could look like:

0011111100010000101000001001001100001000001000101

The image file will also contain metadata. Metadata is additional data stored with the image that can provide extra information such as the resolution, date taken, and name of the image.

Images use the RGB system that mixes the colors red, green and blue to create each color. The RGB system uses hexadecimal.

Each image has a resolution and color depth (sometimes also known as bit depth). The resolution is the number of pixels wide and high that have to be used to create the image. The color depth is the number of bits that are used to represent each color. This cool table could help.

Color depth

Numbers of colors that can be represented

1

2

2

4

3

8

4

16

5

32

You should notice a pattern. The numbers of colors that can be represented is 2^color depth.

If the resolution of an image is increased, the image will be created using more pixels, so the size will increase.

If the color depth of the image is increased, each pixel will need more data to store each color so the size will increase.


Converting sound to binary

Sound is made up of sound waves. When sound is recorded, this is done at set time intervals (at a set pattern.) This process is known as sound sampling.


Use the book (page 24) to refer to the images soon to be mentioned.


Figure 1.4 in the book is an example of a sound wave.

Recording the sound at each time sample would grant the following set of sound values (look at the table).

Each sound value is converted to binary to be processed by the computer.

Figure 1.5 is a recording of the sound in figure 1.4, yet they look different. This is because the number of samples taken is too far apart, and sounds in between each sample were lost. Therefore, the sample rate (or sample frequency) needs to be increased. This is the number of samples taken in a second (measured in hertz). Sounds also require sample resolution. This is the number of bits that are used to represent each sample. The higher the sample resolution, the more accurate each sample/sound will be.


1.4 - Measuring data storage

Data is measured using different units.

Unit

Description

Bit

Smallest measurement for data

Nibble

4 bits in a nibble

Byte

8 bits in a byte

Kibibyte (KiB)

1024 bytes in a kibibyte

Mebibytes (MiB)

1024 kibibytes in a mebibyte

Gibibyte (GiB)

1024 mebibytes in a gibibyte

Tebibyte (TiB)

1024 gibibytes in a tebibyte

Pebibyte (PiB)

1024 tebibytes in a pebibyte

Exbibyte (EiB)

1024 pebibytes in an exbibyte


Calculating the size of a file

For image files, you need to know:

  • the number of images in the file

  • the resolution of the image

  • the color depth of the image

After that, the calculation is

width of image x height of image x color depth of image x number of images in file

Which can be simplified into:

resolution of image × color depth × number of images


For sound files, you need to know:

  • the length of the soundtrack

  • the sample rate of the soundtrack

  • the sample resolution of the soundtrack

After that, the calculation is:

sample rate × sample resolution × length of soundtrack


1.5 - Data compression

Compression is reducing the size of a file.

Benefits of compressing a file:

  • Not as much storage space is needed

  • Moving the file will take less time

  • It will be quicker to upload and download the file

  • Less bandwidth needed to transmit the file over the internet

There are two types of compression, lossy and lossless.

Lossy compression uses a compression algorithm that finds and removes unnecessary data in the file, such as colors that the human eye cannot distinguish or sounds the human ear cannot hear. It could also remove softer sounds that are played at the same time as louder sounds, as humans will only hear the louder sound. This is called perceptual music shaping. The size of a sound file can also be reduced by reducing sample rate and sample resolution. For images, it could reduce the color depth or reduce the image resolution.

Lossless compression uses a compression algorithm to reduce the size of the file without permanently removing any data. A common method that can be used is by finding repeating data and grouping it together.


Use the book (page 28) for a good example of lossless compression.


A similar process can be used for image files with a lossless compression algorithm called run length encoding (RLE). It will group together repeating pixels and store how many times they occur.


Use the book (page 29) for a good example of RLE.


2 - Data transmission

Data packets

Information over the internet is broke down into packets and these are created by TCP and transmitted over the internet. To define, a packet is a small chunk of information/data.

TCP stands for Transmission Control Protocol and it is used for organizing data transmission over networks.

When transferring data, it is easier to route small chunks of data than large ones. Routing is the process of finding the most optimal path over a network.

Structure of a packet

A packet contains:

  • Destination IP

  • Source IP

  • Data payload, the message

Packet is made up of:

  • Packet header

  • Payload (the actual data)

  • Trailer

The packet header contains:

  • Source IP

  • Destination IP

  • Packet number

  • Error checkers (e.g. parity bits and checksums)

The packet trailer contains:

  • Additional error checks

  • End of packet notification

Packet switching

Sending packets over the internet is called packet switching. It is more efficient than circuit switching.

Packet switching involves:

  • Data is broken down into packets

  • Each packet could take a different route

  • A router controls the route a packet takes

  • Packets may arrive out of order

  • Once the last packet has arrived, packets are reordered

Wired transmission

Methods of data transmission:

  • Serial

    • One bit is sent at a time through a single wire.

  • Parallel

    • Multiple bits are sent at a time across several wires.

    • Data will be skewed (i.e. bits will arrive in the wrong order as each wire will transmit at a slightly different speed)

      • This is called asynchronous transmission, meaning data will not always arrive at the same time.

  • Simplex

    • Simplex transmissions are unidirectional and travel only in one direction.

  • Half-duplex

    • Half-duplex transmissions are bidirectional. They can travel in both directions, but not at the same time.

  • Duplex

    • Duplex transmissions are bidirectional, and data can travel at the same time.

It is a mixture of the two groups of methods that forms what final method the transmission will use.

Simplex

Half-duplex

Full-duplex

Serial

Serial-Simplex

Data is transmitted one bit at a time in a single direction on one wire

Serial-Half-duplex

Data can be transmitted in both directions on a single wire but only one bit at a time can be transmitted in one direction at a time

Serial-Full-duplex

Data can be transmitted in both directions at the same time on a single wire one bit at a time 

Parallel

Parallel-Simplex

Multiple wires transmit one bit at a time in one direction

Parallel-Half-duplex

Multiple wires send multiple bits of data in both directions but only one direction at a time

Parallel-Full-duplex

Multiple wires send multiple bits of data in both directions at the same time



Advantages


Disadvantages

Serial

-The data will arrive in the order it is sent

-It is less likely to have errors

-Serial transmission is cheap over short and long distances as the cost of wire is fairly inexpensive

-Data transmission is slow, especially over long distances as only small quantities of data can be transmitted at a time

-Serial transmission is expensive over very long distances as the cost of wire dramatically increases

Parallel

-Parallel transmission is fast as large quantities of data can be transmitted at any one time

-Parallel transmission is expensive over short distances as multiple wires need to be purchased. -Transmission is very expensive over long distances as the cost of wires dramatically increases with the distance

-Delays can be caused if data arrives asynchronously as the receiver has to wait for all of the bits before accepting new data. This is especially true over longer distances

-Buffers may be used to store data temporarily while waiting for all bits to arrive

Simplex

-Simplex wires are cheap as only one wire is used

-Data transmission is slow as data still travels one bit at a time in only one direction at a time

-Simplex transmission requires two sets of wires for bidirectional transmission meaning it can become expensive

Half-duplex

-Half-duplex transmission is cheaper than simplex for bidirectional transmission as it requires fewer wires

Transmission is still slow as data travels one bit at a time in only one direction at a time

Full-duplex

-Full-duplex transmission is faster as data can travel in both directions simultaneously. The receiver does not have to wait for the sender to stop before they can start transmitting their data

-Full-duplex is expensive as the wire technology to transmit in both directions is more difficult to implement

Example scenarios of using each

It will come up in the exam:

  • Serial

    • Connecting an external hard drive to a computer

    • Transmitting data over a telephone line

  • Parallel

    • Transmitting data from a computer to a printer using a multi-wire connector

  • Simplex

    • Transmitting data from a computer to a printer. The printer doesn’t need to send data back to the computer

      • Modern versions of devices such as printers may send acknowledgement signals to confirm they have received the data. This may require half-duplex rather than simplex connections

  • Half-duplex

    • Phone conversations where only one person needs to speak at a time

    • A walkie-talkie is a two way radio with a push to speak button. The receiver is turned off while the transmitter is turned on. This prevents you from hearing the other person while you speak

  • Full-duplex

    • Broadband connections to the internet. Data must be sent and received at the same time. Accessing information on the internet is known as downloading information. Putting information onto the internet for others to access is known as uploading

    • Phone conversations where both people can talk and be heard at the same time allowing them to interrupt each other

USB

USB stands for Universal Serial Bus. As the name suggests, it uses serial transmission. Many devices such as phones, printers, and video cameras use USB.

Different USB connectors exist for different devices:

  • USB-A (flash drives, mice, keyboards, external HDD, etc)

  • USB-B (printers, scanners, optical drives, floppy drives, etc)

  • USB-C

USB-C is become the new industry standard as it is very small and fast.

When a device is connected to a USB port, the computer:

Automatically detects that the device has been connected

Automatically recognizes the device and the appropriate device driver is loaded so the device can communicate with the computer.

If the device is new, the computer will look for a matching device driver. If one cannot be found then the user must download and install an appropriate driver manually.

Advantages

Disadvantages

Devices are automatically detected and drivers are automatically loaded for communication. This simplifies the data transmission process for the user

The maximum cable length is roughly 5 metres meaning it cannot be used over long distances, limiting its use

Cable connectors fit in only one way. This prevents incorrect connections and ensures compatible data transmission

Older versions of USB have limited transmission rates for example USB 2.0 has 480Mbps

As USB usage is standardised, there is a lot of support available online and from retailers

Very old USB standards may not be supported in the near future (USB 1.1, USB 2.0, etc)

Several different data transmission rates are supported. The newest transmission rate as of 2022 is USB4 2.0 with 80 Gbps (81,920 Mbps, 170x faster than USB 2.0)

 

Newer USB standards are backwards compatible with older USB standards

 

Error checking

Why check for errors?

Computers expect data in certain formats

  • A format is a way of arranging the data so that it can be easily understood by people and by computers

  • People agree to certain formats so that systems work more efficiently and there is little chance of misunderstanding each other

  • An example of a format is date and time, DD/MM/YY vs MM/DD/YYYY

An error or corruption occurs when data received is not as expected and therefore is difficult or impossible to process, such as if the wrong format is used

  • For example, take the value 00100001. If the second most significant bit is swapped, it will be 01100001. This means that the value has changed and in certain situations like space coordinates or bank transfers one number or bit changing is a HUGE deal.

  • If many bits were flipped, the text or original data would be completely unreadable.

  • This means that any job that relies on computers performing highly sensitive data transfers must have methods of error checking.

How do errors occur?

  • They can occur due to interference

    • Examples of this are wire degradation or electrical fields changing the signal.

  • Results of this can include:

    • Data loss - data is lost in transmission

    • Data gain - additional data is received

    • Data change - some bits have been changed or flipped.

  • Wireless technology uses radio signals or other electromagnetic signals to transmit data.

  • Bad weather or physical barriers like walls can stop the correct transmission of this data.

Parity check

  • The parity checking protocol determines whether bits in a transmission have been corrupted

  • Every byte transmitted has one of its bits allocated as a parity bit

  • The sender and receiver must agree before transmission whether they are using odd or even parity

  • If odd parity is used then there must be an odd number of 1’s in the byte, including the parity bit

  • If even parity is used then there must be an even number of 1’s in the byte, including the parity bit

  • The value of the parity bit is determined by counting the number of 1’s in the byte, including the parity bit

  • If the number of 1’s does not match the agreed parity then an error has occurred

  • Parity checks only check that an error has occurred, they do not reveal where the error(s) occurred

Even parity

  • Below is an arbitrary binary string

EVEN
Parity bit

Byte

0

1

0

1

1

0

1

0

  • If an even parity bit is used then all bits in the byte, including the parity bit, must add up to an even number

    • There are four 1’s in the byte. This means the parity bit must be 0 otherwise the whole byte, including the parity bit, would add up to five which is an odd number

    • Else, an error has occurred

Odd parity

  • Below is an arbitrary binary string

ODD
Parity bit

Byte

1

1

0

1

1

0

1

0

  • If an odd parity bit is used then all bits in the byte, including the parity bit, must add up to an odd number

    • There are four 1’s in the byte. This means the parity bit must be a 1 otherwise the whole byte, including the parity bit, would add up to four which is an even number

    • Else, an error has occurred

How errors occur

When using parity bits, error occurs when the of total bits does not match the agreed parity

This can be due to bits flipping or changing due to interference on a wire.

Parity bytes and parity blocks

Parity checks have a problem, and it’s that they don’t pinpoint where the error actually is in the byte

Parity blocks and parity bytes can be used to check an error has occurred and where the error is located.

The table above uses odd parity. Each byte row calculates the horizontal bit parity as normal

Each bit column calculates the vertical parity for each row. This is the parity byte. It is calculated before transmission and is sent with the parity block.

Each parity bit calculates if a flip error occurred in a byte row, while the parity byte calculates if a flip error occurred in a bit column.

Cross referencing these two can give you the exact incorrect bit.

In the table above, we can see that byte 3/bit cell 5 is an error and should be 0 instead.

The error could either be auto-fixed or retransmission could be requested from the sender

Checksums

  • Checksums determine if data has been corrupted but do not reveal where

  • Data is sent in blocks and an additional checksum value is added at the end of the block

  • Checksums are custom user-created algorithms that perform mathematical calculations on data

  • An example of a custom checksum algorithm in computer science is:

    • A checksum byte is defined as a value between 1 and 255 which is stored in 8 bits. 8 bits are collectively known as a byte

    • If the sum of all of the bytes of a transmitted block of data is <= 255 then the checksum value is the sum of all of the bytes

    • If the sum of all of the bytes is > 255 then the checksum is calculated with an algorithm:

      • X = sum of all of the bytes

      • Y = X / 256

      • Round down Y to nearest whole number

      • Z = Y * 256

      • Checksum = X - Z

Custom Checksum Walkthrough

  • If X = 1496

    • Y = 1496 / 256 = 5.84

    • Rounded down Y = 5

    • Z = 5 * 256 = 1280

    • Checksum = 1496 - 1280 = 216

    • The checksum value in this example would be 216

When a block of data is transmitted, the checksum value is calculated then transmitted with the rest of the data

When the data is received the checksum value is calculated based on the received data and compared to the checksum value received. If they are the same then

Echo check

  • Transmitting the received data back to the sender. Sender checks the data to see if any errors occurred during transmission

  • Not reliable as an error could have occurred when the sender transmits the data or when the receiver transmits the data. Neither will know when the error occurred.

  • If an error does occur the sender will retransmit the data

Automatic Repeat Request (ARQ)

  • When the receiver receives transmitted data it must check for the presence of any errors. Errors can usually be detected but not always pinpointed

  • An Automatic Repeat Request is a protocol that notifies the sender that an error has occurred and that the data received is incorrect. It works as follows:

    • If an error is detected the receiver sends a negative acknowledgement transmission to indicate the data is corrupted

    • If no error is detected the receiver sends a positive acknowledgement transmission meaning the data is correct

    • If the receiver does not send any acknowledgement transmission then the sender waits for a certain time period known as a time-out before automatically resending the data

    • This process is repeated until all data has been received and acknowledged

3 - Hardware

The CPU processes instructions and data that are input into the computer so that the result can be output

  • A microprocessor is a type of integrated circuit on a single chip

Components of CPU

The CPU has two main components - the Control Unit (CU) and the Arithmetic Logic Unit (ALU)

  • The Control Unit controls the flow of data around the CPU

  • The Control Unit also sends control signals to the different components instructing them what to do e.g. read, write, add, subtract

  • The Control Unit decodes instructions (into an opcode [action to be done] and operand [what object to do the action on]

  • The Control Unit controls the timings of operations (the clock speed) 

  • The Arithmetic Logic Unit (ALU) performs the calculations required to execute the instructions, these include ADD and SUBTRACT

  • The ALU also carries out logical operations such as COMPARE

  • The ALU has a built-in register where it stores interim results of calculations

Registers

The CPU also has a bunch of registers with specific functions in executing instructions

Special purpose register

Definition

Program Counter (PC)

stores the address of the next instruction to be fetched from memory

Memory Address Registers (MAR)

stores the address of the instruction or data to be fetched from or written to memory

Memory Data Register (MDR)

  • stores the data that has been fetched from memory or being written to memory

  • Data from MDR is sent to ALU to be executed

Current Instruction Register (CIR)

stores the instruction the CPU is currently decoding or executing

Accumulator

Temporarily stores the results of the calculations performed by the arithmetic and logic unit

Buses

They are wires down which electrical signals and data travel. They are collected called the system bus.

  • Data bus transmits data CPU to/from memory or input/output controllers. It travels in both directions, it is bidirectional.

  • Address bus transmits addresses from CPU to memory. It is unidirectional.

  • Control bus transfers control signals from the CU to other components of the computer such as memory or input/output controllers. It is bidirectional.

That diagram shows visually how everything travels.

Step

Detailed Explanation

Fetch

  • The memory address of the instruction to be fetched is stored in the Memory Address Register and is sent down the address bus. 

  • The data/instruction at the memory address is transferred back to the CPU, via the data bus, where it is stored in the Memory Data Register

  • The instruction is copied into the Current Instruction Register and the Program Counter increments

Decode

  • The instruction in the Current Instruction Register is decoded, by the Control unit, into an opcode and an operand

Execute

  • The instruction is executed by the Arithmetic Logic Unit and the opcode is performed upon the operand. 

  • The result is stored in the accumulator or written to a memory location within memory

Performance of a CPU

  • The more cores a computer has the more instructions that can be executed per second resulting in better performance (dual-core, quad-core)

  • The higher the clock speed, the more instructions can be performed in a second. 1Hz = 1 instruction, 1KHz = 1000, 1MHz = 1,000,000 and 1GHz = 1,000,000,000 (billion)

    • So 3.4GHz core can run 3,400,000,000 (3.4bil) instructions per second

  • Cache is a small amount of memory close to the CPU that stores frequently used information. It can be accessed VERY fast, so the more cache size the better performance of CPU as more quickly accessible things can be stored in the cache

Instruction sets

An instruction set is a list of all the commands that can be processed by a CPU and the commands are machine code, example add, subtract, load, etc.

Embedded system

An embedded system is used to perform a dedicated function, e.g. domestic appliances, cars, security systems, lighting systems or vending machines. This is different to a general purpose computer that is used to perform many different functions, e.g. a personal computer (PC) or a laptop.

  • It runs on firmware.

Type of embedded system

Description

Microcontrollers

Integrated circuit containing a CPU and memory (RAM or ROM) built in to the same chip

Microprocessor

Integrated circuit containing only a CPU on the chip

RAM , ROM , peripherals need to be added if required

Examples of embedded systems:

Embedded system

Possible input devices

Possible Output

Digital clock

Buttons to set the time/mode/alarm

Screen showing the time

Alarm

Traffic Lights

Pedestrian button

Timer

Movement sensor

Lights

Lighting system

Movement sensor

Lights

Security system

Keypad to enter alarm code

Camera

Movement sensor

Alarm

Vending machine

Keypad to make choice

Actuator controlling movement of choice

Central Heating system

Keypad to set temperature

Temperature sensor

Heat

Advantages of an embedded system:

  • low power consumption

  • small physical size

  • low cost to manufacturer

  • they can be controlled remotely

  • can operate in real time and respond to inputs very quickly

Input devices

Barcodes

  • Barcodes are a series of black and white bars which represent a code

  • A barcode reader shines a red laser at the barcode to read the data it represents

  • The light from the white lines is reflected back

  • Black lines absorb the light so less is reflected

  • Converts difference of reflection into binary value

  • Benefits:

    • Faster checkouts

    • Automated stock control

    • Less chance of error due to manual entry

    • More detailed tracking info

Digital camera

  • Captures light and converts to digital image

  • They are integrated into phones

  • They instantly create image

  • This image can be edited or have a filter applied to it or reduplicated many times and shared

Keyboard

  • Text-based data input

  • Built into laptops

  • Phones have digital keyboards

  • Each key makes contact with a peg that makes contact with a membrane. This is then converted into an electrical signal

Microphone

  • Converts sound waves into electrical signals that can be processed by the computer

  • Can be used to record music, telephone calls, communicate online and dictation.

Optical mouse

  • A mouse uses a laser to detect and track movement, then processed by microprocessor

  • Can be wired or wireless

  • Simple and intuitive to use

  • Reliable as there are no moving parts

QR code

  • Visual representation of data using black and white squares

  • Can represent over 7000 digits whereas a barcode represents up to 30 digits

  • Scanned by a camera (often on a mobile device)

  • A piece of software convert the squares into binary data

  • QR codes often link to a website where more information can be found

  • They can also be used to advertise products, share contact details, provide promotional codes, train tickets, and event tickets

    • However they can often have malware

Touchscreen

  • A touchscreen can be classed as both an input device and an output device


Type


How it works


Benefits/Drawbacks


Uses

Resistive screen

Resistive screens consist of two conductive layers. The top layer is flexible. When the screen is touched the two layer connect, completing a circuit

+ Cheap to produce. 

+ Resistant to surface  contaminants

+ Can be activated with nearly every object (stylus, finger, gloved hand)

Used in cash machines, information kiosks, medical equipment

Infra-red screens

LEDs shine infrared light across a screen forming a matrix. When the screen is touched the beams are interrupted

+ Excellent image quality

+ high precision 

+ durable

+ allows for multiple touches at the same time

- Requires a bare finger or stylus for activation

Tablets, laptops, smartphones

Capacitive screens

Made up of a protective layer, a transparent conductive layer and a glass substrate. Touching the screen changes the electrostatic field of the conductive layer

+Excellent image quality

+Unlimited touch-life

+Scale well

- Sensitive to interference from light, water, snow

Large scale commercial displays

Information kiosks

Medical equipment

2D and 3D scanners

  • A two-dimensional (or flat-bed) scanner shines a strip of light over a document. Reflected light is measured for each pixel. This data is converted into binary data so the document can be digitally recreated

  • A three- dimensional laser scanner shines a light over an object. The geometry and dimensions are recorded so the object can be recreated digitally

  • 2D scanners can be used for creating digital versions of documents or photographs

  • Reading passports at airports

  • Typical uses of 3D scanners and printers are dentistry, product development, medical

  • A cheap and quick way of creating a digital representation of both 2D and 3D objects so they can be manipulated, stored, transmitted or copied

Summary

Device

Example Uses

Benefits 

Barcode scanner

Checkouts, parcel delivery

Faster checkout, less errors, detailed stock/tracking information

QR code scanner

Advertising products, linking to websites, e-tickets

Can hold more information than a barcode

Can be scanned using a camera on a mobile device (smartphone)

2D and 3D scanners

Scan documents, photos and objects

Converts 2D and 3D objects into digital data which is easier and quicker to transmit/duplicate or manipulate

Digital camera

Smartphones, professional photography, security systems

Instant preview and image

Keyboard

Entering text 

Universal, easy to use

Mouse

Navigating a GUI

Making selections and entering commands

Intuitive

Microphone

Recording real-world sound

Musical recordings

Telephone calls

Dictation

 

Touchscreen

Entering text and commands on mobile devices (tablet, smartphone)

Cash machines

Interactive advertisements

Information screens

Can be durable

Good image quality

Intuitive/easy to use

Output devices

Shows results of processing

Actuator

Used with a motor to translate energy into real-world movement of a physical object

  • Examples of use include turning a wheel, opening or closing a door, controlling a conveyer belt, operating machinery, moving robotic arms, vibrating a machine, starting or stopping a pump, opening or closing a valve

They are often used with sensors

Light projectors

Projects computer outputs onto a large screen.

  • Gives presentations in education and business settings

There are two types, DLP and LCD

  • DLP systems use millions of micro mirrors in a grid on a microprocessor within the projector. Light is shone through color filters and the mirrors. The position of the mirrors can be altered to change the positioning of the light

  • LCD projectors use three mirror filters to separate an image into red, green and blue wavelengths. They are then combined to produce the full image which is passed through the lens onto the wall/screen.

Device

Advantages

Disadvantages

Digital light projector (DLP)

Higher contrast ratios. 

Smooth video

Image tends to suffer from “shadows” when showing a moving image

Higher reliability

DLP do not have grey components in the image

Smaller and lighter

The color definition is not as good as LCD projectors

Better suited to dusty atmospheres than LCD projectors

LCD projector


 

Give a sharper image than DLP projectors

Contrast ratios are not as good as DLPs

Better colour saturation and intensity than DLP projectors

Have a limited life

Use less power and generate less heat

LCD panels degrade over time.

Quieter running that DLP

 

Laser and Inkjet printers

Both create hard copies of a digital document, good for when you don’t have an electronic device on you.

Inkjet printers

  • Have a print head which moves across the page

  • Spray liquid ink droplets from ink cartridges through very fine nozzles onto the paper.

  • The droplets can be piezoelectric or thermal bubble technology

  • Inkjet printers produce high quality hard copies of digital documents/images

Laser printers

  • Very fast at printing when making multiple copies

  • Useful for printing high volume jobs like leaflets

  • Low running cost per page

  • Have large toner (dry version of ink) cartridges and large paper trays

  • Use positive and negative charges to make the toner particles stick to piece of paper, heat is then used to bond the particles to the paper

3D printers

  • Create 3D models of a digital model by depositing layers of material, such as plastic or resin, on top of one another to slowly build up a 3D object

  • Allow for precision and can be used in medicine to create prosthetics and blood vessels

  • Can be used to create rapid prototypes

  • Models can be transmitted digitally and then models printed out all across the world

LCD screens

  • Liquid Crystal Display screens are made up of millions of tiny liquid crystals making up pixels arranged in a matrix

  • Requires backlighting

  • Used for TVs, monitors, phones, tables

  • Low power consumption, run at a low temperature

  • Do not suffer from image burn

  • Give bright images and colors

  • Cheaper to produce than LED screens

LED screens

  • Light Emitting Diode screens are made up of tiny LEDs

  • No backlighting needed, much lighter and thinner

  • They are replacing LCD in modern times

  • Better image quality, longer life span

  • Consume very very little power

  • Can be used to create VERY large screens like in football matches and festivals

Speakers

  • Speakers are used to take digital sounds or recordings and output them as sound waves which can be heard by humans

  • The digital data is changed into a electric current using a digital to analogue converter (DAC)

  • It is then passed through an amplifier to create a current large enough to drive a loudspeaker

  • The loudspeaker converts the current into a sound wave

  • Typical uses include listening to music, listening to video sound, telephone calls and alarms

Sensor type

What it measures

Typical use

Acoustic

Sound levels

To detect changes in sound levels of industrial machinery

To monitor noise pollution

In security system to detect suspicious sounds

Accelerometer

Acceleration rate, tilt, vibration

Detecting sudden changes in vehicle movement and deploy safety features if needed

In mobile phones to detect orientation of the device

Flow

Rate of gas, liquid or powder flow

Detect changes in the flow through pipes in water system

Gas

Presence of a gas e.g. carbon monoxide

Detect levels of gas in confined spaces

Detect gas levels when fixing gas leaks

Humidity

Levels of water vapour

Monitor humidity in greenhouses

Infra-red

Detecting motion or a heat source

Security systems detecting intruders who break the beam

Measures heat radiation of objects - used by emergency services to detect people

Level

Liquid levels

Detects levels of petrol in a car tank

Detect levels of water in a water tank

Detect a drop in water levels due to a leak

Light

Light levels

Automatically switching on lights when it gets dark (street lights, headlights)

Magnetic field

Presence and strength

Anti-lock braking system

Monitoring rotating machinery such as turbines

Moisture

Presence and levels of moisture

Monitoring moisture in soil

Monitoring damp in buildings

pH

Acidity or alkaline

Monitoring soil to ensure optimum growing conditions

Monitor pHlevels in chemical processes

Pressure

Gas, liquid or physical pressure

Monitoring tyre pressure

Monitoring pressure in pipes during manufacturing process

Proximity

Distance

Monitoring position of objects in robotics

Used in safety systems to prevent objects colliding

Temperature

Temperature in Celsius, Fahrenheit or Kelvin

Used to maintain temperature in swimming pools

Used to control temperature in chemical processes

Storage

Primary storage

Primary storage is directly accessed by the CPU. Examples include RAM and ROM

RAM

  • The purpose of RAM (random access memory) is store data, instructions, and software currently in use

  • It is also called main memory

  • Faster read-write speeds than secondary storage as it is closer to CPU

  • Volatile, meaning it is temporary and data will be lost

ROM

  • The role of Read-only memory (ROM) is to store the computer’s boot-up sequence

    • The boot-up sequence is a set of instructions the computer executes when then computer is initially switched on

    • This sequence will run a series of checks to ensure all of the system hardware is working

    • It will then load the operating system which will move from secondary storage to RAM

  • ROM is non-volatile which means data will be stored when the computer is switched off

  • ROM is read-only which means data cannot be written to ROM

RAM

ROM

Volatile

Non-volatile

Can read and write data to RAM

Read-only

Secondary storage

Secondary storage cannot be directly accessed by the CPU. Examples include HDD and SSD

Types

  • Magnetic

  • Solid state

  • Optical

Magnetic

  • High power consumption

  • Relatively slow read/write speeds

  • Unreliable as has moving parts

  • A magnetic hard disk is made up of several metal discs coated with a magnetic material

    • These are called platters

    • Iron particles on each platter are magnetised to represent a 0 or 1

Solid state

Uses NAND and NOR gates to persistently control flow of electrons. Current flowing = 1, no current flowing = 0

  • Low power consumption

  • Fast read/write speeds

  • Reliable and has no moving parts

Optical

Optical devices include CDs, DVDs and Blu-rays

  • All optical devices work by shining a laser at the disk and processing the reflection

  • An arm moves the laser across the surface of the disk

Comparing the two types of storage so far:

Primary storage

Secondary storage

Volatile / temporary

Non-volatile /permanent

RAM and cache can be read from and written to

ROM is read-only

Secondary storage can be read from and written to

Can be directly accessed by the CPU

Cannot be directly accessed by the CPU

Smaller capacity

Larger capacity

Data access speeds faster than secondary storage

Data access speeds slower than primary storage

Stores data and instructions

Stores data and instructions

Virtual memory

  • The purpose of RAM is to store current data and program instructions in use

  • The amount of physical RAM available is limited. The average modern desktop computer has between 4GB  and 16GB of RAM. Some programs are larger than this

  • Virtual memory is part of secondary storage which acts as RAM when RAM is full

  • It prevents the computer system crashing when RAM is full

  • Data that needs to be accessed by the CPU directly is switched by the operating system from virtual memory into RAM and an inactive page from RAM replaces it in virtual memory. This is called page switching

Cloud Storage

  • Cloud storage is the concept of storing data on remote servers, that can be accessed via the internet, instead of on a local storage device (such as an SSD or HDD)

  • The physical servers, where the data is stored, are owned and managed by a hosting company

    • Cloud storage warehouses often have thousands of servers containing hard drives

    • The hosting company provides services such backing up the data, managing access to the data as well as general security

  • The data can be accessed at any time, on any device, as long as there is an internet connection

  • The data is accessible using a web browser or dedicated software that connects to the cloud storage service

  • There is potentially limitless storage, although it does need to be paid for

  • Online storage means it is easy to share data and collaborate with others

  • If the internet connection is slow/lost the access to your data is affected

Benefit

Explanation

Accessibility

  • Data can be accessed from anywhere

  • Data can be accessed by anyone with the relevant permissions, making it quick to share files and collaborate with others

  • Data can be accessed on any device with an internet connection

Scalability

  • Cloud storage providers allow customers to increase or decrease their storage capacity as needed

Reliability

  • Cloud storage providers often use multiple servers to store and backup data, reducing the risk of data loss due to hardware failure

Security

  • Cloud storage providers offer advanced security features, such as data encryption and multi-factor authentication multi-factor authentication, to protect user data from unauthorised access

  • There is no need to hire specialist staff as IT services being provided by the cloud storage provider

5 - The internet and its uses

(This part is very rough, and has not been finalized. Consider it a draft.)

5.1 - The internet and the world wide web

Internet - a very large global network between devices that allows users to access the world wide web

World Wide Web - the collection of all web pages and websites that can be access using the internet

infrastructure - the physical structures that are used to connect devices (such as all the components and cables)

network - devices that are joined together using cables or wireless technology

website - a collection of web pages, normally about a related topic or purpose

web page - a single page within a website


The three fundamental parts of WWW are:

  • HTML

  • URL

  • HTTP

5.2 - Requesting and retrieving web pages

uniform resource locator (URL): another name for the text-based address for a website.

web browser - a piece of software that retrieves and displays web pages.

There are 3 main components of a URL:

protocol - a set of rules for transmitting data

domain name - a specific part of a URL that contains the unique name for the web server

domain name server (DNS) - a special server containing a database of domain names and their corresponding IP addresses.

web server - a network component where the web pages for a website are stored.

The process of retrieving a webpage

is as follows:

  1. web browser contacts DNS requesting for webserver

  2. DNS searches for webserver in its own database

  3. if found, DNS sends webserver DNS to your browser. if not, it continues searching.

  4. browser contacts server and requests for webpage using http

  5. web server sends data of webpage along with HTML and scripts

  6. browser renders and displays webpage

active script - the script used to produce any interactive elements on webpage

cascading style sheet (CSS) - a scripting language used to create a presentation template for a web page, and it includes what kind of font and color text will appear on the webpage.

hypertext markup language (HTML) - a scripting (web authoring) language that is used to create web pages. (it is not a programming language)

hypertext transfer protocol (HTTP): a protocol that is used for transmission of web pages and related data across the internet.

Another protocol that can be used to request for the web pages is HTTPS.

Hyper Text Transfer Protocol Secure

This protocol has another layer of security that encrypts any data that is transferred.

It involves the use of digital certificates.

It is a certificate that the owner of the website need to apply for from a certificate authority.

hypertext transfer protocol secure (https) - a secure of version the HTTP that encrypts data for transmission.

encryption - a method of securing data for storage or transmission that scrambles it, making it meaningless. (this was covered in a previous chapter).

digital certificate - certificate awarded to a website if they can prove they are a real organization and take measures to securely transmit data.

certificate authority - the awarding organization that checks if an organization is real before awarding them a digital certificate.

Request for a webpage using HTTPS:

  1. The browser sends a request to web server asking for certificate.

  2. The web server sends a copy of certificate.

  3. The browser checks if it is authentic.

  4. If it is authentic, the browser continues communication and allows any data between the user and web server

  5. If the certificate is not authentic, the web browser will report that the website is not secure.

HTTPS is the standard HTTP protocol with an extra layer of security, that being either SSL (Secure Sockets Layer) or TLS (Transport Layer Security)

secure sockets layer (SSL) - a type of protocol that encrypts data for transmission. It is the protocol, that is combined with the HTTP to create HTTPS.

transport layer security (TLS) - an updated version of the SSL protocol.

The purpose of a web browser

A web browser is a software application that allows you to access information from the world wide web

The main purpose of a web browser is to render hypertext markup language (HTML) and display web pages

This is done by requesting the HTML and other aspects of the page to render the data so we can view the web pages.

Functions include:

  • storing bookmarks and favorites

  • recording user history

  • allowing use of multiple tabs

  • storing cookies

  • providing navigation tools

  • providing an address bar

Cookies store data so that you may regularly use on the internet so that you do not need to enter this data every time. Their main functions include:

  • Saving personal details

  • Tracking user preferences

  • Holding items in an online shopping cart

  • Storing login details

There are two types of cookies: session cookies and persistent cookies.

  • Session Cookies

    • These are temporary and are stored only during a user's browsing session

    • They are used to maintain a user's state or activity during a single session, such as when filling out a form or navigating through a website

  • Persistent Cookies

    • These are stored on a user's device for a longer period, usually for a few weeks to several years

    • They are used to remember user preferences and settings, such as language preferences, login details, and shopping cart items

Digital Currency

A digital currency is one that only exists electronically (E.G. bitcoin, ethereum). They are decentralized, meaning they are not controlled by an entity like the government. They are “owned” by the blockchain (please dont say this in your exam).

They are also volatile meaning their price could rise really fast then drop really low with no warning or expectation, making them risky investments and hard to store as a stable store of value.

Blockchain is a digital ledger that records every transaction made with a particular digital currency. Each transaction is time-stamped and added to the blockchain in a permanent and unalterable way. Blockchain is decentralized, it is not controlled by a single entity or authority.

Instead, every participant in the network has a copy of the ledger and can verify the transactions independently.

The blockchain is made up of "blocks" of transactions that are linked together in a "chain" using  cryptographic algorithms

This creates a secure and tamper-proof record of every transaction made with the digital currency. Just to make sure that no fraudulent activity takes place, each transaction must be verified by multiple participants in the network.

Cyber security

Cyber security threats and their aims

Brute-force attack

  • A trial-and-error method where it tries every possible combination of a password until the password is found

  • Their aim is to gain unauthorised access to a system or network

Data interception

  • Eavesdropping on communication channels to intercept and steal sensitive information like passwords or credit card numbers

  • Their aim is to steal sensitive information for personal gain or for more cybersecurity attacks

DDoS attack

  • A DDoS (distributed denial of service) attack uses multiple bots to flood servers with lots of requests at once which it cant handle so it crashes

  • Their aim is to disrupt the normal functioning of a system or network by denying users access

Hacking

  • Gaining unauthorised access to a system or network to steal data, disrupt services or cause damage.

  • The aims can vary from personal gain to activism

Malware

Malware is malicious software designed to harm or gain unauthorised access to a system or network. Types include:

  • A virus, a piece of code that attaches itself to a program or file then spreads to other files in the system when run, infecting the whole system. It causes damage like deleting data or damaging hardware.

  • A worm, similar but is a standalone program that spreads and replicates itself over computer networks. It takes up storage space or bandwidth

  • A trojan horse disguises itself as a safe program or file, but when installed it deletes data or damages hardware

  • Spyware records all key presses and transmits these to a third party (e.g. records keyboard presses when a user is entering their password)

  • Adware displays unwanted advertisements on the computer without the user’s consent, these ads can lead to more malware.

  • Ransomware encrypts user files and demands a payment to decrypt them. It can delete files or disrupt entire businesses

  • The aim of malware attacks can range from data theft to disruption of services

Phishing

  • User is sent an email that looks legitimate

  • Contains a link to a fake website where the user is encouraged to enter their details

  • The aim is to steal sensitive information for personal gain or to use it for further cyber attacks

Pharming

  • Malware is downloaded without the user’s knowledge

  • Redirects user to a fake website where they’re encouraged to enter their personal details

  • The aim of pharming is to steal sensitive information for personal gain or to use it for further cyber attacks

Social Engineering

  • Manipulating individuals into to gain access to confidential information or into performing an action that benefits the attacker

  • It can be done through many ways, here are some:

    • Instant Messaging : False update warnings (Curiosity)

    • Scareware : False virus warnings (Fear)

    • Emails : False emails which look genuine (Trust)

    • Baiting : Memory stick left publicly outside with malicious codes embedded (Curiosity)

    • Phone Calls : False warning calls (Fear)

  • The aim of social engineering is to exploit human behavior and vulnerabilities to gain unauthorized access to a system or network

Cyber security solutions

Access Levels

  • They are used to restrict access of sensitive information to only authorized users

  • Prevents unauthorized access, which is the main security threat to data

  • Access levels can be set based on a user's role, responsibility, or clearance level, examples:

    • Full access

    • Read-only access

    • No access

Anti-Malware

  • They are used to prevent and remove malware

  • This includes anti-spyware and anti-virus programs

  • It scans the computer files and any files being downloaded and compares them to a list of known malware

  • If malware is found, it is quarantined to prevent the spread. It is then deleted

Authentication

  • Used to ensure only authorized users have access to data

  • There are several ways of authentication such as:

    • Username-Password system, a strong password should be complex and not easily guessed and users should avoid using the same password for everything

    • Biometrics uses biological data like fingerprint, facial recognition or iris scans.

      • Can’t be guessed

      • Hard to fake

      • Can’t be recorded by spyware

      • Can’t be seen over a shoulder for example

    • Two-factor authentication or 2FA requires users to enter two forms of verification before accessing data, such as a password and a verification code sent by email or by SMS.

  • These methods help prevent unauthorized access and protect sensitive data

Automating software updates

  • Automating software updates ensures that software systems are up-to-date with the latest security patches, which helps to prevent security threats

  • It does this by scanning the internet for known new updates to software, if any are found the user is either notified or the update is automatically installed

Communications

  • Checking the spelling and tone of communications is important to prevent phishing attacks (i dont know why this is in the syllabus. is cambridge racist?)

URL

Firewall

  • Can be software-based or hardware-based

  • Monitors incoming and outgoing traffic between the computer and the network and keeps a log of the traffic

  • If the traffic matches a criteria it is allowed, if not it is denied

Privacy settings

  • Controls the amount of personal information shared online

  • Important measure to prevent identity theft

  • Users should regularly review privacy settings

Proxy-servers

  • Are used to hide user’s IP address making the user hard to track

  • Act as a firewall and can also filter web traffic by setting criteria for the traffic

  • Malicious content is blocked and the user is notified

  • Useful for protecting against external threats as it can direct traffic away from the user

Secure Socket Layer (SSL)

  • Security protocol which is used to encrypt data transmitted over the internet

  • Prevents eavesdropping and other forms of interception

  • Used to protect bank transactions

  • It works by sending a digital certificate to user’s web browser

  • Contains the public key which can be used for authentication

  • Once certificate is authenticated, transaction begins

6 - Automated and emerging technologies

Automated systems use sensors, a microprocessor and actuators.

  • Sensors detect changes as analogue data in an environment and convert them into electrical signals that can be processed by a microprocessor.

  • Microprocessors analyze signals from a sensor and make decisions based on pre-programmed logic.

  • Actuators receive signals from a microprocessor and perform actions such as opening a valve or turning on a motor

By combining these three, automated systems are created. These are systems that respond to changes in the environment without human intervention.

Here are some scenarios where they are used.

Scenario

Advantages

Disadvantages

Industry

  • Reduced labour costs

  • Improved efficiency and accuracy

  • Increased production rate

  • High initial investment

  • Limited flexibility to changes in production processes

  • Maintenance costs can be high

Transport

  • Improved safety and reliability

  • Reduced labour costs

  • Improved fuel efficiency

  • High initial investment

  • May not be suitable for all types of transportation

  • Maintenance costs can be high

Agriculture

  • Increased efficiency in planting and harvesting crops

  • Improved crop yield and quality

  • Reduced labour costs

  • High initial investment

  • May not be suitable for all types of crops or terrain

  • Maintenance costs can be high

Weather

  • Improved accuracy in weather prediction

  • Ability to issue warnings in a timely manner

  • Ability to collect large amounts of data quickly

  • May be affected by external factors like interference or equipment failure

  • May not be 100% accurate all the time

  • May require continuous monitoring and calibration

Gaming

  • Improved speed and efficiency in game development

  • Ability to create complex and interactive games

  • Reduced labour costs

  • May not be suitable for all types of games or game development

  • May require significant programming expertise

  • May be affected by technical glitches or bugs

Lighting

  • Improved energy efficiency

  • Ability to program lighting to suit different needs

  • Reduced labour costs

  • High initial investment

  • May not be suitable for all types of lighting needs

  • Maintenance costs can be high

Science

  • Improved speed and accuracy in data collection and analysis

  • Ability to carry out complex experiments

  • Reduced labour costs

  • High initial investment

  • May not be suitable for all types of experiments

  • May require significant technical expertise

These are the shared ones:

Advantages of automated systems

Disadvantages of automated systems

Faster

Expensive

Better success rate

Requires maintenance


Worked Example stolen from savemyexams

A theme park has a game where a player tries to run from the start to the finish without getting wet. The system for the game uses sensors and a microprocessor to spray water at a player as they run past each sensor. Describe how the sensors and the microprocessor are used in this system.

[8]

  • A motion sensor collects analogue data [1]

  • This data is converted to digital using ADC [1]

  • The sensor sends data to the microprocessor [1]

  • where the data is compared to stored data [1]

  • If the value is outside range water will be sprayed [1]

  • A signal is sent to the actuator to spray water [1]

  • If the value is within range no action is taken [1]

  • This runs in a continuous loop [1]

Robotics

Robotics refers to an area of computer science that deals with the creation, design, and operation of robots.

It involves the design and creation of robots for various applications. They are designed using a combination of mechanical, electrical and computer engineering

Examples are:

  • Factory equipment

  • Domestic robots

  • Delivery drones

Characteristics of robots

  • They have a mechanical structure or framework

  • They have electrical components such as sensors, processors and actuators.

  • They are programmable.

Where they can be used

Robots can be used in many areas such as:

  • Medicine

  • Agriculture

  • Domestic

  • Construction

  • Industry

  • Transport

Advantages

Disadvantages

Increased productivity: robots can work continuously without breaks or fatigue

High initial investment: purchasing and setting up robots can be expensive

Consistency and accuracy: robots can perform tasks with a high level of precision and accuracy

Maintenance costs: robots require regular maintenance and repairs, which can add to the overall cost.

Safety: robots can perform tasks that are dangerous or hazardous for humans

Lack of flexibility: robots are programmed for specific tasks and cannot adapt easily to new situations or tasks.

Cost-effective: robots can help reduce labor costs in the long run

Unemployment: increased use of robots can lead to job loss in certain industries.

AI

AI is a branch of Computer Science dealing with the simulation of intelligent behaviors by computers.

Characteristics of AI

The characteristics of AI are:

  • Collection of data and rules

  • The ability to reason

  • The ability to learn and adapt

Types of AI systems

There are two main types of AI systems:

Expert systems

  • Have a knowledge base

    • A database of facts to generate rules. These rules are used to make decisions and solve problems.

  • Have a rule base

    • A set of rules that is used to apply the knowledge in the knowledge base to specific problems.

  • Have an inference engine

    • A program that applies the rules in the rule base to the facts in the knowledge base to solve problems

  • Have an interface

    • A way for users to interact with the system and provide input

Machine learning

  • This type of AI system has the ability to automatically adapt its own processes and data.

  • It uses algorithms to analyze data and identify patterns

  • The system can learn from the data and improve its performance over time.

Computer Science

1 - Data representation

1.1 - Binary and hexadecimal

Humans process data called analogue data. It is a continuous stream of data to our senses.

The data-processing parts of a computer are made up of small logic gates, which cannot process analogue data. These gates can only process digital data, which is stored in registers. Digital data (also called binary data) only has 2 values, 1 and 0.


Number systems

Everyday we use the denary number system. It is called a base-10 system as it only has 10 digits (0-9). The units in a denary system are ones, tens, hundreds, thousands, etc. Each time a unit goes up it increases by the power of 10.

Computers use the binary number system. It is called a base-2 number system as it has 2 digits (0 and 1). Each time the unit goes up, it increases by the power of 2.

Denary values must be converted to binary values to be processed by a computer.


Use the book (page 11) to learn how to convert denary to binary.


Use the book (page 13) to learn how to convert binary to denary.


Hexadecimal (or hex in short) is a number system that can be used by humans but cannot be processed by computers. It must first be converted to binary. Hex is a base-16 system as it uses 16 symbols, 0-9 and A-F. This allows the denary values 0-15 to be represented. t

The symbols A-F are used instead of 10-15 so only one symbol is needed for the characters.


Use the book (page 14) to learn how to convert binary to hexadecimal.


Use the book (page 15) to learn how to convert hexadecimal to binary.


The benefits of using hexadecimal rather than binary

  • Hexadecimal is a shorter way of representing binary, taking up less space on the screen.

  • Hexadecimal is easier to read, write and understand.

  • Hexadecimal makes it easier to debug and locate errors in data.


1.2 - Binary manipulation and negative numbers

Adding binary numbers

Adding binary numbers has rules.

  • 0+0=0

  • 1+0=1

  • 1+1=10

  • 1+1+1=11


Use the book (page 17) to learn how to add binary numbers in detail.


An overflow error may occur when adding binary numbers. This is when a number is generated that is larger than the maximum amount for a register. Each computer has a predefined limit, for example 16-bit registers. If a number larger than the maximum is generated in a process, an overflow error will occur causing the wrong number to be displayed.


Logical binary shifts (multiplication and division)

Another process that can occur is called a logical binary shift. This shift can move the binary values left or right, multiplying or dividing them. This will result in the left-most or right-most digit will be removed from the register, and a new 0 will be added in the left-most or right-most sections.

Each logical shift to the left multiplies the entire number by 2.

Each logical shift to the right divides the entire number by 2.


Use the book (page 19) to learn how to perform logical binary shifts in detail.


Negative binary numbers

Negative numbers can be represented in binary, however there is no “-” symbol in binary so a method exists called two’s complement.

This method is very simple. First, flip all the numbers (1s becomes 0s and 0s becomes 1s), then add 1 to the result (using the binary addition method)


Use the book (page 20) to learn how to use two’s complement in detail with an example.


1.3 - Representing text, images and sound

Text, images and sounds also have to be converted to binary before a computer can process them.


Converting text to binary

To convert text to binary a tool called a character set has to used. There are two main types of character sets, ASCII and Unicode.

ASCII represents characters using 8-bit binary numbers, meaning it can represent up to 256 characters (0-255). Some languages require more than 256 characters, so Unicode was invented, which can represent characters using 16-bit binary numbers, meaning it can represent up to 65536 characters. Many more characters can be developed in different alphabets and also symbols such as emojis can be used.


Converting images to binary

Images are made up of tiny dots called pixels. Each pixel has a color which can be represented with a binary value. If an image only had black and white, each pixel would be either black or white. The binary value 1 could represent white and 0 could represent black.

If each pixel is converted to its binary value, the data could look like:

0011111100010000101000001001001100001000001000101

The image file will also contain metadata. Metadata is additional data stored with the image that can provide extra information such as the resolution, date taken, and name of the image.

Images use the RGB system that mixes the colors red, green and blue to create each color. The RGB system uses hexadecimal.

Each image has a resolution and color depth (sometimes also known as bit depth). The resolution is the number of pixels wide and high that have to be used to create the image. The color depth is the number of bits that are used to represent each color. This cool table could help.

Color depth

Numbers of colors that can be represented

1

2

2

4

3

8

4

16

5

32

You should notice a pattern. The numbers of colors that can be represented is 2^color depth.

If the resolution of an image is increased, the image will be created using more pixels, so the size will increase.

If the color depth of the image is increased, each pixel will need more data to store each color so the size will increase.


Converting sound to binary

Sound is made up of sound waves. When sound is recorded, this is done at set time intervals (at a set pattern.) This process is known as sound sampling.


Use the book (page 24) to refer to the images soon to be mentioned.


Figure 1.4 in the book is an example of a sound wave.

Recording the sound at each time sample would grant the following set of sound values (look at the table).

Each sound value is converted to binary to be processed by the computer.

Figure 1.5 is a recording of the sound in figure 1.4, yet they look different. This is because the number of samples taken is too far apart, and sounds in between each sample were lost. Therefore, the sample rate (or sample frequency) needs to be increased. This is the number of samples taken in a second (measured in hertz). Sounds also require sample resolution. This is the number of bits that are used to represent each sample. The higher the sample resolution, the more accurate each sample/sound will be.


1.4 - Measuring data storage

Data is measured using different units.

Unit

Description

Bit

Smallest measurement for data

Nibble

4 bits in a nibble

Byte

8 bits in a byte

Kibibyte (KiB)

1024 bytes in a kibibyte

Mebibytes (MiB)

1024 kibibytes in a mebibyte

Gibibyte (GiB)

1024 mebibytes in a gibibyte

Tebibyte (TiB)

1024 gibibytes in a tebibyte

Pebibyte (PiB)

1024 tebibytes in a pebibyte

Exbibyte (EiB)

1024 pebibytes in an exbibyte


Calculating the size of a file

For image files, you need to know:

  • the number of images in the file

  • the resolution of the image

  • the color depth of the image

After that, the calculation is

width of image x height of image x color depth of image x number of images in file

Which can be simplified into:

resolution of image × color depth × number of images


For sound files, you need to know:

  • the length of the soundtrack

  • the sample rate of the soundtrack

  • the sample resolution of the soundtrack

After that, the calculation is:

sample rate × sample resolution × length of soundtrack


1.5 - Data compression

Compression is reducing the size of a file.

Benefits of compressing a file:

  • Not as much storage space is needed

  • Moving the file will take less time

  • It will be quicker to upload and download the file

  • Less bandwidth needed to transmit the file over the internet

There are two types of compression, lossy and lossless.

Lossy compression uses a compression algorithm that finds and removes unnecessary data in the file, such as colors that the human eye cannot distinguish or sounds the human ear cannot hear. It could also remove softer sounds that are played at the same time as louder sounds, as humans will only hear the louder sound. This is called perceptual music shaping. The size of a sound file can also be reduced by reducing sample rate and sample resolution. For images, it could reduce the color depth or reduce the image resolution.

Lossless compression uses a compression algorithm to reduce the size of the file without permanently removing any data. A common method that can be used is by finding repeating data and grouping it together.


Use the book (page 28) for a good example of lossless compression.


A similar process can be used for image files with a lossless compression algorithm called run length encoding (RLE). It will group together repeating pixels and store how many times they occur.


Use the book (page 29) for a good example of RLE.


2 - Data transmission

Data packets

Information over the internet is broke down into packets and these are created by TCP and transmitted over the internet. To define, a packet is a small chunk of information/data.

TCP stands for Transmission Control Protocol and it is used for organizing data transmission over networks.

When transferring data, it is easier to route small chunks of data than large ones. Routing is the process of finding the most optimal path over a network.

Structure of a packet

A packet contains:

  • Destination IP

  • Source IP

  • Data payload, the message

Packet is made up of:

  • Packet header

  • Payload (the actual data)

  • Trailer

The packet header contains:

  • Source IP

  • Destination IP

  • Packet number

  • Error checkers (e.g. parity bits and checksums)

The packet trailer contains:

  • Additional error checks

  • End of packet notification

Packet switching

Sending packets over the internet is called packet switching. It is more efficient than circuit switching.

Packet switching involves:

  • Data is broken down into packets

  • Each packet could take a different route

  • A router controls the route a packet takes

  • Packets may arrive out of order

  • Once the last packet has arrived, packets are reordered

Wired transmission

Methods of data transmission:

  • Serial

    • One bit is sent at a time through a single wire.

  • Parallel

    • Multiple bits are sent at a time across several wires.

    • Data will be skewed (i.e. bits will arrive in the wrong order as each wire will transmit at a slightly different speed)

      • This is called asynchronous transmission, meaning data will not always arrive at the same time.

  • Simplex

    • Simplex transmissions are unidirectional and travel only in one direction.

  • Half-duplex

    • Half-duplex transmissions are bidirectional. They can travel in both directions, but not at the same time.

  • Duplex

    • Duplex transmissions are bidirectional, and data can travel at the same time.

It is a mixture of the two groups of methods that forms what final method the transmission will use.

Simplex

Half-duplex

Full-duplex

Serial

Serial-Simplex

Data is transmitted one bit at a time in a single direction on one wire

Serial-Half-duplex

Data can be transmitted in both directions on a single wire but only one bit at a time can be transmitted in one direction at a time

Serial-Full-duplex

Data can be transmitted in both directions at the same time on a single wire one bit at a time 

Parallel

Parallel-Simplex

Multiple wires transmit one bit at a time in one direction

Parallel-Half-duplex

Multiple wires send multiple bits of data in both directions but only one direction at a time

Parallel-Full-duplex

Multiple wires send multiple bits of data in both directions at the same time



Advantages


Disadvantages

Serial

-The data will arrive in the order it is sent

-It is less likely to have errors

-Serial transmission is cheap over short and long distances as the cost of wire is fairly inexpensive

-Data transmission is slow, especially over long distances as only small quantities of data can be transmitted at a time

-Serial transmission is expensive over very long distances as the cost of wire dramatically increases

Parallel

-Parallel transmission is fast as large quantities of data can be transmitted at any one time

-Parallel transmission is expensive over short distances as multiple wires need to be purchased. -Transmission is very expensive over long distances as the cost of wires dramatically increases with the distance

-Delays can be caused if data arrives asynchronously as the receiver has to wait for all of the bits before accepting new data. This is especially true over longer distances

-Buffers may be used to store data temporarily while waiting for all bits to arrive

Simplex

-Simplex wires are cheap as only one wire is used

-Data transmission is slow as data still travels one bit at a time in only one direction at a time

-Simplex transmission requires two sets of wires for bidirectional transmission meaning it can become expensive

Half-duplex

-Half-duplex transmission is cheaper than simplex for bidirectional transmission as it requires fewer wires

Transmission is still slow as data travels one bit at a time in only one direction at a time

Full-duplex

-Full-duplex transmission is faster as data can travel in both directions simultaneously. The receiver does not have to wait for the sender to stop before they can start transmitting their data

-Full-duplex is expensive as the wire technology to transmit in both directions is more difficult to implement

Example scenarios of using each

It will come up in the exam:

  • Serial

    • Connecting an external hard drive to a computer

    • Transmitting data over a telephone line

  • Parallel

    • Transmitting data from a computer to a printer using a multi-wire connector

  • Simplex

    • Transmitting data from a computer to a printer. The printer doesn’t need to send data back to the computer

      • Modern versions of devices such as printers may send acknowledgement signals to confirm they have received the data. This may require half-duplex rather than simplex connections

  • Half-duplex

    • Phone conversations where only one person needs to speak at a time

    • A walkie-talkie is a two way radio with a push to speak button. The receiver is turned off while the transmitter is turned on. This prevents you from hearing the other person while you speak

  • Full-duplex

    • Broadband connections to the internet. Data must be sent and received at the same time. Accessing information on the internet is known as downloading information. Putting information onto the internet for others to access is known as uploading

    • Phone conversations where both people can talk and be heard at the same time allowing them to interrupt each other

USB

USB stands for Universal Serial Bus. As the name suggests, it uses serial transmission. Many devices such as phones, printers, and video cameras use USB.

Different USB connectors exist for different devices:

  • USB-A (flash drives, mice, keyboards, external HDD, etc)

  • USB-B (printers, scanners, optical drives, floppy drives, etc)

  • USB-C

USB-C is become the new industry standard as it is very small and fast.

When a device is connected to a USB port, the computer:

Automatically detects that the device has been connected

Automatically recognizes the device and the appropriate device driver is loaded so the device can communicate with the computer.

If the device is new, the computer will look for a matching device driver. If one cannot be found then the user must download and install an appropriate driver manually.

Advantages

Disadvantages

Devices are automatically detected and drivers are automatically loaded for communication. This simplifies the data transmission process for the user

The maximum cable length is roughly 5 metres meaning it cannot be used over long distances, limiting its use

Cable connectors fit in only one way. This prevents incorrect connections and ensures compatible data transmission

Older versions of USB have limited transmission rates for example USB 2.0 has 480Mbps

As USB usage is standardised, there is a lot of support available online and from retailers

Very old USB standards may not be supported in the near future (USB 1.1, USB 2.0, etc)

Several different data transmission rates are supported. The newest transmission rate as of 2022 is USB4 2.0 with 80 Gbps (81,920 Mbps, 170x faster than USB 2.0)

 

Newer USB standards are backwards compatible with older USB standards

 

Error checking

Why check for errors?

Computers expect data in certain formats

  • A format is a way of arranging the data so that it can be easily understood by people and by computers

  • People agree to certain formats so that systems work more efficiently and there is little chance of misunderstanding each other

  • An example of a format is date and time, DD/MM/YY vs MM/DD/YYYY

An error or corruption occurs when data received is not as expected and therefore is difficult or impossible to process, such as if the wrong format is used

  • For example, take the value 00100001. If the second most significant bit is swapped, it will be 01100001. This means that the value has changed and in certain situations like space coordinates or bank transfers one number or bit changing is a HUGE deal.

  • If many bits were flipped, the text or original data would be completely unreadable.

  • This means that any job that relies on computers performing highly sensitive data transfers must have methods of error checking.

How do errors occur?

  • They can occur due to interference

    • Examples of this are wire degradation or electrical fields changing the signal.

  • Results of this can include:

    • Data loss - data is lost in transmission

    • Data gain - additional data is received

    • Data change - some bits have been changed or flipped.

  • Wireless technology uses radio signals or other electromagnetic signals to transmit data.

  • Bad weather or physical barriers like walls can stop the correct transmission of this data.

Parity check

  • The parity checking protocol determines whether bits in a transmission have been corrupted

  • Every byte transmitted has one of its bits allocated as a parity bit

  • The sender and receiver must agree before transmission whether they are using odd or even parity

  • If odd parity is used then there must be an odd number of 1’s in the byte, including the parity bit

  • If even parity is used then there must be an even number of 1’s in the byte, including the parity bit

  • The value of the parity bit is determined by counting the number of 1’s in the byte, including the parity bit

  • If the number of 1’s does not match the agreed parity then an error has occurred

  • Parity checks only check that an error has occurred, they do not reveal where the error(s) occurred

Even parity

  • Below is an arbitrary binary string

EVEN
Parity bit

Byte

0

1

0

1

1

0

1

0

  • If an even parity bit is used then all bits in the byte, including the parity bit, must add up to an even number

    • There are four 1’s in the byte. This means the parity bit must be 0 otherwise the whole byte, including the parity bit, would add up to five which is an odd number

    • Else, an error has occurred

Odd parity

  • Below is an arbitrary binary string

ODD
Parity bit

Byte

1

1

0

1

1

0

1

0

  • If an odd parity bit is used then all bits in the byte, including the parity bit, must add up to an odd number

    • There are four 1’s in the byte. This means the parity bit must be a 1 otherwise the whole byte, including the parity bit, would add up to four which is an even number

    • Else, an error has occurred

How errors occur

When using parity bits, error occurs when the of total bits does not match the agreed parity

This can be due to bits flipping or changing due to interference on a wire.

Parity bytes and parity blocks

Parity checks have a problem, and it’s that they don’t pinpoint where the error actually is in the byte

Parity blocks and parity bytes can be used to check an error has occurred and where the error is located.

The table above uses odd parity. Each byte row calculates the horizontal bit parity as normal

Each bit column calculates the vertical parity for each row. This is the parity byte. It is calculated before transmission and is sent with the parity block.

Each parity bit calculates if a flip error occurred in a byte row, while the parity byte calculates if a flip error occurred in a bit column.

Cross referencing these two can give you the exact incorrect bit.

In the table above, we can see that byte 3/bit cell 5 is an error and should be 0 instead.

The error could either be auto-fixed or retransmission could be requested from the sender

Checksums

  • Checksums determine if data has been corrupted but do not reveal where

  • Data is sent in blocks and an additional checksum value is added at the end of the block

  • Checksums are custom user-created algorithms that perform mathematical calculations on data

  • An example of a custom checksum algorithm in computer science is:

    • A checksum byte is defined as a value between 1 and 255 which is stored in 8 bits. 8 bits are collectively known as a byte

    • If the sum of all of the bytes of a transmitted block of data is <= 255 then the checksum value is the sum of all of the bytes

    • If the sum of all of the bytes is > 255 then the checksum is calculated with an algorithm:

      • X = sum of all of the bytes

      • Y = X / 256

      • Round down Y to nearest whole number

      • Z = Y * 256

      • Checksum = X - Z

Custom Checksum Walkthrough

  • If X = 1496

    • Y = 1496 / 256 = 5.84

    • Rounded down Y = 5

    • Z = 5 * 256 = 1280

    • Checksum = 1496 - 1280 = 216

    • The checksum value in this example would be 216

When a block of data is transmitted, the checksum value is calculated then transmitted with the rest of the data

When the data is received the checksum value is calculated based on the received data and compared to the checksum value received. If they are the same then

Echo check

  • Transmitting the received data back to the sender. Sender checks the data to see if any errors occurred during transmission

  • Not reliable as an error could have occurred when the sender transmits the data or when the receiver transmits the data. Neither will know when the error occurred.

  • If an error does occur the sender will retransmit the data

Automatic Repeat Request (ARQ)

  • When the receiver receives transmitted data it must check for the presence of any errors. Errors can usually be detected but not always pinpointed

  • An Automatic Repeat Request is a protocol that notifies the sender that an error has occurred and that the data received is incorrect. It works as follows:

    • If an error is detected the receiver sends a negative acknowledgement transmission to indicate the data is corrupted

    • If no error is detected the receiver sends a positive acknowledgement transmission meaning the data is correct

    • If the receiver does not send any acknowledgement transmission then the sender waits for a certain time period known as a time-out before automatically resending the data

    • This process is repeated until all data has been received and acknowledged

3 - Hardware

The CPU processes instructions and data that are input into the computer so that the result can be output

  • A microprocessor is a type of integrated circuit on a single chip

Components of CPU

The CPU has two main components - the Control Unit (CU) and the Arithmetic Logic Unit (ALU)

  • The Control Unit controls the flow of data around the CPU

  • The Control Unit also sends control signals to the different components instructing them what to do e.g. read, write, add, subtract

  • The Control Unit decodes instructions (into an opcode [action to be done] and operand [what object to do the action on]

  • The Control Unit controls the timings of operations (the clock speed) 

  • The Arithmetic Logic Unit (ALU) performs the calculations required to execute the instructions, these include ADD and SUBTRACT

  • The ALU also carries out logical operations such as COMPARE

  • The ALU has a built-in register where it stores interim results of calculations

Registers

The CPU also has a bunch of registers with specific functions in executing instructions

Special purpose register

Definition

Program Counter (PC)

stores the address of the next instruction to be fetched from memory

Memory Address Registers (MAR)

stores the address of the instruction or data to be fetched from or written to memory

Memory Data Register (MDR)

  • stores the data that has been fetched from memory or being written to memory

  • Data from MDR is sent to ALU to be executed

Current Instruction Register (CIR)

stores the instruction the CPU is currently decoding or executing

Accumulator

Temporarily stores the results of the calculations performed by the arithmetic and logic unit

Buses

They are wires down which electrical signals and data travel. They are collected called the system bus.

  • Data bus transmits data CPU to/from memory or input/output controllers. It travels in both directions, it is bidirectional.

  • Address bus transmits addresses from CPU to memory. It is unidirectional.

  • Control bus transfers control signals from the CU to other components of the computer such as memory or input/output controllers. It is bidirectional.

That diagram shows visually how everything travels.

Step

Detailed Explanation

Fetch

  • The memory address of the instruction to be fetched is stored in the Memory Address Register and is sent down the address bus. 

  • The data/instruction at the memory address is transferred back to the CPU, via the data bus, where it is stored in the Memory Data Register

  • The instruction is copied into the Current Instruction Register and the Program Counter increments

Decode

  • The instruction in the Current Instruction Register is decoded, by the Control unit, into an opcode and an operand

Execute

  • The instruction is executed by the Arithmetic Logic Unit and the opcode is performed upon the operand. 

  • The result is stored in the accumulator or written to a memory location within memory

Performance of a CPU

  • The more cores a computer has the more instructions that can be executed per second resulting in better performance (dual-core, quad-core)

  • The higher the clock speed, the more instructions can be performed in a second. 1Hz = 1 instruction, 1KHz = 1000, 1MHz = 1,000,000 and 1GHz = 1,000,000,000 (billion)

    • So 3.4GHz core can run 3,400,000,000 (3.4bil) instructions per second

  • Cache is a small amount of memory close to the CPU that stores frequently used information. It can be accessed VERY fast, so the more cache size the better performance of CPU as more quickly accessible things can be stored in the cache

Instruction sets

An instruction set is a list of all the commands that can be processed by a CPU and the commands are machine code, example add, subtract, load, etc.

Embedded system

An embedded system is used to perform a dedicated function, e.g. domestic appliances, cars, security systems, lighting systems or vending machines. This is different to a general purpose computer that is used to perform many different functions, e.g. a personal computer (PC) or a laptop.

  • It runs on firmware.

Type of embedded system

Description

Microcontrollers

Integrated circuit containing a CPU and memory (RAM or ROM) built in to the same chip

Microprocessor

Integrated circuit containing only a CPU on the chip

RAM , ROM , peripherals need to be added if required

Examples of embedded systems:

Embedded system

Possible input devices

Possible Output

Digital clock

Buttons to set the time/mode/alarm

Screen showing the time

Alarm

Traffic Lights

Pedestrian button

Timer

Movement sensor

Lights

Lighting system

Movement sensor

Lights

Security system

Keypad to enter alarm code

Camera

Movement sensor

Alarm

Vending machine

Keypad to make choice

Actuator controlling movement of choice

Central Heating system

Keypad to set temperature

Temperature sensor

Heat

Advantages of an embedded system:

  • low power consumption

  • small physical size

  • low cost to manufacturer

  • they can be controlled remotely

  • can operate in real time and respond to inputs very quickly

Input devices

Barcodes

  • Barcodes are a series of black and white bars which represent a code

  • A barcode reader shines a red laser at the barcode to read the data it represents

  • The light from the white lines is reflected back

  • Black lines absorb the light so less is reflected

  • Converts difference of reflection into binary value

  • Benefits:

    • Faster checkouts

    • Automated stock control

    • Less chance of error due to manual entry

    • More detailed tracking info

Digital camera

  • Captures light and converts to digital image

  • They are integrated into phones

  • They instantly create image

  • This image can be edited or have a filter applied to it or reduplicated many times and shared

Keyboard

  • Text-based data input

  • Built into laptops

  • Phones have digital keyboards

  • Each key makes contact with a peg that makes contact with a membrane. This is then converted into an electrical signal

Microphone

  • Converts sound waves into electrical signals that can be processed by the computer

  • Can be used to record music, telephone calls, communicate online and dictation.

Optical mouse

  • A mouse uses a laser to detect and track movement, then processed by microprocessor

  • Can be wired or wireless

  • Simple and intuitive to use

  • Reliable as there are no moving parts

QR code

  • Visual representation of data using black and white squares

  • Can represent over 7000 digits whereas a barcode represents up to 30 digits

  • Scanned by a camera (often on a mobile device)

  • A piece of software convert the squares into binary data

  • QR codes often link to a website where more information can be found

  • They can also be used to advertise products, share contact details, provide promotional codes, train tickets, and event tickets

    • However they can often have malware

Touchscreen

  • A touchscreen can be classed as both an input device and an output device


Type


How it works


Benefits/Drawbacks


Uses

Resistive screen

Resistive screens consist of two conductive layers. The top layer is flexible. When the screen is touched the two layer connect, completing a circuit

+ Cheap to produce. 

+ Resistant to surface  contaminants

+ Can be activated with nearly every object (stylus, finger, gloved hand)

Used in cash machines, information kiosks, medical equipment

Infra-red screens

LEDs shine infrared light across a screen forming a matrix. When the screen is touched the beams are interrupted

+ Excellent image quality

+ high precision 

+ durable

+ allows for multiple touches at the same time

- Requires a bare finger or stylus for activation

Tablets, laptops, smartphones

Capacitive screens

Made up of a protective layer, a transparent conductive layer and a glass substrate. Touching the screen changes the electrostatic field of the conductive layer

+Excellent image quality

+Unlimited touch-life

+Scale well

- Sensitive to interference from light, water, snow

Large scale commercial displays

Information kiosks

Medical equipment

2D and 3D scanners

  • A two-dimensional (or flat-bed) scanner shines a strip of light over a document. Reflected light is measured for each pixel. This data is converted into binary data so the document can be digitally recreated

  • A three- dimensional laser scanner shines a light over an object. The geometry and dimensions are recorded so the object can be recreated digitally

  • 2D scanners can be used for creating digital versions of documents or photographs

  • Reading passports at airports

  • Typical uses of 3D scanners and printers are dentistry, product development, medical

  • A cheap and quick way of creating a digital representation of both 2D and 3D objects so they can be manipulated, stored, transmitted or copied

Summary

Device

Example Uses

Benefits 

Barcode scanner

Checkouts, parcel delivery

Faster checkout, less errors, detailed stock/tracking information

QR code scanner

Advertising products, linking to websites, e-tickets

Can hold more information than a barcode

Can be scanned using a camera on a mobile device (smartphone)

2D and 3D scanners

Scan documents, photos and objects

Converts 2D and 3D objects into digital data which is easier and quicker to transmit/duplicate or manipulate

Digital camera

Smartphones, professional photography, security systems

Instant preview and image

Keyboard

Entering text 

Universal, easy to use

Mouse

Navigating a GUI

Making selections and entering commands

Intuitive

Microphone

Recording real-world sound

Musical recordings

Telephone calls

Dictation

 

Touchscreen

Entering text and commands on mobile devices (tablet, smartphone)

Cash machines

Interactive advertisements

Information screens

Can be durable

Good image quality

Intuitive/easy to use

Output devices

Shows results of processing

Actuator

Used with a motor to translate energy into real-world movement of a physical object

  • Examples of use include turning a wheel, opening or closing a door, controlling a conveyer belt, operating machinery, moving robotic arms, vibrating a machine, starting or stopping a pump, opening or closing a valve

They are often used with sensors

Light projectors

Projects computer outputs onto a large screen.

  • Gives presentations in education and business settings

There are two types, DLP and LCD

  • DLP systems use millions of micro mirrors in a grid on a microprocessor within the projector. Light is shone through color filters and the mirrors. The position of the mirrors can be altered to change the positioning of the light

  • LCD projectors use three mirror filters to separate an image into red, green and blue wavelengths. They are then combined to produce the full image which is passed through the lens onto the wall/screen.

Device

Advantages

Disadvantages

Digital light projector (DLP)

Higher contrast ratios. 

Smooth video

Image tends to suffer from “shadows” when showing a moving image

Higher reliability

DLP do not have grey components in the image

Smaller and lighter

The color definition is not as good as LCD projectors

Better suited to dusty atmospheres than LCD projectors

LCD projector


 

Give a sharper image than DLP projectors

Contrast ratios are not as good as DLPs

Better colour saturation and intensity than DLP projectors

Have a limited life

Use less power and generate less heat

LCD panels degrade over time.

Quieter running that DLP

 

Laser and Inkjet printers

Both create hard copies of a digital document, good for when you don’t have an electronic device on you.

Inkjet printers

  • Have a print head which moves across the page

  • Spray liquid ink droplets from ink cartridges through very fine nozzles onto the paper.

  • The droplets can be piezoelectric or thermal bubble technology

  • Inkjet printers produce high quality hard copies of digital documents/images

Laser printers

  • Very fast at printing when making multiple copies

  • Useful for printing high volume jobs like leaflets

  • Low running cost per page

  • Have large toner (dry version of ink) cartridges and large paper trays

  • Use positive and negative charges to make the toner particles stick to piece of paper, heat is then used to bond the particles to the paper

3D printers

  • Create 3D models of a digital model by depositing layers of material, such as plastic or resin, on top of one another to slowly build up a 3D object

  • Allow for precision and can be used in medicine to create prosthetics and blood vessels

  • Can be used to create rapid prototypes

  • Models can be transmitted digitally and then models printed out all across the world

LCD screens

  • Liquid Crystal Display screens are made up of millions of tiny liquid crystals making up pixels arranged in a matrix

  • Requires backlighting

  • Used for TVs, monitors, phones, tables

  • Low power consumption, run at a low temperature

  • Do not suffer from image burn

  • Give bright images and colors

  • Cheaper to produce than LED screens

LED screens

  • Light Emitting Diode screens are made up of tiny LEDs

  • No backlighting needed, much lighter and thinner

  • They are replacing LCD in modern times

  • Better image quality, longer life span

  • Consume very very little power

  • Can be used to create VERY large screens like in football matches and festivals

Speakers

  • Speakers are used to take digital sounds or recordings and output them as sound waves which can be heard by humans

  • The digital data is changed into a electric current using a digital to analogue converter (DAC)

  • It is then passed through an amplifier to create a current large enough to drive a loudspeaker

  • The loudspeaker converts the current into a sound wave

  • Typical uses include listening to music, listening to video sound, telephone calls and alarms

Sensor type

What it measures

Typical use

Acoustic

Sound levels

To detect changes in sound levels of industrial machinery

To monitor noise pollution

In security system to detect suspicious sounds

Accelerometer

Acceleration rate, tilt, vibration

Detecting sudden changes in vehicle movement and deploy safety features if needed

In mobile phones to detect orientation of the device

Flow

Rate of gas, liquid or powder flow

Detect changes in the flow through pipes in water system

Gas

Presence of a gas e.g. carbon monoxide

Detect levels of gas in confined spaces

Detect gas levels when fixing gas leaks

Humidity

Levels of water vapour

Monitor humidity in greenhouses

Infra-red

Detecting motion or a heat source

Security systems detecting intruders who break the beam

Measures heat radiation of objects - used by emergency services to detect people

Level

Liquid levels

Detects levels of petrol in a car tank

Detect levels of water in a water tank

Detect a drop in water levels due to a leak

Light

Light levels

Automatically switching on lights when it gets dark (street lights, headlights)

Magnetic field

Presence and strength

Anti-lock braking system

Monitoring rotating machinery such as turbines

Moisture

Presence and levels of moisture

Monitoring moisture in soil

Monitoring damp in buildings

pH

Acidity or alkaline

Monitoring soil to ensure optimum growing conditions

Monitor pHlevels in chemical processes

Pressure

Gas, liquid or physical pressure

Monitoring tyre pressure

Monitoring pressure in pipes during manufacturing process

Proximity

Distance

Monitoring position of objects in robotics

Used in safety systems to prevent objects colliding

Temperature

Temperature in Celsius, Fahrenheit or Kelvin

Used to maintain temperature in swimming pools

Used to control temperature in chemical processes

Storage

Primary storage

Primary storage is directly accessed by the CPU. Examples include RAM and ROM

RAM

  • The purpose of RAM (random access memory) is store data, instructions, and software currently in use

  • It is also called main memory

  • Faster read-write speeds than secondary storage as it is closer to CPU

  • Volatile, meaning it is temporary and data will be lost

ROM

  • The role of Read-only memory (ROM) is to store the computer’s boot-up sequence

    • The boot-up sequence is a set of instructions the computer executes when then computer is initially switched on

    • This sequence will run a series of checks to ensure all of the system hardware is working

    • It will then load the operating system which will move from secondary storage to RAM

  • ROM is non-volatile which means data will be stored when the computer is switched off

  • ROM is read-only which means data cannot be written to ROM

RAM

ROM

Volatile

Non-volatile

Can read and write data to RAM

Read-only

Secondary storage

Secondary storage cannot be directly accessed by the CPU. Examples include HDD and SSD

Types

  • Magnetic

  • Solid state

  • Optical

Magnetic

  • High power consumption

  • Relatively slow read/write speeds

  • Unreliable as has moving parts

  • A magnetic hard disk is made up of several metal discs coated with a magnetic material

    • These are called platters

    • Iron particles on each platter are magnetised to represent a 0 or 1

Solid state

Uses NAND and NOR gates to persistently control flow of electrons. Current flowing = 1, no current flowing = 0

  • Low power consumption

  • Fast read/write speeds

  • Reliable and has no moving parts

Optical

Optical devices include CDs, DVDs and Blu-rays

  • All optical devices work by shining a laser at the disk and processing the reflection

  • An arm moves the laser across the surface of the disk

Comparing the two types of storage so far:

Primary storage

Secondary storage

Volatile / temporary

Non-volatile /permanent

RAM and cache can be read from and written to

ROM is read-only

Secondary storage can be read from and written to

Can be directly accessed by the CPU

Cannot be directly accessed by the CPU

Smaller capacity

Larger capacity

Data access speeds faster than secondary storage

Data access speeds slower than primary storage

Stores data and instructions

Stores data and instructions

Virtual memory

  • The purpose of RAM is to store current data and program instructions in use

  • The amount of physical RAM available is limited. The average modern desktop computer has between 4GB  and 16GB of RAM. Some programs are larger than this

  • Virtual memory is part of secondary storage which acts as RAM when RAM is full

  • It prevents the computer system crashing when RAM is full

  • Data that needs to be accessed by the CPU directly is switched by the operating system from virtual memory into RAM and an inactive page from RAM replaces it in virtual memory. This is called page switching

Cloud Storage

  • Cloud storage is the concept of storing data on remote servers, that can be accessed via the internet, instead of on a local storage device (such as an SSD or HDD)

  • The physical servers, where the data is stored, are owned and managed by a hosting company

    • Cloud storage warehouses often have thousands of servers containing hard drives

    • The hosting company provides services such backing up the data, managing access to the data as well as general security

  • The data can be accessed at any time, on any device, as long as there is an internet connection

  • The data is accessible using a web browser or dedicated software that connects to the cloud storage service

  • There is potentially limitless storage, although it does need to be paid for

  • Online storage means it is easy to share data and collaborate with others

  • If the internet connection is slow/lost the access to your data is affected

Benefit

Explanation

Accessibility

  • Data can be accessed from anywhere

  • Data can be accessed by anyone with the relevant permissions, making it quick to share files and collaborate with others

  • Data can be accessed on any device with an internet connection

Scalability

  • Cloud storage providers allow customers to increase or decrease their storage capacity as needed

Reliability

  • Cloud storage providers often use multiple servers to store and backup data, reducing the risk of data loss due to hardware failure

Security

  • Cloud storage providers offer advanced security features, such as data encryption and multi-factor authentication multi-factor authentication, to protect user data from unauthorised access

  • There is no need to hire specialist staff as IT services being provided by the cloud storage provider

5 - The internet and its uses

(This part is very rough, and has not been finalized. Consider it a draft.)

5.1 - The internet and the world wide web

Internet - a very large global network between devices that allows users to access the world wide web

World Wide Web - the collection of all web pages and websites that can be access using the internet

infrastructure - the physical structures that are used to connect devices (such as all the components and cables)

network - devices that are joined together using cables or wireless technology

website - a collection of web pages, normally about a related topic or purpose

web page - a single page within a website


The three fundamental parts of WWW are:

  • HTML

  • URL

  • HTTP

5.2 - Requesting and retrieving web pages

uniform resource locator (URL): another name for the text-based address for a website.

web browser - a piece of software that retrieves and displays web pages.

There are 3 main components of a URL:

protocol - a set of rules for transmitting data

domain name - a specific part of a URL that contains the unique name for the web server

domain name server (DNS) - a special server containing a database of domain names and their corresponding IP addresses.

web server - a network component where the web pages for a website are stored.

The process of retrieving a webpage

is as follows:

  1. web browser contacts DNS requesting for webserver

  2. DNS searches for webserver in its own database

  3. if found, DNS sends webserver DNS to your browser. if not, it continues searching.

  4. browser contacts server and requests for webpage using http

  5. web server sends data of webpage along with HTML and scripts

  6. browser renders and displays webpage

active script - the script used to produce any interactive elements on webpage

cascading style sheet (CSS) - a scripting language used to create a presentation template for a web page, and it includes what kind of font and color text will appear on the webpage.

hypertext markup language (HTML) - a scripting (web authoring) language that is used to create web pages. (it is not a programming language)

hypertext transfer protocol (HTTP): a protocol that is used for transmission of web pages and related data across the internet.

Another protocol that can be used to request for the web pages is HTTPS.

Hyper Text Transfer Protocol Secure

This protocol has another layer of security that encrypts any data that is transferred.

It involves the use of digital certificates.

It is a certificate that the owner of the website need to apply for from a certificate authority.

hypertext transfer protocol secure (https) - a secure of version the HTTP that encrypts data for transmission.

encryption - a method of securing data for storage or transmission that scrambles it, making it meaningless. (this was covered in a previous chapter).

digital certificate - certificate awarded to a website if they can prove they are a real organization and take measures to securely transmit data.

certificate authority - the awarding organization that checks if an organization is real before awarding them a digital certificate.

Request for a webpage using HTTPS:

  1. The browser sends a request to web server asking for certificate.

  2. The web server sends a copy of certificate.

  3. The browser checks if it is authentic.

  4. If it is authentic, the browser continues communication and allows any data between the user and web server

  5. If the certificate is not authentic, the web browser will report that the website is not secure.

HTTPS is the standard HTTP protocol with an extra layer of security, that being either SSL (Secure Sockets Layer) or TLS (Transport Layer Security)

secure sockets layer (SSL) - a type of protocol that encrypts data for transmission. It is the protocol, that is combined with the HTTP to create HTTPS.

transport layer security (TLS) - an updated version of the SSL protocol.

The purpose of a web browser

A web browser is a software application that allows you to access information from the world wide web

The main purpose of a web browser is to render hypertext markup language (HTML) and display web pages

This is done by requesting the HTML and other aspects of the page to render the data so we can view the web pages.

Functions include:

  • storing bookmarks and favorites

  • recording user history

  • allowing use of multiple tabs

  • storing cookies

  • providing navigation tools

  • providing an address bar

Cookies store data so that you may regularly use on the internet so that you do not need to enter this data every time. Their main functions include:

  • Saving personal details

  • Tracking user preferences

  • Holding items in an online shopping cart

  • Storing login details

There are two types of cookies: session cookies and persistent cookies.

  • Session Cookies

    • These are temporary and are stored only during a user's browsing session

    • They are used to maintain a user's state or activity during a single session, such as when filling out a form or navigating through a website

  • Persistent Cookies

    • These are stored on a user's device for a longer period, usually for a few weeks to several years

    • They are used to remember user preferences and settings, such as language preferences, login details, and shopping cart items

Digital Currency

A digital currency is one that only exists electronically (E.G. bitcoin, ethereum). They are decentralized, meaning they are not controlled by an entity like the government. They are “owned” by the blockchain (please dont say this in your exam).

They are also volatile meaning their price could rise really fast then drop really low with no warning or expectation, making them risky investments and hard to store as a stable store of value.

Blockchain is a digital ledger that records every transaction made with a particular digital currency. Each transaction is time-stamped and added to the blockchain in a permanent and unalterable way. Blockchain is decentralized, it is not controlled by a single entity or authority.

Instead, every participant in the network has a copy of the ledger and can verify the transactions independently.

The blockchain is made up of "blocks" of transactions that are linked together in a "chain" using  cryptographic algorithms

This creates a secure and tamper-proof record of every transaction made with the digital currency. Just to make sure that no fraudulent activity takes place, each transaction must be verified by multiple participants in the network.

Cyber security

Cyber security threats and their aims

Brute-force attack

  • A trial-and-error method where it tries every possible combination of a password until the password is found

  • Their aim is to gain unauthorised access to a system or network

Data interception

  • Eavesdropping on communication channels to intercept and steal sensitive information like passwords or credit card numbers

  • Their aim is to steal sensitive information for personal gain or for more cybersecurity attacks

DDoS attack

  • A DDoS (distributed denial of service) attack uses multiple bots to flood servers with lots of requests at once which it cant handle so it crashes

  • Their aim is to disrupt the normal functioning of a system or network by denying users access

Hacking

  • Gaining unauthorised access to a system or network to steal data, disrupt services or cause damage.

  • The aims can vary from personal gain to activism

Malware

Malware is malicious software designed to harm or gain unauthorised access to a system or network. Types include:

  • A virus, a piece of code that attaches itself to a program or file then spreads to other files in the system when run, infecting the whole system. It causes damage like deleting data or damaging hardware.

  • A worm, similar but is a standalone program that spreads and replicates itself over computer networks. It takes up storage space or bandwidth

  • A trojan horse disguises itself as a safe program or file, but when installed it deletes data or damages hardware

  • Spyware records all key presses and transmits these to a third party (e.g. records keyboard presses when a user is entering their password)

  • Adware displays unwanted advertisements on the computer without the user’s consent, these ads can lead to more malware.

  • Ransomware encrypts user files and demands a payment to decrypt them. It can delete files or disrupt entire businesses

  • The aim of malware attacks can range from data theft to disruption of services

Phishing

  • User is sent an email that looks legitimate

  • Contains a link to a fake website where the user is encouraged to enter their details

  • The aim is to steal sensitive information for personal gain or to use it for further cyber attacks

Pharming

  • Malware is downloaded without the user’s knowledge

  • Redirects user to a fake website where they’re encouraged to enter their personal details

  • The aim of pharming is to steal sensitive information for personal gain or to use it for further cyber attacks

Social Engineering

  • Manipulating individuals into to gain access to confidential information or into performing an action that benefits the attacker

  • It can be done through many ways, here are some:

    • Instant Messaging : False update warnings (Curiosity)

    • Scareware : False virus warnings (Fear)

    • Emails : False emails which look genuine (Trust)

    • Baiting : Memory stick left publicly outside with malicious codes embedded (Curiosity)

    • Phone Calls : False warning calls (Fear)

  • The aim of social engineering is to exploit human behavior and vulnerabilities to gain unauthorized access to a system or network

Cyber security solutions

Access Levels

  • They are used to restrict access of sensitive information to only authorized users

  • Prevents unauthorized access, which is the main security threat to data

  • Access levels can be set based on a user's role, responsibility, or clearance level, examples:

    • Full access

    • Read-only access

    • No access

Anti-Malware

  • They are used to prevent and remove malware

  • This includes anti-spyware and anti-virus programs

  • It scans the computer files and any files being downloaded and compares them to a list of known malware

  • If malware is found, it is quarantined to prevent the spread. It is then deleted

Authentication

  • Used to ensure only authorized users have access to data

  • There are several ways of authentication such as:

    • Username-Password system, a strong password should be complex and not easily guessed and users should avoid using the same password for everything

    • Biometrics uses biological data like fingerprint, facial recognition or iris scans.

      • Can’t be guessed

      • Hard to fake

      • Can’t be recorded by spyware

      • Can’t be seen over a shoulder for example

    • Two-factor authentication or 2FA requires users to enter two forms of verification before accessing data, such as a password and a verification code sent by email or by SMS.

  • These methods help prevent unauthorized access and protect sensitive data

Automating software updates

  • Automating software updates ensures that software systems are up-to-date with the latest security patches, which helps to prevent security threats

  • It does this by scanning the internet for known new updates to software, if any are found the user is either notified or the update is automatically installed

Communications

  • Checking the spelling and tone of communications is important to prevent phishing attacks (i dont know why this is in the syllabus. is cambridge racist?)

URL

Firewall

  • Can be software-based or hardware-based

  • Monitors incoming and outgoing traffic between the computer and the network and keeps a log of the traffic

  • If the traffic matches a criteria it is allowed, if not it is denied

Privacy settings

  • Controls the amount of personal information shared online

  • Important measure to prevent identity theft

  • Users should regularly review privacy settings

Proxy-servers

  • Are used to hide user’s IP address making the user hard to track

  • Act as a firewall and can also filter web traffic by setting criteria for the traffic

  • Malicious content is blocked and the user is notified

  • Useful for protecting against external threats as it can direct traffic away from the user

Secure Socket Layer (SSL)

  • Security protocol which is used to encrypt data transmitted over the internet

  • Prevents eavesdropping and other forms of interception

  • Used to protect bank transactions

  • It works by sending a digital certificate to user’s web browser

  • Contains the public key which can be used for authentication

  • Once certificate is authenticated, transaction begins

6 - Automated and emerging technologies

Automated systems use sensors, a microprocessor and actuators.

  • Sensors detect changes as analogue data in an environment and convert them into electrical signals that can be processed by a microprocessor.

  • Microprocessors analyze signals from a sensor and make decisions based on pre-programmed logic.

  • Actuators receive signals from a microprocessor and perform actions such as opening a valve or turning on a motor

By combining these three, automated systems are created. These are systems that respond to changes in the environment without human intervention.

Here are some scenarios where they are used.

Scenario

Advantages

Disadvantages

Industry

  • Reduced labour costs

  • Improved efficiency and accuracy

  • Increased production rate

  • High initial investment

  • Limited flexibility to changes in production processes

  • Maintenance costs can be high

Transport

  • Improved safety and reliability

  • Reduced labour costs

  • Improved fuel efficiency

  • High initial investment

  • May not be suitable for all types of transportation

  • Maintenance costs can be high

Agriculture

  • Increased efficiency in planting and harvesting crops

  • Improved crop yield and quality

  • Reduced labour costs

  • High initial investment

  • May not be suitable for all types of crops or terrain

  • Maintenance costs can be high

Weather

  • Improved accuracy in weather prediction

  • Ability to issue warnings in a timely manner

  • Ability to collect large amounts of data quickly

  • May be affected by external factors like interference or equipment failure

  • May not be 100% accurate all the time

  • May require continuous monitoring and calibration

Gaming

  • Improved speed and efficiency in game development

  • Ability to create complex and interactive games

  • Reduced labour costs

  • May not be suitable for all types of games or game development

  • May require significant programming expertise

  • May be affected by technical glitches or bugs

Lighting

  • Improved energy efficiency

  • Ability to program lighting to suit different needs

  • Reduced labour costs

  • High initial investment

  • May not be suitable for all types of lighting needs

  • Maintenance costs can be high

Science

  • Improved speed and accuracy in data collection and analysis

  • Ability to carry out complex experiments

  • Reduced labour costs

  • High initial investment

  • May not be suitable for all types of experiments

  • May require significant technical expertise

These are the shared ones:

Advantages of automated systems

Disadvantages of automated systems

Faster

Expensive

Better success rate

Requires maintenance


Worked Example stolen from savemyexams

A theme park has a game where a player tries to run from the start to the finish without getting wet. The system for the game uses sensors and a microprocessor to spray water at a player as they run past each sensor. Describe how the sensors and the microprocessor are used in this system.

[8]

  • A motion sensor collects analogue data [1]

  • This data is converted to digital using ADC [1]

  • The sensor sends data to the microprocessor [1]

  • where the data is compared to stored data [1]

  • If the value is outside range water will be sprayed [1]

  • A signal is sent to the actuator to spray water [1]

  • If the value is within range no action is taken [1]

  • This runs in a continuous loop [1]

Robotics

Robotics refers to an area of computer science that deals with the creation, design, and operation of robots.

It involves the design and creation of robots for various applications. They are designed using a combination of mechanical, electrical and computer engineering

Examples are:

  • Factory equipment

  • Domestic robots

  • Delivery drones

Characteristics of robots

  • They have a mechanical structure or framework

  • They have electrical components such as sensors, processors and actuators.

  • They are programmable.

Where they can be used

Robots can be used in many areas such as:

  • Medicine

  • Agriculture

  • Domestic

  • Construction

  • Industry

  • Transport

Advantages

Disadvantages

Increased productivity: robots can work continuously without breaks or fatigue

High initial investment: purchasing and setting up robots can be expensive

Consistency and accuracy: robots can perform tasks with a high level of precision and accuracy

Maintenance costs: robots require regular maintenance and repairs, which can add to the overall cost.

Safety: robots can perform tasks that are dangerous or hazardous for humans

Lack of flexibility: robots are programmed for specific tasks and cannot adapt easily to new situations or tasks.

Cost-effective: robots can help reduce labor costs in the long run

Unemployment: increased use of robots can lead to job loss in certain industries.

AI

AI is a branch of Computer Science dealing with the simulation of intelligent behaviors by computers.

Characteristics of AI

The characteristics of AI are:

  • Collection of data and rules

  • The ability to reason

  • The ability to learn and adapt

Types of AI systems

There are two main types of AI systems:

Expert systems

  • Have a knowledge base

    • A database of facts to generate rules. These rules are used to make decisions and solve problems.

  • Have a rule base

    • A set of rules that is used to apply the knowledge in the knowledge base to specific problems.

  • Have an inference engine

    • A program that applies the rules in the rule base to the facts in the knowledge base to solve problems

  • Have an interface

    • A way for users to interact with the system and provide input

Machine learning

  • This type of AI system has the ability to automatically adapt its own processes and data.

  • It uses algorithms to analyze data and identify patterns

  • The system can learn from the data and improve its performance over time.

robot