This template is meant to help you get started with creating a way to view your sensor data.
- Clone or download this repository.
- Download the Allow-Control-Allow-Origin* plugin for Chrome. Delete the default matcher and add this one:
*://localhost*
. - In
index.html
, replace theUSERNAME_HERE
andPASSWORD_HERE
strings - Use the
get_sensor
function to retrieve information from your sensor. If you have multuple sensors, you can add an index parameter to specify which one to do (i.e.get_sensor(callback, index)
).
You will need to set up a simple HTTP server in order to run this code. To do so:
- Install Python from
http://www.python.org
- Using the command prompt (Windows) or terminal (Mac), navigate to the folder your code is in and run the command
python -m SimpleHTTPServer 8000
. - Browse to
http://localhost:8000
. You should see theindex.html
of this repository.