Skip to content

Instantly share code, notes, and snippets.

@projectweekend
Last active January 17, 2016 18:13
Show Gist options
  • Save projectweekend/05e114ec1bf3843e57f9 to your computer and use it in GitHub Desktop.
Save projectweekend/05e114ec1bf3843e57f9 to your computer and use it in GitHub Desktop.
void writeJSONToSerial(void)
{
String jsonString = "{\"temp_f\":";
jsonString += sensordata.tempF;
jsonString += ",\"temp_c\":";
jsonString += sensordata.tempC;
jsonString += "}";
Serial.println(jsonString);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment