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.
Hardware Required
- Raspberry Pi
- GrovePi
- Grove DHT sensor
- Grove Light sensor
- Grove Sound Sensor
- Grove LED
- Grove Connection wires
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.
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
You will start getting the data live on Twitter in a few seconds
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.