Product DescriptionPhoto interrupter module and a digital interface, built-in 13 LED build a simple circuit to produce.photo-interrupter warning lampIt comes with digital interfaces of the LED, the light blocking access number 3 sensor interfaces,sensing when the light interrupterDevice senses a key signal, LED lights, otherwise off.Routines source code:int Led = 13 ;// define LED Interfaceint buttonpin = 3; // define the photo interrupter sensor interfaceint val ;// define numeric variables valvoid setup(){pinMode (Led, OUTPUT) ;// define LED as output interfacepinMode (buttonpin, INPUT) ;// define the photo interrupter sensor output interface}void loop (){val = digitalRead (buttonpin) ;// digital interface will be assigned a value of 3 to read valif (val == HIGH) // When the light sensor detects a signal is interrupted, LED flashes{digitalWrite (Led, HIGH);}else{digitalWrite (Led, LOW);}}
Home >
Electronic & Electrical
>
Broken Light Module Product Product Product
Broken Light Module Product Product Product
Trade on HiSupplier, Worry Free Guarantee
•Trading safety, secure your money, lower the risk, protect both buyers and suppliers
•HiSupplier is a Chinese multinational company in U.S, it helps to coordination and order landing.
- Product Details
- Company Profile
- Product Reviews
Related Products
Didn't find what you're looking for?
Post Buying Lead or
contact our customer service specialist for help!