I am trying to connect my Arduino Nano to Blynk server using sim800. But in Arduino serial monitor it shows this message and it does not exit Blynk.begin(); command to continue executing commands and shows online device in software. I have attached the images below, please help me.
TinyGSM lib version : 0.12.0
Blynk lib version : 1.3.2
This is my code:
#define BLYNK_TEMPLATE_NAME "xxxxxxxxxxx"
#define BLYNK_AUTH_TOKEN "xxxxxxxxxxxxxxxxxxxx"
#define TINY_GSM_MODEM_SIM800
#define BLYNK_PRINT Serial
#define BLYNK_HEARTBEAT 30
#include <SoftwareSerial.h>
#include <TinyGsmClient.h>
#include <BlynkSimpleTinyGSM.h>
char apn[] = "mcinet";
char user[] = "";
char pass[] = "";
SoftwareSerial sim800Serial (5, 4); // RX, TX
TinyGsm modem(sim800Serial);
BlynkTimer timer;
float sensorTemperature = 20.50;
#define VIRTUAL_PIN_Temp V1
void setup() {
Serial.begin(9600);
sim800Serial.begin(9600);
modem.restart();
Blynk.begin(BLYNK_AUTH_TOKEN,modem,apn,user,pass);
timer.setInterval(10000L,sendFloatData);
}
void sendFloatData(){
if(Blynk.connected()){
sensorTemperature = sensorTemperature + 0.15;
if(sensorTemperature>35.0){
sensorTemperature=20.5;
}
}
Blynk.virtualWrite(V1,sensorTemperature);
Serial.print("sending temp: ");
Serial.print(sensorTemperature,2);
}
void loop() {
Blynk.run();
timer.run();
}```
monitor serial:
```[17282] Connecting to mcinet ...
[23683] Connected to GPRS
[23755] Connecting to blynk.cloud:80
[26316] Redirecting to fral.blynk.cloud:80
[26408] Connecting to fral.blynk.cloud:80
[33196] Ready (ping: 350ms).
[40352] Connecting to fral.blynk.cloud:80
[100260] Connecting to fral.blynk.cloud:8080
[106206] Connecting to fral.blynk.cloud:80
[107610] Ready (ping: 358ms).
[114766] Connecting to fral.blynk.cloud:80
[175304] Connecting to fral.blynk.cloud:8080
[181316] Connecting to fral.blynk.cloud:80
[182902] Ready (ping: 536ms).
[190057] Connecting to fral.blynk.cloud:80```
