Skip to content

Instantly share code, notes, and snippets.

@davidsulpy
Last active July 19, 2016 15:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davidsulpy/085e7b3dfc9ed8138c2945dc61d04551 to your computer and use it in GitHub Desktop.
Save davidsulpy/085e7b3dfc9ed8138c2945dc61d04551 to your computer and use it in GitHub Desktop.
postBucket() function for >4 sensors
void postBucket()
{
Process isstreamer;
String newjson;
newjson="https://groker.initialstate.com/api/events?accessKey="+accessKey+"&bucketKey="+bucketKey;
newjson+= "&Sensor 1="+sensor_data[0];
newjson+= "&Sensor 2="+sensor_data[1];
isstreamer.begin("curl");
isstreamer.addParameter(newjson);
// Print posted data for debug
Serial.print("Sending data: ");
Serial.println(newjson);
isstreamer.run();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment