←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
Revision

Internet of Things · Unit 5 Revision

Quick summary and key points for Unit 5

IoT Design Methodology: Specifications & Architecture Views

Overview: For a hostel water tank, start with “avoid overflow” as the purpose.

Why Do We Need an IoT Design Methodology?

  • Building an IoT project is much more challenging than writing a simple software program in C++ or Python.
  • Physical electronic hardware and sensors
  • Microcontrollers (like Arduino or ESP32)
  • Wireless networking (Wi-Fi, Zigbee, cellular)
  • Cloud databases and server APIs
  • Mobile phone apps and web dashboards

The 8-Step IoT Design Methodology

  • Begin with purpose and requirements before modelling the domain, data and services.
  • Step 1 Purpose & Requirements
  • Step 2 Process Specification
  • Step 5 Service Specifications
  • Step 6 IoT Level Specification
  • Step 7 Functional & Operational Views
  • Step 8 Integration & Application

View diagram · The 8-Step IoT Design Methodology Flow

Step-by-Step Practical Example: Smart Home Garden System

  • Let’s understand all 8 steps using a simple project: An Automatic Garden Watering System.
  • Step 1: Purpose & Requirements: Purpose: Automatically check soil moisture in the home garden and turn on the water pump when the soil becomes too dry.
  • Rules: Read soil moisture every 15 minutes.
  • Budget/Limits: Must run on a small battery and Wi-Fi, with a hardware cost under ₹1,500.
  • Step 2: Process Specification: Draws a clear flowchart of how the system operates step-by-step:
  • Deep Sleep MCU sleeps drawing minimal microamps; RTC timer wakes device every 15 mins
  • Sample Sensor Powers up probe, takes moisture reading, evaluates threshold
  • Actuate Relay If moisture < 30%, activates pump relay for designated duration

View diagram · Low-Power IoT Sensor Wake-and-Sleep Execution Cycle

Functional View vs. Operational View

  • In DAVV BCA exams, this comparison is very frequently asked:
  • Functional View Specification Answers “WHAT does the system do?” Organizes the system into logical functional blocks (Sensing, Control, Security,…
  • Operational View Specification Answers “WHERE and ON WHAT hardware does it run?” Selects the exact physical chips, cloud servers, and communication…
  • Main Question: WHAT does the system do?
  • Focus: Logical blocks and software capabilities
  • Examples of Decisions: Sensing logic, user login rules, alert conditions
  • Target Audience: Software architects and system analysts

View diagram · Architecture Perspectives

Steps 7 & 8: Integration and Application Development

  • Step 7 (Device & Component Integration): Connect the real hardware on a breadboard: wire the sensor to GPIO pins, add power supply, and write the Arduino C++…
  • Step 8 (Application Development): Build the final user interface — creating the mobile app (Flutter / Android) and cloud dashboard with toggle switches,…

IoT Privacy & Security Solutions: Threats & Countermeasures

Overview: A smart meter can reveal household routines even when it sends no names.

Why is IoT Security Uniquely Challenging?

  • Securing an IoT system is much harder than securing a laptop, bank server, or desktop computer:
  • Tiny Memory & Limited Battery: A ₹300 microcontroller has only a few kilobytes of RAM and a small processor.
  • Physically Exposed Outdoors: Unlike cloud servers locked inside secure air-conditioned data centers, IoT sensors, streetlights, and water meters sit…
  • Billions of Targets: If hackers find a vulnerability in a popular smart bulb or CCTV camera, they can hijack millions of devices at once to…

Layer-Wise IoT Security Threats & Attacks

  • In university exams, IoT security attacks are organized across the three main layers:
  • 1. Perception Layer Attacks Physical hardware theft, wire tampering, radio jamming of wireless signals, and eavesdropping on unencrypted sensor data.
  • 2. Network Layer Attacks Man-in-the-Middle (MITM) snooping, Denial of Service (DoS/DDoS) floods, and Sybil attacks (faking multiple device…
  • 3. Application Layer Attacks Weak/default passwords (like ‘admin/admin’), SQL injection on cloud databases, and malicious firmware uploads.
  • Perception (Physical): Hardware theft, radio jamming, physical tampering
  • Network (Transmission): Man-in-the-Middle (MITM), DoS/DDoS, routing attacks
  • Application (Cloud): Weak passwords, unpatched bugs, stolen API keys

View diagram · Threat Landscape Across IoT Architectural Layers

Comprehensive IoT Security Solutions

  • To protect IoT systems against hackers, engineers use multiple layers of defense:
  • A. Lightweight Cryptography (LWC): Heavy encryption algorithms like RSA-2048 require too much CPU power and battery.
  • Symmetric Encryption (AES-128): Fast and lightweight encryption where both sender and receiver use the same secret key to scramble sensor readings.
  • Asymmetric Encryption (ECC - Elliptic Curve Cryptography): Provides the exact same military-grade security as 2048-bit RSA, but uses tiny 256-bit keys, using far less battery and…
  • B. Secure Communication Protocols (TLS & DTLS): TLS 1.3: Secures TCP-based protocols like MQTT and HTTPS using encryption certificates.
  • DTLS (Datagram Transport Layer Security): A lightweight version of TLS designed specifically to secure UDP-based protocols like CoAP.
  • C. Device Identity & Mutual Authentication (mTLS): Every physical smart device is given a unique digital identity (an X.509 digital certificate) burned into a secure crypto chip.
  • Mutual Authentication (mTLS): The device proves its identity to the cloud, AND the cloud proves its identity to the device.

View diagram · Secure IoT Communication Stack

Privacy Preservation Techniques in IoT

  • When millions of smart home cameras, smartwatches, and car GPS modules upload data 24/7, user privacy must be protected:
  • Data Anonymization Removing personal names, phone numbers, and exact home GPS coordinates before saving to cloud databases.
  • Differential Privacy Adding small, controlled statistical noise to data so individual people cannot be identified from overall group trends.
  • Edge / Local Processing Smart cameras process facial AI directly on the camera hardware and upload only a text count (“3 people”), never streaming…
  • Role-Based Access Control Strict login rights: users can only see their own smart plug data, while technicians only see combined city averages.

View diagram · Privacy Preservation Strategies

Arduino Uno: Architecture, GPIO Pinout & Programming

Overview: To read a switch, configure the pin as an input and give it a defined idle level.

What is Arduino Uno?

  • Arduino Uno is an open-source electronics development board that is world-famous among college students, hobbyists, and engineers.
  • Microcontroller Chip ATmega328P (8-bit AVR RISC architecture)
  • Clock Speed 16 MHz crystal oscillator (runs 16 million instructions/sec)
  • Operating Voltage 5V DC (Can take 7V to 12V through the black DC power jack)
  • Memory Breakdown 32 KB Flash (stores your code), 2 KB SRAM (variables), 1 KB EEPROM (permanent storage)

View diagram · Arduino Uno R3 Key Hardware Specifications

GPIO Pinout and Hardware Layout

  • The Arduino Uno board has 28 external header pins where you can plug jumper wires:
  • Digital I/O Pins: Pins 0 to 13 (14 pins)
  • PWM Output Pins: Pins 3, 5, 6, 9, 10, 11 (marked with ~)
  • Analog Input Pins: Pins A0 to A5 (6 pins)
  • Hardware Serial (UART): Pin 0 (RX) & Pin 1 (TX)
  • SPI Interface: Pins 10 (SS), 11 (MOSI), 12 (MISO), 13 (SCK)
  • I2C Interface: Pin A4 (SDA) & Pin A5 (SCL)

View diagram · Arduino Uno Pinout and Microcontroller Layout

Arduino Software & Programming Model

  • Arduino programs are written in C/C++ using the free Arduino IDE software.
  • Common Built-In Arduino Functions: pinMode(pin, mode): Configures a pin as INPUT or OUTPUT (e.g.
  • digitalWrite(pin, value): Sets a digital pin to HIGH (5V) or LOW (0V).
  • digitalRead(pin): Reads whether a pin is receiving HIGH or LOW.
  • analogRead(pin): Reads an analog pin (A0-A5) and gives a number from 0 to 1023.
  • analogWrite(pin, value): Sends a PWM value (0 to 255) to control LED brightness or motor speed.
  • delay(ms): Pauses program execution in milliseconds (e.g.
  • Serial.begin(baud): Opens communication with computer Serial Monitor (e.g.

Practical IoT Example: Automated LDR Streetlight

  • Here is a simple, complete Arduino sketch that turns an LED/Relay on pin 13 ON when it gets dark outside using an LDR light sensor on pin…

Raspberry Pi Architecture, Interfaces & Arduino Comparison

Overview: A Raspberry Pi can run a full operating system and host a camera dashboard.

What is Raspberry Pi? (Single Board Computer)

  • A Raspberry Pi is not just a microcontroller board like Arduino — it is a complete, credit-card-sized Single Board Computer (SBC)!
  • Multi-core 64-bit ARM processor
  • 2 GB to 8 GB of RAM
  • USB ports for keyboard and mouse
  • HDMI ports to plug into a computer monitor or TV
  • Built-in Wi-Fi, Bluetooth, and Ethernet port
  • Processor (SoC) Broadcom BCM2711, Quad-core Cortex-A72 64-bit ARM CPU @ 1.5 GHz
  • System Memory (RAM) 2 GB, 4 GB, or 8 GB LPDDR4 SDRAM

View diagram · Raspberry Pi (Model 4B) Hardware Highlights

Onboard Hardware Interfaces

  • The Pi connects displays, cameras, storage and network interfaces through different ports.
  • Essential Hardware Ports: 40-Pin GPIO Header: Connects directly to electronic sensors, buttons, LEDs, and relays.
  • CSI (Camera Serial Interface): Special ribbon cable port to connect the official Raspberry Pi high-definition camera module.
  • DSI (Display Serial Interface): Ribbon cable port for small LCD touchscreens.
  • USB Ports: 2 fast USB 3.0 ports (blue) for external hard drives, and 2 standard USB 2.0 ports (black) for mouse and keyboard.
  • MicroSD Card Slot: Acts as the main hard drive holding the Linux OS, software, and files.

View diagram · Raspberry Pi 4 Hardware Interfaces & Peripherals

The 40-Pin GPIO Header Breakdown

  • The 40-pin header allows the Raspberry Pi to control physical circuits using 3.3V logic:
  • Power Pins 2 × 5V power pins, 2 × 3.3V power pins, and 8 × Ground (GND) return pins.
  • Digital GPIO Pins 26 programmable digital input/output pins running strictly at 3.3V.
  • I2C Bus Pins Pin 3 (SDA) and Pin 5 (SCL) for two-wire digital sensors and displays.
  • SPI & UART Pins Hardware SPI pins (MOSI, MISO, SCLK, CS) and UART serial pins (TX, RX).
  • ⚠️ CRITICAL WARNING FOR STUDENTS:
    • Voltage Level: Arduino Uno uses 5V logic on its pins, but Raspberry Pi GPIO pins work strictly at 3.3V logic.
    • No Built-In ADC: Raspberry Pi has NO analog input pins.

View diagram · 40-Pin Header Capabilities (3.3V Logic)

Raspberry Pi vs. Arduino Uno: The Ultimate Comparison

  • This is one of the most frequently asked 10-mark questions in DAVV BCA exams:
  • Device Type: Microcontroller Board (MCU)
  • Processor Chip: Microchip ATmega328P (8-bit AVR RISC)
  • Clock Speed: 16 MHz
  • RAM (Memory): 2 KB
  • Storage: 32 KB Flash memory
  • Operating System: No OS (Runs one single program in a loop)

When Should You Choose Which in an IoT Project?

  • A small controller suits simple, low-power repeated actions.
  • Choose Arduino Uno When • Your task is simple: read a sensor, turn on a relay.
  • Choose Raspberry Pi When • Complex tasks: Computer vision, face recognition, or AI.

View diagram · Selection Decision Matrix

IoT Case Study: Smart City Streetlights Control & Monitoring

Overview: A streetlight can use a light sensor to decide whether it is dark and a current sensor to check whether the lamp actually came on.

Introduction & Problem Statement

  • In traditional city street lighting (like older setups in Indore, Bhopal, or Jabalpur), streetlights are turned ON and OFF manually by municipal…
  • Huge Wastage of Electricity: Streetlights stay turned ON at 100% full brightness all night long (for 10 to 12 hours), even from 1:00 AM to 5:00 AM when…
  • High Municipal Bills: Streetlights alone consume up to 40% of a city municipal corporation’s entire electricity budget.
  • No Automatic Fault Alerts: When a light bulb burns out, the municipal corporation only finds out days later when citizens complain or patrol vans spot…

System Architecture & Hardware Components

  • The system connects every streetlight pole in the city to a central cloud dashboard:
  • Sensing Layer LDR (Sunlight) + PIR (Car/Human Motion) + ACS712 (Current Sensor)
  • Controller Layer ESP32 / NodeMCU microcontroller with built-in Wi-Fi / LoRa
  • Actuator & Lamp PWM Dimmer Circuit + Energy-saving LED Streetlight
  • Wireless Telemetry Lightweight MQTT messages sent over Wi-Fi / 4G / LoRaWAN
  • City Control Dashboard Live map of all street poles, power graphs, and fault tickets
  • Detailed Hardware Breakdown: LDR (Light Dependent Resistor): Senses daylight.
  • PIR / Radar Motion Sensor: Detects approaching vehicles, motorbikes, and pedestrians from 30 to 50 meters away.

View diagram · Smart Streetlight IoT Architecture

Step-by-Step Operating Logic & Modes

  • The controller combines light or motion input with a lighting rule.
  • Day/Night Check LDR reads ambient light; turns lamp 100% OFF during daytime
  • Motion Detection PIR sensor detects traffic; surges to 100% or dims to 30% idle mode
  • Current Sensing ACS712 measures electrical draw across lamp fixtures
  • Fault Dispatch If switch ON but current = 0A, triggers MQTT alert to city repairs
  • The 4 Operational Modes: Mode 1: Daytime Standby (0% Power): During sunny daylight, the streetlight remains completely OFF.
  • Mode 2: Quiet Night Conservation (30% Power): During late-night hours when no cars or pedestrians are around, the streetlight stays at a gentle 30% brightness.
  • Mode 3: Vehicle Approach (100% Power): The instant a car or bicycle approaches, the motion sensor detects it and immediately surges the light to 100% full…

View diagram · Smart City Streetlight Automation & Fault Detection Flow

Key Benefits for Smart Cities

  • Adaptive lighting can save energy by reducing output where full light is unnecessary.
  • 50% to 70% Energy Savings Dimming lights when roads are quiet cuts municipal electricity bills by more than half.
  • Instant Repair Dispatch Repair turnaround drops from 3-5 days down to a few hours thanks to automatic sensor alerts.
  • Longer Bulb Lifespan Running LEDs at 30% brightness keeps internal heat low, doubling the working life of the bulbs.
  • Lower Carbon Emissions Saving millions of units of electricity reduces the burning of coal at power stations.

View diagram · Quantified Impact on Smart Cities