Search found 2 matches

by Carlosrod298
Mon Aug 26, 2019 6:14 pm
Forum: Networking 802.15.4 / ZigBee / WIFI / GPRS / 3G / Industrial protocols...
Topic: Example of HTTP Post request for sending json data
Replies: 5
Views: 23017

Re: Example of HTTP Post request for sending json data

I made this code for sending in json format void SendHttpData(){ ////////////////////////////////////////////////// // 1. Switch ON ////////////////////////////////////////////////// error = WIFI_PRO.ON(socket); if (error != 0) { USB.println(F("1. WiFi did not initialize correctly")); ErrCount++; } ...
by Carlosrod298
Mon Aug 26, 2019 5:19 pm
Forum: Programming - API
Topic: Concatenation of strings
Replies: 3
Views: 4154

Re: Concatenation of strings

Hello! You can declare your string like this // example of body for POST request char body[300]; // example of body for POST request char ArrayVars[30]; char float_str[10]; //ID snprintf( body, sizeof(body), "{\"ID\":%s ,",LibeliumID); //Radiation dtostrf( radiation, 1, 3, float_str); //Convert floa...