1)Object:

In this project, we will use Arduino to get signal from tilt sensor. When sensor is tilt, Arduino will turon LED otherwise the LED will turn off.

2)Devices and parts:

Arduino UNO R3 x 1;
USB cable x 1;
Tilt switch sensor x 1;
Jump wires.

Circuit graph

BUTTON_bb

4)Download sample code from following link:

Get tilt switch Arduino sample code here

Load above code into Arduino IDE and you will see result as following:

5:Result

Put tilt sensor in horizon position,LED is off. See following picture:
IMG_20160620_163658

Tilt the sensor in some angle, LED is on. see following picture:

IMG_20160620_163834

Leave a Reply

WordPress spam blocked by CleanTalk.
Bombax Theme designed by itx