Year 12

AQA A level Computer Science [P1] Communication Notes

Communication

— Computer Science · AS Level (9618) · Paper 1 · Networks, Devices & the Internet —
★ Exam Tip: Paper 1 is hard because there is so much to remember — so understand → visualise → WRITE it out (don't just re-read!). Many questions are plain common sense. For every topology / device / cable know: advantages · disadvantages · how data moves · where it is used. Learn in your own words — but every point must be there (marks are per point).

1. Networking Basics

Networking: the exchange of information and ideas among people with a common profession or special interest.

(teacher: just like making contacts — two teachers with the same field talk so both benefit.)

Internet: a global network providing communication facilities.

Tip: to define anything, ask why was it created? The internet was made only to connect people & build a network worldwide.

Network: when two or more systems are connected through wire or wireless.

Network with 2 devicesexchange of data
2 devices: no switch needed, direct wire
SwitchNetwork with 3 devicesLAN
3+ devices: need a SWITCH

Advantages of using a network

AdvantageWhat it means
File sharingusers can share files with other users
Hardware sharingusers can share hardware such as printers (send a print job to a colleague's printer)
Software sharingusers can share software applications (e.g. online Word, synced)
Communicationusers can send mail or chat (chat, video call)

Disadvantages of using a network

DisadvantageWhat it means
Costadditional equipment would be required (switch, router, wires, modem…)
Managementnetwork requires management from technical staff (salaries = extra cost)
Malwarevirus can easily spread through an improperly secured network (infected email file; use a firewall)
Hackingonce a device is connected to another device, it is easier to hack
Hacking = accessing someone's data without their permission. It is only possible when there is a connection between the devices — no connection, no hacking.

2. Types of Network — LAN & WAN

NETWORKLANLocal Area NetworkWANWide Area Network

LAN — a network connecting computers in a single room, in a single building (house, office…).

WAN — a network connecting computers on different sites, possibly thousands of kilometres apart.

LAN (one building)LAN — KarachiLAN — Islamabadjoined via the Internet = WAN
LAN is classified by SPACE only (no fixed km). Country / continent / world = WAN. The Internet is the biggest WAN.
Remember: LAN vs WAN is decided by area, not by number of devices. Even 2 PCs = LAN. Two offices (Karachi + Islamabad) linked = WAN. More than 2 devices ⇒ use a switch. A switch joins PCs — it does not join different LANs (a router does).

3. Client–Server Model & Peer-to-Peer

A network can be designed in two different ways (= the architecture of the network): ① Client–Server model   ② Peer-to-Peer (P2P)

ServerClient–Server← clients / usersPeer-to-Peerevery computer = peer / user
client–server: all traffic goes through the server · P2P: every PC linked to every other

Server: a computer or system that provides resources, data to other computers known as clients.

  • A server is a very high-processing computer (several CPUs, huge storage, own OS e.g. Linux / Windows Server) built not to crash when many clients ask at once — it is not just a storage device.
  • Client–server: all data sits on the server. Client requests → server accepts → sends data back. Clients are not interconnected; client→client data goes via the server.
e.g. Serverstores / does
File serverstores files
Print serverhandles printing jobs / print files
Proxy serverinternet data passes through it first before reaching your PC (security)
Web serverwebsites are stored here
Application serverapp data / software
Exam Tip: Scenario questions ask which server fits this place? — school ⇒ web, print, file servers · business office ⇒ proxy + application servers too. Always answer according to the scenario (website ⇒ web server, user's browser = client).

Past-paper style questions — Client–Server

Q12 marks · definition

What is meant by a client–server model of networked computers?

① at least one computer used to "serve"② other computers are referred to as "clients"③ server provides services / applications

Write all three — it is a 2-mark question.

Scenario Adownloading a file from a website

Downloading a file from a website is an example of a client–server application. What is meant by client–server?

• the file is made available from a web server• the user's browser is the client software• the client (browser) requests the file from the server• the desired file is returned to the client computer
Scenario Bbank

A bank has a client–server model. Describe, using the bank as an example, the key features.

• the bank's server holds the customer account data• and performs the requested task• computers used by customers are the clients• that send requests to the server• which returns the results of the request• e.g. a customer asks for a list of recent transactions on their account
Scenario Cemployees & shared files

How does the client–server model enable employees to access the same files from different computers?

• the employees' computers are the clients• the server hosts the shared file ("host" = the file is stored/placed on the server)• an employee can request a file from the server from any client computer• several employees can access the same file (on the server) at the same time

Benefits of client–server

  • Files and resources are centralised (controlled by the organisation — server owner decides who gets what data)
  • Creation / management of security (data on one secure high-end computer; a virus file sent by a client goes to the server first and can be caught)
  • Centralised backup (process of replicating data to the server — if a PC breaks the data is safe)
  • Internet monitoring (organisation can block YouTube / USB etc.)
  • Clients can be less powerful machines, therefore less expensive to buy
  • Saving resources on the server reduces the burden on the client
Backup ≠ Sync backup = a copy stored in another place. Sync = same data shown instantly on all devices (OneNote on phone & laptop).
Centralised vs decentralised: the internet itself is decentralised (nobody owns it) but Facebook / YouTube / Google control huge parts of it — if their server goes down, businesses die. Web 3.0 / blockchain tries to decentralise again (blockchain ≠ P2P file sharing).

Peer-to-peer (P2P)

Qkey features of P2P
• all computers are of equal status (all are "peers" = users)• each computer provides access to resources and data• computers can communicate and share resources• each computer is responsible for its own security
PC APC BPC Chas packet 3has packet 1has packet 2peers swap the missing packets with each other
e.g. BitTorrent: a movie is split into packets 1,2,3 — no single server is overloaded (A-level detail; idea only)

Benefits of P2P

  • It avoids congestion when more clients are simultaneously requesting to download a file (result day: everyone hits one server → crash!)
  • It allows the user to download different parts of files separately
  • The parts are available from more than one host

Drawbacks of P2P

  • Reduced security — each computer is at risk from viruses from other computers (to send directly you must know each other's IP → anyone can reach anyone; that's why torrents get blocked / VPN used)
  • No central management of backup — if the data from one computer is not backed up it is lost to all of them
  • No central management of files — consistency may be difficult to maintain
  • Individual computers may respond slower because they are being accessed by other computers

4. Sub-networks

Internet (WAN)ModemSubnetwork 1SwitchRouterSubnetwork 2
Internet → modem → switch of subnetwork 1 → router → switch of subnetwork 2

A big organisation (e.g. Sales dept + Development dept in one building) splits its LAN into smaller sub-networks joined by a router — each has its own switch and PCs. The reasons & the subnet mask are in section 15.

5. Thin Client & Thick Client

Software HouseAhmedAbdullahdownloaded: code files,data, software (local)accesses data dailyfrom the serverTHICK CLIENTTHIN CLIENT
Software-house story: Ahmed downloaded everything; Abdullah always works through the server
Ahmed (thick): can go home and work remotely; no issue if the server goes down ⇒ more functional.
Abdullah (thin): needs a connection with the server — if the server goes down he cannot work.

Thin client: a device or software which is heavily dependent on having access to a server. A thin client will not work unless it is connected at all times to the server. e.g. web browser (no internet / server down = useless). Online games like PUBG / Fortnite also behave as thin clients — character freezes if net is lost.

Thick client: can either be a device or software that can also work offline. It is still able to do some processing whether it is connected to a server or not. e.g. laptop (a downloaded game like Subway Surfers works offline too).

Words: uptime = time you can keep working (even when server is down) · downtime = server down, nothing works. Power cut = downtime!

Thick client — advantages & disadvantages

AdvantagesDisadvantages
more robust — device can carry out processing even when not connected to serverless secure — relies on the client to keep their own data secure
better uptimeeach client needs to update data and software individually
reduce server demand (less load → server less likely to crash)data integrity issues — many clients access the same data ⇒ inconsistent data
clients have more control
Data integrity example:
a Word file sits on the server and two people edit it ⇒ same file, consistent. But if both download it and edit separately, the two copies differ ⇒ inconsistent / not synchronised.

Thin client — advantages & disadvantages

AdvantagesDisadvantages
less expensive to expand — low-powered, cheap devices can be used (data is on the server)dependent on the server — if the server goes down the device cannot work
data updates & new software installation done centrally on the servermore downtime
more secure — server offers protection against hacking and malware

Difference between thin client and thick client

Thin clientThick client
relies on the servercan work without the server
relies on faster internet (must stay connected)can work on a slow network connection
requires few local resources (SSD, HDD, RAM) — processing is on the serverrelies heavily on local resources
data stored on the serverdata stored on the device itself
Exam Tip: in "difference" questions write both sides together, point by point (thin … / thick …) — one-sided answers lose marks.

6. Network Topologies

Definition: "A network topology is the arrangement with which computer systems are connected to each other."

Types in the syllabus: Bus · Star · Mesh · Hybrid (ring exists but is not in the syllabus). For each one learn: ① advantages ② disadvantages ③ how packets travel ④ where it is used.

A. Bus topology

Bus: uses a single central cable to which all computers and devices are connected. (a terminator sits at each end of the cable and stops the signal.)

TTsingle central cable — every device hangs off it
T = terminator at each end of the bus

Advantages

  • easier to set up / extend (just connect one more device to the cable)
  • less cable required
  • less expensive

Disadvantages

  • if the main cable breaks, the network degrades badly (no device works)
  • difficult to detect / troubleshoot a fault at an individual station (check PCs one by one)
  • efficiency reduces as devices increase (rope with more and more shirts)
  • collisions — not suitable for heavy traffic
  • security is lower — several computers receive the signal sent from the source
How packets travelbus topology
① packets have the address of the recipient② sender transmits data through the bus③ the bus carries data along the central cable④ as the data arrives at each computer, the system compares the address to see if it matches

e.g. A → F: B, C, D, E each compare the address, no match, ignore; F matches ⇒ delivered.

Where usedbus topology
• when a small and temporary network is needed (cheap, quick — just a wire)• networks that do not rely on high data-transfer speed• used in offices or schools

Careful: two PCs joined directly by an Ethernet cable is not a bus topology.

LAN: 3 computers, 1 server, 1 router — bus topology[2] complete the diagram

Draw one single cable with a terminator (T) at each end; connect the router, server, computer A, B and C to that same cable.

TTRouterInternetServerComputer AComputer BComputer C
single central cable + 2 terminators + every device joined to it

B. Star topology

Star: every computer is linked with a central device. The central device can be a switch, hub, server or central computer — computers are not directly interconnected.

every node has its own dedicated link to the centre

Advantages

  • signals only go to the destination ⇒ secure
  • easy to connect / remove a node (one link to the centre)
  • centralised management helps in monitoring the network
  • failure of one node or link doesn't affect the rest
  • fewer collisions (each device has its own line)

Disadvantages

  • if the central device fails, the whole network goes down
  • performance depends on the capacity of the central device (data-transfer rate)
How packets travelstar topology (board heading says "bus" — teacher corrected it to STAR)
① packets have the address of the recipient② sender sends data to the central device③ the central device reads the address and finds where the recipient is④ it directly sends the data to the recipient⑤ it transmits packets only to the recipient
Where usedstar topology
• large organisations · educational establishments• where high performance is a must• found at home as well, where the router acts as the server (data goes device → router → device)
Features of stardescribe the star topology
• must have a central device• each node is connected to the central device• each node has a dedicated connection• each connection must be bi-directional (can send AND receive)
University admissions — star[3] draw a diagram

Server room has the server + printer; the department has three employees, each with a computer, all on a star network.

ServerPrinterEmployee 1Employee 2Employee 3
✓ label every device ✓ link all to the server ✓ use double-headed (bi-directional) arrows
Exam trick: without arrows on the cables (bi-directional) you will not get the full 3 marks. Labelling is essential too.

C. Mesh topology

Mesh: all the devices are interconnected to each other. (there is no central device; a server here would just be one more node linked to every device.)

6 devices ⇒ 15 cables!

Advantages

  • any broken link in the network does not affect the other nodes (many alternative routes)
  • good privacy and security since packets travel along dedicated routes

Disadvantages

  • a large amount of cabling is needed — expensive and time-consuming
  • set-up and maintenance is difficult and complex (expanding means a new cable to every device)
How packets travelmesh topology
① packets have the address of the recipient② sender transmits packets directly to the node③ as each node is connected to at least one other node
Where usedmesh topology
• where establishment of communication is very important — if one wire breaks another route exists• military organisations• emergency services
Efficiency twist: data-transfer efficiency does not drop in mesh (each pair has its own wire). PC processing efficiency does. IP addresses are still used even with cables.

D. Hybrid topology

Hybrid: a combination of two or more topologies (e.g. a bus backbone with star clusters). Little detail needed — "star + bus mixed".

bus backbonestar clusters
bus in the middle + stars hanging off it

Advantages

  • highly reliable — in case of failure there are many sub-networks
  • easy to troubleshoot and fix errors

Disadvantages

  • cost — expensive to set up
  • difficult to manage
  • complex network

Where used: a large organisation with different topologies in each building.

TopologyKey ideaBiggest plusBiggest minusUsed in
Busone cablecheap, easycable breaks / collisionssmall, temporary
Starcentral devicesecure, fewer collisionscentre fails = all downschools, offices, homes
Meshall linked to allreliable, privatecabling costmilitary, emergency
Hybrid2+ types mixedreliablecostly, complexbig organisations

7. Cloud Computing

Definition: Cloud computing refers to data and applications being stored and run on the cloud, so less storage is occupied and less processing is done on the local device.
Beforestorage + processingon the LOCAL device(big firms built own servers!)nowstorage + processingon the CLOUDlight device
the local device is "freed" — e.g. OneNote data lives in Microsoft's cloud, not on your PC

What is the cloud? A big building which contains servers (a data centre) — owned by a company; you rent space and power on it.

Before: even big firms (YouTube, Microsoft) built their own servers in their own buildings. A small business can't afford a server room, expensive hardware, maintenance staff & programming skills — cloud solves that.

Advantages of cloud computing

  • files can be accessed any time, from any device, anywhere in the world with internet
  • no need to carry an external storage device
  • cloud storage can be free (e.g. first 15 GB)
  • most providers have inbuilt backup
  • security could be better
  • can easily increase capacity (scalability)
  • data can be easily shared

Disadvantages

  • can only access the cloud with internet access
  • no control over security
  • can take a long time to upload / download the data
  • can be more expensive in the long term ($5/month for years vs one-time own server)
  • there could be a limit to the amount of storage unless paid for
Scalability example:
A business with 150 students uses 15 GB → starts teaching more subjects → just asks the provider to double the storage (a few dollars). With your own server you'd have to buy hardware — and any hardware fault or backup problem is your responsibility; with cloud, the provider's.
Private cloudPublic cloud
owned by and only accessed by an organisation
e.g. YouTube / Facebook / Amazon own servers
owned by a cloud service provider
e.g. AWS, Microsoft OneDrive, IBM
Application: highly regulated industries and government agencies (data stays secure)Application: for general use (normal file storage / data access)
Exam Tip: recent chapter ⇒ few past papers. Examiner may ask difference between public and private cloud and where each is used — "what you haven't read is what comes."

8. Transmission Media

Data can travel in two ways: wireless or wired. Questions are almost always a comparison — wireless vs wired.

Benefits of wireless (vs wired)

  • devices can be more mobile — not tied to a cable (carry the laptop to any room)
  • easier to set up — no cables to be installed
  • additional devices can easily be added (just open WiFi settings)
  • many different types of device can be connected at the same time (laptop, mobile, iPad, console)

Drawbacks of wireless (vs wired)

  • easier to hack — no dedicated channel; packets travel through the air
  • interference (microwave oven, magnetic fields)
  • signal degrades quickly (weaker / fluctuating, not stable)

Wired media

Two options: ① Copper cable (twisted pair & coaxial)    ② Fibre-optic cable

CableWhat it is
Twisted paira copper cable used for connecting telephones to telephone lines — one cable with four twisted pairs (this is the Ethernet / PTCL cable used for the net)
Coaxiala copper cable, used in long-distance telephone cabling and by cable television companies (PTCL TV)
Fibre opticlight is transferred using the concept of total internal reflection
Light ininner core: HIGH refractive indexouter cladding: LOW refractive indextotal internalreflection
light bounces along the core by total internal reflection (TIR) — even round bends
0101101pulses of light: ON = 1, OFF = 0 (like flashing a torch / SOS)
pulses of light are sent; those pulses have values 0 and 1
Remember: light is very fast ⇒ fibre has high transmission speed. Torch analogy (Stranger Things): light on/off = signals = binary 1/0. Light still weakens a little after long bounces ⇒ a repeater boosts it.
repeaterweak (fading) signalboosted / regenerated
a repeater enhances the SIGNAL strength — not the speed of the signal

Fibre-optic vs copper — benefits & drawbacks

BenefitsDrawbacks
Fibre optic• less interference (light is not affected by magnetic fields)
• greater bandwidth ⇒ faster transmission (bandwidth = rate of data transfer)
• difficult to hack ⇒ more secure
• requires less signal boosting (1–2 repeaters vs ~15–20 for copper)
• consumes less power
• lighter in weight (easier to install)
• installation cost is high
• trained people required to maintain & install
• breaks when bent (tiny wires)
• only transfers data in one direction (a 2nd fibre is needed to receive)
• does not carry power, only data
• difficult to terminate
Copper• installation cost is low
• more flexible
• easier to terminate (just unplug)
• vast knowledge as it has been around for years
• less bandwidth rate
• needs repeaters (signal degrades)
• higher interference (magnetic influence)
Note: copper benefits/drawbacks apply to both coaxial and twisted pair. "Terminate" = remove/end the connection.

Wireless media — electromagnetic waves

WaveFrequency rangeUsed in
Radio waves3 kHz – 3 GHzWiFi — carry data back and forth between the wireless adapter and the router
Microwaves3 GHz – 300 GHzWiFi / TV signals (board: "TV and MRI")
Infrared300 GHz – 400 THzTV remote, automatic doors, escalators
Order: radio < micro < infrared — each range starts where the last ends (3 GHz, 300 GHz). Only 1–2 marks, but cheap to learn!

Satellites: the Earth is curved and signals travel in straight lines, so antenna A cannot reach antenna B directly. The signal is beamed from antenna A up to a satellite orbiting Earth, boosted by the satellite, and beamed back down to be picked up by antenna B.

EarthABstraight beam is blocked by the curve
problem: curvature
EarthABsatellitebeamed upboosted & beamed back
fix: satellite relays the signal
Note: a satellite acts like a repeater (repeaters boost the signal in one direction only) — but strictly, satellites send signals on to another place.

9. Hardware Used in a LAN

The teacher drew these on diagrams so you can see them — don't just memorise "router connects two networks".

SwitchPC3PC4PC1PC2unicast: host → one host
switch forwards a message to ONE chosen host

Switch

A connecting device that can send a unicast message. (unicast message = sent directly to a single host — like a DM to one person in a group chat)

It connects all the PCs of a LAN through its Ethernet (twisted-pair) ports; data comes in and is forwarded to the destination. Wording: it can send unicast — it can also send to many/all.

NIC — Network Interface Card

NIC3 points
• provides the device with a MAC address• to uniquely identify it on the network• allows each individual device to connect to the network

The Ethernet port on a laptop/PC is the NIC (card on the motherboard; can be built-in, or a USB dongle). "Interface" = gives the device the ability to connect to the network. MAC = a unique address per device, so data can be sent to the right device.

WNIC — Wireless Network Interface Card

WNICsame points + wireless
• provides the device with a MAC address• to uniquely identify it on the network• allows each individual device to connect to the network wirelessly instead of a cable• they use an antenna to communicate with networks via microwaves
MAC addressIP address
physical address of the device (NIC)logical address used on the internet / WAN
used inside a local network (LAN, even Bluetooth)used e.g. Gmail / Zoom data over the internet

Cables: fibre optic or copper cable (discussed already in section 8).

Bridge

P1P5P2P6P3P7P4P8P1 → P8: data goes to EVERY computer ⇒ more traffic
without a bridge: whole bus is one segment; also while P1↔P8 talk, nobody else can (collision)
P1P5P2P6P3P7P4P8Bridgesegment 1segment 2bridge stores each PC + its MAC address (P1–M1 … P8–M8)
bridge splits one LAN (bus) into 2 segments
P1P5P2P6P3P7P4P8BridgeP1 → P2same segment ⇒ bridge keeps it on the LEFT side only
P1→P2: stays in segment 1
P1P5P2P6P3P7P4P8BridgeP1 → P8 ⇒ bridge passes it across to the RIGHT side
P1→P8: crosses to segment 2

Bridge: connects two different LANs; divides a single LAN into two to reduce traffic.

Bridge vs switch: a switch is just a connecting device (like a piece of wire) — no MAC list. A bridge stores the MAC addresses so it can decide left or right. In a LAN MAC addresses are used, not IP.

WAP — Wireless Access Point

RouterFirst floor: router + PCsWAPSecond floor
router (1st floor) → cable → WAP (2nd floor) gives wireless coverage on the other floor
  • allows devices to connect to the LAN instead of using a cable
  • easy to move a device to a different location
Note: a WiFi router can work as a WAP but they are not the same.
WiFi routerWAP
gives wired ports + wirelesswired into the router; gives wireless only
assigns IP addresses; behaves like a switchdoes not assign IP — takes IP from the router and passes on
Why WAP? 2-storey house, no signal downstairs: a 2nd router has its own login / password / IP settings ⇒ hard to manage. A WAP keeps one network, one login. (A WAP generates a fresh wireless signal; it doesn't "catch & boost" — that's a repeater.)

Repeater: a device used to boost signals. (e.g. hill blocks A → B, so a tower on the hill relays the signal; long fibre cables have repeaters.)

Router & Gateway

bus LANRouterbus LANSIMILAR networks (same protocol / topology)
router
LANGWGatewayWAN / different protocolDISSIMILAR networks (different protocols)
gateway
RouterGateway
• connects two or more networks  • can connect a network to a WAN  • receives packets and forwards them towards the destination  • using the IP address of the destination  • assigns private IP addresses
connects SIMILAR networksconnects DISSIMILAR networks

Protocol = a set of rules. Different protocols ⇒ use a gateway (LAN ↔ WAN). Home routers have a gateway built in — "almost the same thing".

10. Bit Streaming

Bit streaming = a video (or other media) is turned into bits, put on a server, and sent to your device continuously so you can watch while it arrives.

Qhow is video sent using bit-streaming?
① the data is compressed before transmitting② the video is transmitted continuously as a series of bits③ the video is hosted on a media server④ on download, the server sends data to a buffer on the client's computer⑤ the buffer stores the data from the server⑥ the user's stream software receives the bit stream from the buffer
videocompressedmedia serverbufferstream software0 0 1 1 1 0 … (series of bits)buffer = temporary memory on the user's PC
compress → bits → media server → buffer → stream software (VLC / YouTube player / Twitch)
On-demandpre-recorded (e.g. YouTube video)
① digital video tapes are converted to bit-streaming format for broadcasting on the net = encoding② encoded streaming video is uploaded to a dedicated server③ a link for the encoded video is placed on a website④ user clicks the link to download the encoded video; it is broadcast to the user when they require it⑤ can be paused / go back and rewatch / fast-forward
Real-timelive (cricket match, live class)
① an event is captured live with a video camera② the camera is connected to a computer③ the video signal is converted to a streaming media file, encoded on the computer④ the encoded feed is uploaded to a dedicated streaming server via cable or high-speed internet⑤ the server sends the live images to all users requesting it as real-time streaming⑥ cannot be paused
Encoding = converting video into the bit-stream format a machine understands.
Bit rateimportance of bit rate / broadband speed
• bit rate determines how quickly the data is sent over the internet to the viewers• the higher the bit rate / broadband speed the better the quality of bit streaming and no buffering

Slow net ⇒ the "spinning circle" (buffering). Switch to faster WiFi ⇒ buffering drops.

Benefits

  • no need to wait for the whole file to be downloaded
  • no need to store large files on the user's computer
  • allows on-demand playback
  • no specialist software required for playback in a browser

Drawbacks

  • video hangs if very slow internet
  • video hangs if inadequate buffering capacity
  • loss of internet means can't access films
  • may require specific software to run the file
  • viruses can be downloaded from websites
Study tip (teacher): learn this today — 15 minutes after class and it's done. Say it in your own words (Urdu if needed); exact wording doesn't matter, all the points do.

Difference between World Wide Web (WWW) and the Internet

InternetWorld Wide Web
• a massive network of networks (a WAN made of many LANs)
• stands for Interconnected Networks
• uses the TCP/IP protocol
• a collection of (multimedia) web pages / documents
• stored on websites
• http / protocols are used to transmit data
• web pages are written in HTML
• URLs specify the location of web pages
• web documents are accessed using browsers
Little extras (A2 detail — only for understanding):
Protocol = set of rules. TCP (Transmission Control Protocol) splits big data (e.g. 16 GB) into small packets; IP (Internet Protocol) gets them to the right address. HTTP makes the browser show HTML pages. HTML = text/structure, CSS = style/colours, JavaScript = functionality. Internet = the network; WWW = the collection of websites on it.

11. Collisions — CSMA/CD

CSMA/CD = Carrier Sense Multiple Access with Collision Detection. A set of rules (protocol) for sharing one channel on a bus.

P1P5P2P6P3P7P4P8💥COLLISIONP1 → P8 and P3 → P5 at the same time on ONE channel
two signals meet on the same wire ⇒ collision: data cannot reach its destination (and may be corrupted)
Explain CSMA/CDexam answer
① Carrier Sense Multiple Access with Collision Detection② before transmitting, a device checks if the channel is busy③ if the channel is free, the data is sent④ when transmission begins it listens to the other device (like a traffic policeman watching every road)⑤ if there is a collision, transmission is stopped⑥ both devices wait a different random time, then try again
line idle?send datalisten: collision?stop + random waitthen try againno
if no collision the data gets through; if there is one: stop, wait a random time, retry
Random wait example:
after the collision PC1 is told to wait 5 s, PC3 waits 15 s (random different times). PC1 retransmits first after 5 s ⇒ no second clash.
Functions of CSMA/CD
• monitor traffic• only allow data to be sent when the line is idle• detects collision on the network• halts transmissions when a collision occurs• calculates random wait time• allows re-transmission after a random amount of time
How is a collision detected?

due to a voltage change — devices measure the voltage on the line; a change in voltage = another signal is on the wire = collision.

12. Hardware Devices to Support the Internet

Modem: device that connects the router to the Internet. (mark-scheme wording: "connects a device to the Internet over a telephone line" — telephone line = Ethernet / twisted pair.)

Internet (WAN)ModemRouteroutside the house(from the ISP)inside the house:assigns IPs
Internet → MODEM (just gives the net, NO IP assigning) → ROUTER (assigns IPs, shares to devices)
ISP = Internet Service Provider — the company you take your internet from.

PSTN — Public Switched Telephone Network

The landline (PTCL) system. Your phone has a direct wired connection to the nearest switching centre (an office of the phone company — those poles/lines are communication lines, not packets); data hops from switching centre to switching centre until the one nearest the receiver.

KarachiIslamabadswitchingcentrenot used — the data takes the NEAREST centres
Karachi → nearest switching centre → … → centre nearest Islamabad (wired all the way; copper / twisted pair)
PSTN transmissiondescribe — 3 points
① the PSTN consists of many different types of communication line② data is transmitted in both directions at the same time (= full duplex; walkie-talkie = half duplex)③ the communication passes through different switching centres
DescriptionConventional telephone (PSTN)Internet-based system
connection only in use whilst sound is being transmitted✓
dedicated channel used between two points for the duration of the call✓
connection maintained throughout the telephone call✓
encoding schemes and compression technology used✓
lines remain active even during a power outage✓

Why: PSTN = circuit switching (dedicated line, kept open 24/7, phone line has its own power). Internet = packets via IP, connection only exists while data is sent; compression (e.g. RLE) is possible; router needs power.

Dedicated lines — benefits

  • faster transmission of data
  • more consistent transmission speed
  • improved security

Drawbacks

  • expensive to set up / maintain
  • disruption to the dedicated line would leave no alternative

Modem (again): connects a device to the internet over a telephone line.

13. IP Addressing

IP stands for: Internet Protocol (protocol = a set of rules).

Purposewhat is the purpose of an IP address?
• used to locate a device on a network; it gives an identifier to each device• each address is unique within the network• it allows a device to send data to the correct destination

Analogy: your home address — if you give the right address, the Daraz / Amazon parcel reaches the correct destination. IPv4 was designed with the internet (32 bits ≈ 4 billion addresses) — later not enough ⇒ IPv6.

See your own IP:
open Command Prompt → type ipconfig → you get the IPv4 address, the subnet mask (e.g. 255.255.255.0) and the default gateway. Two people in different networks can have the same private IP (e.g. 192.168.100.10).

Public and private IP addresses

ISPInternet ServiceProvider12.222.54.76PUBLIC IP192.168.0.1private IP192.168.0.2private IP192.168.0.3private IP
ISP gives the ROUTER one public IP; the router gives every device in the house a private IP
Public IPPrivate IP
• registered on the internet (by the ISP)
• gives access to the Internet
• public IP addresses are unique
• assigned by the ISP
• not publicly registered on the internet
• you cannot access the internet by just a private IP
• assigned by the router
192.168.0.1private IP12.222.54.76public IPINTERNETNATpublic
NAT swaps the private IP for the router's public IP so the packet can go out to the Internet
Explain the difference between public and private IPexam answer
• a public address can be reached across the internet; a private address can only be reached internally• NAT (Network Address Translation) is necessary for a private IP to access the Internet, but a public IP does not need NAT• a private address is more secure than a public address• public IPs are provided by the ISP whereas private IPs are assigned by the router• public addresses are unique whereas private addresses are unique within their network but can be duplicated within other networks
Don't confuse: an IP address has two parts — network ID (e.g. 192.168.0 — same for the whole network) and host ID (.1, .2, .3 — each device, assigned by the router). Inside a LAN with no internet, MAC addresses carry the data.

Static and dynamic IP addresses

StaticDynamic
when a computer disconnects and rejoins a network the address does not change
address is assigned by the ISP
each time the computer rejoins a network the address changes
address is assigned by the network OS (the router)
public IPs are static (teacher)private IPs are dynamic — restart the router and devices may get new ones

14. Subnetting & Subnet Mask

New chapter (9618) — no past-paper questions yet, syllabus mainly needs the use of subnetting. Learn the structured answer below.

HUBPC1PC9 (192.168.0.9)
PC1 shouts to EVERY device to find PC9 ⇒ traffic grows, network slows if all devices broadcast
subnet 1HUBsubnet 2192.168.02.xHUBbroadcast doesNOT pass a router
solution: split into subnets joined by routers
Use of subnetting4 points
• splits a large network into a grouping of smaller networks• to help minimise traffic• improving speed and network performance• a subnet mask ensures that traffic remains within its designated subnet

Octets & the IP address

192.octet168.octet1.octet0octetIPv4: 4 octets × 8 bits = 32 bits · each octet is 0 – 255
each group is called an OCTET (8 bits)

An IP address contains two things: ① network address and ② host address.

network address 192.168.1.0Router192.168.1.2 (host address)192.168.1.1
the house/office network = network address; each device in it = a host address

Analogy: your home network has one network address; every individual device inside it has its own host address (192.168.1 is the same for all, only the last number changes).

Classfirst octetexample
A0 – 1271.0.0.1
B128 – 191128.1.0.1
C192 – 223192.168.1.0
D224 – 239224.0.0.0

Subnet mask

Definition: the subnet mask is used to identify how many octets are used as network or host. 255 = network octet · 0 = host octet.
255.0.0.0255.0.0.0 → 1 network octet, 3 host octets255.255.0.0255.255.0.0 → 2 network, 2 host255.255.255.0255.255.255.0 → 3 network, 1 host (home)■ red box = NETWORK octet ■ green box = HOST octet
the more 255s, the fewer host octets (fewer devices fit in the subnet)
Worked idea:
mask 255.255.255.0 with IP 192.168.1.10: first 3 octets (192.168.1) = network; last octet (10) = host. 0 in the last octet ⇒ up to 256 values ⇒ 3 hosts now + capacity for 254 more (teacher's answer). With mask 255.0.0.0 and IP 127.0.0.1: only 127 is the network octet; the other three are host octets.
Broadcasts only look at the network bits: 192.168.01.x stays in its subnet; 192.168.02.1 is a different subnet ⇒ needs a router. Bigger organisations increase host bits and reduce network bits.
Careful: public vs private is decided from the whole IP address — not from the subnet mask. Subnetting converts host bits ⇄ network bits.

15. IPv4 & IPv6 · DNS · URL

(Teacher's recording stopped before this part — notes here come from the board only.)

IPv4 formatIPv6 format
• each IP address should contain 4 numbers (4 groups)
• each in the range 0 – 255
• separated by full stops (not colons)
• the address should not be more than 32 bits
• a valid hexadecimal number
• only one double colon (::) is allowed
• 8 groups, separated by colons
• each group is 4 hexadecimal digits
192.168.0.12001:0800:0000:0000:0000:0000:0000:0000
Qexplain why there is a need for IPv6

the number of IP addresses needed will exceed the number available using IPv4 (32-bit ≈ 4 billion).

DNS — Domain Name Service

  • DNS resolves domain names to numbers (IP addresses)
  • a domain name is an identifier of a website e.g. youtube.com
DomainIP address
Papersdock.com243.66.243.1
yahoo.com222.15.240.1
youtube.com221.16.247.2

DNS looks for the IP address of a particular domain name.

URL — Uniform Resource Locator

(b)(i)[3] meaning of the parts of the URL

http://cie.org.uk/computerscience.html

http — enables the browser to know what protocol is being used to access information in the domaincie.org.uk — is the domain namecomputerscience.html — the file name which is being viewed
  • %20 — the coding for a space, as <space> is not allowed in a URL
  • ? — acts as a separator; separates the URL from all the parameters
How a URL is converted to the matching IPexam steps
URL is parsed→ domain namesent to nearestDNS serverresolver searchesits databasefound ⇒ the IPis returnednot found ⇒ sent tohigher-level DNSstill not found⇒ error message
DNS holds a list of domain names and their matching IPs

16. Quick Recap — Full Chapter Cheat-Sheet

✓ Networks & models
  • Network = 2+ systems joined by wire/wireless · LAN = one room/building · WAN = different sites (Internet = biggest WAN)
  • Client–server: server holds data, clients request ⇒ central security, backup, monitoring, cheap clients · P2P: equal peers ⇒ no congestion, but weak security / no central backup
  • Thin client = needs server always (browser) · Thick = can work offline (laptop). Thin: cheap, central updates, secure; thick: robust, uptime, but less secure & inconsistent data
✓ Topologies
  • Bus: one cable + terminators · cheap/easy · cable break, collisions, low security · small & temporary
  • Star: central device, bi-directional links · secure, fewer collisions · centre fails = all down · schools/offices/home
  • Mesh: all linked · reliable, private · lots of cable · military/emergency · Hybrid: 2+ mixed · reliable but costly
✓ Cloud & media
  • Cloud = data+apps stored/run on servers (data centre) · adv: anywhere, scalable, free, backup · dis: needs internet, long-term cost, no security control · private (one org, govt) vs public (provider, general)
  • Fibre: light, TIR, fast, secure, few repeaters · costly, breaks, one-way · Copper (twisted, coaxial): cheap, flexible · less bandwidth, interference
  • Wireless: radio (3 kHz–3 GHz) · micro (3–300 GHz) · infrared (300 GHz–400 THz) · satellite relays across Earth's curve
DeviceOne-line job
Switchconnects PCs in a LAN, can send unicast (to one host)
NIC / WNICgives device a MAC address, uniquely identifies it, connects it (wirelessly via antenna/microwaves)
Bridgeconnects 2 LANs / splits 1 LAN into 2 using stored MAC addresses ⇒ less traffic
WAPlets devices join the LAN wirelessly instead of cable
Repeaterboosts weak signals
Routerjoins similar networks, to WAN, forwards packets by IP, assigns private IPs
Gatewaysame as router but joins DISSIMILAR networks
Modemconnects router to the Internet (no IP assigning)
✓ Internet topics
  • Bit streaming: compress → bits → media server → buffer → stream software · on-demand (encode, upload, link, can pause) vs real-time (live camera, can't pause) · higher bit rate ⇒ no buffering
  • Internet = network of networks (TCP/IP) · WWW = collection of web pages (HTTP, HTML, URL, browser)
  • CSMA/CD: check line idle → send → listen → collision (voltage change) → stop → random wait → retry
  • PSTN: many lines, both directions at once, switching centres · dedicated lines: fast, consistent, secure but costly, no alternative
  • IP locates a device · public (ISP, unique, internet) vs private (router, needs NAT) · static (ISP, fixed) vs dynamic (router, changes)
  • Subnetting: split big network ⇒ less traffic, faster; subnet mask 255 = network octet, 0 = host octet; broadcasts don't cross a router
  • IPv4 4 groups × 0–255, dots, 32 bit · IPv6 8 groups × 4 hex, colons, one :: · DNS domain → IP · URL = protocol://domain/file