Updating multiple channel data | ThingSpeak API | Forum

Avatar

Please consider registering
Guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —






— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed sp_TopicIcon
Updating multiple channel data
No permission to create posts
May 22, 2019
12:05 pm
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

Hello All,

I'm new to thingspeak. I created 4 channel for updating data from 4 sensors using TCP connection. I configured below code to acquire and update two channel data. Arduino Serial monitor prints both channel data. But below code only updates single channel in thingspeak cloud i.e DHT22 sensor. Analog channel A0 is not been sent to thingspeeak. How can I modfiy below code to update two channel sensor data ??/
Pls help...Smile

#include ESP8266TEENSY.h
#include DHT.h

//comment out the following line to disable status LEDS when running on batteries
#define EnableLEDs

//Define status indicator LED pins
#define GREEN 24
#define RED 13

//define wifi SSID and password
#define SSID "YOURSSID"
#define PASSWORD "yourpassword"

//define thingspeak address and port
#define HOST_NAME "api.thingspeak.com"
#define HOST_PORT (80)

//define thingspeek channel write key
#define channelKey1 "your_thingspeak_channel_write_API_key"
#define channelKey2 "your_thingspeak_channel_write_API_key"

#define DHTTYPE DHT22 // DHT 22 (AM2302), AM2321

//define DHT sensor pin
#define DHTPIN 16

// Define ESP8266 RESET pin
#define ESPRESETPIN 2

//define structure for returning sensor readings
struct reading {
int h;
int f;
float voltage1;
} reading_r ;

//create ESP8266 instance
ESP8266 wifi(Serial1, 115200);

//initialize DHT
DHT dht(DHTPIN, DHTTYPE);

//initialize other global variables
bool connectStat;
int failCount;
bool espPresent = false;

void setup() {
Serial.begin(115200);
Serial.println(F("Started"));
//set pin mode for status indicator LED pins
pinMode(GREEN, OUTPUT);
pinMode(RED, OUTPUT);

//set pin mode for DHT22 output pin
pinMode(DHTPIN, INPUT_PULLUP);

//SET ESP RESET PIN TO OUTPUT
pinMode(ESPRESETPIN, OUTPUT);

//reset ESP8266
digitalWrite(ESPRESETPIN, LOW);
delay(20);
digitalWrite(ESPRESETPIN, HIGH);

//wait for ESP status
if (recFind("ready", 5000)){
Serial.println(F("Ready"));
//set ESP8266 to station mode
if (wifi.setOprToStation()){
Serial.println(F("Station mode enabled"));
Serial.println(F("ESP initialized"));
flushSerial();
flashLED(GREEN, 1);
initEsp();
espPresent = true;
}
}
else{
Serial.println(F("ESP not found"));
Serial.println(F("...check ESP UART Speed"));
Serial.println(F("...verify ESP LED activity"));
flashLED(RED, 5);
}

}

void loop() {
if (espPresent){
//read sensor
reading_r = readSensor();
//send message
sendMessage();
//put ESP to sleep
Serial.println(F("Put ESP to sleep"));
bool espAsleep = false;
while (!espAsleep){
Serial1.println(F("AT+SLEEP=2")); //put the ESP8266 to sleep
if (recFind("OK", 5000)){
Serial.println(F("ESP sleeping"));
espAsleep = true;
}
else {
Serial.println(F("ESP failed to sleep"));
flushSerial();
}
}
delay(900000); //delay 15 minutes
Serial.println(F("Initialize ESP"));
initEsp();
}
}

//function to flush software serial read buffer
void flushSerial(){
while (Serial1.available() > 0){
Serial1.read();
}
}

//function to flash LEDs a specified number of times
void flashLED(uint8_t color, uint8_t flashCount){
#ifdef EnableLEDs
for (uint8_t flsh = 0; flsh < flashCount; flsh++ ){
digitalWrite(color, HIGH);
delay(150);
digitalWrite(color, LOW);
delay(100);
}
#endif
}

//Bool function to seach Serial RX buffer for string value
bool recFind(String target, uint32_t timeout)
{
char rdChar;
String rdBuff = "";
unsigned long startMillis = millis();
while (millis() - startMillis 1){
rdChar = Serial1.read();
rdBuff += rdChar;
if (rdBuff.indexOf(target) != -1) {
break;
}
}
if (rdBuff.indexOf(target) != -1) {
break;
}
}
if (rdBuff.indexOf(target) != -1){
return true;
}
return false;
}

//function to reset ESP
void initEsp(){
bool espReady = false;
bool resetStatus = false;
while (!resetStatus){
//reset ESP
digitalWrite(ESPRESETPIN, LOW);
delay(300);
digitalWrite(ESPRESETPIN, HIGH);
//wait for esp ready
if (recFind("ready", 5000)){
Serial.println(F("ESP Ready"));
espReady = true;
flashLED(GREEN, 2);
}
else {
Serial.println(F("ESP not ready"));
flashLED(RED, 2);
}
//check wifi connection
if (espReady){
//wait for wifi connection
bool wifiJoined = false;
if (recFind("GOT IP", 5000)){
wifiJoined = true;
}
if (wifiJoined){
Serial.println(F("Wifi connected"));
flashLED(GREEN, 3);
resetStatus = true;
Serial.print("IP:");
Serial.println(wifi.getLocalIP().c_str());
}
//join wifi if not connected
else {
Serial.println(F("wifi not joined"));
//check to see if esp is responding
if (wifi.kick()){
Serial.println(F("ESP is up"));
Serial1.println(F("AT+CWJAP?"));
if (recFind("No AP", 5000)){
Serial.println(F("No AP configured"));
flushSerial();
//join wifi
if (wifi.joinAP(SSID, PASSWORD)){
Serial.println(F("wifi joined"));
flashLED(GREEN, 3);
resetStatus = true;
Serial.print("IP:");
Serial.println( wifi.getLocalIP().c_str());
}
else {
Serial.println(F("failed to join wifi"));
flashLED(RED, 3);
}
}
else {
Serial.println(F("no response to AT+CWJAP command"));
flashLED(RED, 3);
}
}
else {
Serial.println(F("ESP didn't respond to kick"));
flashLED(RED, 3);
}
}
}
flushSerial();
}
}

struct reading readSensor(){
uint8_t sumReadHUM = 100;
uint8_t sumReadTMP = 100;
uint8_t trashReadHUM = 0;
uint8_t trashReadTMP = 0;
//Enable DHT22 VCC pin
pinMode(DHTPIN, INPUT);
delay(100);
Serial.println(F("read sensor"));
int sensorvalue = analogRead(A0);

//read sensor and discard first reading
trashReadTMP += dht.readTemperature(true);
trashReadHUM += dht.readHumidity();
delay(2200);
//read sensor 2 more times and average
sumReadTMP += dht.readTemperature(true);
sumReadHUM += dht.readHumidity();
delay(2200);
sumReadTMP += dht.readTemperature(true);
sumReadHUM += dht.readHumidity();
pinMode(DHTPIN, INPUT_PULLUP);
//add readings to struct and return
reading_r.h = (sumReadHUM / 2);
reading_r.f = (sumReadTMP / 2);
reading_r.voltage1 = sensorvalue (3.3 / 4096.0);
Serial.println(reading_r.h);
Serial.println(reading_r.f);
Serial.printin(reading_r.voltage1);
return reading_r;
}

void sendMessage(){
connectStat = 0;
uint8_t disableCount = 0;
while (!connectStat){

//open tcp conncection to thingspeek.com
if (wifi.createTCP(HOST_NAME, HOST_PORT)){
Serial.println(F("TCP connected"));
flashLED(GREEN, 4);

//build data package
String outmessage = "GET /update?key=";
outmessage+=channelKey;
outmessage+="&field1=";
outmessage+=reading_r.h;
/* you can create addditional field definitions to upload more data fields by duplicating the following
* two lines of code and incrementing the 'field#' number in the first line and specifying another variable
* to upload in the second line */
outmessage+="&field2=";
outmessage+=reading_r.f;
//add the rest of the data packet
outmessage+=" HTTP/1.0

";

//find length of outmessage and add 1
int outmessage_len = outmessage.length() + 1;
// Prepare the character array (the buffer)
char outChar[outmessage_len];
// Copy string message to character array for sending
outmessage.toCharArray(outChar, outmessage_len);

//Send data package
if (wifi.send((const uint8_t*)outChar, outmessage_len)){
Serial.println(F("send success!"));
flashLED(GREEN, 5);
flushSerial();
connectStat = 1;
}
else {
Serial.println(F("send failed"));
Serial1.println(F("AT+CIPCLOSE"));
flashLED(RED, 5);
}
}
else {
Serial.println(F("socket error"));
Serial1.println(F("AT+CIPCLOSE"));
flashLED(RED, 4);
}
if (connectStat){
failCount = 0;
disableCount = 0;
}
else {
if (disableCount == 3){
failCount = 0;
disableCount = 0;
connectStat = 1;
}
else {
if (failCount == 3){
flushSerial();
initEsp();
failCount = 0;
disableCount++;
}
else {
failCount++;
}
}
}
flushSerial();
}
}

May 22, 2019
6:15 pm
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

Have you looked at the examples in the ThingSpeak Support Library here: https://github.com/mathworks/thingspeak-arduino ?

Pay special attention to the files:
- ESP-01_AT_Commands_Hardware_Serial_Hookup.pdf
- ESP-01_AT_Commands_SoftSerial_Hookup.pdf

You may be running out of memory to hold the post, or you may be sending a value that ThingSpeak interprets as a string. Use the 'Export Recent Data' button on your channel view to see what is being accepted into your channel.

May 23, 2019
12:03 am
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

On selecting 'Export Recent Data' button, the window displays three types of data format, JSON XML and CSV

May 23, 2019
7:36 am
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

Id look at the JSON, but you can look at whichever makes the most sense to you. All three will show the same data. Is there anything in the field2 location?

May 24, 2019
7:24 am
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

My requirement is to update 2 channel data not multiple field data of a channel.
I modified above code from build data package section for sending 2 channel data

//build data package
String outmessage = "GET /update?api_key=";
outmessage+=channelKey1;
outmessage+="&field1=";
outmessage+=reading_r.h;
outmessage+="&field2=";
outmessage+=reading_r.f;
outmessage+="&field3=";
outmessage+=reading_r.voltage1;

String outmessage2 = "GET /update?api_key=";
outmessage2+=channelKey2;
outmessage2+="&field1=";
outmessage2+=reading_r.voltage2;

//add the rest of the data packet

Serial.println(outmessage);
Serial.println(outmessage2);

outmessage+=" HTTP/1.0

";

//find length of outmessage and add 1
int outmessage_len = outmessage.length() + 1;
// Prepare the character array (the buffer)
char outChar[outmessage_len];
// Copy string message to character array for sending
outmessage.toCharArray(outChar, outmessage_len);

int outmessage2_len = outmessage2.length() + 1;
char outChar2[outmessage2_len];
outmessage2.toCharArray(outChar2, outmessage2_len);

//Send data package
if (wifi.send((const uint8_t*)outChar, outmessage_len) )
{
if (wifi.send((const uint8_t*)outChar2, outmessage2_len) )
{
Serial.println(F("send success!"));
//flashLED(GREEN, 5);
flushSerial();
connectStat = 1;
}
else {
Serial.println(F("send failed"));
Serial1.println(F("AT+CIPCLOSE"));
// flashLED(RED, 5);
}
}
else {
Serial.println(F("socket error"));
Serial1.println(F("AT+CIPCLOSE"));
// flashLED(RED, 4);
}
if (connectStat){
failCount = 0;
disableCount = 0;
}
else {
if (disableCount == 3){
failCount = 0;
disableCount = 0;
connectStat = 1;
}
else {
if (failCount == 3){
flushSerial();
initEsp();
failCount = 0;
disableCount++;
}
else {
failCount++;
}
}
}
flushSerial();
}
}
}

still only one channel updates in thingspeak. In arduino IDE, this code complies and loads into teensy board and serial monitor prints the data along the format.
whats wrong in this code? Pls helpFrown

May 24, 2019
11:28 am
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

Does the number of entries for the second channel increase?

You could try to switch the order of the updates and see if the second channel updates when it is called first. If that works, then perhaps you are calculating the message length wrong and the wifi.send () call is timing out waiting for more characters.
Other than that I haven't found a glaring code issue yet.

You might also try to put a delay between the two wifi.send() calls. If the function is nonblocking, simultaneous calls might confuse it.

You might also try using the ThingSpeak Communication library. It handles much of the background work for you.
The ThingSpeak Communication Library is available on GitHub and the Arduino IDE library manager.
https://github.com/mathworks/thingspeak-arduino

May 27, 2019
10:26 am
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

hello cstapels,

Thanks for your reply.

Does the number of entries for the second channel increase?
Ans: No only one field of data is sent

You could try to switch the order of the updates and see if the second channel updates when it is called first. If that works, then perhaps you are calculating the message length wrong and the wifi.send () call is timing out waiting for more characters.
Other than that I haven't found a glaring code issue yet.
Ans: You are right when second channel called first it updates but channel 1 doesnt update. How could i resolve this

I believe there is some problem in sending data package section
//Send data package
if (wifi.send((const uint8_t*)outChar, outmessage_len) )
{
if (wifi.send((const uint8_t*)outChar2, outmessage2_len) )
{
Serial.println(F("send success!"));
//flashLED(GREEN, 5);
flushSerial();
connectStat = 1;
}
else {
Serial.println(F("send failed"));
Serial1.println(F("AT+CIPCLOSE"));
// flashLED(RED, 5);
}
}
else {
Serial.println(F("socket error"));
Serial1.println(F("AT+CIPCLOSE"));
// flashLED(RED, 4);
}
if (connectStat){
failCount = 0;
disableCount = 0;
}
else {
if (disableCount == 3){
failCount = 0;
disableCount = 0;
connectStat = 1;
}
else {
if (failCount == 3){
flushSerial();
initEsp();
failCount = 0;
disableCount++;
}
else {
failCount++;
}
}
}
flushSerial();
}
}
}

How can i change "if wifi.send()" to include multiple channel data. I think it includes only channel 1.

May 28, 2019
8:09 am
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

This code snippet looks like the ifs are nested. I suggest that you separate the two posting actions and then build up from there.

May 28, 2019
10:13 am
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

can you provide example format of how to separate two post actions and then send data... I searched for the answers on internet but no success.

Does license type matter for data posting to cloud? I have 30 days free trial not an registered user

May 28, 2019
3:15 pm
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

Simplify your code until it does one post successfully. Then copy that block and insert it right after the first block, but change the variables to refer to the second channel's id,keys,and data. Right now, you have them intertwined.

If you want to be really safe, put a bit of delay in between the two blocks.

A paid license will allow you to post once every second for each channel. A free license allows one post every 15 seconds, per channel.
For more information, have a look at the Frequently Asked Questions: (https://thingspeak.com/pages/license_faq)
and How to Buy: (https://thingspeak.com/prices)

June 10, 2019
2:25 am
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

what is the maximum number of fields that a single channel can have in case of Free(Trial) and Paid account?

June 10, 2019
6:39 am
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

I have modified my code to send two channel data, the problem is it is reading sensor data but not posting to thingspeak. Can anybody tel me what is the problem?
#include "ESP8266TEENSY.h"
#include

#define SSID ""// "ITEAD"
#define PASSWORD ""// "12345678"
#define HOST_NAME "api.thingspeak.com"
#define HOST_PORT (80)

String channelKey2 = "6IXQZJ7APKQGKKMI";
String channelKey3 = "HHV800ZCOT0WQ1K8";

struct reading {
float voltage0;
float voltage1;
} reading_r ;

ESP8266 wifi(Serial1 , 115200);
WiFiClient client;
WiFiClient client2;

bool connectStat;
int failCount;
bool espPresent = false;

void setup() {
Serial.begin(115200);
Serial1.begin(115200);
Serial.println(F("Started"));

//wait for ESP status
delay(1000);
flushSerial();
Serial1.println("AT+RST");
if (recFind("ready", 5000)){
Serial.println(F("Ready"));
//set ESP8266 to station mode
Serial1.println("AT+CWMODE=1");
if (recFind("OK", 5000)){
Serial.println(F("Station mode enabled"));
Serial.println(F("ESP initialized"));
initEsp();
espPresent = true;
}
}
else{
Serial.println(F("ESP not found"));
Serial.println(F("...check ESP UART Speed"));
Serial.println(F("...verify ESP LED activity"));
}

}

void loop() {
if (espPresent){
//read sensor
reading_r = readSensor();
//send message
sendDataToThingspeak();
}
}

//function to flush software serial read buffer
void flushSerial(){
while (Serial1.available() > 0){
Serial1.read();
}
}

//Bool function to seach Serial RX buffer for string value
bool recFind(String target, uint32_t timeout)
{
char rdChar;
String rdBuff = "";
unsigned long startMillis = millis();
while (millis() - startMillis 1){
rdChar = Serial1.read();
rdBuff += rdChar;
if (rdBuff.indexOf(target) != -1) {
break;
}
}
if (rdBuff.indexOf(target) != -1) {
break;
}
}
if (rdBuff.indexOf(target) != -1){
return true;
}
return false;
}

//function to reset ESP
void initEsp(){
bool espReady = false;
bool resetStatus = false;
while (!resetStatus){
flushSerial();
//wait for esp ready
Serial1.println("AT+RST");
if (recFind("ready", 5000)){
Serial.println(F("ESP Ready"));
espReady = true;
}
else {
Serial.println(F("ESP not ready"));
}
//check wifi connection
if (espReady){
//wait for wifi connection
bool wifiJoined = false;
if (recFind("GOT IP", 5000)){
wifiJoined = true;
}
if (wifiJoined){
Serial.println(F("Wifi connected"));
resetStatus = true;
}
//join wifi if not connected
else {
Serial.println(F("wifi not joined"));
//check to see if esp is responding
Serial1.println("AT");
if (recFind("OK", 5000)){
Serial.println(F("ESP is up"));
Serial1.println(F("AT+CWJAP?"));
if (recFind("No AP", 5000)){
Serial.println(F("No AP configured"));
flushSerial();
//join wifi
Serial1.print("AT+CWJAP=\"");
Serial1.print(SSID);
Serial1.print("\",\"");
Serial1.print(PASSWORD);
Serial1.println("\"");
if (recFind("GOT IP", 7000)){
Serial.println(F("wifi joined"));
resetStatus = true;
}
else {
Serial.println(F("failed to join wifi"));
}
}
else {
Serial.println(F("no response to AT+CWJAP command"));
}
}
else {
Serial.println(F("ESP not responding"));
}
}
}
flushSerial();
}
}

struct reading readSensor(){
Serial.println(F("read sensor"));
int SV1 = analogRead(A8);
int SV2 = analogRead(A9);

reading_r.voltage0 = SV1 * (3.3 / 4095.0);
reading_r.voltage1 = SV2 * (3.3 / 4095.0);

Serial.println(reading_r.voltage0);
Serial.println(reading_r.voltage1);
return reading_r;
}

void sendDataToThingspeak(void)
{
if (client.connect(HOST_NAME,80)) // "184.106.153.149" or api.thingspeak.com
{

String postStr = channelKey2;
postStr +="&field1=";
postStr += reading_r.voltage0;

postStr += "

";

client.print("POST /update HTTP/1.1
");
client.print("Host: api.thingspeak.com
");
client.print("Connection: close
");
client.print("X-THINGSPEAKAPIKEY: "+channelKey2+"
");
client.print("Content-Type: application/x-www-form-urlencoded
");
client.print("Content-Length: ");
client.print(postStr.length());
client.print("

");
client.print(postStr);

Serial.print("ADC value: ");
Serial.print(reading_r.voltage0);

Serial.println("%. Send to Thingspeak.");
}
client.stop();

if (client2.connect(HOST_NAME,80)) // "184.106.153.149" or api.thingspeak.com
{

String postStr = channelKey3;
postStr +="&field1=";
postStr += reading_r.voltage1;

postStr += "

";

client2.print("POST /update HTTP/1.1
");
client2.print("Host: api.thingspeak.com
");
client2.print("Connection: close
");
client2.print("X-THINGSPEAKAPIKEY: "+channelKey3+"
");
client2.print("Content-Type: application/x-www-form-urlencoded
");
client2.print("Content-Length: ");
client2.print(postStr.length());
client2.print("

");
client2.print(postStr);

Serial.print("ADC value: ");
Serial.print(reading_r.voltage1);

Serial.println("%. Send to Thingspeak.");
}
client2.stop();
Serial.println("Waiting...");

// thingspeak needs minimum 15 sec delay between updates, i've set it to 30 seconds
delay(10000);
}

June 10, 2019
2:28 pm
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

All channels have eight fields. You can enable or disable any of them. There are also Latitude, longitude and status fields that you can use to store other kinds of data as well. The elevation field is fixed as a numeric data type.

Add the field 2 data you your post string to post to two fields at once. Tho code above is probably failing because you aren't waiting between successive updates. If you update the fields simultaneously, you don't have to wait.

String postStr = channelKey2;
postStr +="&field1=";
postStr += reading_r.voltage0;
..
postStr +="&field2=";
postStr += reading_r.otherreadingyouwanttoappend;
...and so on.

We definitely recommend that you use the ThingSpeak Library for Arduino and ESP8266. It will manage many of these requests for you.
https://github.com/mathworks/thingspeak-arduino

June 10, 2019
11:25 pm
Avatar
cmti

Silver
Members
Forum Posts: 11
Member Since:
May 22, 2019
sp_UserOfflineSmall Offline

All channels have eight fields. You can enable or disable any of them. There are also Latitude, longitude and status fields that you can use to store other kinds of data as well. The elevation field is fixed as a numeric data type.

Is that eight fields are fixed for a particular channel? will it change based on licensing type? Whether Latitude and longitude fields can be used to store sensor data?

Add the field 2 data you your post string to post to two fields at once. Tho code above is probably failing because you aren't waiting between successive updates. If you update the fields simultaneously, you don't have to wait.

String postStr = channelKey2;
postStr +="&field1=";
postStr += reading_r.voltage0;
..
postStr +="&field2=";
postStr += reading_r.otherreadingyouwanttoappend;
...and so on.

I implemented your suggestion but no change happened. the program still not posting the two channel data to thingspeak cloud

We definitely recommend that you use the ThingSpeak Library for Arduino and ESP8266. It will manage many of these requests for you.
https://github.com/mathworks/thingspeak-arduino  

June 11, 2019
8:41 am
Avatar
cstapels
Moderator
Members


Moderators
Forum Posts: 691
Member Since:
March 7, 2017
sp_UserOfflineSmall Offline

The 8 fields is fixed for any particular channel and license. You can use the location and status fields to store data, the elevation part of location has a fixed data type.

To debug your post string, I recommend first getting it to work in the browser. Copy the update string from the api-keys tab of your channel view into a browser address field. Then add &field2=VALUE.

Once you get that working, then use Serial.println() to output the post string from your code and make sure it matches the one that you successfully used to update from the browser. The syntax can be tricky, so its best to go in parts.

The ThingSpeak library includes an example of how to write multiple fields, but perhaps not with AP commands, you will have to interpolate.

The moisture example also shows how to build a multiple field posting string: https://www.mathworks.com/help/thingspeak/MoistureMonitor.html

Forum Timezone: America/New_York

Most Users Ever Online: 166

Currently Online:
28 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 272

Vinod: 240

piajola: 95

turgo: 70

vespapierre: 63

Adarsh_Murthy: 62

Member Stats:

Guest Posters: 1

Members: 8665

Moderators: 1

Admins: 2

Forum Stats:

Groups: 3

Forums: 14

Topics: 1600

Posts: 5760

Newest Members:

Sahil Nair, ahancity, samexpert, Senseworks, h-kasiri, kleifimmakly

Moderators: cstapels: 460

Administrators: Hans: 405, lee: 457