Mission
Build this
Build two temperature witnesses, measure their disagreement side by side, then separate them and point a needle toward real cold.
Borrowed parts are labelled below and have a fallback. The registered device ID is fixed; sensing and behaviour decisions remain yours.
Bill of materials
Parts
| Source | Part | Fallback |
|---|---|---|
| ● kit | DHT11 | — |
| ● kit | Thermistor and 10 kΩ resistor | — |
| ● kit | OLED | — |
| ● kit | SG90 servo | — |
Disconnect USB before rewiring. Motors, the relay, and the servo need appropriate power and a shared ground. Never drive an actuator from the ESP32 3V3 pin.
Your case
A draft is invisible. Its fingerprints are not.
Cold air slips down glass, gathers near a door, and borrows warmth from whatever it passes. You may feel the result on your hand, but the air itself leaves no photograph.
Your detective uses two temperature witnesses in two places. A needle points toward the colder side—but only after you prove that the witnesses are not simply disagreeing with each other.
Suspected scene: one sensor near the entrance, one deeper inside.
Complication: the two sensors speak with different accents.
Question: how much difference remains after you translate them?
The central idea
Let the witnesses meet before you separate them
Put both sensors side by side in the same still air. They will probably report different temperatures. That gap is their offset: disagreement caused by the instruments, not by the greenhouse.
DHT11: 20.0 °C
Thermistor: 19.2 °C
offset = 0.8 °Craw gap: 2.1 °C
minus offset: 0.8 °C
scene difference = 1.3 °CExample only. Your offset must come from your own paired readings.
This is a demanding idea hidden inside simple subtraction: measuring a difference requires knowing what difference your instruments create by themselves.
Why will the two sensors never behave exactly alike?
The DHT11 reports whole degrees and responds slowly. The thermistor gives a changing voltage that your conversion turns into temperature. Their housings, response times, self-heating, and mathematics differ.
Keeping both on equal-length leads and away from the ESP32 removes some unfairness. It does not make them identical. Your measured offset is the bridge between them.
Wiring
Two witnesses, one fair setup
Get each temperature reading working alone. Place both sensors on equal leads. Add the display and needle only after the paired readings are stable.
The power rule: Both sensors and the OLED use 3V3. The servo uses a separate 5 V supply. Join the grounds and unplug USB before rewiring.
Bench referenceOpen the exact wiring map
| ESP32 pin | Part | Part marking | Carries |
|---|---|---|---|
3V3 | DHT11 | VCC | 3V3 power |
GPIO 4 | DHT11 | DATA | Digital in/out — add a 10 kΩ pull-up to 3V3 unless the breakout already has one |
GND | DHT11 | GND | Ground |
3V3 | Thermistor | leg A | 3V3 power — top of the divider |
GPIO 34 | Divider midpoint | thermistor + resistor | Analog voltage — ADC1, safe while Wi-Fi runs |
GND | 10 kΩ resistor | free leg | Ground — bottom of the divider |
3V3 | OLED (SSD1306) | VCC | 3V3 power |
GND | OLED (SSD1306) | GND | Ground |
GPIO 21 | OLED (SSD1306) | SDA | I²C bus — display data |
GPIO 22 | OLED (SSD1306) | SCL | I²C bus — display clock |
GPIO 13 | SG90 servo | signal (orange) | PWM to actuator — moves the direction needle |
external 5 V | SG90 servo | V+ (red) | 5V power — a separate supply, never 3V3 |
GND | SG90 servo | GND (brown) | Ground — join servo and ESP32 grounds |
Keep GPIO 34 below 3.3 V and use an ADC1 input because ADC2 stops working with Wi-Fi. Never power the servo from 3V3.
- 3V3 power
- Digital in/out
- Ground
- Analog voltage
- I²C bus
- PWM to actuator
- 5V power
Equal lead lengths help the sensors respond on a similar timescale. Unequal delay can look exactly like a short-lived draft.
When does the needle earn the right to move?
Stillness can be the most honest answer
Your corrected difference will never sit perfectly at zero. The DHT11 changes in whole-degree steps, the thermistor reading wanders, and the two sensors react at different speeds.
Build the quiet middle from your co-located experiment. If the corrected difference wanders between −0.7 °C and +0.6 °C in the same air, a 0.2 °C “draft” is not evidence. It is the instrument breathing.
Your team decides:
- Does the needle show direction only, or direction and strength?
- What sign means the door side is colder?
- How long must a difference persist before you report it?
Your investigation
Run the case in two acts
Same place, same air
- Place both sensors together at the same height.
- Wait ten minutes before judging them.
- Record enough paired readings to see the usual offset and wander.
Door side, inner side
- Move one sensor once. Change nothing else.
- Subtract the offset from every new gap.
- Note door activity and ask whether the corrected difference follows it.
| Moment | Door side | Inner side | Corrected gap | Door activity |
|---|---|---|---|---|
| quiet | ___ °C | ___ °C | ___ °C | none |
| door opens | ___ °C | ___ °C | ___ °C | ___ visitors |
| five minutes later | ___ °C | ___ °C | ___ °C | ___ |
When the case gets strange
A believable number can still be a false clue
The difference jumps one whole degree
The DHT11 reports in whole steps. Treat differences smaller than its repeatable resolution as uncertain.
The offset drifts while both sensors stay together
The ESP32, display, or sunlight is heating one witness. Move both away on equal leads and repeat Act One.
A door opening creates one sharp spike
The sensors respond at different speeds. Wait for several stable readings before calling the spike a spatial difference.
The thermistor becomes noisy when Wi-Fi starts
Use ADC1, such as GPIO 34, and average several quick samples before conversion.
temperature-delta is rejected
Document and register one unit and one sign convention for the free measurement, then publish that consistently.
Choose your theory of the case
What kind of detective team will you become?
The careful translators
Make sensor agreement the main question. Study how stable the offset remains over time.
The cold-corner mappers
Move one witness through marked positions and draw where corrected differences persist.
The door historians
Combine the corrected gap with entrance counts and ask whether activity leaves a thermal trace.
A calm way through the build
Collect four pieces of evidence
dd-01says hello.Prove the garden connection first.
- Both witnesses report separately.
Get the DHT11 and converted thermistor stable before subtracting them.
- The offset has a measured range.
Co-locate the sensors and define the quiet middle.
- The needle moves only for evidence.
Separate the sensors, add the servo, and test with door activity.
The garden handshake
Share what you found
The temperature topic is registered. The delta is your deliberate addition: document its unit, sign, correction, and uncertainty so another team can read it correctly.
Reference temperature
garden/greenhouse-1/draft-node/dd-01/temperatureUnit: celsius
Your added measurement
garden/greenhouse-1/draft-node/dd-01/temperature-deltaUnit: document your choice
Listen beyond your own device.
garden/entrance/counter/gk-01/countEntrance counts give you timing, not automatic causation. Look for repeated patterns before claiming that visitors created the difference.
Finish line
Ready to introduce to the garden
dd-01 stays online and publishes its registered reference temperature.
The reject feed stays clear, including any team-defined temperature-delta messages.
The device reads the entrance counter topic.
The needle moves only when the corrected difference exceeds measured uncertainty.
The build log contains the co-location run, offset, sign convention, separated run, and response-time limitation.
Both sensors remain fixed and protected, the servo is safely powered, and the device label can be scanned.
The clever part is not finding two different numbers. It is earning the right to say that the room, rather than the instruments, made them different.