All paths

Air, heat and humidity sensors

The sensors that watch the air, read close to the wire on the Uno: DS18B20 and DHT22 timing, SHT31 and AHT20 by hand, BME680 pressure and gas, SGP30, real CO2 with an SCD41 and particles with a PMS5003, then a space station cabin air monitor.

Arduino Uno R3Free7 lessons7 h4 chapters2,399 XPEmbedded engineering · Intermediate+150 XP

0 of 7 done

What you will build

3 projects, built step by step

7 lessons in 4 chapters, about 7 hours on a simulated Arduino Uno R3. Free, in your browser, every step checked by the simulator.

Chapter 1 project

DHT22 timing

Read a DHT22 with no library: the start pulse, the sensor’s answer, forty bits told apart by how long they stay high, the checksum and the sign bit, with every pulse width printed.

Open it in the simulator
Chapter 2 project

BME680 and SGP30: pressure and gas

Air pressure into altitude with a BME680, then the two metal-oxide gas sensors: the BME680’s hot plate against a clean-air baseline, and the SGP30’s TVOC and CO2eq, its warm-up and its humidity compensation.

Open it in the simulator
Chapter 3 project

Particles with a PMS5003

A laser particle counter read byte by byte: the 32-byte frame and its checksum, PM1.0, PM2.5 and PM10, a running average graded on the US AQI bands and the WHO guideline, and sleep on the SET pin.

Open it in the simulator
The map

Chapter by chapter

Each lesson opens when the one before it is done, and each chapter ends in a project.

Chapter 1

One wire, one pin

Temperature and humidity on a single data pin, with the timing done by hand.

  1. Open236 XP

    DS18B20 vs the thermistor

    One room read two ways: two DS18B20 probes sharing one wire, each with its own 64-bit address, and a thermistor on an analog pin. ROM codes, CRCs, resolution against conversion time, and when each part is the right one.

    0 of 6 steps

  2. ProjectLocked472 XP

    DHT22 timing

    Read a DHT22 with no library: the start pulse, the sensor’s answer, forty bits told apart by how long they stay high, the checksum and the sign bit, with every pulse width printed.

    0 of 6 steps

4 questions, graded as you go.
Chapter 2

On the I2C bus

Humidity, pressure and gas sensors read from their datasheets with plain Wire calls.

  1. Locked236 XP

    SHT31 and AHT20 on one bus

    Two modern humidity sensors side by side, read with plain Wire calls: the bus scan, the commands, the raw words, Sensirion’s CRC-8, the AHT20’s packed 20-bit numbers, and a dew point from the Magnus formula.

    0 of 6 steps

  2. ProjectLocked498 XP

    BME680 and SGP30: pressure and gas

    Air pressure into altitude with a BME680, then the two metal-oxide gas sensors: the BME680’s hot plate against a clean-air baseline, and the SGP30’s TVOC and CO2eq, its warm-up and its humidity compensation.

    0 of 7 steps

5 questions, graded as you go.
Chapter 3

What you breathe

Real CO2 and fine particles, and the health numbers that grade them.

  1. Locked218 XP

    Real CO2 with an SCD41

    A photoacoustic NDIR sensor that measures CO2 itself, every five seconds: the data-ready flag, the ventilation bands from fresh air to the workplace limit, a warning lamp, and why every CO2 sensor needs calibrating.

    0 of 6 steps

  2. ProjectLocked472 XP

    Particles with a PMS5003

    A laser particle counter read byte by byte: the 32-byte frame and its checksum, PM1.0, PM2.5 and PM10, a running average graded on the US AQI bands and the WHO guideline, and sleep on the SET pin.

    0 of 6 steps

5 questions, graded as you go.
Chapter 4

Boss: the cabin

Every sensor on one bus, keeping a space station module breathable.

  1. Locked267 XP

    Boss: a space station cabin air monitor

    Put it all together: CO2 from an SCD41, temperature and humidity from an SHT31 and particles from a PMS5003, each graded OK, WARN or ALARM, the worst on an LCD, a red lamp and a buzzer, for a module with no window to open.

    0 of 7 steps

3 questions, graded as you go.
Syllabus

Every lesson in the course

All 7 lessons, in order, each with what it covers. Any of them opens in the editor right away.

Chapter 1

One wire, one pin

  1. DS18B20 vs the thermistorOne room read two ways: two DS18B20 probes sharing one wire, each with its own 64-bit address, and a thermistor on an analog pin. ROM codes, CRCs, resolution against conversion time, and when each part is the right one.
  2. DHT22 timingRead a DHT22 with no library: the start pulse, the sensor’s answer, forty bits told apart by how long they stay high, the checksum and the sign bit, with every pulse width printed.
Chapter 2

On the I2C bus

  1. SHT31 and AHT20 on one busTwo modern humidity sensors side by side, read with plain Wire calls: the bus scan, the commands, the raw words, Sensirion’s CRC-8, the AHT20’s packed 20-bit numbers, and a dew point from the Magnus formula.
  2. BME680 and SGP30: pressure and gasAir pressure into altitude with a BME680, then the two metal-oxide gas sensors: the BME680’s hot plate against a clean-air baseline, and the SGP30’s TVOC and CO2eq, its warm-up and its humidity compensation.
Chapter 3

What you breathe

  1. Real CO2 with an SCD41A photoacoustic NDIR sensor that measures CO2 itself, every five seconds: the data-ready flag, the ventilation bands from fresh air to the workplace limit, a warning lamp, and why every CO2 sensor needs calibrating.
  2. Particles with a PMS5003A laser particle counter read byte by byte: the 32-byte frame and its checksum, PM1.0, PM2.5 and PM10, a running average graded on the US AQI bands and the WHO guideline, and sleep on the SET pin.
Chapter 4

Boss: the cabin

  1. Boss: a space station cabin air monitorPut it all together: CO2 from an SCD41, temperature and humidity from an SHT31 and particles from a PMS5003, each graded OK, WARN or ALARM, the worst on an LCD, a red lamp and a buzzer, for a module with no window to open.
Kits

Build it on your bench too

Every lesson runs in the simulator with nothing to buy. When you want the real thing, these kits have the parts.

Have a kit already?

Find your kit

Pick the starter kit you own and run every lesson in its manual with the same parts on the same pins.

See every kit
Questions

About Air, heat and humidity sensors

Is Air, heat and humidity sensors free?

Yes. All 7 lessons of Air, heat and humidity sensors are free and run in your browser, with nothing to install and no parts to buy before you start.

Do I need a real Arduino Uno R3?

No. Every lesson runs on a simulated Arduino Uno R3 with its parts on the canvas, and the simulator checks each step as you go. When you want to build it for real, the same wiring and code work on a real board.

How long does Air, heat and humidity sensors take?

About 7 hours: 7 lessons in 4 chapters, each one a few short steps. Your progress is kept, so you can stop after any lesson and pick up where you left off.

What will I build?

Each chapter ends in a project that puts it together: DHT22 timing, BME680 and SGP30: pressure and gas and Particles with a PMS5003.

Where do I start?

With "DS18B20 vs the thermistor", and each lesson builds on the one before it. New to circuits? Electronics basics is the course that starts from zero.