I2C Environmental Sensors
Digital sensors like BME680, BME280, and other I2C devices provide high-precision measurements through a simple two-wire interface.BME680 (I2C)
The BME680 communicates over I2C and supports multiple sensors on the same bus using different addresses.
Source:
/home/daytona/workspace/source/example/sensors/SensorModuleV2/SensorList/BME680SensV2/BasicBME680Sensor/BasicBME680Sensor.ino:1
DHT Digital Sensors
DHT sensors use a single-wire digital protocol for temperature and humidity readings.DHT22/DHT11 Setup
/home/daytona/workspace/source/example/sensors/SensorModuleV2/SensorList/DHTSensV2/BasicDHTSensor/BasicDHTSensor.ino:1
DHT Sensor Types
- DHT11: Lower accuracy (±2°C, ±5% RH), 1Hz sampling
- DHT22: Higher accuracy (±0.5°C, ±2% RH), 0.5Hz sampling
RTC and Time-Based Sensors
Real-time clock sensors maintain accurate time and date:Calibration for Digital Sensors
Even digital sensors can benefit from calibration:/home/daytona/workspace/source/example/sensors/SensorModuleV2/SensorList/DHTSensV2/DHTWithCalibration/DHTWithCalibration.ino:1
I2C Scanner Utility
Find connected I2C devices and their addresses:Common I2C Addresses
| Sensor | Default Address | Alternate Address |
|---|---|---|
| BME680 | 0x76 | 0x77 |
| BME280 | 0x76 | 0x77 |
| DS3231 RTC | 0x68 | - |
| MLX90614 | 0x5A | Configurable |
| INA219 | 0x40 | 0x41-0x4F |
Wiring Diagrams
I2C Bus (Multiple Sensors)
DHT22 Single-Wire Digital
Troubleshooting
I2C Communication Fails
- Check pull-up resistors (4.7kΩ recommended)
- Verify correct I2C address
- Use I2C scanner to detect devices
- Check wire length (keep short, < 1m)
- Verify 3.3V logic levels
DHT Sensor Returns NaN
- Check pull-up resistor (10kΩ required)
- Increase delay between readings (min 2 seconds)
- Verify correct sensor type (DHT11 vs DHT22)
- Check power supply stability
Next Steps
Analog Sensors
Learn about analog sensor interfaces
Multi-Sensor Systems
Build systems combining multiple sensor types