Learning Goals 5 min
WiFi is great inside your home but dies at 30 m through walls. Bluetooth dies at 10 m. LoRa (Long Range) regularly works at 2–10 km outdoors with milliwatts of transmit power. That's how cattle trackers, parking sensors, and rural weather stations talk to each other. By the end of this lesson you will:
- Explain the three knobs that give LoRa its range: spread-spectrum modulation, sub-GHz frequencies, and very low data rates.
- Identify common LoRa hardware (SX1276 / RFM95 modules, Heltec WiFi-LoRa boards, LoRaWAN gateways).
- Pick the right frequency band for your region (433 MHz in Asia, 868 MHz in EU, 915 MHz in US/AU) and explain why it matters.
Warm-Up 10 min
Hardware (today is mostly theory; build is L04-18):
- 2 × LoRa modules — RFM95W on a breakout, or Heltec WiFi-LoRa boards (popular all-in-one).
- Antennas (don't power on without one — can damage the radio).
The big number
WiFi: ~30 m through walls, ~100 m line-of-sight.
Bluetooth: ~10 m.
LoRa with default settings: 2–10 km line-of-sight with the same milliwatt-class power budget. World records: 700+ km in ideal conditions (mountain top to mountain top).
Trade-off: throughput. LoRa typically does ~300 bps to ~50 kbps — text messages, not video. For sensor telemetry it's plenty.
New Concept · How LoRa achieves range 25 min
Three knobs
- Chirp Spread Spectrum (CSS) modulation: instead of sending a fixed-frequency carrier with bits modulated onto it, LoRa "chirps" — sweeps through a band of frequencies for each symbol. Receivers can correlate noisy chirps and recover the data even when the signal is well below the noise floor. Robust, slow.
- Sub-GHz frequencies (433 / 868 / 915 MHz): lower frequencies penetrate walls and travel farther for the same power, compared to WiFi's 2.4 GHz. The trade-off is lower available bandwidth.
- Low data rates: the slower you transmit, the more energy each bit has, the lower the noise floor your bit needs to clear. LoRa users explicitly trade speed for range with the "spreading factor" (SF).
Spreading factor
| SF | Symbol time | Data rate | Range (typ.) |
|---|---|---|---|
| SF7 | 1 ms | 5.5 kbps | ~2 km |
| SF9 | 4 ms | 1.7 kbps | ~5 km |
| SF12 | 32 ms | 0.3 kbps | ~10 km+ |
SF12 is the "maximum range, glacial speed" setting. SF7 is the "reasonable speed, modest range" default. Pick by need.
Frequency bands by region
Sub-GHz spectrum is regulated. Use the legal band for your country:
| Region | Band | Notes |
|---|---|---|
| Europe (UK, EU) | 868 MHz | Most popular in Europe |
| US, Canada, AU, NZ | 915 MHz | 915 in NA + AU |
| Asia (Malaysia, Singapore, India, China) | 433 MHz or 920 MHz | Check local rules. 433 widely used. |
Mix the wrong band and your modules don't communicate. Modules sold as "LoRa 433" vs "LoRa 868/915" have different antennas, different tuning, and won't talk across bands.
LoRa vs LoRaWAN
- LoRa: the physical radio layer. Two modules talk peer-to-peer. We'll do this in L04-18.
- LoRaWAN: a network protocol on top of LoRa. Devices talk to a gateway; gateway forwards to the internet via TCP. The Things Network (TTN) is a free public LoRaWAN. We'll do this in L04-19.
Duty cycle limits
EU 868 MHz: max 1% duty cycle per device. That means a device can transmit for ~36 seconds per hour, total. LoRaWAN's SF12 takes 1+ second per packet, so you get ~36 packets per hour max.
US 915 MHz: instead of duty cycle, "dwell time" rules — at most 400 ms continuous transmit per packet.
Both intentionally keep the band uncrowded. Plan messages accordingly.
What LoRa is great for
- Cattle / wildlife trackers.
- Parking-spot occupancy sensors (city-wide deployment).
- Smart utility meters.
- Soil moisture monitors on remote farms.
- Weather stations off-grid.
- Asset trackers (bikes, shipping containers).
What LoRa is NOT good for: video streaming, real-time control, anything with kbps+ data needs.
Worked Example · Plan a deployment 20 min
Brief — farm soil-moisture network
You have a 2 km × 1 km farm. You want 20 soil moisture probes scattered across it, each reporting to a single base station in the farmhouse. The probes are battery-powered (target: 2 years on 2 × AA).
Step 1 — pick a topology
Star: 20 probes each talk to one base. Simple. No mesh routing. LoRa naturally fits.
Alternative mesh: probes relay for each other. More complex, longer range, but overkill for 2 km.
Step 2 — pick frequency
Asia: 433 MHz. Match modules. Tune antennas for 433.
Step 3 — pick spreading factor
Each probe sends 10 bytes of data once per 15 minutes = 24 × 4 × 10 bytes = 960 bytes / hour total per probe. At SF9 (1.7 kbps) one packet takes ~50 ms. Comfortably under the 1% duty cycle. Range: 5 km, well over the 2 km farm. Pick SF9.
Step 4 — pick hardware
Probes: cheap RFM95 module + ATmega328 + soil probe + 2 × AA. Deep sleep between transmissions; wake every 15 min. Battery life: ~2 years.
Base: ESP32 + RFM95. ESP wakes when LoRa packet arrives, forwards to MQTT, sleeps.
Step 5 — power budget
- Probe deep-sleep: ~5 µA.
- Probe transmit burst: 100 mA for 50 ms = ~1 µAh per packet.
- Probe per hour: 4 × (1 µAh + 5 µA × 15 min) = ~5 µAh + 4 packets × 1 µAh ≈ 9 µAh / hour. Two AA = 2500 mAh × 1000 = 2.5M µAh. Runtime ≈ 280,000 hours ≈ 30 years. Battery self-discharge becomes the real limit (~5 years).
The maths checks out. LoRa is the right radio.
Step 6 — what would NOT work
- WiFi: 30 m range. Would need ~50 access points. Infeasible.
- Bluetooth: 10 m. Worse.
- 4G cellular: works range-wise but each module costs £30+ and a SIM card with data plan per node. Cost-prohibitive.
- LoRa: each module £5, no service fee, batteries last years. Winner.
Try It Yourself · Paper exercises 15 min
You're in the UK (868 MHz). A friend in the US (915 MHz) wants to relay a LoRa message across the Atlantic. Will it work?
Reveal
No — different bands. Even if range allowed it, the modules can't hear each other. (And 868 transmission is illegal in the US, 915 illegal in the UK.)
Why does LoRa work in basements / rural areas where WiFi doesn't?
Reveal
Lower frequency (sub-GHz) penetrates walls / foliage / soil better than 2.4 GHz. Plus the spreading-spectrum modulation tolerates signal levels far below the noise floor.
SF12 packets take ~1 s on air. Duty cycle limit in EU: 1%. Max packets/hour per device?
Reveal
1% of 3600 s = 36 s of airtime per hour. SF12 packet ≈ 1 s. ~36 packets/hour. Less than once per minute.
You want to stream a 1 fps webcam thumbnail (10 KB JPEG) from a remote hiker's GPS to a base station. Will LoRa do it?
Reveal
No. 10 KB = 80 kbits. SF7 = 5.5 kbps → 14.5 s per frame, well over 1 fps. SF12 → minutes per frame. LoRa is for low-rate telemetry, not images. Use cellular for this brief.
Two LoRa devices accidentally end up on the same frequency at the same SF, transmitting at the same time. What happens?
Reveal
The packets collide; both are lost. LoRa has no inherent CSMA (carrier-sense) protocol like WiFi does. LoRaWAN uses a class-A pattern: device transmits, then opens a brief receive window. Networks rely on duty-cycle limits to keep collisions rare.
Mini-Challenge · Pick parameters for your build 10 min
Design a LoRa link for: a doorbell-style emergency button for an elderly neighbour 1 km away, batteries should last 5+ years.
- Frequency band (your region).
- Spreading factor (range vs latency).
- Packet schedule (once on press; no idle traffic).
- Power budget (deep sleep + occasional transmit + receive ACK).
Reveal one design
- Band: your region's legal sub-GHz.
- SF: SF10 (range ~7 km, packet time ~250 ms). Comfortable for 1 km.
- Packet schedule: only on button press. Optional: tx ack from base + heartbeat once per day.
- Deep sleep ~5 µA. Wake on button = ~100 mA for 300 ms (transmit) ≈ 8 µAh per press. 2 × AA (2500 mAh) → millions of presses possible. Battery self-discharge limits lifetime to ~5–10 years.
Recap 5 min
LoRa = chirp-spread-spectrum + sub-GHz + low data rate = km-range. Spreading factor trades speed for range. Region-specific bands. Duty cycle limits. Plain LoRa is peer-to-peer; LoRaWAN adds gateway-and-network structure (L04-19). Tomorrow we wire two LoRa modules and talk between them.
- LoRa
- Low-power, long-range radio technology using chirp-spread-spectrum at sub-GHz. Owned by Semtech; chip family includes SX1276, SX1278.
- RFM95 / SX1276
- The most popular LoRa chip in hobby modules. RFM95 = breakout board; SX1276 = bare chip.
- Spreading factor (SF)
- LoRa's speed-vs-range tradeoff knob. SF7 = fast (5.5 kbps, 2 km). SF12 = slow (300 bps, 10+ km).
- Sub-GHz
- Radio bands below 1 GHz (433, 868, 915 MHz). Penetrate walls / foliage better than 2.4 GHz.
- Duty cycle
- Maximum fraction of time a device may transmit. EU 868 MHz: 1% per device. Limits packet rate.
- LoRaWAN
- Network protocol on top of LoRa: devices → gateway → internet. Standardised by the LoRa Alliance.
- The Things Network (TTN)
- Free public LoRaWAN network with thousands of community-run gateways worldwide.
- Star topology
- Many devices → one central base / gateway. The natural LoRa shape.
- Mesh
- Devices relay for each other. LoRa doesn't mesh natively; some libraries (LoRa-MAC, Meshtastic) add it.
Homework 5 min
- Look up the legal LoRa frequency band for your region. Note it.
- If you have a LoRa module, check it's the right band. Antenna attached.
- Read ahead to ARD-L04-18 (LoRa Point-to-Point). Bring 2 LoRa modules + 2 ESPs (or 2 Arduino + RFM95) tomorrow.