Electrical – SW-420 vibration sensor module getting stuck

sensorvibration

I am experimenting with SW-420 vibration sensor modules I just got from China. The digital out pin is supposed to output HIGH when sensor detects vibration, and LOW, when at rest.

There's an onboard LED that is lit when sensor is at rest and goes out when it has detected vibration.

However, with several (sometimes many) attempts at light poking, I can provoke a state when the LED is out constantly, although there is no movement. Usually it takes a light touch to kick it out of this state and the onboard LED lits up to show that the sensor is at rest.

I am wondering if this is a typical behavior of the vibration switch and I should program the firmware accordingly, to detect and handle a situation when the sensor gives uninterrupted HIGH for unreasonable stretch of time.

Best Answer

Looking at some details of the SW-420 vibration switch here, it seems that the switch can be on or off (stable) without vibration and produces pulses when there is vibration.

enter image description here

Related Topic