Ky 010 Broken Light Module
Rs. 28.00 Rs. 34.00
- Product Code: SEN-SPEED
- SKU -
- Availability: In Stock
- For Bulk Order 9962060070
Quick support on WhatsApp (+919962060070) only between morning 11am-4pm, no call will be answered
SPECIFICATIONS: | |
Voltage | 5V |
Dimensions(mm) | 19 x 15 x 8 |
Weight(g) | 3 |
OVERVIEW:
-Voltage 5V
-Photo interruption module triggers a signal when light is blocked between the opening of the sensor.
PACKAGE INCLUDES:
1 PCS x Ky 010 Broken Light Module
//SOURCE CODE TAKEN FROM BELOW LINK
//https://arduinomodules.info/ky-010-photo-interrupter-module/
int Led = 13; // define LED pin
int buttonpin = 3; // define photo interrupter signal pin
int val; //define a numeric variable
void setup()
{
pinMode(Led, OUTPUT); // LED pin as output
pinMode(buttonpin, INPUT); //photo interrupter pin as input
}
void loop()
{
val=digitalRead(buttonpin); //read the value of the sensor
if(val == HIGH) // turn on LED when sensor is blocked
{
digitalWrite(Led,HIGH);
}
else
{
digitalWrite(Led,LOW);
}
}
15 days