Introduction to Raspberry Pi
• • A low-cost, credit card-sized single-board
computer developed by the Raspberry Pi
Foundation.
• • Key Features:
• - Quad-core CPU, GPIO pins, USB, HDMI, Wi-
Fi, Bluetooth
• - Runs Linux (usually Raspberry Pi OS)
• • Why it's perfect for IoT:
• - Low power, portable, programmable, GPIO
control
Raspberry Pi Architecture
• • Key Components:
• - CPU, GPU, RAM
• - GPIO Pins (for sensors & actuators)
• - USB, HDMI, Ethernet/Wi-Fi
• • OS Support:
• - Raspbian (Raspberry Pi OS), Ubuntu,
Windows IoT Core
• • Diagram: Block diagram of Raspberry Pi 4
What is IoT (Quick Refresher)
• • Definition: IoT connects everyday objects to
the internet for data exchange and
automation.
• • Core Components:
• - Sensors, Actuators
• - Connectivity (Wi-Fi, MQTT, etc.)
• - Data processing (Cloud, Edge)
• • Use-cases: Smart Homes, Wearables, Smart
Cities, Health Tech
Raspberry Pi as an IoT Gateway
• • Role in IoT Systems:
• - Acts as edge device / gateway
• - Collects sensor data, processes, and sends
to cloud
• • Advantages:
• - Full OS + GPIO access
• - Real-time data handling
• - Wireless capabilities
Interfacing Raspberry Pi with
Sensors
• • GPIO Pin Access: Supports Digital I/O, PWM,
I2C, SPI protocols
• • Example: DHT11 (Temperature & Humidity
Sensor)
• • Python Code Snippet:
• import Adafruit_DHT
• sensor = Adafruit_DHT.DHT11
• humidity, temp =
Adafruit_DHT.read_retry(sensor, 4)
IoT Project Example + Cloud
Integration
• • Mini Project: Smart Weather Station using
Raspberry Pi + DHT11 + ThingSpeak
• • Flow: Sensor → Pi → Python Code → Cloud
Dashboard
• • Cloud Tools: ThingSpeak, Blynk, MQTT
Broker (Mosquitto), Google Firebase
• • Future Scope: AI on edge, voice control with
Google Assistant, camera integration