GP2Y1010AU0F Compact Optical Dust/Smoke Sensor (HCSENS0024)
The GP2Y1010AU0F (HCSENS0024) from Sharp is an optical air quality sensor, designed to sense dust particles. An infrared emitting diode (IRED) and a phototransistor are diagonally arranged into this device, which allows it to detect the reflected light of dust in air. It is very effective in detecting very fine particles like the cigarette smoke.
The sensor has a very low consumption current of only 20mA (MAX) (11mA Typical) whilst the sensor is taking a measurement. The output of the sensor is an analogue voltage proportional to the measured dust density, with a sensitivity of 0.5V/0.1mg/m3.
This sensor comes complete with a connection cable (connector already attached), a 1.5K current limiting resistor for use with the IR LED, and a 220uF 16V capacitor. Please see diagram for how to use these components.
Overall Dimensions: 46mm x 33mm x 18mm
Product code: HCSENS0024Please note: This sensor has been calibrated by the factory. Adjusting the sensitivity potentiometer situated on the back of the module will cause the module to give inaccurate readings.
A suitable capacitor and resistor are supplied with this kit. Do not omit these components as it will cause damage and/or inaccurate reading from the sensorPinout:
Pin 1 (WHT)......IR LED power (5V via supplied 1.5K resistor)
Pin 2 (BLU).......GND
Pin 3 (GRN).......IR LED control (HIGH = IR LED off, LOW = IR LED on)
Pin 4 (YEL)........GND (connected to case)
Pin 5 (BLK)........Sensors analogue output
Pin 6 (RED).......5V powerExample sketch:
/* FILE: GP2Y1010AU0F_Dust_Sensor_Example
AUTHOR: Andrew Davies
This example Arduino sketch will read the analogue voltage from the dust senors output
pin and convert it into a mg/m^3 value. To keep the sketch simple the result is based
on an approximation of the linear part of the output v dust density graph in the
You will need to connect the sensor to your Arduino as follows:
Pin 1 (WHT).......5V via 1.5K resistor
Pin 2 (BLU).......GND
Pin 3 (GRN).......D2
Pin 4 (YEL).......GND
Pin 5 (BLK).......A0
Pin 6 (RED).......5V
Additionally a 220uF capacitor should be connected across the sensors Pin 5 and GND
You may copy, alter and reuse this code in any way you like, but please leave
reference to HobbyComponents.com in your comments if you redistribute this code.
This software may not be used directly for the purpose of selling products that
directly compete with Hobby Components Ltd's own range of products.
THIS SOFTWARE IS PROVIDED "AS IS". HOBBY COMPONENTS MAKES NO WARRANTIES, WHETHER
EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ACCURACY OR LACK OF NEGLIGENCE.
HOBBY COMPONENTS SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR ANY DAMAGES,
INCLUDING, BUT NOT LIMITED TO, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR ANY
REASON WHATSOEVER. */
/* The following values are a rough approximation taken from the datasheet graph.
* To simplify the sketch, calculations are based on the liner operating range
* of the sensor. */
/* Sensor voltage at 0mg/m^3 */
#define VOLTAGE_AT_0_MG_M3 0.6
/* Sensor voltage at 0.5mg/m^3 */
#define VOLTAGE_AT_0_5_MG_M3 3.6
/* As the ADC and the sensor outputs are both linear we can simply scale the output
* voltage of the sensor to convert from volts to mg/m^3. */
#define SCALLING_FACTOR 0.5 / (VOLTAGE_AT_0_5_MG_M3 - VOLTAGE_AT_0_MG_M3)
/* Control pin for sensors IR-LED */
#define LED_PIN 2
/* Sensors output pin */
#define SENSOR_PIN A0
/* Set up serial interface and configure the LED pin */
/* Turn the sensors IR LED on for 320us */
/* Read the sensors analogue output */
Result = analogRead(SENSOR_PIN);
/* Turn the IR LED off */
/* Show the result in volts */
Serial.print("Sensor voltage: ");
SensorVoltage = Result * (5.00 / 1024);
/* Show the result in mg/m^3 */
DustDensity = (SensorVoltage - VOLTAGE_AT_0_MG_M3) * SCALLING_FACTOR;
Serial.print("Dust density: ");
Datasheet:Disclaimer: Libraries, example code, and diagrams are provided as an additional free service by Hobby Components and are not sold as part of this product. We do no provide any guarantees or warranties as to their accuracy or fitness for purpose.
Descriptions and diagrams on this page are copyright Hobby Components Ltd and may not be reproduced without permission.