Description
The SW520D Tilt Sensor Module is a compact, low-cost orientation detection board for Arduino and robotics projects. Its sensing element is a SW-520D ball switch: a sealed metal cylinder containing a conductive ball. When the module is upright (in its calibrated orientation), gravity holds the ball against the internal contacts, closing the circuit. When tilted beyond approximately 15°, the ball rolls away and the circuit opens . An onboard LM393 comparator converts this switch state into a clean digital output, and a potentiometer allows threshold adjustment.
The module operates from 3.3V to 5V, with digital output logic consistently documented as HIGH when upright and LOW when tilted . This makes it straightforward to interface with any microcontroller GPIO. Two LEDs provide visual feedback: power, and output state (lit when upright, off when tilted). The PCB measures approximately 32×14mm with a mounting hole.
Critical limitation: This is a binary tilt switch, not an angle-measuring sensor. It cannot report the degree of tilt or distinguish tilt direction . For true dual-axis or angle measurement, use an accelerometer (e.g., ADXL345, MPU6050) or two SW520D modules mounted perpendicular to each other .
Features
-
SW-520D Ball Switch Sensing Element: Sealed, mercury-free switch with omni-directional tilt detection; the switch itself is waterproof and dustproof (IP67 rated for some variants) .
-
LM393 Comparator with Clean Digital Output: Provides stable HIGH/LOW switching with >15mA drive capability for direct MCU or relay module connection .
-
Active-LOW Tilt Output: DO outputs HIGH when upright and LOW when tilted—consistent across multiple independent sources .
-
Adjustable Sensitivity Potentiometer: Onboard trimpot allows threshold fine-tuning for the trigger angle .
-
Wide Voltage Compatibility (3.3V–5V): Works with Arduino, ESP32, Raspberry Pi (digital GPIO), and most platforms .
-
Dual LED Indicators: Power LED and output-state LED (lit upright, off tilted) simplify calibration and troubleshooting .
-
Compact PCB with Mounting Hole: Approx. 32×14mm board for easy installation .
-
Requires Debounce in Software: Ball switches bounce during transitions (10–50ms), so a 50ms debounce delay is recommended .
Technical Specifications
| Parameter | Specification |
|---|---|
| Sensor Element | SW-520D single-ball tilt switch (sealed, waterproof) |
| Comparator IC | LM393 |
| Operating Voltage | 3.3V – 5V DC |
| Output Type | Digital (DO only) |
| Output Logic | HIGH = upright; LOW = tilted |
| Trigger Angle | ~15° from calibrated upright position |
| Output Drive Capability | >15mA |
| PCB Size | Approx. 32 × 14 mm |
| Switch Contact Rating | 20V max, 20mA max (switch element) |




Reviews
There are no reviews yet.