Laser_Photoelectric_Switch__SKU__FIT0319_-DFRobot

FIT0319 Laser Photoelectric Switch GAB100M-AK-5V

Introduction

The laser photoelectric switch is a photoelectric switch that is composed of emitter and receptor.The emitter consists of a laser diode,and the laser has the characteristics of high precision, good orientation etc.The receptor consists of a photoelectric element.When receiving the laser pulse, the built-in light conducting.The emitter and receptor can assemble a detector. It can be directly compatible with Arduino to develop related products .Of course,it is also very suitable for photoelectric counting, security, ultra-high vehicle overrun detection etc.

Specifications

NOTE: Class 3R are usually up to 5 mW and involve a small risk of eye damage within the time of the blink reflex. Staring into such a beam for several seconds is likely to cause damage to a spot on the retina.

Tutorial

Connection Diagram

FIT0319 Laser Photoelectric Switch GAB100M-AK-5V Connection Diagram

The output pin of the laser photoelectric switch is connected to pin 10 of the Arduino board.The LED on 13 pin will reflect the state of the output pin.Try to block the laser and watch the effect. The Receptor will output high level when it detects laser signal.

Sample Code

/*!
 * @file  FIT0319.ino
 * @brief  The LED on 13 pin will reflect the state of the output pin of the laser photoelectric switch.
 * @copyright  Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com)
 * @license  The MIT License (MIT)
 * @author  YouYou from DFRobot
 * @version  V1.0
 * @date  2013-05-17
 */

/*
    Connection:
       output pin(black) -- Arduino digital pin 10
       VCC pin(brown) -- VCC(+5V)
       GND pin(blue) -- GND(0V)
*/
int led = 13;
int laserOut = 10;

void setup()
{
   pinMode(led,OUTPUT);
   pinMode(laserOut,INPUT);
}

void loop()
{
   digitalWrite(led,digitalRead(laserOut));
}

FAQ

Q&A Some general Arduino Problems/FAQ/Tips
A For any questions, advice or cool ideas to share, please visit the DFRobot Forum.

More Documents

DFshopping_car1.png Get The Laser Photoelectric Switch GAB100M-AK-5V from DFRobot Store or DFRobot Distributor.

Turn to the Top