Vibration and shock detection is useful in security systems, automation, and embedded electronics projects. The SW-420 Vibration Sensor Module is a low-cost and easy-to-use solution designed to detect movement, vibration, and sudden impacts using a mechanical vibration switch and comparator-based circuit. This article will discuss the SW-420 vibration sensor module, including its overview, pinout, specifications, working principle, applications, and more.

The SW-420 is a simple electronic module designed to detect vibration, shock, or sudden movement. The module operates using a mechanical vibration switch that responds when movement exceeds a certain level. This sensor includes an onboard LM393 comparator and an adjustable potentiometer that allows to set the vibration sensitivity. When vibration is detected, the module outputs a digital HIGH or LOW signal, making it easy to interface with microcontrollers such as Arduino, ESP8266, or ESP32. Indicator LEDs are usually included to show power and detection status.

| Pin Name | Pin Label | Description |
| VCC | VCC | Power supply input for the module. Supports 3.3V to 5V DC, making it compatible with most microcontrollers such as Arduino and ESP series. |
| GND | GND | Ground connection. Must be connected to the system ground to complete the circuit. |
| DO | Digital Output | Outputs a digital HIGH or LOW signal. The output changes state when vibration exceeds the sensitivity threshold set by the onboard potentiometer. |
| Model | Type | Voltage | Output | Sensitivity Adj. | Use Case |
| Normally Closed Vibration Sensor Module | Spring vibration switch | 3.3–5V | Digital (NC/NO) | (Fixed) | Simple knock/shock detection |
| DFRobot SEN0433 Vibration Sensor | Enhanced vibration board | 3.3–5V | Digital / Analog* | Adjustable | More stable hobby projects |
| Elecbee Vibration + Relay Module | Vibration + relay output | 5V / 12V | Relay switch | Adjustable | Direct mechanical switching |
| Industrial Vibration Sensor | Heavy-duty industrial sensor | Varies (industrial spec) | Analog / Digital* | Application-specific | Machinery/industrial monitoring |
| Parameter | Specification |
| Product Name | SW-420 Vibration Sensor Module |
| Sensor Type | Mechanical vibration switch (normally closed) |
| Operating Voltage | 3.3V – 5V DC |
| Operating Current | ~15 mA (typical) |
| Output Type | Digital (HIGH / LOW) |
| Comparator IC | LM393 |
| Sensitivity Adjustment | Yes, via onboard potentiometer |
| Output Interface | 3-pin header (VCC, GND, DO) |
| Detection Method | Shock, vibration, knocking, movement |
| Response Time | Fast (mechanical contact-based) |
| Indicator LEDs | Power LED, Output status LED |
| Mounting | Bolt holes for easy installation |
| PCB Size | Approx. 32 mm × 14 mm |
| Operating Temperature | −10 °C to +70 °C (typical) |
| Compatibility | Arduino, ESP8266, ESP32, Raspberry Pi (with logic care) |
| Measurement Type | Threshold-based (not quantitative) |
| Cost & Availability | Low-cost, widely available |

• SW-420 Vibration Sensor - This is the core sensing element of the module. It is a normally closed mechanical vibration switch that reacts to shock, movement, or vibration. When vibration occurs, the internal contact changes state, triggering the detection circuit.
• LM393 Comparator IC - The LM393 compares the vibration signal against a preset threshold. It converts the raw mechanical signal into a clean digital output, ensuring stable and reliable detection.
• Potentiometer (10K Trimmer) - The potentiometer allows sensitivity adjustment. Turning it changes the threshold level, letting users fine-tune how much vibration is required to trigger the output.
• Power LED - This LED indicates that the module is powered correctly, helping users confirm proper voltage supply during setup.
• Status (Output) LED - The status LED lights up when vibration is detected, providing visual feedback for calibration and testing.
• Resistors and Capacitors - These components stabilize the circuit, limit current, and filter noise to improve signal reliability.
• Pin Header (VCC, GND, DO) - The 3-pin header provides easy connection to microcontrollers, supplying power and delivering the digital output signal.
• PCB with Mounting Holes - The printed circuit board holds all components securely and includes mounting holes for easy installation in enclosures or projects.

The SW-420 Vibration Sensor Module application circuit shows how a mechanical vibration switch is converted into a stable digital signal using an LM393 comparator. The vibration switch is connected to the input side of the comparator through a resistor network. When there is no vibration, the switch remains in its normal state, and the input voltage at the comparator stays below the reference threshold. In this condition, the digital output remains inactive.
When vibration or shock occurs, the internal contacts of the SW-420 vibration switch momentarily change state. This causes a sudden change in voltage at the comparator input. The LM393 compares this changing signal with a preset reference voltage defined by resistors and the adjustable potentiometer. If the vibration signal exceeds the threshold, the comparator switches its output state.
Capacitors in the circuit help filter noise and smooth sudden spikes, preventing false triggering from very small disturbances. The output of the LM393 drives the digital output pin and the status LED, which turns on when vibration is detected. The power LED simply indicates that the module is properly powered. This circuit allows the SW-420 module to reliably detect vibration and provide a clean digital signal that can be easily read by a microcontroller such as Arduino or ESP-based boards.