105 Cloud Computing for IoT
105.1 Learning Objectives
By the end of this chapter series, you will be able to:
- Explain the five essential characteristics of cloud computing as defined by NIST
- Compare IaaS, PaaS, and SaaS service models and select the appropriate one for IoT projects
- Evaluate public, private, and hybrid cloud deployment models for compliance and scalability
- Implement identity and access management (IAM) and device security for cloud IoT platforms
- Design production-grade cloud IoT deployments with cost optimization and auto-scaling
Cloud computing for IoT means using powerful remote servers to store and process the enormous amounts of data that connected devices generate. Think of it like using a professional laundry service for an entire hotel – your small devices collect the data, but the heavy cleaning and sorting happens at a facility built for scale.
“I have been collecting temperature readings all day,” said Sammy the Sensor, “but where do they all go?” Max the Microcontroller smiled, “I send them up to the cloud! No, not the fluffy white kind in the sky – the cloud is a bunch of really powerful computers in a big building called a data center, and they store and crunch all your readings for us.”
Lila the LED asked, “But why can’t you just do all that work yourself, Max?” Max laughed, “Because I am tiny! I can handle simple tasks, but when Sammy collects a million readings and we need to spot patterns or make predictions, I need help. The cloud is like having a super-smart friend with an enormous brain who can do the heavy lifting.”
“The best part,” added Bella the Battery, “is that the cloud only charges us for what we use – like paying for just the slices of pizza you eat instead of buying the whole restaurant. That is called pay-as-you-go. And when more sensors join our team and the data piles up, the cloud just grows bigger automatically!”
Key Concepts
- Cloud Computing: On-demand delivery of IT resources (compute, storage, networking, analytics) over the internet with pay-per-use pricing, eliminating the need to own and operate physical data centers
- IoT-Cloud Integration: The architectural pattern connecting resource-constrained IoT devices to cloud infrastructure via MQTT brokers, HTTP APIs, or managed IoT services for scalable data storage, processing, and remote management
- Edge-Cloud Continuum: The spectrum of processing locations from device-local computation through edge/fog nodes to regional and global cloud, with data and logic placed based on latency, bandwidth, and cost requirements
- Scalability: The cloud’s ability to increase or decrease computing resources automatically in response to IoT workload changes, handling millions of devices without pre-provisioned capacity
- Managed IoT Platform: A cloud service that provides device registry, message brokering, protocol translation, and rules-based routing as fully managed infrastructure, eliminating the need to operate these components yourself
- Pay-Per-Use: The cloud billing model where costs scale directly with actual resource consumption (messages processed, storage used, compute time), eliminating idle capacity costs inherent in on-premises infrastructure
105.2 Overview
Cloud Computing has become a fundamental enabler for Internet of Things (IoT) systems, providing the scalable infrastructure needed to store, process, and analyze massive volumes of sensor data. The combination of IoT’s distributed sensing capabilities with cloud computing’s centralized processing power creates powerful applications across domains.
This chapter series explores cloud computing fundamentals, service models, deployment strategies, security considerations, and their specific application to IoT architectures.
Cloud computing provides virtually unlimited scale and powerful analytics for IoT, but introduces latency and connectivity dependencies that make it unsuitable for real-time control.
Remember this rule: Use cloud for storage, analytics, and management; use edge for real-time decisions and offline operation.
105.3 Chapter Series
This comprehensive topic has been organized into six focused chapters:
105.3.1 1. Cloud Computing Fundamentals
What you’ll learn:
- NIST definition and five essential characteristics
- Evolution from grid computing to modern cloud
- Why IoT systems benefit from cloud infrastructure
Key topics: On-demand self-service, rapid elasticity, measured service, resource pooling
105.3.2 2. Cloud Service Models
What you’ll learn:
- Compare IaaS, PaaS, and SaaS for IoT applications
- Choose the right service model for your team and requirements
- Understand serverless vs. container-based architectures
Key topics: Infrastructure as a Service, Platform as a Service, Software as a Service, microservices
105.3.3 3. Cloud Deployment Models
What you’ll learn:
- Evaluate public, private, hybrid, and community clouds
- Design hybrid architectures for compliance and scalability
- Decide where to process data based on latency, cost, and security
Key topics: Public cloud, private cloud, hybrid cloud, edge-cloud integration
105.3.4 4. Cloud Security for IoT
What you’ll learn:
- Implement identity and access management (IAM)
- Apply shared responsibility model across service types
- Secure device credentials with per-device certificates
Key topics: Authentication, authorization, X.509 certificates, multi-region security
105.3.5 5. Production Cloud Deployment
What you’ll learn:
- Transition from development to production-grade infrastructure
- Optimize costs for cloud IoT at scale
- Handle cloud platform rate limits and throttling
Key topics: Cost optimization, throttling, auto-scaling, production readiness
105.3.6 6. Cloud Platforms and Message Queues
What you’ll learn:
- Compare AWS IoT Core, Azure IoT Hub, and alternatives
- Select appropriate message queue technologies
- Calculate capacity requirements for IoT deployments
Key topics: AWS IoT, Azure IoT, MQTT brokers, Kafka, capacity planning
105.4 Worked Example: Cloud Cost Comparison for a 10,000-Sensor Fleet
A logistics company operates 10,000 GPS trackers on delivery vehicles, each reporting location every 30 seconds. They need to choose between AWS IoT Core (PaaS), self-managed MQTT on EC2 (IaaS), and a turnkey fleet SaaS platform. The comparison below covers 12-month total cost of ownership.
Traffic Profile
Messages: 10,000 devices x 2 msg/min x 60 min x 16 hr/day = 19.2 million msg/day
Message size: 150 bytes (lat, lon, speed, heading, timestamp)
Monthly messages: 19.2M x 30 days = 576 million messages/month
Monthly data volume: 576M x 150 bytes = 86.4 GB/month
12-Month Cost Comparison
IoT Data Compression: Bandwidth and Cost Savings
A factory monitoring system has 1,000 vibration sensors sampling at 1000 Hz (1000 readings/second). Each reading is a 32-bit float (4 bytes). Raw data to cloud is expensive. How much can edge compression save?
Given data:
- Sensors: 1,000
- Sample rate: 1,000 Hz
- Sample size: 4 bytes (float32)
- Cellular data cost: $1.50/GB
- Edge gateway: Raspberry Pi 4 (can run compression algorithms)
Option A: Raw data to cloud
Data rate per sensor: \[R_{\text{sensor}} = 1000 \text{ samples/sec} \times 4 \text{ bytes} = 4000 \text{ bytes/sec} = 4 \text{ KB/sec}\]
Fleet-wide data rate: \[R_{\text{fleet}} = 1000 \times 4 \text{ KB/sec} = 4000 \text{ KB/sec} \approx 3.91 \text{ MB/sec}\]
Daily data volume: \[V_{\text{daily}} = 3.91 \text{ MB/sec} \times 86,400 \text{ sec} = 337,824 \text{ MB} \approx 330 \text{ GB/day}\]
Annual cost: \[\text{Cost}_{\text{annual}} = 330 \text{ GB/day} \times 365 \times \$1.50/\text{GB} = \$180,675/\text{year}\]
Option B: Edge FFT compression
Apply Fast Fourier Transform at edge, transmit only frequency spectrum (1/100th of time-domain data for typical vibration analysis):
\[V_{\text{compressed}} = \frac{330 \text{ GB/day}}{100} = 3.3 \text{ GB/day}\]
Annual cost: \[\text{Cost}_{\text{annual}} = 3.3 \times 365 \times \$1.50 = \$1,807/\text{year}\]
Savings: \((180,675 - 1,807)/180,675 = 99\%\) reduction!
Edge compute cost: Raspberry Pi 4 power: 5W × $0.12/kWh × 24h × 365 days = $5.26/year (negligible)
Key insight: For IoT sensor data with predictable patterns, edge pre-processing (FFT, PCA, autoencoders) can reduce bandwidth by 10-1000x. The cellular cost savings pay for edge compute hardware in days, making hybrid edge-cloud architectures mandatory for high-frequency sensor applications.
| Cost Category | AWS IoT Core (PaaS) | Self-Managed EC2 (IaaS) | Fleet SaaS Platform |
|---|---|---|---|
| Message ingestion | $576/mo (576M x $1/M) | $0 (self-hosted) | Included |
| Compute | $150/mo (rules engine) | $800/mo (4x m5.xlarge + MQTT broker) | Included |
| Storage (TimescaleDB) | $200/mo (RDS) | $200/mo (RDS) | Included |
| Device management | $50/mo (IoT Device Mgmt) | $0 (manual) | Included |
| SaaS subscription | N/A | N/A | $2.50/device/mo = $25,000/mo |
| Engineering (setup) | 2 weeks ($8,000) | 8 weeks ($32,000) | 2 days ($1,600) |
| Engineering (ongoing) | 0.25 FTE ($3,750/mo) | 1.0 FTE ($15,000/mo) | 0.1 FTE ($1,500/mo) |
| Monthly total | $4,726 | $16,000 | $26,500 |
| Year 1 total | $64,712 | $224,000 | $319,600 |
Decision Framework
| If your priority is… | Choose | Because |
|---|---|---|
| Lowest total cost with custom features | PaaS (AWS IoT Core) | $65K/year, full control over analytics and dashboards |
| Fastest time to market (days, not weeks) | SaaS | $320K/year but operational in 48 hours with pre-built fleet UI |
| Maximum infrastructure control | IaaS | $224K/year, own the MQTT broker, no vendor message pricing |
| Under 1,000 devices | SaaS | At low scale, SaaS per-device cost ($30K/year) beats PaaS engineering overhead |
The Crossover Point: SaaS is cheaper than PaaS below approximately 1,200 devices (where SaaS monthly cost of $3,000 + $1,500 engineering matches PaaS monthly cost of $4,726). Above that, PaaS scales more economically because message costs grow linearly while SaaS per-device fees compound.
105.5 Learning Path
105.6 Quick Reference
| Topic | Best Chapter |
|---|---|
| “What is cloud computing?” | Fundamentals |
| “Should I use AWS or Azure?” | Platforms |
| “IaaS vs PaaS vs SaaS?” | Service Models |
| “Public vs private cloud?” | Deployment Models |
| “How do I secure IoT devices?” | Security |
| “How do I handle 100K devices?” | Production |
| “Which message broker should I use?” | Platforms |
105.8 Knowledge Check
105.9 Concept Relationships
| Current Concept | Builds On | Enables | Contrasts With | Common Confusion |
|---|---|---|---|---|
| Cloud Service Models | IaaS/PaaS/SaaS abstraction | IoT platform selection | On-premises infrastructure | More abstraction = less capability (false – enables faster delivery) |
| Elastic Scalability | NIST essential characteristics | Auto-scaling IoT workloads | Fixed capacity provisioning | Elastic = free scaling (still costs money per resource) |
| Edge vs Cloud | Latency requirements, real-time control | Hybrid architectures, fog computing | Cloud-only or edge-only | Must choose one or the other (they’re complementary) |
| Cost Crossover | Pay-per-use vs reserved capacity | Platform selection, budget planning | Ignoring TCO | Cloud always cheaper (on-prem wins above 100K devices at stable load) |
| Shared Responsibility | IaaS/PaaS/SaaS security models | Compliance planning, security design | Full provider responsibility | SaaS = zero customer responsibility (false – data classification remains) |
105.10 See Also
- Cloud Computing Fundamentals - NIST model, rapid elasticity, measured service
- Cloud Service Models - IaaS, PaaS, SaaS for IoT applications
- Edge-Fog-Cloud Overview - Complete computing continuum
- Data in the Cloud - Cloud data processing and analytics
- IoT Reference Architectures - How cloud fits standardized frameworks
105.11 What’s Next
| Direction | Chapter | Description |
|---|---|---|
| Start | Cloud Computing Fundamentals | Begin the series with NIST model and essential characteristics |
| Related | Edge-Fog-Cloud Overview | The complete computing continuum from device to cloud |
| Related | Data in the Cloud | Cloud data processing and analytics for IoT |
| Related | IoT Reference Architectures | How cloud fits into standardised IoT reference frameworks |
Common Pitfalls
Designing IoT devices that fail completely when cloud connectivity is lost, without local buffering or degraded-mode operation. Networks fail, VPN connections drop, and cloud regions have outages. Always implement local message queuing and graceful degradation.
Not modeling cloud costs before deployment. AWS IoT Core charges $1/million messages. At 1,000 devices reporting every second, that is 86.4 billion messages/day = $86,400/day. Always calculate projected cloud spend at design time using cloud pricing calculators.
Comparing cloud storage ($0.023/GB-month on S3) to on-premises disk cost ($0.01/GB-month amortized hardware) without including staff costs, hardware refresh, and colocation fees. Cloud storage includes replication, durability guarantees, and zero management overhead.
Concentrating all IoT infrastructure in one cloud provider without failover. When AWS us-east-1 experienced a 7-hour outage in 2021, single-cloud systems went dark. For critical infrastructure IoT, design multi-region failover at minimum.