ข้อมูล
น้ำหนัก
บาร์โค้ด
ลงสินค้า
อัพเดทล่าสุด
รายละเอียดสินค้า
เซ็นเซอร์ Infrared Sharp GP2Y0A02 infrared distance sensor 20-150cm
(มีสต็อกสินค้าในประเทศไทยพร้อมจัดส่ง)
  
Features:
 
1. Distance measurement range: 20 to 150 cm 
2. Signal output type: voltage analog signal 
3. Package size: 29.5×13×21.6 mm 
4. Power consumption: nominal value 33 mA 
5. Supply voltage: 4.5 to 5.5 V
 
6. Accuracy is related to the number of AD digits collected and the conversion calculation formula. 10AD can generally reach 0.1CM.
 
GP2Y0A02YK0F is a distance measurement sensor module from Sharp . It consists of three parts: PSD (position sensitive de te ctor) and IR ED (infrared emitting diode) and signal processing circuit. Due to the triangulation method, the material of the measured object, the ambient temperature and the measurement time do not affect the measurement accuracy of the sensor. The sensor output voltage value corresponds to the detected distance. By measuring the voltage value, the distance of the detected object can be obtained, so this sensor can be used for distance measurement, obstacle avoidance and other occasions.



https://github.com/guillaume-rico/SharpIR

 */
  // Sharp IR code for Robojax.com
#include "SharpIR.h"
 
#define IR A0 // define signal pin
#define model 1080 // used 1080 because model GP2Y0A21YK0F is used
// Sharp IR code for Robojax.com
// ir: the pin where your sensor is attached
// model: an int that determines your sensor:  1080 for GP2Y0A21Y
//                                            20150 for GP2Y0A02Y
//                                            430 for GP2Y0A41SK   
/*
2 to 15 cm GP2Y0A51SK0F  use 1080
4 to 30 cm GP2Y0A41SK0F / GP2Y0AF30 series  use 430
10 to 80 cm GP2Y0A21YK0F  use 1080
10 to 150 cm GP2Y0A60SZLF use 10150
20 to 150 cm GP2Y0A02YK0F use 20150
100 to 550 cm GP2Y0A710K0F  use 100550
 
 */
 
SharpIR SharpIR(IR, model);
void setup() {
    // Sharp IR code for Robojax.com
 Serial.begin(9600);
 Serial.println("Robojax Sharp IR  ");
}
 
void loop() {
    // Sharp IR code for Robojax.com
    delay(500);   
 
  unsigned long startTime=millis();  // takes the time before the loop on the library begins
 
  int dis=SharpIR.distance();  // this returns the distance to the object you're measuring
 
  // Sharp IR code for Robojax.com
 
  Serial.print("Mean distance: ");  // returns it to the serial monitor
  Serial.println(dis);
  //Serial.println(analogRead(A0));
  unsigned long endTime=millis()-startTime;  // the following gives you the time taken to get the measurement
 Serial.print("Time taken (ms): ");
 Serial.println(endTime);  
     // Sharp IR code for Robojax.com
     
}

ทดสอบที่1.5เมตร มีerror บ้างเนื่องจากแสงภายนอกเช่นหลอดไฟในห้อง
เงื่อนไขอื่นๆ
Tags

วิธีการชำระเงิน

บมจ. ธนาคารกรุงไทย สาขาโรงไฟฟ้าบางปะกง ออมทรัพย์
ธนาคารกรุงเทพ จำกัด (มหาชน) สาขาบิ๊กซี ฉะเชิงเทรา 2 ออมทรัพย์
บมจ. ธนาคารกรุงไทย สาขาบิ๊กซี ฉะเชิงเทรา 2 ออมทรัพย์
พร้อมเพย์ สาขา- -
Scan this!
สนธยา ใจผ่อง
063-xxxxxx-8
Accept All Banks | รับเงินได้จากทุกธนาคาร
พูดคุย-สอบถาม