09293690454 0437407566
Batangas City
SENSOR MODULE – KEY SWITCH/ BUTTON
We are one of the largest free online selling communities with thousands of active sellers.
Do you have something to sell? Your next sale might be just a few clicks away.
Based from 899 member feedbacks. We value your suggestions and use it.
This module acts an external control to the Arduino without the need to mount the switch on a breadboard. When the key is pressed the build in LED on pin 13 will be turned off.
Connections:
Pin – = GND, connect to GND of the Arduino
Pin (middel pin) +5 v, connect to Arduino +5
Pin S signal, connect to Arduino pin 10
Use the LED on digital pin 13, and connect the button module input to digital 3, and
when button is pressed, the LED will turn on, otherwise, it will turn off.
int Led=13;
int buttonpin=3;
int val;
void setup()
{
pinMode(Led,OUTPUT);
pinMode(buttonpin,INPUT);
}
void loop()
{
val=digitalRead(buttonpin);
if(val==HIGH)
{
digitalWrite(Led,HIGH)
}
else
{
digitalWrite(Led,LOW)
}
}
This seller has been a member since: Nov. 24, 2015
Member Location:
Total Classifieds: 1021
Why seller feedback is important?
Transact with most credible & reputable sellers
Know the seller you are going to deal with
Claim warranty long after purchasing the item
Warn you and other buyers against scams
Motivates sellers to provide good service