Sensor Twitter Feed

Sensor Twitter Feed

In this project we use the GrovePi with the Grove LED, DHT, light and sound sensor and tweet the value live to the internet. You can use this example to make a live Sensor Twitter Feed powered by the Raspberry Pi and the GrovePi.

This is a simple example to demonstrate how to use multiple Grove Sensors with GrovePi in your Projects. All the parts used in this project are available in the GrovePi Starter Kit.

Sensor Twitter Feed

Hardware Required

  1. Raspberry Pi
  2. GrovePi
  3. Grove DHT sensor
  4. Grove Light sensor
  5. Grove Sound Sensor
  6. Grove LED
  7. Grove Connection wires

Parts for the sensor twitter feed

Connecting the Sensors

Connect the sound sensor to Port A0, light sensor to Port A1, LED to Port D3 and the DHT sensor to Port D4.

Sensor twitter feed example

Running the Program

In the Raspberry Pi terminal, change directory to GrovePi/Projects/Sensor Twitter Feed:

cd /GrovePi/Projects/Sensor_Twitter_Feed/

In the directory, Run the wifi_twit.py in example python program in root (sudo):

sudo python wifi_twit.py

terminal

You will start getting the data live on Twitter in a few secondsCapture

Source Code

The source code for the example can be found here.

Get Help

Have a question or a problem?  Post it on the forums and we’ll help you out.