🌐 AP Computer Science Principles
Unit 4.1 — Internet Structure

Topic: Packets, Protocols, and IP Addressing

🎯 Learning Objectives

By the end of this lesson, students should be able to:

🌍 What is the Internet?

The Internet is a global network of interconnected computers and networks that communicate with each other.

Instead of one giant system, the Internet is made up of many smaller networks connected together.

These networks include:

All of these networks communicate using standard rules and technologies.

📦 Packets

When data travels across the Internet, it is not sent all at once. Instead, the data is broken into small pieces called packets.

Packet Definition

A packet is a small unit of data transmitted over a network.

Each packet contains:

Why Packets Are Used

Packets make communication faster and more reliable.

Example of Packet Transmission

Imagine sending a large file across the Internet.

  1. The file is broken into packets.
  2. Each packet travels independently across the network.
  3. Packets may take different routes.
  4. The destination computer reassembles the packets in the correct order.

📡 Routing

Routing is the process of determining the path that packets take across networks.

Devices called routers help direct packets to their destination.

Routers:

Packets may travel through many routers before reaching their destination.

📜 Protocols

A protocol is a set of rules that define how devices communicate over a network.

Protocols ensure that different computers can understand each other.

Without protocols, devices would not know:

Common Internet Protocols

TCP (Transmission Control Protocol)

TCP is responsible for:

TCP provides reliable communication.

IP (Internet Protocol)

IP is responsible for:

IP determines where packets need to go.

HTTP / HTTPS

These protocols are used for web communication.

Used when:

HTTPS adds encryption for security.

🧭 IP Addressing

Every device connected to the Internet needs a unique identifier. This identifier is called an IP address.

IP Address Definition

An IP address is a unique number assigned to each device on a network. It allows devices to find and communicate with each other.

Example IPv4 Address

192.168.1.1

IPv4 addresses contain four numbers separated by dots. Each number ranges from 0 to 255.

Another example:

8.8.8.8

(Google public DNS server)

🆕 IPv6

Because the Internet has grown so much, IPv4 addresses are running out. To solve this, a new addressing system was created called IPv6.

2001:0db8:85a3:0000:0000:8a2e:0370:7334

IPv6 provides many more possible addresses.

🌐 How Data Travels Across the Internet

Example: Visiting a Website

  1. You type a website URL into your browser.
  2. Your computer creates packets containing a request.
  3. Packets are sent to your Internet Service Provider (ISP).
  4. Routers direct packets across the Internet.
  5. The destination server receives the packets.
  6. The server sends response packets back.
  7. Your computer reassembles the packets and displays the webpage.

🔑 Key Vocabulary

Term Definition
Internet Global network connecting millions of networks
Packet Small unit of data sent across a network
Router Device that directs packets across networks
Protocol Set of rules for communication between devices
TCP Protocol that ensures reliable delivery of packets
IP Protocol responsible for addressing and routing
IP Address Unique identifier for a device on a network
IPv4 Original 32-bit IP addressing system
IPv6 Newer addressing system with far more addresses

🧠 Key Takeaways

AP CSP Exam Tip: The College Board often asks questions about packets traveling different paths, fault tolerance of the Internet, protocols enabling communication, and IP addressing and routing.