Arduino KY-017 mercury tilt switch module, itĀ uses a small mercury ball that completes the circuit when you tilt the module.Ā
This moduleĀ consists of a mercury switch, a 680Ī© resistor and a LED that will light up when tilt is detected. The mercury ball will open/close the circuit when the module is rotated.
Connect the Power line (middle) and ground (-) to +5 and GND respectively. Connect signal (S) to pin 3Ā on the Arduino.