- Mon Mar 30, 2015 10:16 am
#13024
If it's any consolation I was getting similar issues. I am sending 100+ characters to the server.
I have an example that is close to yours. I am sending 8 fields, one of which is a sequence number that increments with each GET string sent. I noticed that with ThingSpeak I was losing a significant number of entries - there were large gaps in the sequences.
I modified the arduino code to send the string to a local server and a PHP page that grabbed the data and wrote it to a log file. It still loses entries: somewhere between 10%-20% don't make it through.
I also have a scheme on my Arduino that writes replies from the 8266 to a memory buffer. I have connected the CH_PD pin so that when the 8266 is off the serial lines (i.e CH_PD is logic 0 -
DON'T do this if you have tied CH_PD directly to +ve, which is bad practice anyway, it should go to a 10k pullup resistor) I can write out the contents of the memory buffer.
What I see is stuff like this going from the Arduino to the 8266:
AT+CIPSEND=112
GET 8266.php?key=from_8266&field1=24.1&field2=655&field3=34.0&field4=91&field5=0&field6=8&field7=33 HTTP/1.0and this is what comes back from the 8266:
GET 8266.php?key=from_8266&field1=24.1&field2=655&field3=34.0&field4=91&fi&83
SE HX5pti3T3F<
OK
UnlinkNote: the HTTP/1.0\r\n is needed to talk to ordinary webservers - without this your PHP might not get the data passed to it.