This week for homework I experimented with the 2YA21 Sharp Infrared Proximity Sensor.
1. Schematic
Soldering on solid core to the stranded wires on the sensor:
2. At around 3 feet, the sensor starts outputting 0 as the analog input. When an object gets to around 4 in, the sensor outputs 630.
3. If an object is closer than the shortest distance, aka 4 in, then the sensor will drop its output values sharply, spanning 630-0 in only about three inches.
4. Inputs at different ranges:
20cm: ~250
40cm: ~150
60cm: ~100
80cm: ~80
Note: When Monica and I were working on this together, we both covered up the back of the sensor, but it seems like in different ways! Mysteriously, when I covered it up, the outputs got very small, and when Monica covered it up, the outputs got very big--and consistently. After asking an instructor about this weird circumstance, it turns out that Monica was touching the circuitry when her hand was covering the back, and since there's resistance in our bodies, it was causing the sensor to go very high!
Comments