TTGO T-Call ESP32 SIM800L cannot be connected with the Blynk cloud

Hello Pete,

My device use a sim card.

I removed sim card and tested it in another device (mobile wifi router) it work fine.

image

Dear Blynk,

Please assist?

I’ve decided to convert my application to Blynk2.0 and still experiencing cloud connection issues.

image

Thank you in advance!

CODE:

#define BLYNK_PRINT Serial

/* Fill-in your Template ID (only if using Blynk.Cloud) */
#define BLYNK_TEMPLATE_ID "TMPLQj1X4EPh"
#define BLYNK_DEVICE_NAME "ESP32 GSM Test101"
#define BLYNK_AUTH_TOKEN "uNzrsTouC2Lm_CNJo-pSJNXoDgOE2l3D";

// Please select the corresponding model
#define SIM800L_IP5306_VERSION_20200811

// Select your modem:
#define TINY_GSM_MODEM_SIM800
#define TINY_GSM_RX_BUFFER    1024  // Set RX buffer to 1Kb

// Default heartbeat interval for GSM is 60
// If you want override this value, uncomment and set this option:
// #define BLYNK_HEARTBEAT 30

#include <TinyGsmClient.h>
#include <BlynkSimpleTinyGSM.h>

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "uNzrsTouC2Lm_CNJo-pSJNXoDgOE2l3D";

// Your GPRS credentials
// Leave empty, if missing user or pass
char apn[]  = "internet";
char user[] = "";
char pass[] = "";

// set GSM PIN, if any
// #define GSM_PIN "1234"

// Hardware Serial on Mega, Leonardo, Micro
#define SerialAT Serial1

// Set serial for debug console (to the Serial Monitor, default speed 115200)
#define SerialMon Serial

// See all AT commands, if wanted
// #define DUMP_AT_COMMANDS

// Define the serial console for debug prints, if needed
#define TINY_GSM_DEBUG SerialMon

// or Software Serial on Uno, Nano
//#include <SoftwareSerial.h>
//SoftwareSerial SerialAT(2, 3); // RX, TX

#include "utilities.h"

#define relay1 13
#define relay2 13
#define relay3 13
#define relay4 13

#ifdef DUMP_AT_COMMANDS
#include <StreamDebugger.h>
StreamDebugger debugger(SerialAT, SerialMon);
TinyGsm modem(debugger);
#else
TinyGsm modem(SerialAT);
#endif
TinyGsmClient client(modem);

BLYNK_WRITE(V0)
{
  int pinValue = param.asInt(); // assigning incoming value from pin V0 to a variable
  digitalWrite(relay1, !pinValue);
  // process received value
}

BLYNK_WRITE(V1)
{
  int pinValue = param.asInt(); // assigning incoming value from pin V1 to a variable
  digitalWrite(relay2, !pinValue);
  // process received value
}

BLYNK_WRITE(V2)
{
  int pinValue = param.asInt(); // assigning incoming value from pin V2 to a variable
  digitalWrite(relay3, !pinValue);
  // process received value
}

BLYNK_WRITE(V3)
{
  int pinValue = param.asInt(); // assigning incoming value from pin V3 to a variable
  digitalWrite(relay4, !pinValue);
  // process received value
}

void setup()
{
  // Debug console
  Serial.begin(115200);

  pinMode(relay1, OUTPUT);
  pinMode(relay2, OUTPUT);
  pinMode(relay3, OUTPUT);
  pinMode(relay4, OUTPUT);

  digitalWrite(relay1, HIGH);
  digitalWrite(relay2, HIGH);
  digitalWrite(relay3, HIGH);
  digitalWrite(relay4, HIGH);
  
  delay(10);

  setupModem();

  SerialMon.println("Wait...");

  // Set GSM module baud rate and UART pins
  SerialAT.begin(115200, SERIAL_8N1, MODEM_RX, MODEM_TX);

  delay(6000);

  // Restart takes quite some time
  // To skip it, call init() instead of restart()
  SerialMon.println("Initializing modem...");
  modem.restart();
  // modem.init();

  String modemInfo = modem.getModemInfo();
  SerialMon.print("Modem Info: ");
  SerialMon.println(modemInfo);

  // Unlock your SIM card with a PIN
  // modem.simUnlock("1234");
  
  Blynk.begin(auth, modem, apn, user, pass);
}

void loop()
{
  Blynk.run();
}

Best regards,
Chris

1 Like

Have you tried baud rate 9600 instead of 115200 ?

Hi John,

Yes I did…same result.

I’ve never bern able to get a T-Call to connect to Blynk using port 80, even with a variety of different SIM cards.

Pete.

I would recommend esp32 or nodemcu boards instead.

It is an ESP32 board.

Pete.

I know, I meant the one without sim card like the wroom and wrover etc.

Then you’d need to add an external SIM module. The T-Call is a nice elegant way to handle everything in one board, and has the advantage of having with a backup battery option too.

Pete.

You’re absolutely right, I’m using an esp32 wroom and portable 4G router with a very high speed internet. With this method I can connect multiple devices to 1 router.

I agree Pete, the combination - ESP32 Sim combination is great for remote control, remote viewing, remote data applications. All inclusive - sim, wifi, bluetooth, external battery connection etc.

I will test code by adding, “blynk-cloud.com”,8080

other than this I am not sure how to go about this project.

Is there anyway somebody could connect to my pc via teamviewer to assist with faultfinding?

That’s the Legacy URL.

IoT URL is “blynk.cloud”

Pete.

Noted, thank you Pete.

Can you believe this…still no success.

Who do you think I should contact to assist with debugging?

Best regards,
Chris

Have you tried a different SIM card?

Pete.

Also have you tried

Blynk.begin(auth, modem, apn, user, pass)

I have used another sim card but will confirm if they have any restrictions. Blynk connected once and never again. Will keep you posted on the developments!

Thank you.

Hi John, I tested them all.

By the look of it, it must be hardware or sim card.

Code is in order.

Will let you know my findings.

Thank you for the guidance and assistance this far.