Posting to with Python for Android allows you to write your sensor data to the cloud and access the data from browsers anywhere in the world by you or your Facebook friends. Sensors are social too!


  • Access API


  • The example program can be run from the smartphone or emulator.

Steps to Get Started

  1. Goto and join the site using your Facebook login
  2. Goto My Configuration to generate the API Secret
  3. Download to your PC and add your API Key and Secret as per Step 2
  4. Move the modified to the smartphone or emulator
  5. Ensure you have network access as the program will write to the server at
  6. Run the program.
  7. Your data will be available to you and your friends on

import urllib import urllib2 import time import datetime print 'start logging' d = datetime.datetime.utcnow() url = '' # add your key and secret # # lat, lng, and unit are optional # will use default if not provided # # dt is optional # will use server time if not provided values = {'key' : 'change_key', 'secret' : 'change_secret', 'sid': 'light', 'lat' : '1.347343', 'lng' : '103.775859', 'dt' : d.strftime("%Y-%m-%d %H:%M:%S"), 'val' : '100', 'unit' : 'lux' } data = urllib.urlencode(values) req = urllib2.Request(url, data) response = urllib2.urlopen(req) the_page = print the_page print "end logging"


Remember to change the API secret and key before running the program