ThingSpeak http error code 0 but data is inserted

14 visualizaciones (últimos 30 días)
Azad Sheikh
Azad Sheikh el 6 de Oct. de 2019
Comentada: rosyid el 20 de Oct. de 2022
Just tried testing esp32 with sim800L on ThingSpeak free channel. Not sure why getting the "http error code 0" because the channel values are getting inserted with new values. It is functioning, but, would be helpful if someone could point out why the http error code 0 is returned ?
int i = ThingSpeak.writeField(myBlowerChannel, 1, temp, myBlowerKey);
value of 'i' is coming '0' but the temp data is getting inserted
  1 comentario
rosyid
rosyid el 20 de Oct. de 2022
Problem reading channel. HTTP error code 0
What can I do to fix this error

Iniciar sesión para comentar.

Respuesta aceptada

Vinod
Vinod el 8 de Oct. de 2019
The most likely situation is that your device is doing multiple updates within the allowed update rate (every 15s as a free user, and every 1s with a paid license). The vast majority of the updates are getting a '0' response code, and that is what you are seeing.
Can you share your arduino sketch so we can suggest the modifications to be made?
  2 comentarios
Vinod
Vinod el 9 de Oct. de 2019
Also, if you have not already seen it, I would reccomend using the library to send data to ThingSpeak. See:
There are examples there that can help you get started with programming the ESP32 correctly.
Azad Sheikh
Azad Sheikh el 12 de Oct. de 2019
Editada: Azad Sheikh el 12 de Oct. de 2019
Hi Vinod
thank you for the answer, appreciate it. Apologies for late reply from my side. issue was indeed because of more frequent data update, I changed it to 15+ secs and it worked. (it was working earlier also but now no error code)
Kind Regards

Iniciar sesión para comentar.

Más respuestas (0)

Comunidades de usuarios

Más respuestas en  ThingSpeak Community

Categorías

Más información sobre REST API en Help Center y File Exchange.

Productos


Versión

R2019b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by