Introduction: Tilt Sensor (Raspberry Pi)

Picture of Tilt Sensor (Raspberry Pi)

Basic tutorial of how to setup a Tilt sensor with the Raspberry Pi.

Step 1: Parts

Picture of Parts

RPI 3 –

4 Amp Power Adapter –

16GB Micro SD –

120 pcs jumper cable:

Tilt Sensor:

(ALT) Tilt Sensor:

Step 2: Setup

Picture of Setup

VCC -> 5V


DO -> GPIO 21

Step 3: Code

Picture of Code

1. Upload Script to RPI

2. To run script type: "python"

Step 4: Additional Info

Picture of Additional Info


Glumgad (author)2017-12-24

Yes, you can make a lot of fun toys with a tilt sensor.

Like that for example

About This Instructable




Bio: the Raspberry Pi is Awesome!
More by piddlerintheroot:AIY VISION KIT (Raspberry Pi)Tilt Sensor (Raspberry Pi)Accelerometer (Raspberry Pi)
Add instructable to: