Suddenly all my devices stopped uploading information to ThingSpeak

조회 수: 2 (최근 30일)
jp Valeo
jp Valeo 2024년 5월 14일
댓글: Christopher Stapels 2024년 5월 14일
I have 4 devices composed by 1 Arduino Nano and 1 SIM808 GPRS Módule which sends information about a facility to ThingSpeak and alarm SMS when some variables meet a certain condition.
Currently the 4 devices continue sending SMS but suddenly stopped uploading information to ThingSpeak on May 9 of this year. They have been placed in different cities, with SIM cards from different providers, for 2 years. Could it be that the way information is uploaded to ThingSpeak has changed?
I tried ingesting a single point into my channel using the browser (based on what was indicated in the documentation) and It worked.
Because of that I think the problem is that the code I use to upload information to Thingspeak no longer works.
The function I created to upload information to thingspeak is below:
//Función en envía datos a la plataforma ThingSpeak
void msj_ThingSpeak(){
wdt_reset();
mySerial.println("AT+CIPSTATUS"); //Consultar el estado actual de la conexión
delay(2000);
mySerial.println("AT+CIPMUX=0"); //Comando configura el dispositivo para una conexión IP única o múltiple. 0 = única
delay(3000);
updateSerial();
wdt_reset();
mySerial.println("AT+CSTT=\"igprs.claro.com.ar\",\"clarogprs\",\"clarogprs999\""); //Configura el APN, usuario y contraseña.
delay(1000);
updateSerial();
mySerial.println("AT+CIICR"); //Comando para realizar una conexión inalámbrica con GPRS o CSD
delay(3000);
updateSerial();
wdt_reset();
mySerial.println("AT+CIFSR"); //Obtener nuestra IP local
delay(2000);
updateSerial();
mySerial.println("AT+CIPSPRT=0"); //Establece un indicador '>' al enviar datos
delay(3000);
updateSerial();
wdt_reset();
mySerial.println("AT+CIPSTART=\"TCP\",\"api.thingspeak.com\",\"80\""); //Indica tipo de conexión, url o dirección IP y puerto de la conexión
delay(6000);
updateSerial();
wdt_reset();
mySerial.println("AT+CIPSEND"); //Envía datos a través de una conexión TCP o UDP
delay(4000);
updateSerial();
wdt_reset();
String datos="GET https://api.thingspeak.com/update?api_key=xxxxxxxxxxxxxxxx&field4=0" + String(promedio);
mySerial.println(datos); //Envía los datos al servidor remoto
delay(4000);
updateSerial();
wdt_reset();
mySerial.println((char)26); //Envía el caracter "Enter"
delay(5000); //Ahora se espera una respuesta
mySerial.println();
updateSerial();
wdt_reset();
mySerial.println("AT+CIPSHUT"); //Cierra la conexión(Desactiva el contexto GPRS PDP)
delay(5000);
updateSerial();
wdt_reset();
Serial.flush(); //Limpiamos puertos serie
mySerial.flush();
}
  댓글 수: 1
Christopher Stapels
Christopher Stapels 2024년 5월 14일
There seem to be several user reporting a change in behavior, though I am aware of no updates on that date. Ill update if I find if anything changed.

댓글을 달려면 로그인하십시오.

답변 (0개)

커뮤니티

더 많은 답변 보기:  ThingSpeak 커뮤니티

카테고리

Help CenterFile Exchange에서 ThingSpeak에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by