Hi,
I’m having a trouble publishing data to particle/webhook
My Json structure is the following
{“1”:“1”,“2”:“1509981568.000000”,“5”:“17.870001”,“6”:“1014.549377”,“7”:“31.963867”,“8”:“847.000000”,“9”:“3.160000”,“10”:“17.360001”,“11”:“18.850040”,“14”:“5.118750”,“15”:“216.628906”,“31”:“0.000000”,“32”:“57.831329”,“33”:“25.976004”,“34”:“14.024445”,“35”:“302.308136”}
if I compose this Json, the data did not arrive full, It arrives only the 60%, I don’t know why, but I have to split in two json to receive the data
//Building JSON1
String dest = "{";
if(Svtime.length() !=0){ dest = dest + "\"1\":\""+ "1" +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"2\":\""+ Svtime +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"5\":\""+ Stemp +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"6\":\""+ Spress +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"7\":\""+ Shum +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"8\":\""+ Svis +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"9\":\""+ SUV +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"10\":\""+ Stempsoil1 +"\",";}
if(Svtime.length() !=0){ dest = dest + "\"11\":\""+ Shumsoil1 +"\"";}
dest = dest + "}";
//////////////////////////////////Building JSON3///////////////////////////////////
String dest2 = "{";
if(Svtime.length() !=0){ dest2 = dest2 + "\"1\":\""+ "1" +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"2\":\""+ Svtime +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"14\":\""+ Sbatt +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"15\":\""+ Sbattp +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"31\":\""+ SPKrain +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"32\":\""+ SPKgust +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"33\":\""+ SPKwind +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"34\":\""+ SPKknots +"\",";}
if(Svtime.length() !=0){ dest2 = dest2 + "\"35\":\""+ SPKdegrees +"\"";}
dest2 = dest2 + "}";
The result is:
{“1”:“1”,“2”:“1509981568.000000”,“5”:“17.870001”,“6”:“1014.549377”,“7”:“31.963867”,“8”:“847.000000”,“9”:“3.160000”,“10”:“17.360001”,“11”:“18.850040”}
{“1”:“1”,“2”:“1509981568.000000”,“14”:“5.118750”,“15”:“216.628906”,“31”:“0.000000”,“32”:“57.831329”,“33”:“25.976004”,“34”:“14.024445”,“35”:“302.308136”}
Any body know how to reach to send it in only one json?
Thank’s
Eduard