Master Vibration Detection with Arduino: A Simple Sensor & LED Setup
Components and supplies
| × | 1 | ||||
![]() |
| × | 3 | |||
![]() |
| × | 1 | |||
![]() |
| × | 1 |
Apps and online services
![]() |
|
About this project
In this project, we will connect Arduino with Vibration sensor and LED. When no vibration is detected, Vibration sensor output is 0 (low voltage),otherwise its output is 1(high voltage)。 If Arduino get 0 (no vibration) from vibration sensor it will turn on green LED and turn off Red LED. If Arduino get 1 from vibration sensor, it will turn on Red LED and turn off green LED.
Code
- Vibration Sensor Module (Code)
Vibration Sensor Module (Code)Arduino
int vib_pin=7;
int led_pin=13;
void setup() {
pinMode(vib_pin,INPUT);
pinMode(led_pin,OUTPUT);
}
void loop() {
int val;
val=digitalRead(vib_pin);
if(val==1)
{
digitalWrite(led_pin,HIGH);
delay(1000);
digitalWrite(led_pin,LOW);
delay(1000);
}
else
digitalWrite(led_pin,LOW);
}
Schematics

Manufacturing process
- Vibration Sensors: Principles, Types, and Industrial Applications
- How PIR Sensor Circuits Work: Design, Operation, and Real‑World Applications
- Understanding the Oxygen (O2) Sensor: Role, Placement, and Failure Signs
- Build a Robust Temperature & Sensor API on Raspberry Pi Using the GY‑91 Module
- Build a Raspberry Pi Home Temperature Monitor with MCP9808, InfluxDB & Grafana
- Emotion Sensor & EEG: Low-Cost Hardware for Real-Time Emotion Detection
- UnifiedWater v1 – Complete Arduino Water Quality Sensor Kit
- Arduino PIR Sensor Halloween Prank: Motion-Triggered Scare with LED Lights & MP3 Audio
- Smart 3D Printed Pet Feeder Powered by Arduino Nano
- SW 420 Vibration Sensor Module: Comprehensive Guide for Arduino & Security Applications



