Sharp Infrared Distance Sensor 2Y0A21

With this infrared distance sensor from Sharp, you can measure distances within the range of 10 to 80cm. Due to its small size and fast measurement times, the infrared sensor is perfect for robot projects where you want to dodge obstacles. The analog output can be easily evaluated on an Arduino. There, a voltage of 3.1 V corresponds to 10cm and falls proportionally to 0.3 V at 80cm. The distance can be easily calculated using the following formula: Distance (cm) = (3027.4 / AnalogValue)^1.2134. To achieve as precise values as possible, you should calibrate the sensor by taking comparison measurements before use. In our online shop, you can also buy many other components for your Arduino projects, just take a look around!

If you have any questions or problems with the control, or have suggestions for the product description, simply send us an email or use the rating function. We are happy to help.


Connections:

  • Red = +5V
  • Black = GND
  • Yellow = Analog Voltage (3.1V to 0.3V)


Downloads:

Sharp_2Y0A21_Datasheet.pdf


Arduino UNO  Code Example

int AnalogValue;
int Distance;

void setup() {
     Serial.begin(9600);
}

void loop() {
     AnalogValue=analogRead(0);
     Distance=pow((3027.4/AnalogValue), 1.2134);
     Serial.println(Distance);
     delay(100);
}


Technical Details:

  • Measurement range: 10 - 80cm
  • Supply voltage: 4.5 - 5.5V
  • Operating current: approx. 30mA
  • Analog output: Non-linear to distance
  • Time per measurement: 38.3ms ± 9.6ms
  • Cable length: 20cm
  • Weight: 8g


Delivery contents:

  • 1x Sharp Infrared Distance Sensor 2Y0A21
  • 1x Connection cable


Write a review

Note: HTML is not translated!
    Bad           Good

Sharp Infrared Distance Sensor 2Y0A21

  • Brand: purecrea
  • Product Code: 420257
  • Availability: In Stock
  • CHF12,90

  • Ex Tax: CHF11,93

Related Products

APDS-9960 RGB / Gesture / Distance Sensor Module I2C

APDS-9960 RGB / Gesture / Distance Sensor Module I2C

With the ADPS-9960 gesture sensor, you can easily control your Arduino projects with hand gestures. ..

CHF9,90 Ex Tax: CHF9,16

Infrared Sensor TCRT5000 Proximity Switch Breakout Module

Infrared Sensor TCRT5000 Proximity Switch Breakout Module

This infrared sensor is suitable for easily detecting whether something is in front of the sensor. T..

CHF2,90 Ex Tax: CHF2,68

HB100 Radar Sensor Module

HB100 Radar Sensor Module

This microwave radar sensor is perfect as a motion detector, light control, speed measurement, or fo..

CHF9,90 Ex Tax: CHF9,16

Sharp Infrared Distance Sensor 20-150cm GP2Y0A02

Sharp Infrared Distance Sensor 20-150cm GP2Y0A02

With this infrared distance sensor Y0A02 from Sharp, you can measure distances in the range of 20 to..

CHF15,90 Ex Tax: CHF14,71

VL53L1X ToF Distance Sensor up to 4m

VL53L1X ToF Distance Sensor up to 4m

The VL53L1X distance sensor is a Time-of-Flight (ToF) distance module based on the VL53L1X from ST. ..

CHF18,90 Ex Tax: CHF17,48

Gravity Digital Microwave Sensor Radar / Speed Sensor

Gravity Digital Microwave Sensor Radar / Speed Sensor

This microwave sensor/radar sensor employs the Doppler effect to detect moving objects using microwa..

CHF16,90 Ex Tax: CHF15,63

VL53L0X ToF Distance Sensor up to 2m

VL53L0X ToF Distance Sensor up to 2m

The VL53L0X Distance Sensor / Ranging Sensor is a Time-of-Flight (ToF) distance module based on the ..

CHF14,90 Ex Tax: CHF13,78

DFRobot TF Mini LiDAR ToF Laser Range Sensor

DFRobot TF Mini LiDAR ToF Laser Range Sensor

The TF Mini LiDAR from DFRobot is a ToF (Time of Flight) LiDAR sensor that can measure distance to a..

CHF49,90 Ex Tax: CHF46,16

Gravity VL53L0X ToF Distance Sensor up to 2m

Gravity VL53L0X ToF Distance Sensor up to 2m

The DFRobot Gravity VL53L0X distance sensor is a Time-of-Flight (ToF) range module based on the ST V..

CHF15,90 Ex Tax: CHF14,71

A02YYUW Waterproof Ultrasonic Distance Sensor

A02YYUW Waterproof Ultrasonic Distance Sensor

Most ultrasonic distance sensors are not waterproof, which can be a problem if you want to use the s..

CHF25,90 Ex Tax: CHF23,96

LPB40B IP65 LiDAR 40m Distance Sensor UART

LPB40B IP65 LiDAR 40m Distance Sensor UART

The LPB40B IP65 LiDAR 40m Distance Sensor UART is a high-precision sensor for distance and depth mea..

CHF89,90 Ex Tax: CHF83,16

Tags: Sharp, Module, Arduino, Sensor, Breakout, Distance, IR, Infrared, Distance sensor, Distance sensor, Robot, Analog, 2Y0A21, GP2Y0A21YK0F