-->
Page 1 of 1

inconsistent readings thingspeak ,arduino mega,esp8266-01

PostPosted: Mon Aug 08, 2016 8:44 am
by oded
hi all.

(i have posted this in the thingspeak support forum as well w/o results so far.)


i try to read last values of 3 field set of Thhingspeak channel.
like that:-
after setting up client with these libraries
#include <WiFiEsp.h>
#include <WiFiEspClient.h>
#include <WiFiEspServer.h>
#include <WiFiEspUdp.h>
#include <ThingSpeak.h> ////<<<<<<<<<<<<<<
etc.
etc.

void loop() {
int field1 = ThingSpeak.readIntField(141045,1);
Serial.println();
delay(1000);
Serial.print("field 1 is: ");
Serial.print(field1);
Serial.println();
int field2 = ThingSpeak.readIntField(141045,2);
Serial.println();
delay(10000);
Serial.print("field 2 is: ");
Serial.print(field2);
Serial.println();
int field3 = ThingSpeak.readIntField(141045,3);
Serial.println();
delay(10000);
Serial.print("field 3 is: ");
Serial.println(field3);
Serial.println();
delay(10000); // Note that the weather station only updates once a minute
;};


PROBLEM:
I set the data to be 600 , 600,600
i get unstable readings (of same line wihch i try to read for testing purposes over the loop),
as follows over the arduino mega serial terminal

field 1 is: 0
[WiFiEsp] Connecting to api.thingspeak.com
[WiFiEsp] TIMEOUT: 605
[WiFiEsp] Disconnecting 0
field 2 is: 0
[WiFiEsp] Connecting to api.thingspeak.com
field 3 is: 600
[WiFiEsp] Connecting to api.thingspeak.com
field 1 is: 600
[WiFiEsp] Connecting to api.thingspeak.com
[WiFiEsp] TIMEOUT: 605
[WiFiEsp] Disconnecting 0
field 2 is: 0
[WiFiEsp] Connecting to api.thingspeak.com
field 3 is: 600
[WiFiEsp] Connecting to api.thingspeak.com
field 1 is: 600
[WiFiEsp] Connecting to api.thingspeak.com
[WiFiEsp] TIMEOUT: 607
[WiFiEsp] Disconnecting 0
field 2 is: 0
[WiFiEsp] Connecting to api.thingspeak.com
field 3 is: 600
[WiFiEsp] Connecting to api.thingspeak.com
field 1 is: 600
[WiFiEsp] Connecting to api.thingspeak.com
[WiFiEsp] TIMEOUT: 605
[WiFiEsp] Disconnecting 0
field 2 is: 0
[WiFiEsp] Connecting to api.thingspeak.com
field 3 is: 600


any body can explain whats wrong here ?

is it low memory of arduino as one suggested somewhere ?

wifi is strong , and all results come ok over http terminal .

thanks
Oded,