Working Principle
The GP2Y1010AU0F from Sharp is an optical dust sensor that uses forward-scattering light detection to measure airborne particulate density. An infrared LED (inside the sensor) emits a pulsed beam into a detection chamber. Dust particles entering the chamber scatter light, and a photodiode positioned at an angle (typically 60°) detects the scattered intensity. The output voltage is proportional to particle concentration (µg/m³).
This is NOT the same as a true PM2.5 laser particle counter (like the PMS5003) but provides a cost-effective relative dust density measurement suitable for indoor air quality trends and threshold-based filtering control.
Electrical Characteristics
| Parameter | Value |
|---|---|
| Detection Range | 0–0.5 mg/m³ (500 µg/m³) |
| Sensitivity | ~0.5 V per 0.1 mg/m³ |
| Clean Air Voltage | ~0.9 V (baseline) |
| Supply Voltage | 5 V (LED), 5 V (sensor) |
| LED Pulse Width | 0.32 ms (critical timing) |
| Sampling Interval | 10 ms recommended |
| Current Draw | ~20 mA (max during LED pulse) |
| Output | Analog voltage (proportional to dust) |
| Particle Size | >0.8 µm (cannot distinguish PM2.5 vs PM10) |
Interfacing with an MCU
The sensor has a 6-pin connector (JST). The LED needs a 150 Ω resistor and a 220 µF capacitor on its supply line. Critical timing: Pulse the LED pin LOW for 0.32 ms, sample the analog output 0.28 ms after the LED turns on, then turn the LED off. This timing sequence must be precise for accurate readings.
Calibration
- Baseline voltage: Measure output in clean air; typical baseline is ~0.9 V. Subtract this from all readings
- Dust density formula:
density = (Vout - 0.9) / 5.0in mg/m³ (approximate, sensor-dependent) - Reference calibration: Compare against a known PM2.5 monitor for accurate mg/m3 conversion
- Timing precision: Use
delayMicroseconds()for the 280 µs sample delay; jitter causes noisy readings
Code Example
/*
* GP2Y1010AU0F Optical Dust Sensor — Arduino
* Wiring: LED control → Pin 7, Analog out → A0
* 150Ω + 220µF on LED supply line
*/
#define DUST_LED 7 /* LED control (active LOW) */
#define DUST_ADC A0 /* Analog output */
#define SAMPLE_DELAY_US 280 /* Sample 0.28ms after LED on */
#define LED_OFF_DELAY 40 /* 0.04ms before LED off */
void setup() {
Serial.begin(9600);
pinMode(DUST_LED, OUTPUT);
digitalWrite(DUST_LED, HIGH); /* LED off (active LOW) */
Serial.println("GP2Y1010AU0F Dust Sensor Ready");
}
float readDust() {
digitalWrite(DUST_LED, LOW); /* LED on */
delayMicroseconds(SAMPLE_DELAY_US); /* Wait 0.28 ms */
int adcVal = analogRead(DUST_ADC); /* Sample */
delayMicroseconds(LED_OFF_DELAY);
digitalWrite(DUST_LED, HIGH); /* LED off */
float voltage = adcVal * (5.0 / 1024.0);
/* Approximate dust density (mg/m³) */
float dustDensity = (voltage - 0.9) / 5.0;
if (dustDensity < 0) dustDensity = 0;
return dustDensity;
}
void loop() {
float dust = readDust();
Serial.print("Dust: ");
Serial.print(dust * 1000, 0); /* Convert to µg/m³ */
Serial.println(" µg/m³");
delay(1000);
}
Real-World Applications
Air Purifier Control & Environmental Monitoring
The GP2Y1010AU0F is commonly used in consumer air purifiers to auto-adjust fan speed based on particle density. IoT weather stations, HVAC filter monitoring, and smoke detection prototypes also use it. While not as precise as laser particle counters, its low cost ($3–5) makes it suitable for relative air quality trending and threshold-based alerting.
Limitations
- Not a PM2.5 counter: Cannot distinguish particle sizes; measures total scatter from all particles >0.8 µm.
- Timing critical: Inaccurate LED pulse timing causes noisy, unreliable readings.
- Open chamber: Dust accumulates on the optical elements over time; periodic cleaning required.
- Humidity sensitivity: Water droplets scatter light like particles, causing false high readings in humid air.
- Relative accuracy: Not suitable for regulatory PM reporting; use PMS5003/SPS30 for calibrated PM2.5/PM10.