Limits with the length of "uri" when using Ciao | Arduino | Forum

Avatar

Please consider registering
Guest

Search

— Forum Scope —






— Match —





— Forum Options —





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

Register Lost password?
sp_Feed sp_TopicIcon
Limits with the length of "uri" when using Ciao
Avatar
mac
New Member
Forum Posts: 1
sp_UserOfflineSmall Offline
1
August 10, 2017 - 10:02 am
sp_Permalink sp_Print

What limits apply to the length of "uri" when using Ciao to send a URL to ThingSpeak (free account)?

CiaoData data = Ciao.write(CONNECTOR, SERVER_ADDR, uri); // to send the URL to ThingSpeak?

I am using a Arduino Uno with ESP8266 WiFi built in (not a WiFi Shield) to send Temperature/Humidity data from DHTxx sensors.

My code works with 2 sensors (4 data fields) but fails with 3 sensors.

#define CONNECTOR "rest"
#define SERVER_ADDR "api.thingspeak.com"

#define APIKEY_THINGSPEAK   "my key"

 

String uri = "/update?api_key=";
uri += APIKEY_THINGSPEAK;
uri += "&field1=";
uri += String(h1);
uri += "&field2=";
uri += String(t1);
uri += "&field3=";
uri += String(h2);
uri += "&field4=";
uri += String(t2);

CiaoData data = Ciao.write(CONNECTOR, SERVER_ADDR, uri);

Would it better to use

ThingSpeak.writeField(myChannelNumber,1,t1, myWriteAPIKey);

ThingSpeak.writeField(myChannelNumber,2,t2, myWriteAPIKey);

etc

Forum Timezone: America/New_York

Most Users Ever Online: 114

Currently Online:
23 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 252

Vinod: 164

cstapels: 96

piajola: 75

vespapierre: 63

Adarsh_Murthy: 59

Newest Members:

dannymm1

KamorkasOr

GRV2903

Jusikaclaiz

Raymondpoers

ScottDus

Forum Stats:

Groups: 4

Forums: 17

Topics: 1313

Posts: 4565

 

Member Stats:

Guest Posters: 1

Members: 5703

Moderators: 0

Admins: 2

Administrators: Hans, lee