Ky 020 Tilt Switch Sensor Module For Arduino
Rs. 14.00 Rs. 17.00
- Product Code: SEN-VIB
- SKU -
- Availability: In Stock
- For Bulk Order 9962060070
Quick support on WhatsApp (+919962060070) only between morning 11am-4pm, no call will be answered
SPECIFICATIONS: | |
Material | FR4 |
Operating Voltage(VDC) | 5 |
Shipment Weight | 0.095 kg |
Shipment Dimensions | 5 × 3 × 2 cm |
OVERVIEW:
-Operating Voltage: 5v DC.
-This module is Small and Simple to use.
-Digital switch output (0 & 1)
-High sensitivity
-Completes the circuit when the module is tilted
-LED lights up when tilt switch is activated
-₹ 60.00 (inc GST)
-₹ 50.85 (+18% GST extra)
PACKAGE INCLUDES:
1 PCS x Ky 020 Tilt Switch Sensor Module For Arduino
//SOURCE CODE TAKEN FROM BELOW LINK
//https://arduinomodules.info/ky-020-tilt-switch-module/
int tiltPin = 2; // pin number for tilt switch signal
int ledPin = 13; // pin number of LED
int tiltState = 0; // variable for reading the tilt switch status
void setup() {
pinMode(ledPin, OUTPUT); // set the LED pin as output
pinMode(tiltPin, INPUT); // set the tilt switch pin as input
}
void loop(){
// get the tilt switch state
tiltState = digitalRead(tiltPin);
// check if tilt switch is tilted.
if (tiltState == HIGH) {
digitalWrite(ledPin, HIGH);
}
else {
digitalWrite(ledPin, LOW);
}
}
15 days