Component guide · Intermediate · 4 min read
Optical Dust Sensors

Sharp GP2Y1010AU0F, GP2Y1014AU0F and GP2Y1023AU0F, Waveshare and DFRobot GP2Y1010 Modules, DSM501A, Grove PPD42NS, Winsen ZPH02 and MemsFrontier MPM30 Infrared PM Sensors
By Geekobot Learning Team · Updated 29 Oct 2026
On this page
These low-cost sensors shine an infrared LED through the air and measure light scattered by dust. Sharp GP2Y1010 and GP2Y1014 give an analog voltage when you pulse the LED; GP2Y1023 gives a PWM output. DSM501A, PPD42NS, ZPH02 and MPM30 use a heater to draw air and output low-pulse time. They show trends and smoke well, but laser sensors are far more accurate for PM2.5 numbers.
Key specs at a glance
- Principle
- Infrared LED scattering, no laser
- Sharp output
- GP2Y1010/1014 analog; GP2Y1023 PWM
- Pulse timing
- LED on 0.32 ms every 10 ms, sample at 0.28 ms
- Infrared PM sensors
- DSM501A, PPD42NS: low-pulse occupancy; ZPH02, MPM30: UART or PWM
- Supply
- 5V typical, Sharp LED needs 150Ω and 220µF
- Accuracy
- Trend indication, not calibrated µg/m³
Models in this guide
These are alternatives. Pick the one that fits your project; you only need one.
Option 1Sharp Microelectronics GP2Y1010AU0F Dust Sensor, Analog Output, Range: 0~1500 µg/m³₹549
Option 2Sharp Microelectronics GP2Y1010AU0F PM2.5 Dust & Smoke Particle Sensor Module₹373
Option 3Sharp Microelectronics GP2Y1014AU0F Dust Sensor Module – Optical Detection₹619
Option 4Sharp Microelectronics GP2Y1014AU0F Dust Sensor, Analog Output, High Precision, Range: 0~1500 µg/m³₹359
Option 5Sharp Microelectronics GP2Y1014AU0F Optical Dust Sensor, PM2.5, Analog Output, 5V, 0-0.5 mg/m³₹599
Option 6Sharp Microelectronics GP2Y1023AU0F Dust Sensor, Digital PWM Output, High Sensitivity, Range: 0~750 µg/m³₹689
What the Sharp GP2Y1010, GP2Y1014, GP2Y1023 and infrared dust sensors (DSM501A, PPD42NS, ZPH02, MPM30) is
The Sharp GP2Y1010AU0F and similar infrared dust sensors detect dust and smoke by shining an IR LED through an air hole and measuring scattered light.
The Sharp sensor needs a 150Ω resistor and 220µF capacitor on the LED supply; the Waveshare and DFRobot modules include these and a divider so 3.3V boards can read the output. Pulse the LED from a digital pin, wait 280 µs, read the analog pin, then switch it off.
DSM501A and PPD42NS must stand upright so the heater can pull air through. Count the total low-pulse time over 30 seconds and convert it with the datasheet curve. Give them a minute to warm up after power on.
Sharp GP2Y1010, GP2Y1014, GP2Y1023 and infrared dust sensors (DSM501A, PPD42NS, ZPH02, MPM30) pinout
The pins on the Sharp GP2Y1010, GP2Y1014, GP2Y1023 and infrared dust sensors (DSM501A, PPD42NS, ZPH02, MPM30) and what each one does.
| Pin | Function |
|---|---|
| V-LED | LED supply through 150Ω (Sharp) |
| LED | LED control, active low on Sharp |
| Vo | Analog output (Sharp) |
| P1 / P2 | Low-pulse outputs on DSM501A and PPD42NS |
| VCC / GND | 5V supply |
- V-LED
- LED supply through 150Ω (Sharp)
- LED
- LED control, active low on Sharp
- Vo
- Analog output (Sharp)
- P1 / P2
- Low-pulse outputs on DSM501A and PPD42NS
- VCC / GND
- 5V supply
Wiring the Sharp GP2Y1010, GP2Y1014, GP2Y1023 and infrared dust sensors (DSM501A, PPD42NS, ZPH02, MPM30)
Mount the sensor with the air hole unblocked and away from fans that blow straight into it.
| Sharp GP2Y1010, GP2Y1014, GP2Y1023 and infrared dust sensors (DSM501A, PPD42NS, ZPH02, MPM30) pin | Arduino | Note |
|---|---|---|
| Sharp V-LED | 5V via 150Ω, 220µF to GND | Modules have this built in |
| Sharp LED | D7 | LOW turns the LED on |
| Sharp Vo | A0 | Divide for 3.3V boards |
| DSM501A Vout2 | D8 | PM1 and up, pulseIn LOW |
- Sharp V-LED
- Arduino:
- 5V via 150Ω, 220µF to GND
- Note:
- Modules have this built in
- Sharp LED
- Arduino:
- D7
- Note:
- LOW turns the LED on
- Sharp Vo
- Arduino:
- A0
- Note:
- Divide for 3.3V boards
- DSM501A Vout2
- Arduino:
- D8
- Note:
- PM1 and up, pulseIn LOW
Example code
The 0.6 V clean-air offset varies per sensor; measure it in clean air and use your own value.
const int ledPin = 7;
const int voPin = A0;
void setup() {
Serial.begin(9600);
pinMode(ledPin, OUTPUT);
digitalWrite(ledPin, HIGH); // LED off
}
void loop() {
digitalWrite(ledPin, LOW); // LED on
delayMicroseconds(280);
int raw = analogRead(voPin);
delayMicroseconds(40);
digitalWrite(ledPin, HIGH); // LED off
delayMicroseconds(9680);
float v = raw * 5.0 / 1023.0;
float dust = (v - 0.6) * 170.0; // rough µg/m3, set 0.6 V from clean air
if (dust < 0) dust = 0;
Serial.print("Vo "); Serial.print(v, 2);
Serial.print(" V dust ~"); Serial.print(dust, 0); Serial.println(" ug/m3");
delay(1000);
}Setup and tuning
add the 150 Ω resistor and 220 µF capacitor on the LED supply, as in the datasheet.
pulse the LED for 0.32 ms and sample the output 0.28 ms after turning it on.
read the analog voltage and convert to dust density with the datasheet slope.
record the clean-air voltage as zero.
these sensors are indicative; use laser PM sensors for PM2.5 values.
What you need
Shop this list16 of 17 found in our store · ₹8,504
Sharp Microelectronics GP2Y1010AU0F Dust Sensor, Analog Output, Range: 0~1500 µg/m³: the part this guide coversSharp Microelectronics GP2Y1010AU0F Dust Sensor, Analog Output, Range: 0~1500 µg/m³₹549
Sharp Microelectronics GP2Y1010AU0F PM2.5 Dust & Smoke Particle Sensor Module: another version this guide coversSharp Microelectronics GP2Y1010AU0F PM2.5 Dust & Smoke Particle Sensor Module₹373
Sharp Microelectronics GP2Y1014AU0F Dust Sensor Module – Optical Detection: another version this guide coversSharp Microelectronics GP2Y1014AU0F Dust Sensor Module – Optical Detection₹619
Sharp Microelectronics GP2Y1014AU0F Dust Sensor, Analog Output, High Precision, Range: 0~1500 µg/m³: another version this guide coversSharp Microelectronics GP2Y1014AU0F Dust Sensor, Analog Output, High Precision, Range: 0~1500 µg/m³₹359
Sharp Microelectronics GP2Y1014AU0F Optical Dust Sensor, PM2.5, Analog Output, 5V, 0-0.5 mg/m³: another version this guide coversSharp Microelectronics GP2Y1014AU0F Optical Dust Sensor, PM2.5, Analog Output, 5V, 0-0.5 mg/m³₹599
Sharp Microelectronics GP2Y1023AU0F Dust Sensor, Digital PWM Output, High Sensitivity, Range: 0~750 µg/m³: another version this guide coversSharp Microelectronics GP2Y1023AU0F Dust Sensor, Digital PWM Output, High Sensitivity, Range: 0~750 µg/m³₹689
Waveshare GP2Y1010AU0F Dust Sensor Module – Optical Air Quality Sensor: another version this guide coversWaveshare GP2Y1010AU0F Dust Sensor Module – Optical Air Quality Sensor₹1,249
DFRobot Gravity Dust Sensor Adapter – Plug & Play GP2Y1010AU: another version this guide coversDFRobot Gravity Dust Sensor Adapter – Plug & Play GP2Y1010AU₹436
DSM501A PM2.5 Dust Sensor Module for Arduino & Air-Conditioners – Analog Output: another version this guide coversDSM501A PM2.5 Dust Sensor Module for Arduino & Air-Conditioners – Analog Output₹582
Seeed Studio Studio Grove Dust Sensor PPD42NS – PM2.5 & PM1.0 Dual PWM Output: another version this guide coversSeeed Studio Grove Dust Sensor PPD42NS – PM2.5 & PM1.0 Dual PWM Output₹1,159
Winsen ZPH02 PM2.5 Particle Sensor – Infrared Counting, 5V DC, EH2.54-5P Interface: another version this guide coversWinsen ZPH02 PM2.5 Particle Sensor – Infrared Counting, 5V DC, EH2.54-5P Interface₹699
MemsFrontier MPM30-C4 Infrared PM Sensor (4 Pin) – ZH1.5mm-4P Socket, UART/PWM Output: another version this guide coversMemsFrontier MPM30-C4 Infrared PM Sensor (4 Pin) – ZH1.5mm-4P Socket, UART/PWM Output₹509
MemsFrontier MPM30-C6 Infrared Particulate Matter Sensor (6-Pin ZH1.5mm Socket): another version this guide coversMemsFrontier MPM30-C6 Infrared Particulate Matter Sensor (6-Pin ZH1.5mm Socket)₹549- Uno R3 development board: the controller used in the wiring tableFind this part
Dupont jumper wires: for the connectionsDupont Jumper Wires (40 pcs)₹49Closest match, check the specs
Solderless breadboard: to build without solderingSolderless Breadboard₹68
Electrolytic capacitor: bulk capacitance across the supplyElectrolytic Capacitor₹16
Alternatives and when to choose them
- PM2.5 dust sensors: all types side by side.
- Laser PM sensors: accurate PM2.5 numbers.
- PMS5003 and PMS7003: the common laser sensor.
Common mistakes to avoid
- Wrong LED timing.
- Missing LED resistor and capacitor.
- Expecting PM2.5 accuracy.
- No averaging.
Frequently asked questions
Why does my GP2Y10 always read the same?
The LED timing is wrong; pulse and sample at the datasheet times.
Can it measure PM2.5?
Not accurately; use a laser sensor such as the PMS5003 for PM2.5.
Why do readings vary a lot?
The sensor is noisy, so average many samples before using the value.
Do I need the resistor and capacitor?
Yes. They store and limit the current for the LED pulses.
Can it detect cigarette smoke?
Yes. It responds strongly to cigarette and other smoke.
Parts for this guide
Projects that use it
Put this into practice: 12 step-by-step builds in our project library use parts from this guide.
Keep learning
Sources
Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.

