←Back to Subject
Notes
Notes
Study material and explanations
Diagrams
Diagrams
Visualize concepts easily
Mnemonics
Mnemonics
Tricks to remember faster
One Night Prep
One Night Prep
Short and focused revision
Revision
Revision
Quick summary and key points
Important Questions
Important Questions
Practice most relevant questions
Notes

Internet Connectivity & IP Addressing in IoT: IPv4 vs. IPv6

Study material and explanations for Unit 3

Internet Connectivity & IP Addressing in IoT: IPv4 vs. IPv6

Introduction: Giving Every “Thing” a Global Address

Just like every house in Indore or Bhopal needs a postal pin code and house number for delivery packages, every smart device connected to the Internet needs a unique numerical identifier called an IP (Internet Protocol) Address.

With more than 30 billion IoT devices worldwide (far more than the total human population), assigning an address to every single device is a major challenge for computer networks.


1. Principles of Internet Connectivity in IoT

How does a small sensor in a field actually connect to the Internet? There are two main ways:

The Three Stages of IoT Internet Connectivity
1. Local Sensor Network
Wi-Fi, Zigbee, BLE, LoRaWAN
➔ 2. IoT Border Gateway
Translates local packets to IP & routes ➔
3. Global Internet
Public IPv4 / IPv6 Routers & Cloud
  1. Direct IP Connectivity: The device has built-in Wi-Fi or cellular hardware (like an ESP32 or a 4G SIM module) and connects directly to the Internet with its own IP address.
  2. Gateway-Mediated Connectivity: Tiny, battery-powered sensors (using Bluetooth or Zigbee) do not have the power or memory to run full IP software. Instead, they send data to a nearby IoT Gateway, and the gateway forwards the data to the Internet.

2. The Great Addressing Problem: IPv4 vs. IPv6

Address Space Comparison: IPv4 vs. IPv6
IPv4 (32-Bit Address Space)
Total addresses: 2³² ≈ 4.3 Billion.
Already completely run out because of smartphones, laptops, and servers!
IPv6 (128-Bit Address Space)
Total addresses: 2¹²⁸ ≈ 3.4 × 10³⁸.
Practically infinite; enough to give a unique IP address to every grain of sand on Earth!

Detailed Comparison Table for DAVV Exams:

Parameter IPv4 IPv6
Address Length 32 bits (4 bytes) 128 bits (16 bytes)
Notation Format Dotted Decimal: 192.168.1.1 Hexadecimal Colon: 2001:0db8:85a3::8a2e:0370:7334
Total Address Pool 4.29 Billion (Exhausted!) 3.4 × 10³⁸ Addresses (Virtually infinite!)
Address Setup Manual or via DHCP server Stateless Address Autoconfiguration (SLAAC)
Header Size Variable (20 to 60 bytes) Fixed (40 bytes) for faster routing
Need for NAT Yes, Mandatory (Many devices share 1 public IP) No NAT Needed (Every device gets a real global IP)
Built-in Security IPsec is an optional add-on IPsec is built-in by default

3. Why is IPv6 Mandatory for the Future of IoT?

  1. No More NAT (Network Address Translation):
    • In IPv4, all your home smart bulbs and plugs hide behind your single home Wi-Fi router’s IP address. This makes it difficult for an external server to reach a specific bulb directly.
    • IPv6 gives every single bulb, sensor, and plug its own permanent global address, allowing true direct communication!
  2. SLAAC (Auto Configuration):
    • If you install 1,000 smart streetlights across a city, setting IP addresses manually is impossible.
    • With IPv6 SLAAC, a device turns on, reads the local router’s prefix, and automatically configures its own unique IP address!
  3. Better Multicast Support:
    • IPv6 allows sending a single firmware update to thousands of smart electric meters at the exact same time without slowing down the network.

4. Static vs. Dynamic IP Addressing in IoT

  • Static IP Addressing: The device is permanently configured with a fixed IP address that never changes.
    • Used for: Central IoT Gateways, MQTT Brokers, and Web Servers so client devices always know where to send readings.
  • Dynamic IP Addressing: The device is given a temporary IP address by a router or DHCP server.
    • Used for: Smartwatches, mobile wearables, and connected cars that move between different Wi-Fi networks and mobile towers.

💡 DAVV Exam Preparation Tips

5-Mark Question: “What is IPv4 address exhaustion? Why is IPv6 essential for the growth of IoT?”

  • IPv4 Exhaustion: IPv4 only offers 4.3 billion addresses (2³²), which is completely finished due to laptops and smartphones.
  • Why IPv6: Offers 2¹²⁸ (3.4 × 10³⁸) addresses, enough for tens of billions of smart devices.
  • Key Benefits: Removes the need for NAT and allows devices to auto-configure their own IP addresses using SLAAC.

10-Mark Question: “Explain Internet Connectivity Principles for connected devices. Compare IPv4 and IPv6 across address length, notation, configuration, and security. What are the advantages of IPv6 for massive IoT deployments?”

  • Explain Direct IP vs Gateway-mediated connection.
  • Draw the IPv4 vs IPv6 comparison table with all 7 points.
  • Detail why IPv6 is ideal for IoT: Infinite address pool, no NAT bottlenecks, SLAAC plug-and-play setup, and built-in IPsec security.