0% found this document useful (0 votes)
8 views40 pages

Intriguing Notes by Adam

The document provides an overview of various number systems including binary, hexadecimal, and denary, detailing their uses and conversions. It also covers data representation in sound and images, data storage measurements, data compression methods, and data transmission techniques. Additionally, it discusses error detection methods and the importance of protocols in ensuring accurate data communication.

Uploaded by

merchantaggy
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views40 pages

Intriguing Notes by Adam

The document provides an overview of various number systems including binary, hexadecimal, and denary, detailing their uses and conversions. It also covers data representation in sound and images, data storage measurements, data compression methods, and data transmission techniques. Additionally, it discusses error detection methods and the importance of protocols in ensuring accurate data communication.

Uploaded by

merchantaggy
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 40

Computer Science

Data representation

Binary number system

 It is a number system based on the number 2


 There are only two values used in this system to represent all values; 0 and 1
 The typical headings for a binary number with eight digits are – 2^7, 2^6, 2^5,
2^4, 2^3, 2^2, 2^1, 2^0

Uses of binary data


 To process data in logic gates
 To store data in registers
 To process data on the computer

Hexadecimal Number system

 Number system based on the number 16


 There are only 16 values used in this system to represent all values
 Denary digits 0 to 9
 Letters A to F
 The typical headings for a hexadecimal number with 5 digits are – 16^4, 16^3,
16^2, 16^1, 16^0
Uses of hexadecimal data:

 Error codes
o An error message generated by the computer
o The hexadecimal values refer to the memory location of the error
 HTML (hypertext markup language) colour codes
o It is used when writing or developing web pages
o It is often used to represent text colour on the computer screen
o All colours can be made up of combinations of the three primary
colours (rgb)
o The different intensity of each colour is determined by its hexadecimal
value
 MAC address
o It is a number which uniquely identifies a device on a network
o Refers to the NIC which is part of the device
o It is rarely changed
o It can be of 48/64 bits
o It is shown as 6 groups of two hexadecimal digits
o Two types of MAC addresses
 Universally administered MAC address
 Most common type
 Set by manufacturer at factory
 Rare for user to change this MAC address
 Locally administered MAC address
 Easy to change
 Internet Protocol (IP) address
o It gives a unique address to each device connected to a network
identifying its location
o Assigned by the internet service protocol
o There are two versions of IP addresses:
 IPv4
 32 bits
 Denary or hexadecimal
 Uses decimal point
 IPv6
 128 bits
 Broken down into 16 chunks
 Hexadecimal
o Main advantages of IPv6 over IPv4:
 Removes risk of IP address collisions
 Has built in authentication checks
 Allows for more efficient packet routes
o There are two types of IP addresses:
 Static:
 Remains the same each time a device logs onto the
internet
 Remote servers which are hosting a website
 An online database
 A file transfer protocol server
 Allows devices to be fully traceable
 Allow for faster upload and download speeds
 More expensive to maintain as the device has to be
running constantly for information
 Dynamic:
 Change each time a device logs onto the internet
 Assigned by the ISP by using dynamic host configuration
protocol
 Greater privacy
 Less reliable addressing type
 VoIP connection fails due to IP address change

Why do programmers use hexadecimal to represent binary data?

 Easier to debug
 Easier to understand
 It takes up less screen space
 Less likely to make a mistake

Denary number system


 It is a number system based on the number 10
 0-10 are used as values
 The typical headings for a denary number with 5 digits are – 10^4, 10^3, 10^2,
10^1, 10^0

Conversions to know:

 Binary -> Denary


 Denary -> Binary
 Binary -> Hexadecimal
 Hexadecimal -> Binary
 Hexadecimal -> Denary
 Denary -> Hexadecimal

Addition of binary numbers:

 0+0 = 0
 0+1 = 1
 1+1 = 0 (1 carry forward)
 0+0+0 = 0
 0+0+1 = 1
 0+1+1 = 0 (1 carry forward)
 1+1+1 = 1 (1 carry forward)
Overflow

 The result of carrying out a calculation that produces a value that is too large
for the computer’s allocated size
 E.g. Formation of a 9bit value on a 8 bit addition
Logical Shifts

 Moving bits to the left or right in a register


 Any bits shifted out of a register are replaced with zeros
 Each left shift is equivalent to multiplying binary number by 2
 Each right shift is equivalent to diving the binary number by 2

Two’s Complement

 A method of representing negative numbers in binary


 First write the positive value of number in binary
 Flip the number 1 becomes 0, 0 becomes 1
 Add the number by 1
 Add up all the 1 values

Converting a negative Two’s Complement number to positive

 Take the MSD as negative, then add the rest

ASCII (American standard code for information interchange)

 Has a standard version and extended version


 Only western languages supported
 Standard ASCII
o Character set consists of 7 bit codes
o 0-127 values
o Only supports English
 Extended ASCII
o Character set consists of 8 bit codes
o 0-255
o Supports Latin languages
o Includes graphical characters

Unicode

 Represents all languages


 Character set consists of 16 bit codes and approximately 65000 characters

Sound

 Sound waves vary continuously hence it’s analogue


 To store the waves in a computer, they’re sampled via an Analogue to Digital
converter (ADC)
 Sound waves are sampled at regular time intervals
 Keywords:
o Sampling – Measuring the amplitude of sound waves via an ADC
o Sampling resolution/bit depth – The number of bits per sample
o Sampling rate – The number of sound samples taken per second
measured in Hertz

How is sampling used to record a sound clip?

 The amplitude of the sound wave is first determined at a set time interval
 This gives an approximate representation of the sound wave
 Each sample of the sound wave is then encoded as a series of binary digits

Benefits of a larger sampling resolution

 Larger dynamic range


 Better sound quality
 Less sound distortion
Drawbacks of a larger sampling resolution
 Produces larger file size
 Takes longer to download music files
 Requires greater processing power

Formula to calculate a mono audio file size:

 Sample rate * Sample resolution (bits) * Sample length (seconds)

To convert it to byte:

 Divide it by 8

To calculate the stereo sound file:

 Multiply result by 2

Images

 Keywords
o Bitmap image: Images that are made up of pixels
o Image resolution: The number of pixels that make up an image
o Colour depth: The number of colours to represent each pixel

What are the features of high resolution images:

 Consists of many pixels to represent images; there’s a lot of detail


 The file size increases
 The time taken to download an image file also increases
Formula to calculate an image file size:

 Image resolution * Colour depth (bits)

To convert it to byte

 Divide it by 8

Measurement of data storage

 Bit: It is the smallest unit of data that a computer can process and store
 Byte: It consists of 8 bits
 Nibble: It consists of 4 bits
 Kibibyte: 2^10 bits
 Mebibyte: 2^20 bits
 Gibibyte: 2^30 bits
 Tebibyte: 2^40 bits
 Pebibyte: 2^50 bits
 Exbibyte: 2^60 bits

Data compression
 It is necessary to compress data
o To save storage on devices like HDD/SSD
o It will take less time to transfer the file from one device to another
o It will take less time to stream a music or video file
o Reduces the time taken to upload or download files
o Not as much bandwidth is needed to transfer the file over the internet
o Reduced file size also reduce costs
 There are two methods of data compression
o Lossy
 A compression method that reduces the size of a file by
permanently removing data
 Common lossy file compression algorithms are
 MPEG-3
o Used for playing music
o Reduces 90% of audio file size
o Quality isn’t as sharp as the ones found in
CDs/DVD
 MPEG-4
o Used for playing videos
o Still retains an acceptable quality of sounds and
videos
 JPEG
o Used for bitmap image files
o Separates pixel colour from brightness
o Lossless
 A compression method that reduces the size of a file by
temporarily altering the data
 Common lossy file compression algorithms are
 Run-Length Encoding
o An algorithm that groups repeating patterns and
indexes them
o Used to compress text and image files
o Reduces size of string of adjacent, identical data
by making it into two characters – the number of
occurrences of the data and it’s ascii/Unicode
code.
Data Transmission

Keywords
 Data packet:
o Data that is transmitted over a network
 Packet switching:
o A method of transmission in which a message is broken into many data
packets which can then be sent along pathways independently of each
other

A typical packet is split up into:


 Header packet
o It consists of:
 The IP address of the sender and the receiver
 The sequence number of the packet
 The size of the packet
 Payload
o It consists of:
 The actual data in the packets
 Trailer
o It consists of:
 A packet identification method
 An error-checking method e.g. CRC

Cyclic redundancy check

 The sender adds up all the 1-bits in the payload and stores this as a hex value
in the trailer before it is sent
 Once the packet arrives the receiver recalculated the number of 1-bits in the
payload
 The computer then checks this value against the one sent in the trailer
 If both values match, there’s no error, otherwise the packet needs to be re-
sent

Packet switching

 Each packet will follow its path


 Routers will determine the path of each packet
 Routing selection depends on the number of packets waiting to be processed
at each node
 The shortest possible path available is always chosen
 Packets can reach the destination in a different order to that they were sent

Different methods of data transmission


 Serial
o A transmission method where data is sent one bit at a time down a
single wire
o Advantages:
 Less chance of data being skewed
 Less chance of error in the data
 Cheaper to manufacture; only one wire is needed
o Disadvantages:
 Slower rate of data transmission
 Additional data may need to be sent to indicate to the receiving
device when the data transmission has started and stopped
 Parallel
o A transmission method where data is sent multiple bits at a time down
multiple wires
o Advantages:
 Faster rate of data transmission
 Common method of data transmission among devices
o Disadvantages:
 Higher chance of data being skewed
 Higher chance of error in data
 More costly
 Simplex
o A transmission method where data is transmitted in a single direction
only
 Half-duplex
o A transmission method where data is transmitted in both directions but
only one direction at a time
 Full-duplex
o A transmission method where data is transmitted in both directions
simultaneously

USB (universal serial bus)

 It is an industry standard that is used to transmit data


 A USB interface includes a:
o Port:
 A socket that is part of a device or computer that enables you to
insert a USB cable
o Cable:
 A type of transmission media that uses the USB method to
transmit data
o Connection:
 A collective name for using a USB cable plugged into a USB
port to transfer data from one device to another.
o Device
 The name of a device that plugs into a USB port on a computer
 It uses a special type of serial data transmission connection that is used that
is designed to transmit data at high speeds
 Advantages:
o High rate of transmission
o It is a simple interface; the cable to device can only fit into the USB one
way
o A USB port is included in many devices as it is an industry standard
o When inserted into a USB cable, it is automatically detected by the
device
o No need for another power source as it can be used to power a device
 Disadvantages:
o The length of a USB cable is limited (up to 5 metres)
o Rate of transmission isn’t as high as compared to other types of
connection like Ethernet.

Methods of error detection

 Errors can occur during data transmission due to interference leading to:
o Data loss
o Data gain
o Data change
 There are several methods of detecting errors
o Parity check:
 A type of error detection method that adds an additional bit to
each byte to create an odd or even sum
 E.G. _001001
 Before transmission:
 The parity check is set to be either odd or even parity
 If an odd parity is used
 Then a 1 is added as parity bit. This is because all the 1s
in the byte now add up to an odd number
 If an even parity check is used
 Then a 0 is added as a parity bit. This is because all the
1s in the byte now add up to an even number
 After transmission:
 The receiving device will check each byte of data for
errors
 If an odd parity check has been used and the device finds
a byte that has an even number of 1s, then it knows that
an error has occurred with this byte of data
 The same can be said if an even parity check has been
used and an odd number of 1s
o Checksum
 A type of error detection method that performs a calculation on
the data to create a checksum value
 A checksum is calculated and added to the data before
transmission
 After receiving the data, the receiving device calculated its own
checksum
 If the two checksums match, the data is error-free; if they don’t,
an error is detected
o Echo check
 A type of error detection method that sends a copy of the
transmitted data back to the sender to be compared with the
original data sent
 The sending device compares the data it sent to the data it has
received back from the receiving device to see if they match
 If they do, then no error has occurred
 If they don’t match, then the sending device knows the data was
received with error

Automatic Repeat Request (ARQ)

 A type of error detection method that uses acknowledgement and timeout to


see if data has arrived correctly after transmission.
 In a positive acknowledgement method:
o The sending device transmits the first data packet
o The receiving device receives the data and checks it for errors
o Once the receiving device knows it has received the data error free, it
sends a positive acknowledgement back to the sending device
o When the sending device receives this positive acknowledgement, it
knows the receiving device has received the data packet error free and
it sends the next data packet
o If the sending device does not receive a positive acknowledgement
within a set timeframe, a timeout occurs
o When a timeout occurs, the sending device will resend the data packet.
It will keep doing this when a timeout occurs until it receives a positive
acknowledgement
o Sometimes a limit is set
 In a negative acknowledgment method:
o The sending device transmits the first data packet
o The receiving device receives the data packet and checks it for errors
o If the receiving device detects no errors, no further action is taken
o If the receiving device does detect errors, it will send a negative
acknowledgement back to the sender
o If the sender receives a negative acknowledgement, it knows this
means the data was received incorrectly, so it can resend the data
packet
o A timeout is set by the sending device when it sends the data. This is
just so that the sending device knows that if it doesn’t receive a
negative acknowledgement back within that set time period, it doesn’t
need to be still waiting for it and can send the next data packet

Check digit

 A type of error detection method that is used for data entry


 A calculation is performed on the data entered to create a value
 Check digit values are compared to see if the data entered is correct
 This is how a check digit operates:
o A check digit is pre-calculated and stored with the data e.g.
barcode/ISBN
o When the data is entered or scanned, the check digit is recalculated
o If the recalculated check digit matches the stored one, the data is
correct
o If the recalculated check digit does not match the stored one, the data
is incorrect.

Encryption

 A method of securing data for storing or transmission that scrambles it and


makes it meaningless
 Keywords:
o Plain text: The name given to data before encryption
o Cipher text: The name given to data after encryption and transmission
o Encryption key: A type of algorithm that is used to encrypt data
 There are two methods of encryption:
o Symmetric encryption
 A type of encryption that uses the same key to encrypt and
decrypt data
 The process is:
 Plain text is encrypted into cipher text using an encryption
key
 The cipher text and encryption key are sent separately to
the receiving device
 The same key is then used to decrypt the cipher text back
into its plain text form
o Asymmetric encryption
 A type of encryption that uses two different keys (public and
private) to encrypt and decrypt data
 The process is:
 Plain text is encrypted into cipher text using a public key
 The cipher text is transmitted to the receiving device
 The cipher text cannot be decrypted using public key, it is
decrypted using a private key
Hardware

The CPU

 Are used for processing and executing 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 that usually
performs less functions as compared to a regular CPU
Components of CPU

 A CPU consists of:


o Units:
 Examples of units:
 Arithmetic logic unit: The ALU deals with all arithmetic
operations and logical operations
 Control unit: The CU has the job of managing and
synchronising data and instructions transfer in the CPU.
It does this by sending control signals to other
components. Additionally, it also decodes instructions
sent to it
o Registers:
 Registers are high-speed memory components in the CPU that
temporarily store important information
 Examples of registers:
 Program counter (PC): Stores the memory address of the
next instruction that will be processed
 Memory address register (MAR): stores the memory
address of the instruction/data that is about to be fetched
from the RAM
 Memory data register (MDR): Stores data or instructions
that have just been fetched from RAM.
 Current instruction register (CIR): Stores the instruction
that is currently being processed or decoded by the CPU
 Accumulator (ACC): Stores any interim values or final
values created during arithmetic or logical operations
done by the ALU
o Buses:
 Buses are communication systems within the computer that
transfer data and instructions between components
 Examples of buses:
 Address bus: Carries the memory address of
data/instructions in
 Data bus: Carries actual data/instructions
 Control bus: Carries control signals to and from the CU

Fetch-Decode-Execute cycle

 Fetch
o This stage is for fetching the actual data or instructions from the
computer’s memory to the CPU
o Steps:
 The PC stores the address of the next instruction to be
processed. This is copied to the MAR via address bus
 MAR copies this address to the RAM via address bus
 RAM uses the address sent to it to locate the data or instruction
that must be processed
 RAM copies the data/instruction to MDR via data bus
 MDR copies data/instruction to CIR via data bus
 Program counter is incremented so that the address of the next
instruction is contained in it
 Decode
o This stage is used to decode the data/instruction, which is carried out
by the CU using an instruction set
o An instruction set is a set of instructions written in low-level machine
code that tells the computer how to carry out specific functions. They
are the only instructions understood by CPU
 Execute
o This stage used to carry out any final arithmetic or logical operations
and then finish executing the instruction
o ALU is responsible for such operations. Uses the accumulator to store
any interim values created during execution.
o After all calculations are finished the command is executed
 The entire process repeats for each piece of data or instruction that needs to
be carried out by the CPU.

Increasing the CPUs performance

 Cache:
o Cache is internal, temporary storage space inside the CPU itself. It
stores data and instructions which are used regularly by the CPU
o The CPU does not need to fetch regularly used data or instructions
from the RAM, instead, it simply uses the cache. This takes less time
and increases the CPUs performance
o The more cache a computer has, the more data/instructions it can
store nearby, which means less time is spent retrieving information.
So, a larger cache size can mean better CPU performance.
o However an extremely large cache would take more time to look
through while fetching information, causing significant delays which
would render the cache useless. So there must be a limit for the cache
size.
 Clock:
o The system clock is located inside the CPU. Its job is to control the
processing speed and time taken to execute instructions as well as
control the time intervals between each task and synchronise the entire
FDE cycle. In short, it controls the number of FDE cycles completed
each second
o Clock speed is measured in Hertz. The average clock speed found in
most computers is 2 Gigahertz which is 2 billion instructions executed
per second.
o Higher clock speed means that more instructions are processed each
second, increasing the computer’s performance
o However, increasing the clock speed too much can cause the computer
to overheat
 Cores:
o Cores are the components in the computer that run the FDE cycle.
Each core can run one cycle, i.e. process one instruction at a time
o A higher number of cores in a computer means that more instructions
can be processed at once. This allows a computer to multitask, which
increases the computer’s performance

Embedded systems

 An embedded system is a combination of software and hardware that is built


into a device, which runs on firmware and performs a dedicated function
 They differ from general purpose computers as they only perform a specific
task, instead of being multipurpose
 Embedded systems are used in:
o Domestic appliances
o Cars
o Security systems
o Lighting systems
o Vending machines
 Advantages:
o They are small
o They are cheap
o They can be remote-controlled
o No operating system is needed
o They use very less power
 Disadvantages:
o They are difficult to update
o They are susceptible to hacking
o Specialists are needed for repairs
o There are environmental concerns
o They may have a confusing interface

Input devices

 Input devices allow data to be entered into the system


 Examples of input devices:
o Barcode scanner
o Digital camera
o Keyboard
o Microphone
o Optical mouse
o QR code scanner
o Touch screen
 Resistive
 Capacitive
 Infra-red
o 2D and 3D scanners

Output devices

 Output devices are used to tell user information


 Examples of output devices:
o Actuator
o Digital light processing projector
o Inkjet printer
o Laser printer
o Light emitting diode LED screen
o Liquid crystal display LCD screen
o Liquid crystal display LCD projector
o Speaker
o 3D printer

Sensors

 Sensors are input devices that capture analogue data from their immediate
environment at set time intervals
 Examples:
o Acoustic – sound levels of an environment – used in security systems
to detect intruders
o Accelerometer – Any forces of acceleration acting on environment –
Earthquake warnings
o Flow – The amount of fluids moving through an environment – pipes or
plumbing
o Gas – the amount and concentration of a gas – carbon monoxide
detectors in houses
o Humidity – the humidity levels in an environment – greenhouses to
ensure internal humidity is not too less or high
o Infra-red – Any infra-red rays present – security systems
o Level – the level or volume a fluid is at – amount of fuel in vehicles
o Light – the light levels of an environment – automatic lighting
o Magnetic field – any magnetic fields present in the environment –
detecting cars in parking lots or bridges
o Moisture – the moisture present in any environment – detecting
moisture levels in soil
o pH – the pH level of a substance – water bodies to check level of
pollution or detecting soil pH levels to ensure plant health
o Pressure – the pressure which is being exerted on the sensor –
security systems to detect intruders
o Proximity – how close an object is to the sensor – used in robots or
automatic doors
o Temperature – the temperature of the environment – automatic cooling
systems

Data storage
 Primary storage
o Primary storage contains data that is directly accessible by the CPU
o RAM and ROM are examples of primary storage
 Secondary storage
o Contains data that is not directly accessible by the CPU and is not
currently required by the CPU
o It is non-volatile which means that the data contained in it is not lost if
power is switched off
o It stores data that can be transferred to other computers if required
o Pen drives and CDs are examples of secondary storage devices
 Primary storage
o RAM:
 It stores data temporarily, making it a volatile method of data
storage. It stores the data and instructions that are currently
being used by the CPU. E.g. Program files for an application
that is currently open on the user’s computer
 Easy to increase RAM’s size
 Its contents are constantly changing based on what the CPU
requires
o ROM:
 Permanent storage (non-volatile)
 Stores programs that initially boot the computer. E.g. BIOS
 Difficult to increase or decrease size of ROM
 Secondary storage
o Secondary storage needs to be fetched into primary memory first, to be
accessed by the CPU. It can be of two types: internal, such as solid-
state drives or hard-disk drives, or external such as CDs or DVDs
o Magnetic storage:
 Magnetic storage uses magnetised and demagnetised dots to
store data
 A circle disk knows as a platter, spins very fast, with a read-write
head over it. The read/write head magnetises and
demagnetises dots on the platter as required
 The platter is divided into tracks and sectors
 The current state of a dot decides its stored value. Magnetised
= 1, demagnetised = 0.
 E.g. Hard drive
o Optical storage:
 Optical storage uses circular discs and laser to store data
The disc is rotated or spun with a read/write head over it, which
uses a laser beam.
 The laser beam makes indentations on the surface of the disc
by burning data onto it. An indentation is known as a pit while
space between pits are called lands.
 The pits and lands represent binary values. Pit = 1 Land = 0
 Data is written in a spiral or circular pattern around the disc
 E.g. CDs, DVDs, Blu-ray.
o Solid-state storage
 Solid state storage is also knows as flash storage. It uses
transistors and cells to store data. These transistors and cells
are arranged on a semiconductor chip
 Transistors are laid out to form a grid. They are used to form a
control gate which is above a floating gate, at each intersection
in the grid.
 The transistors control the flow of electrons in the semiconductor
chip. They flow through the control gate to the floating gate,
where they are stored.
 After storing the electrons, the binary value of the transistor
changes from 1 to 0
 Typically a NAND or NOR structure is used for solid-state
storage
 E.g. SSD, pen-drives

Virtual memory

 Virtual memory is a sectioned-off segment of the hard disk drive, which acts
as an extension to the primary memory (RAM). It is required for when the
RAM is full but more data transfer needs to take place.
 This is how it operates whenever required:
o Data in RAM is split into pages
o The pages which are not currently being used by CPU or which are not
immediately required are sent to the virtual memory. This clears up
space in the RAM.
o Any new data that the RAM now requires is imported from the
secondary storage
o Once the data in the RAM is no longer needed, it is sent back to
secondary storage. The pages the RAM initially sent to the virtual
memory are fetched back.
 Virtual memory is important as the RAM is at risk of overloading from excess
data and crashing. Virtual memory helps ensure that this does not happen

Cloud storage
 Cloud storage is data stored by a third-party remote server instead of in local
storage. It is accessible via the internet.
 Cloud storage:
o Accessible everywhere, but ONLY if you have an internet connection
o No hardware cost, and you don’t have to manage your own hardware
o Backup of your data is easily available
o It is easy to increase and decrease the amount of storage space you
have
o Trusting a third party with personal data may be unsafe as they could
use it for malicious reasons
 Local storage:
o Only accessible as long as you have your storage with you, but doesn’t
require the Internet
o You have to pay for your own hardware, as well as keep it secure
o Changing the storage size may be difficult
o There is no need to rely on a third-party. You are fully in control of your
own data which means there are less privacy issues

Network interface card


 The NIC is a hardware component that is required by the computer to access
any networks by connecting to routers. It also contains the MAC address

Media Access Control Address

 A MAC address uniquely identifies each computer on a network, which is


provided by the manufacturer when the computer is created. It is located on
the NIC
 Structure:
o It is written in hexadecimal
o NN-NN-NN-DD-DD-DD; the first six digits comprise the manufacturer’s
code, while the last six digits comprise the device’s serial number.
o It is 48 bits in total; 24 bits for the manufacturer’s code and 24 bits for
the device’s serial number.
o It is usually separated by a dash

Internet Protocol Address

 An Internet Protocol address is assigned by the internet service provider and


it uniquely identifies each computer on a network.
 There are two types of IP addresses: static and dynamic
o Static: The IP address never changes unless specifically requested. All
devices with a static IP address are always traceable. A static IP
address may be comparatively less safe.
o Dynamic: The IP addresses change when a computer connects to a
network. It may change every time the computer connects to a
network, or once every few times a computer reconnects. As it is
always changing, it is more difficult to trace, thus ensuring better
privacy.
 Structure:
o There are two types of IP addresses – IPv4 and IPv6. They both have
the characteristics of a typical IP address, however, their structures
differ
o IPv4:
 Usually written in denary digits
 Each number is separated using dots
 There are 4 groups of digits
 It is 32 bits – each group is 8 bits
 Each number is between 0-255
 There are fewer available unique addresses for IPv4
 E.g. 24.2.89.232
o IPv6
 Usually written in hexadecimal
 Each number is separated using a colon
 There are 8 groups of digits
 It is 128 bits – each group is 16 bits
 The values are between 0000 – FFFF
 There are more available unique addresses for IPv6
 E.g. 1234:0A34:1F20:0000:FFFF:998B:900C:5ABC
Software

Types of software

 Software: A series of instructions written in a programming language that


performs a function or a task.
 System Software:
o It provides the services that the computer requires, including operating
system and utility software such as anti-virus
o For e.g. manages hardware and software, provides a user interface
 Application software
o It provides the services that the user requires and runs of the OS
o For e.g. word processors, databases, spreadsheet applications, and
web browsers
 All application software runs on the operating system. The operating system
runs on the firmware a.k.a. the bootloader. Bootloader runs on the hardware

The operating system

 The operating system plays many diverse roles in a computer system. It does
the following tasks:
o Managing files:
 Allows the creation and deletion of folders ad directories to store
files.
 Allows users to create, copy, open, close, move, delete, rename,
save and sort files.
o Handles interrupts:
 Decides the appropriate time to run interrupts in order of
requirement
o Provides a user interface:
 Allows data to be entered by and displayed to the user
 User interfaces can be: Graphical user interface GUI, which
uses icons and pointers OR command line interface CLI, which
requires data to be entered as commands in a programming
language.
o Managing peripherals and drivers:
 Manages and detects any peripherals, i.e. any connected input
or output devices. It additionally installs appropriate drivers
when a device is connected.
 Driver: Software that is required for communication between two
devices externally connected, which translates code from one
device to another.
o Managing memory:
 Manages data transfer to and from the memory (RAM)
 Makes sure all currently running processes have enough
memory space to continue running properly
 Keeps track of each memory location and records its status
(whether it is in use or not)
 Ensures that two processes don’t try and access the same
memory location at once
 Manages transfer of pages between virtual memory and RAM
o Managing multitasking:
 Decides the order in which processes are meant to run, and how
long each instruction should spend getting processed
 Organises a priority queue, to schedule instructions to be
processed in order of importance.
o Providing a platform for running applications
o Providing system security:
 Oversees software updates and ensure all software are always
up to date
 Runs anti-virus checks and sets up the firewall
 Manages data backup and system restoration in case of data
loss
 Manage each user accounts access
o Managing user accounts:
 Helps each user have a separate username, password
 Restricts access for each user as required
 Keeps each users data separate
Interrupts

 Including: - how an interrupt is generated – how it is handled using an


interrupt service routine – what happens as a result of the interrupts
 Interrupt: A signal that is sent to the CPU asking for its attention. These
signals allow the CPU to multitask.
 An interrupt is generated when something demands the CPU’s urgent
attention. Hardware and software can both send interrupts. The CPU checks
for these interrupts at the end of each FDE cycle
 E.g. of hardware interrupts: Pressing a key on the keyboard, moving the
mouse, hardware failures
 E.g. of software interrupts: Division by 0, two processes trying to access the
same memory location
 Interrupts can be of different priority levels. For e.g., an interrupt sent due to
hardware failure would be of greater important than an interrupt sent when the
user requires input. The interrupts are organised into a priority queue based
on their level of importance. A CPU’s interrupt handler organises the
interrupts.
 To handle interrupts, the CPU calls an interrupt service routine. An interrupt
service routine’s job is to retrieve the interrupt and perform the actions
required for it to be solved.
 When the CPU receives an interrupt, it follows the following steps:
o The current FDE cycle is finished and the CPU checks the interrupt
queue.
o If an interrupt with higher priority than the next process is found:
 The next process is stored
 The interrupt’s source is found
 An appropriate interrupt service routine is called, which handles
the interrupt.
o After the interrupt is handled, the CPU once again checks for high-
priority interrupts. If any are found, they are serviced.
o The next process is retrieved and another FDE cycle takes place
 This process takes place continuously
Programming languages

 There are two types of programming languages: High-level and low-level


 High-level languages use English-style words, which are easier to understand
for humans. They need to be converted into low-level language to be
understood by computers. Python, Java and C# are examples
 Low-level have two types: assembly language and machine code
o Assembly language uses mnemonics in place of words. E.g. high-level
language may store a variable using “var num1 <- 100” may be written
as STR 100 in assembly language. It can directly access a computer’s
hardware using commands, such as store variables in specific memory
locations. It must also be translated into machine code before it can be
understood by a computer, however, conversion is less time consuming
o Machine code uses 0s and 1s to represent data in the form of binary
numbers. It does not need any conversions
 High-level language:
o They are machine independent, which means that the code can run on
any computer regardless of its model
o The code is much easier to read and debug since it is written in English
words
o The code cannot directly manipulate a computer’s hardware in any
way.
o The code must always be translated to low-level language first, which
can be time consuming.
 Low-level language:
o They are machine dependent, which means that the code is for a
specific computer only and may not run on other computers.
o Both assembly language and machine code are difficult to read as well
as debug.
o The code can manipulate computer hardware if required.
o Only assembly language requires translation, which is less time taking.
Machine code does not require any translation

Translators

 Translators are required to convert high-level language or assembly language


into machine code, which is the only language that can be understood by the
computer. There are three types of translators: assembler, interpreter,
compiler
o Assembler: Translates assembly language into machine code. It
translates the entire code at once and produces a file. If it finds any
errors it will create an error report and display it once the entire code is
read, without producing a file
o Interpreters and compilers translate high level languages into machine
code. Their methods of reading the code and finding errors are
different.
o An interpreter reads the code line-by-line. If it finds an error, it will stop
immediately and display it to the user. It will continue to read the code
until the error has been corrected. Otherwise, it runs the code. They
are better to use while in the process of writing code, as it lets you
correct errors as they are made.
o A compiler reads the entire code at once. If it finds any errors, it will
compile an error report of all the errors and display it to the user.
Otherwise, it will run the code and create an executable file. They are
better for when the code is complete, as it creates an executable file
that can be run easily anywhere.
o Interpreter:
 Translates and executes code line-by-line
 Stops execution when an error is found
Are better to use while in the process of writing code, as it lets

you correct errors as they are made.
 Needs to be re-translated each time it needs to be run
 The source code is always required for it to be run
 The interpreter software is always needed for code to run
o Compiler:
 Translates the whole code at once before executing it, producing
an executable file.
 Provides an error report for the whole code if errors are detected
 Better for when the code is complete, as it creates an
executable file.
 Doesn’t need to be re-translated each time as it needs to be run,
as an exe file is produced
 The source code is no longer required after the file is produced
 The compiler software is no longer needed after the exe file is
produced.

Integrated development environment

 An IDE is an interface where users can write, edit and run programs easily.
An IDE always contains:
o An editor: Where code can be written and edited
o A runtime environment: Where the code’s outputs are shown and user
input is allowed
 An IDE typically also contains other useful features, such as:
o A compiler or interpreter
o Error diagnostics
o Auto-completion of code
o Auto-correction of code
o Prettyprint, which colour-codes keywords
The internet and its uses

The internet and the world wide web


 The internet is a network of computers joined together through infrastructure
such as wires and cables. It is a type of network that spans the entire world,
connecting computers and enabling them to use the world wide web.
 The world wide web is the collection of websites and web pages accessed
using the internet’s infrastructure. It is primarily software-based, as opposed
to hardware infrastructure.

Uniform resource locator

 Websites and webpages on the world wide web must be accessible easily.
URL exist for this purpose. A URL is a text based address to uniquely identify
a web page. It contains 3 sections: the protocol, the domain name and the
web page/file name.

Web browsers

 A web browser is used mainly for the purpose of rendering hypertext markup
language and displaying web pages to the user. It typically has other
functions as well, such as:
o Storing bookmarks and favourites
o Recording user history
o Allowing the user to open multiple tabs
o Storing cookies
o Providing navigation tools such as a button to reload, go back to the
previous/next page
o Providing an address bar

Retrieval of web pages

 Web pages are stored in web servers. For a web browser to access their
HTML, retrieve it from the server and render it, it first requires the web
server’s IP address. This address is stored in a domain name server to which
a request must be sent first.
 Steps to retrieve a web page are:
o The user types the URL of the website into their web browser’s address
bar.
o The web browser send the URL to a domain name server. The DNS
stores IP addresses of each web server
o The DNS searches in its database for the IP address corresponding to
the URL sent by the user. If the IP address is not found in one DNS, it
is sent to another DNS until it is found. If the URL’s corresponding IP
address is not found at all, an error message is displayed to the user
o When the DNS finds the corresponding IP address, it sends it back to
the web browser
 After this, the hypertext transfer protocol – HTTP – is executed by the browser
to retrieve web pages from their web server and then render them. The
protocol consists of the following steps:
o The web browser sends a request to the web server asking for the web
pages by using its IP address to locate it
o The web server send back all HTML, CSS and active script
o The browser renders the code it receives.

Hypertext transfer protocol secure – HTTPS


 During the transmission of data to and from the web server, there is a risk of it
being hacked and stolen. Personal information such as passwords may be
intercepted and used for malicious purposes. The standard HTTP protocol
does not protect data being transmitted. So HTTPS is used instead, as it
uses digital certificates to ensure security.
 A digital certificate is a certificate that is awarded to a certain web server as
proof of their authenticity. It shows that the website encrypts all its transmitted
data. It is awarded by the certificate authority, which is an organisation which
checks the authenticity of a website.
 Typically a website ensures encryption using the secure socket layer protocol
SSL
 The HTTPS protocol secures its data using the following steps:
o Before the web browser asks for the web pages, it sends a request to
the web server asking for its digital certificate.
o If the web server has one, it sends it to the web browser
o The browser confirms if the certificate is authentic. If it is, web page
transmission takes place in an encrypted manner. Otherwise, a
message displaying that the website is unsafe is displayed to the user.
 Users can check if a website is secure by:
o Ensuring the URL contains HTTPS and not HTTP
o Checking if there is a padlock symbol near the URL

Cookies
 When a user visits a website, they may enter specific information that needs
to be entered again at later dates. For example, passwords and usernames.
However, it is an inconvenience to the user if this information must be entered
again each time. The web server uses cookies to store such information.
 A cookie is a small text file that stores information about the user. There are
two types of cookies: session and permanent.
 They are created by:
o Whenever the website is opened or revisited, the web server sends a
request for the cookie file
o The browser sends the cookie file so that details are automatically
entered.
 Session cookies are temporarily stored in the primary memory. They are only
used as long as the browser is still open. As soon as the browser window is
closed, the cookie is deleted.
 Persistent cookies are permanently stores in secondary storage. They are
stored until they are deleted by the user, or until they reach a specific
expiration date. They’re retrieved each time the browser window is opened.
 Cookies can be used for:
o Saving personal details such as passwords and usernames
o Tracking user preferences
o Holding items in an online shopping cart
o Storing login details
 Cookies can have certain privacy issues, as they store sensitive information.
They are:
o Cookies may store data without the user’s knowledge or permission
o Hackers can intercept the data and build a false user profile, leading to
identity theft
o Sensitive information in the cookie files may be intercepted
o Other websites may gain unauthorised access to certain cookies
o The computer may be hacked and cookie file’s information may be
visible to 3rd parties.
Digital currencies

 Digital currency is a form of payment that is completely electronic and does


not require any tangible currency, such as coins or notes.
 Most digital currencies and tangible currencies both use a centralised system
 A centralised system uses a central authority that oversees all transactions
made by users such as a bank. It can be susceptible to security breaches
and there are confidentiality risks in using such a system. This is often why
crypto currencies are used.
 Crypto currencies are a subtype of digital currencies which use a
decentralised system known as the blockchain. There is no central authority
involved, thus making it safer and more confidential
Blockchains:

 A blockchain is a digital ledger or database of all transactions made on its


network, which is publicly available for all devices on the network.
 Each transaction made on a blockchain is stored on a block, which contains:
o A unique identifier for the transaction
o The sender, receiver and amount of money sent during the transaction
o The previous block’s unique identifier
 All blocks in a blockchain are interconnected via their unique identifiers. Each
block contains the previous block’s identifier. Once added, a block is
completely unchangeable by anyone on the network and can only be viewed.

Cyber attacks

 There are multiple ways malicious third parties can hack into our data and use
it for their own purposes. The most common ones are listed below.
 Brute force attacks:
o The perpetrator tries multiple combinations of passwords repeatedly in
order to guess it and hack into the user’s account. The passwords can
be guessed manually or by using software.
o Preventions:
 Using biometrics
 Using 2 factor authentication
 Using passwords which are difficult to guess – contains symbols
 Data interception:
o Data interception is done by using a packet sniffer software which the
perpetrator has previously installed on transmission hardware. For e.g.
it can be installed on a router.
o The packet sniffer looks through all data packets being transmitted
through that router or piece of hardware. If it finds any useful
information, such as passwords, it copies and sends it to the
perpetrator.
o Preventions:
 Encrypting data
 DDoS (Distributed denial of service)
o DDoS is an attack towards web servers typically done as revenge or to
demand ransom.
o The following steps take place:
 The perpetrator sends out malware publicly so that as many
computers as possible download it by accident. Once
downloaded, it turns the computers into bots. The collection of
all computers is knows as a botnet
 To carry out a DDoS attack, the perpetrator makes the malware
in the bots repeatedly send requests to a certain web server
 The web server crashes due to overload of requests at once,
denying service to legitimate users.
 Preventions
 Use a proxy server
 Use anti malware software.
 Hacking:
o Hacking is the act of gaining unauthorised access to other’s data. This
can be done through vulnerabilities in networks such as open ports or
software bugs.
o Preventions:
 2 factor authentication, biometrics, strong passwords
 Regularly updating software to ensure it has no vulnerabilities
 Using anti-malware software
 Using a firewall
 Malware
o Virus
 It gets installed onto the secondary memory, where it proceeds
to replicate itself until there is no more storage left causing PC to
crash, also may corrupt data.
 Preventions:
 Anti-malware software
 Firewalls
 Mindfulness while clicking unknown links
 Have data backup
o Worm
 Once installed, it finds network vulnerabilities and uses them to
reduce bandwidth.
 Preventions:
 Anti-malware software
 Firewalls
 Mindfulness while clicking unknown links
o Spyware
 Once installed, it can record physical actions taken by the user,
such as keyboard inputs. It sends this data to a third party,
which can cause sensitive typed information to be leaked
 Preventions:
 Anti-malware software
 Firewalls
 Using an on-screen keyboard as clicks cannot be
detected
 Using auto-filled passwords instead of typing them out
o Adware
 Spams ads and unwanted pop-ups on websites, apps or
externally
 Preventions:
 Anti-malware software
 Firewalls
 Mindfulness while clicking unknown links
o Ransomware
 Encrypts the user’s data so that it is inaccessible and demands
money in exchange for the data to be unencrypted.
 Preventions:
 Anti-malware software
 Firewalls
 Have data backup
o Trojan Horse
 Malware that is disguised as a genuine app that may trick users
into downloading it
 Preventions:
 Anti-malware software
 Firewalls
 Mindfulness while clicking unknown links
 Pharming:
o A method used by perpetrators to gain access to sensitive information
such as passwords.
o The steps taken are as follows:
 The user will be tricked into clicking a link which will start an
automatic malware download in their secondary storage
 The next time the user enters a certain URL, such as the link to
bank’s website the malware will redirect them to a fake website
instead. The fake website will imitate the real one in order to
trick the user into believing that it is real
 The user will enter personal information which will be sent to the
perpetrator
o Preventions:
 Refrain from clicking unknown links or download suspicious
software
 Ensure the website is genuine by checking its URL
 Use anti-malware

 Phishing
o Phishing is a method similar to pharming used for obtaining sensitive
information from users for perpetrators to use
o The perpetrator will send an email to the user, which will entice them
into clicking a fake website’s link and entering personal information
there.
o Preventions:
 Refrain from clicking unknown links or download suspicious
software
 Ensure the website is genuine by checking its URL
 Social Engineering
o Social engineering is the act of manipulating or deceiving people to
obtain their personal information
o Preventions:
 Don’t trust unknown people asking for sensitive information
 Use access levels

Preventing Cyber attacks

 Firewalls:
o Typically used for a personal computer to prevent suspicious programs
or data to enter or leave the computer
o It checks incoming and outgoing signals
o It filters data packets to prevent traffic and blocks any packets if
required
o It can whitelist or blacklist sites or data allowed to enter based on
criteria set by the user
o It can be hardware or software
 Proxy servers:
o Typically used for protection of larger servers, to divert attacks on them
o It checks, logs and has the ability to block incoming and outgoing
signals
o It can whitelist or blacklist certain IP addresses and signals
o It processes client-side requests primarily
o It allows faster access to websites using cache
o It can hide a server’s internal network
 Access levels
o Typically used in companies
o It provides each user with different permissions to data
o It limits access to data that can be viewed, and limits access to data
that can be changed or deleted
o It is usually linked to usernames or user IDs
 Anti-Malware:
o It is a software that scans the computer it is installed on for malware
o It keeps a record of known malware
o It removes any suspicious software or malware
o It checks data before it is downloaded and stops the download or
warns user if it detects malware.
 Passwords:
o Strong passwords which are changed often, are good defences against
data breaches
 Biometrics:
o The required data for biometrics, such as fingerprints, is unique for
everyone, so it is difficult to replicate
 Two step verification:
o In two step verification extra data is sent to the user’s device, which
has been pre-set by the user. It is difficult to obtain
o The data must be entered into one system, which is difficult to do from
remote locations.

Automated and Emerging Technologies

Automated system
 A device that is operated without human interaction

Features of an automated system

 Sensors
o A type of input device that is used to capture data from its immediate
environment
 Microprocessors
o An integrated circuit that is able to perform many of the functions of a
CPU
 Actuators
o A mechanical part that causes another device or part to move

Industry

 Advantages
o Faster than humans to take action
o Safer
o Low running cost
 Disadvantages
o Expensive to set up
o Enhanced maintenance
o Computerised system; subject to cyber attacks

Agriculture

 Advantages
o Reduced labour costs
o Safer
o Better control of irrigation process and of precious resources like water
 Disadvantages
o Expensive to set up
o Enhanced maintenance (expensive)
Transport

 Advantages
o Allows the same number of cars to use fewer parking spaces
o Avoids traffic disruption in cities
o Cars can fit into smaller spaces
 Disadvantages
o Requires additional maintenance to ensure it correctly functions

Weather (stations):

 Advantages
o Reduced labour costs
o Safer
o Better control of the irrigation process and of precious resources like
water
 Disadvantages
o Expensive to set up
o Enhanced maintenance (expensive)

Lighting:

 Advantages
o Possible to control light sources automatically
o Reduced energy consumption
o Longer bulb life
 Disadvantages
o Expensive to set up
o Enhanced maintenance

Science:

 Advantages
o Consistent and faster results
o Safer
o Fewer highly trained staff needed for each experiment
 Disadvantages
o Expensive to set up
o Security risks
o Less flexible than using human technicians

Robotics:

 A branch of computer science that looks at the creation and use of robots
 Robots have a range of features:
o A mechanical structure or framework. This is the body of the robot
o Electrical components such as:
 Sensors to record its environment, for e.g., the position of the
component it is building.
 Microprocessors, to take the reading from the sensor and decide
the action to perform
 Actuators, to make the robot move.
o They are programmable
o They are used in factory equipment, domestic robots and drones

Robots in medicine

 Advantages
o Saves time for doctors and nurses
o Enables remote surgeries, reducing patient wait times
o Allows resource sharing among hospitals
 Disadvantage
o Network failures can interrupt remote procedures, necessitating backup
systems
o Programming errors and security risks can cause harm

Robots in agriculture

 Advantages
o Saves time
o Increases efficiency with 24/7 operation
o Ensures precision through satellite-guided automation
 Disadvantages
o High initial costs and ongoing maintenance
o Potential job replacement for human workers

Robots in transport

 Advantages
o Creates new jobs in system management
o Enhances efficiency and security
o Reduces risks in hazardous environments
 Disadvantages
o High initial costs
o Security risks from potential tampering
o Job displacement for some workers

Robots in industry

 Advantages
o Continuous operation 24/7
o Reduce human error and enhance accuracy
o Efficiency as automation speeds up production processes
 Disadvantages
o High initial costs
o Potential job replacement for human workers
o Requires new skill sets for fewer workers to manage and maintain
robots

Robots can also handle specific tasks like:

 Packing items into boxes


 Testing products
 Performing precise tasks

Robots in entertainment
 There are different types of robots used for entertainment purposes:
o Interactive toys
o Teaching kids on building robots and program them to perform specific
tasks
o Help people learn about robotics and coding

Robots used for domestic purposes

 There are different types of robots used for domestic purposes


o Vacuum cleaners and lawnmowers:
 Saves people time
 Still requires monitoring
 Cannot go up or down steps

Artificial Intelligence

 A branch of computer science that looks at creating machines that can


simulate human behaviour
 There is a broad range of AI:
o Image recognition: identifies objects or people in images
o Speech recognition: Recognizes and stores spoken words
o Natural language processing: Understands and responds to
unstructured commands
o Computer games: Moves elements or characters based on the
environment
o Diagnosis systems: Assists in medical diagnosis

Features of AI:

 Data collection: Program gathers data from users or sensors


 A set of programmed rules: Rules are used for decision making
 The ability to reason: Logic-based reasoning develops facts from rules
 The ability to learn and adapt: Machine learning allows systems to improve by
training on data

There are two areas of AI

 Machine learning:
o A computer program that can adapt its stored rules or processes
o It can be supervised or unsupervised
o Supervised: the user tells the machine what the data means
o Unsupervised: The data is input then the data learns from the program
and identifies which items of the data resemble one another
 Expert system:
o A system that attempts to replicate the knowledge of an expert
o It is made up of:
 A knowledge base: A list of facts stored in the expert system
 A rules base: It stores the rules upon the knowledge in the
expert system
 An inference engine – part of the expert system that makes
decisions
 User interface – It outputs questions and statements to the user,
and allows the user to input data

You might also like